智能工作流 是 AI Skill Hub 本期精选Agent工作流之一。已获得 5.2k 颗 GitHub Star,综合评分 8.0 分,整体质量较高。我们强烈推荐将其纳入你的 AI 工具库,帮助提升工作效率。
智能工作流 是一套完整的 AI Agent 自动化工作流方案。通过可视化的节点编排,将复杂的多步骤任务拆解为清晰的自动化流程,实现全程无人值守的智能处理。支持与数百种外部服务和 API 无缝集成,适合构建数据处理管线、业务自动化和 AI 辅助决策系统。
智能工作流 是一套完整的 AI Agent 自动化工作流方案。通过可视化的节点编排,将复杂的多步骤任务拆解为清晰的自动化流程,实现全程无人值守的智能处理。支持与数百种外部服务和 API 无缝集成,适合构建数据处理管线、业务自动化和 AI 辅助决策系统。
# 方式一:pip 安装(推荐)
pip install sparrow
# 方式二:虚拟环境安装(推荐生产环境)
python -m venv .venv
source .venv/bin/activate # Windows: .venv\Scripts\activate
pip install sparrow
# 方式三:从源码安装(获取最新功能)
git clone https://github.com/katanaml/sparrow
cd sparrow
pip install -e .
# 验证安装
python -c "import sparrow; print('安装成功')"
# 命令行使用
sparrow --help
# 基本用法
sparrow input_file -o output_file
# Python 代码中调用
import sparrow
# 示例
result = sparrow.process("input")
print(result)
# sparrow 配置文件示例(config.yml) app: name: "sparrow" debug: false log_level: "INFO" # 运行时指定配置文件 sparrow --config config.yml # 或通过环境变量配置 export SPARROW_API_KEY="your-key" export SPARROW_OUTPUT_DIR="./output"
Structured data extraction, instruction calling and agentic workflows with ML, LLM and Vision LLM
Sparrow is an API-first platform for enterprise document intelligence. It combines accurate structured extraction from documents (invoices, statements, tables) with workflow agents and decision agents.
<p align="center"> <img width="300" height="300" src="https://github.com/katanaml/sparrow/blob/main/sparrow-ui/assets/sparrow_logo_5.png"> </p>
<p align="center"> <strong>🚀 <a href="https://sparrow.katanaml.io">Try Sparrow Online</a> | 📖 <a href="#-quickstart">Quick Start</a> | 🛠️ <a href="#️-installation">Installation</a> | 📚 <a href="#-examples">Examples</a> | 🤖 <a href="#-sparrow-agent">Agents</a></strong> </p>
---
The web UI provides a visual interface on top of the same API:
🎯 Universal Document Processing: Handle invoices, receipts, forms, bank statements, tables 🔧 Pluggable Architecture: Mix and match different pipelines (Sparrow Parse, Instructor, Agents) 🖥️ Multiple Backends: MLX (Apple Silicon), Ollama, vLLM, Docker, Hugging Face Cloud GPU 📱 Multi-format Support: Images (PNG, JPG) and multi-page PDFs 🎨 Schema Validation: JSON schema-based extraction with automatic validation 🌐 API-First Design: RESTful APIs for easy integration 💬 Instruction Calling: Text processing, validation, decision making with GPT-OSS, Mistral, Qwen 3.6, etc. 📊 Visual Monitoring: Built-in dashboard and agent workflow tracking 🔒 Enterprise Ready: Rate limiting, usage analytics, commercial licensing available 🚀 Local Vision LLMs: Mistral, Qwen 3.6, DeepSeek OCR, dots.ocr, Gemma 4, etc.
pyenv for version management)```bash
pyenv install 3.12.10 pyenv global 3.12.10
git clone https://github.com/katanaml/sparrow.git cd sparrow/sparrow-ml/llm pip install -r requirements_sparrow_parse.txt
brew install poppler
```bash
python api.py --port 8002
pip install --upgrade pip pip install mlx-vlm --no-cache-dir
bash
pdftoppm -h
</details>
<details>
<summary>🔧 Runtime Issues</summary>
**Memory Errors:**
- Use smaller or MoE models to reduce VRAM footprint
- Enable image cropping: `--crop-size 100`
- Process single pages instead of entire PDFs
**Model Loading Fails:**bash
./sparrow.sh assistant --pipeline "stocks" --query "Oracle"
**JSON Output:**json { "company": "Oracle Corporation", "ticker": "ORCL" }
**Additional Output:** The stock price of the Oracle Corporation is 186.3699951171875. USD ```
```bash
```bash
python -m venv .env_sparrow_parse source .env_sparrow_parse/bin/activate # Linux/Mac
#### Sparrow Parse (Vision LLM) ```bash
pyenv install 3.12.10 pyenv global 3.12.10
**MLX Installation (Apple Silicon):**bash
python api.py ```
Before running pip install -r requirements_sparrow_parse.txt, check your platform. If you are on macOS and want to run MLX backend, go to requirements_sparrow_parse.txt and make sure sparrow-parse[mlx] libary reference is defined. If you are running Sparrow on Linux/Windows, make sure to use sparrow-parse library reference, this will skip MLX related libraries.
```
/inference)curl -X POST 'http://localhost:8002/api/v1/sparrow-llm/inference' \
-H 'Content-Type: multipart/form-data' \
-F 'query=[{"field_name":"str", "amount":0}]' \
-F 'pipeline=sparrow-parse' \
-F 'options=mlx,mlx-community/Qwen2.5-VL-72B-Instruct-4bit' \
-F 'file=@document.pdf'
/instruction-inference)curl -X POST 'http://localhost:8002/api/v1/sparrow-llm/instruction-inference' \
-H 'Content-Type: application/x-www-form-urlencoded' \
-d 'query=instruction: analyze data, payload: {...}' \
-d 'pipeline=sparrow-instructor' \
-d 'options=mlx,mlx-community/Qwen3.6-35B-A3B-8bit'
Visit http://localhost:8002/api/v1/sparrow-llm/docs for interactive Swagger documentation.

| Component | Purpose | Use Case |
|---|---|---|
| **[Sparrow ML LLM](https://github.com/katanaml/sparrow/tree/main/sparrow-ml/llm)** | Main API engine | Document processing pipelines |
| **[Sparrow Parse](https://github.com/katanaml/sparrow/tree/main/sparrow-data/parse)** | Vision LLM library | Structured JSON extraction |
| **[Sparrow Agents](https://github.com/katanaml/sparrow/tree/main/sparrow-ml/agents)** | Workflow orchestration | Complex multi-step processing |
| **[Sparrow OCR](https://github.com/katanaml/sparrow/tree/main/sparrow-data/ocr)** | Text recognition | OCR preprocessing |
| **[Sparrow UI](https://github.com/katanaml/sparrow/tree/main/sparrow-ui/)** | Web interface | Interactive document processing |
| Feature | Sparrow Parse | Sparrow Instructor | Sparrow Agents |
|---|---|---|---|
| **Input** | Documents + JSON schema | Text instructions | Complex workflows |
| **Output** | Structured JSON | Free-form text | Multi-step results |
| **Use Cases** | Data extraction, forms | Summarization, analysis | Enterprise workflows |
| **Validation** | Schema-based | Manual | Custom rules |
| **Complexity** | Simple | Medium | High |
| **Best For** | Invoices, tables, forms | Text processing | Multi-document flows |
sparrow是一个高质量的开源AI工作流项目,支持多种AI任务
AI Skill Hub 为第三方内容聚合平台,本页面信息基于公开数据整理,不对工具功能和质量作任何法律背书。
建议在沙箱或测试环境中充分验证后,再部署至生产环境,并做好必要的安全评估。
⚠️ GPL 3.0 — 强 Copyleft,衍生作品须开源,含专利保护条款,不可闭源使用。
经综合评估,智能工作流 在Agent工作流赛道中表现稳健,质量优秀。如果你已有明确的使用需求,可以直接上手体验;如果还在评估阶段,建议对比同类工具后再做决策。
| 原始名称 | sparrow |
| 原始描述 | 开源AI工作流:Structured data extraction, instruction calling and agentic workflows with ML, L。⭐5.2k · Python |
| Topics | agentic-aicomputer-visiondocumentaihuggingface-transformersllmpython |
| GitHub | https://github.com/katanaml/sparrow |
| License | GPL-3.0 |
| 语言 | Python |
收录时间:2026-06-02 · 更新时间:2026-06-02 · License:GPL-3.0 · AI Skill Hub 不对第三方内容的准确性作法律背书。
选择 Agent 类型,复制安装指令后粘贴到对应客户端