能力标签
⚙️
Agent工作流

kestrel-sovereign

基于 Python · 无代码搭建完整 AI 自动化流程
⭐ 7 Stars 🍴 1 Forks 💻 Python 📄 Apache-2.0 🏷 AI 6.0分
6.0AI 综合评分
workflowpython
✦ AI Skill Hub 推荐

经 AI Skill Hub 精选评估,kestrel-sovereign 获评「推荐使用」。这款Agent工作流在功能完整性、社区活跃度和易用性方面表现出色,AI 评分 6.0 分,适合有一定技术背景的用户使用。

📚 深度解析
kestrel-sovereign 是一套完整的 AI Agent 自动化工作流方案。随着 AI 能力的不断提升,基于 Agent 的自动化工作流正在成为提升个人和团队效率的核心方式。区别于传统的 RPA 自动化(模拟鼠标键盘操作),AI Agent 工作流通过理解任务意图、动态规划执行路径,能够处理更复杂的非结构化任务。

kestrel-sovereign 工作流的设计遵循"最小配置,最大复用"原则:核心逻辑已经封装好,用户只需配置自己的 API Key 和业务参数即可快速上手。工作流内置错误处理和重试机制,在网络波动或 API 限速等情况下仍能稳定运行,适合作为生产环境的自动化基础设施。

在实际部署时,建议先在测试环境中运行 3-5 次,验证各个环节的输出结果符合预期,再部署到生产环境。AI Skill Hub 评分 6.0 分,是同类 Agent 工作流中的精选推荐。
📋 工具概览

kestrel-sovereign 是一套完整的 AI Agent 自动化工作流方案。通过可视化的节点编排,将复杂的多步骤任务拆解为清晰的自动化流程,实现全程无人值守的智能处理。支持与数百种外部服务和 API 无缝集成,适合构建数据处理管线、业务自动化和 AI 辅助决策系统。

GitHub Stars
⭐ 7
开发语言
Python
支持平台
Windows / macOS / Linux
维护状态
轻量级项目,按需更新
开源协议
Apache-2.0
AI 综合评分
6.0 分
工具类型
Agent工作流
Forks
1
📖 中文文档
以下内容由 AI Skill Hub 根据项目信息自动整理,如需查看完整原始文档请访问底部「原始来源」。

kestrel-sovereign 是一套完整的 AI Agent 自动化工作流方案。通过可视化的节点编排,将复杂的多步骤任务拆解为清晰的自动化流程,实现全程无人值守的智能处理。支持与数百种外部服务和 API 无缝集成,适合构建数据处理管线、业务自动化和 AI 辅助决策系统。

📌 核心特色
  • 可视化 Agent 工作流编排,无需编写复杂代码
  • 支持多步骤自动化任务链,实现全流程无人值守
  • 与外部 API、数据库和第三方服务无缝集成
  • 内置错误处理与自动重试机制,保障稳定运行
  • 提供可复用的自动化模板,快速在同类场景部署
🎯 主要使用场景
  • 自动化日常重复性工作,将精力集中于创造性任务
  • 构建数据采集 → 处理 → 输出的完整自动化管线
  • 实现跨平台、跨系统的数据流转和业务协同
以下安装命令基于项目开发语言和类型自动生成,实际以官方 README 为准。
安装命令
# 方式一:pip 安装(推荐)
pip install kestrel-sovereign

# 方式二:虚拟环境安装(推荐生产环境)
python -m venv .venv
source .venv/bin/activate  # Windows: .venv\Scripts\activate
pip install kestrel-sovereign

# 方式三:从源码安装(获取最新功能)
git clone https://github.com/KestrelSovereignAI/kestrel-sovereign
cd kestrel-sovereign
pip install -e .

# 验证安装
python -c "import kestrel_sovereign; print('安装成功')"
📋 安装步骤说明
  1. 访问 GitHub 仓库获取工作流文件
  2. 在对应平台(Dify / Flowise / Make 等)中找到「导入工作流」功能
  3. 上传工作流文件
  4. 按照提示配置必要的环境变量和 API Key
  5. 运行测试确认流程正常后投入使用
以下用法示例由 AI Skill Hub 整理,涵盖最常见的使用场景。
常用命令 / 代码示例
# 命令行使用
kestrel-sovereign --help

# 基本用法
kestrel-sovereign input_file -o output_file

# Python 代码中调用
import kestrel_sovereign

# 示例
result = kestrel_sovereign.process("input")
print(result)
以下配置示例基于典型使用场景生成,具体参数请参照官方文档调整。
配置示例
# kestrel-sovereign 配置文件示例(config.yml)
app:
  name: "kestrel-sovereign"
  debug: false
  log_level: "INFO"

# 运行时指定配置文件
kestrel-sovereign --config config.yml

# 或通过环境变量配置
export KESTREL_SOVEREIGN_API_KEY="your-key"
export KESTREL_SOVEREIGN_OUTPUT_DIR="./output"
📑 README 深度解析 真实文档 完整度 79/100 查看 GitHub 原文 →
以下内容由系统直接从 GitHub README 解析整理,保留代码块、表格与列表结构。

Kestrel: Sovereign AI Agent Framework

Build AI agents that nobody can take away from their users — not you, not the cloud, not the next pivot.

Kestrel is a continuously-developing framework for creating autonomous AI agents with cryptographic identity, persistent memory, and constitutional governance. Every agent you deploy is owned by its user, governed by immutable principles, and able to remember across every conversation. The core install is stable enough to run real agents today; the surrounding ecosystem (cloud providers, training adapters, integrations) is actively evolving — see Feature Stability for the current per-feature picture.

🏗️ Architecture Overview

Kestrel agents are built on several key components:

  • Cryptographic Identity: Each agent has a unique DID (Decentralized Identifier)
  • Enhanced Storage: SQLite-based memory with FTS, knowledge graphs, and RAG
  • Multi-Model LLM: Fallback between local (Ollama) and cloud (OpenAI) models
  • Constitutional Governance: Immutable principles with interpretive flexibility
  • Blockchain Anchoring: Optional integrity verification via blockchain

🧪 Experimental — works on the happy path; gaps to know about

  • RunPod GPU orchestration — start/stop/status work; managed-mode log retrieval is NotImplementedError; image generation (!dream) is dead code; integration tests skip in CI without RUNPOD_API_KEY. No active development since early April 2026.
  • Vast.ai GPU marketplace — broader test coverage than RunPod, but recent extraction/revert churn; integration tests skip without VASTAI_API_KEY.
  • GCP Compute GPU VMs — similar maturity to Vast.ai; integration tests skip without GCP_PROJECT_ID.
  • Azure Container Apps deploy — provider stub; not the recommended deploy target.
  • GitHub code introspection — file reading, code search, definition lookup, issue tools all work (48 unit tests). The deeper static-analysis surface promised in docs/architecture/GITHUB_FEATURE_DESIGN.md (call graphs, inheritance trees, dependency analysis) is not implemented.
  • Training (LoRA pipeline) — core ships the protocol + factory; the local-MPS adapter is actively maintained. Cloud-training adapters (RunPod/Vertex/Replicate) work but skip CI without API keys; production-grade adapters are being moved to private packages.

What's in core, what's an add-on

pip install kestrel-sovereign gives you a complete, working sovereign agent: identity, memory, constitution, privacy modes, multi-LLM support, voice (Piper TTS + FasterWhisper STT), local sandboxed compute, and a Cloud Run deployment path. Everything you need to run an agent locally with zero cloud commitment.

Cloud providers (RunPod, Vast.ai), specialized integrations (MCP, GitHub App, wallet), and proprietary training adapters are installable add-ons — separate Python packages that register themselves via entry points. This split is being completed across #462 and #560; current state is documented in KESTREL_FEATURES.md.

Feature management (`kestrel feature`)

Kestrel ships a lean core; everything else is a feature. Cloud providers, training adapters, voice cloud backends, and specialized integrations are installable packages that register themselves via Python entry points.

uv run kestrel feature list                   # Show installed + available features
uv run kestrel feature info <name>            # Detailed info about a feature
uv run kestrel feature install <name>         # Install a feature package
uv run kestrel feature enable <name>          # Enable an installed feature
uv run kestrel feature disable <name>         # Disable without uninstalling
uv run kestrel feature scaffold <name>        # Generate a new feature package skeleton

The canonical inventory of features lives in KESTREL_FEATURES.md; the runtime registry is in kestrel_sovereign/data/feature_registry.toml.

Feature authors import its types directly:

🎯 Core Features

⚠️ Feature Stability (v0.1.8 Beta)

Kestrel covers a wide surface; not all of it ships at the same maturity. Verified 2026-04-25 by reading code, tests, skip markers, and recent git activity:

Prerequisites

  • Python 3.11-3.14
  • uv (for package management)
  • Ollama (optional - for local LLM inference without API keys)

Install uv

If you don't have uv installed:

```bash

Installation

```bash

1. Clone and setup

git clone https://github.com/KestrelSovereignAI/kestrel-sovereign.git cd kestrel-sovereign uv sync # Creates .venv and installs all dependencies

3. Run the setup wizard. Interactive by default; --quickstart

Install from PyPI (no source clone)

The Quick Start above clones the repo so you have demos, examples, and the kestrel.toml.example next to your agent. If you only want to run an agent and don't need the source tree, install from PyPI:

```bash

1. Install the CLI (uv tool install is preferred — `kestrel`

lands on PATH in an isolated venv. Plain `pip install

Pip-installed users invoke the in-package module (the wheel only ships

Clean Install Verification

Kestrel supports multiple installation configurations. Use the verification script to test that clean installs work correctly across all supported scenarios:

```bash

Run all 5 install scenarios (creates isolated venvs)

uv run kestrel verify-install

🚢 Deployment

Kestrel supports multiple deployment targets. See KESTREL_FEATURES.md for the full catalog.

Build and push to GCR (both single-agent and multi_agent images)

uv run kestrel deploy build

Deploy to dev (multi-agent host, always warm) or prod (single-agent, auto-scales)

uv run kestrel deploy dev uv run kestrel deploy prod ```

Profiles live in deploy_config.toml. See docs/deployment/README.md for the full runbook (status, logs, teardown, health).

Auto-deploys on version tags via GitHub Actions.

Docker (Local)

```bash

🚀 Quick Start

accepts every default non-interactively. --quickstart auto-detects

Or hand-edit: cp kestrel.toml.example kestrel.toml

5. (Optional) Create an additional agent. `--quickstart` already

After --quickstart with no step 5, the autostart agent is "Kestrel".

uv run kestrel start # starts every agent with autostart=true uv run kestrel start Kestrel # if you only ran --quickstart uv run kestrel start MyAgent # if you ran step 5 (works regardless of autostart) ```

If you're upgrading from a pre-2026-05 setup that used a standalone llm_config.toml, run uv run kestrel migrate-llm-config to fold it into kestrel.toml [llm]. The legacy file is no longer read.

Your agent is now running. Two ports to know about, depending on which start form you used:

CommandListens onWhy
kestrel start (no name)http://localhost:8888 (the multi-agent **host**)Default in-process multi-agent mode; the host fronts every agent registered with autostart = true at multi_agent.host.port (default 8888). Agents registered with autostart = false aren't loaded — start those by name.
kestrel start <name>the **agent's own port**, printed by the CLI on startEach agent gets the next free slot at or above 8801 (the first auto-assigned agent lands there; subsequent agents go to 8802, etc., or whatever --port you passed to kestrel create). The exact value lives in multi_agent.toml under that agent's entry, and kestrel start <name> prints Starting <name> on :<port>....
Port conflict? Edit the agent's entry in multi_agent.toml to change its port, or recreate the agent with a chosen port (kestrel create MyAgent --port 8899). Edit multi_agent.toml's [host] section to change the host port (default 8888). kestrel start itself doesn't take a --port flag — runtime ports are read from multi_agent.toml.
Test it: Visit the URL the CLI printed on start (http://localhost:8888 for the multi-agent host, or whatever per-agent port kestrel start <name> reported). The Sovereign Console is the default page; append /health for a JSON readiness probe.
Windows users: the CLI prints emoji. If you see UnicodeEncodeError: 'charmap' codec can't encode character ..., run chcp 65001 once in your PowerShell session to switch the console to UTF-8. (As of v0.1.9 the CLI auto-reconfigures stdout, so a fresh install should not hit this.)

💡 Example Applications

Kestrel is a foundation for AI agents that need to outlive any single vendor, deployment, or owner. Concrete deployments and good-fit use cases:

  • Healthcare RPM agents — Constitutional governance over an LLM, persistent patient-owned memory, audit trail for every clinically-relevant action.
  • Long-running personal research agents — Memory accumulates across months without dependency on a single provider's chat history.
  • Custodial agents for sensitive document workflows — Privacy-mode tiers (EPHEMERAL → PUBLIC) let one agent handle both an off-the-record consult and a fully-anchored long-term contract.
  • Multi-agent A2A networks — JSON-RPC 2.0 agent-to-agent protocol lets sovereign agents collaborate without surrendering their identity to a central broker.

2. (Optional) Start Ollama for local models - skip if using cloud APIs

ollama serve ollama pull llama3.2:3b

GOOGLE_API_KEY) in your shell env, probes Ollama at

kestrel-sovereign` works too, into whichever venv is active.)

uv tool install kestrel-sovereign

3. Same wizard as above. Writes .env, kestrel.toml, multi_agent.toml,

Per-Agent Configuration

Each agent can have a kestrel.toml config file in its directory:

```toml

🔧 Configuration

LLM Configuration (`kestrel.toml` `[llm]`)

LLM config lives under the [llm] section of kestrel.toml. The setup wizard (kestrel setup llm) will write it for you; you can also hand-edit kestrel.toml after copying from kestrel.toml.example.

Kestrel uses a vendor/route/model schema. A vendor is who makes the weights; a route is how to reach them (adapter + base URL + auth). API keys belong in .env and are referenced by api_key_env. See kestrel.toml.example and docs/architecture/LLM_SERVICE_ARCHITECTURE.md for the canonical spec.

[llm]
route_priority = ["openai:api", "ollama:local"]

[llm.vendors.openai]
is_cloud = true

[llm.vendors.openai.routes.api]
adapter        = "OpenAIAdapter"
api_key_env    = "OPENAI_API_KEY"
model          = "auto"
selection_hints = ["gpt-5", "mini"]

[llm.vendors.ollama]
is_cloud = false

[llm.vendors.ollama.routes.local]
adapter        = "OllamaAdapter"
host           = "http://localhost:11434"
model          = "auto"
selection_hints = ["llama3.2", "qwen"]
Pre-2026-05 setups used a standalone llm_config.toml at the repo root. That path was removed (epic #938). Run kestrel migrate-llm-config to fold a legacy file into kestrel.toml [llm]; the source is renamed to .bak, your prior kestrel.toml is timestamp-backed-up, and the operation is idempotent.

Environment Variables

See .env.example for a complete list. Key variables:

LLM Providers: - OPENROUTER_API_KEY: OpenRouter API key (recommended - access to multiple providers) - OPENAI_API_KEY: OpenAI API key for cloud models - ANTHROPIC_API_KEY: Anthropic API key for Claude models

Storage: - KESTREL_DB_PATH: Directory where the agent database is stored (default: ./agent_data). This is a directory path -- the database file kestrel_prime.db is created inside it. - KESTREL_DATA_KEY: Fernet encryption key for data at rest

GitHub Integration: - GITHUB_TOKEN: Personal access token for GitHub features - GITHUB_SELF_REPO: Agent's source repository (default: KestrelSovereignAI/kestrel-sovereign)

One-time: set up GCP secrets from .env

uv run kestrel deploy secrets sync

Optional: Full-DB Encryption (SQLCipher)

  • If you install pysqlcipher3 and set KESTREL_DB_KEY, the SQLite connection will use SQLCipher and encrypt the entire DB:
export KESTREL_DB_KEY="your-db-passphrase"
uv run python -m kestrel_sovereign.server
  • Without pysqlcipher3, the system falls back to normal SQLite. File blobs and conversations still encrypt with KESTREL_DATA_KEY if set.

available LLM providers — checks for cloud API keys

(OPENROUTER_API_KEY, ANTHROPIC_API_KEY, OPENAI_API_KEY,

CLI Commands (Cross-Platform)

All commands work on Windows, macOS, and Linux. Pass the agent directory as an argument:

uv run kestrel health                       # Check prerequisites
uv run kestrel create MyAgent               # Create a new agent
uv run kestrel start MyAgent                # Start an agent
uv run kestrel stop MyAgent                 # Stop an agent
uv run kestrel status                       # Show all running agents
uv run kestrel list                         # List available agents
uv run kestrel shell MyAgent                # CLI chat interface
uv run kestrel config ./agent_data/MyAgent  # Show agent config

CLI chat (no server needed)

uv run python -m kestrel_sovereign.main ./agent_data/myagent

The Kestrel SDK lives in its own repo + PyPI package:

kestrel-sovereign-sdk (https://github.com/KestrelSovereignAI/kestrel-sovereign-sdk)

from kestrel_sdk.features.base import Feature, tool

from kestrel_sdk.tools.base import ToolCategory, ToolResult

from kestrel_sdk.hooks.base import Hook, HookEvent

```

Standalone with Ollama (no API keys needed)

docker build -f docker/Dockerfile.standalone -t kestrel-standalone . docker run -p 8888:8888 kestrel-standalone

🧩 OpenAI-Compatible API

The server exposes OpenAI-compatible endpoints for use with third-party clients:

  • GET /v1/models
  • POST /v1/chat/completions

For most users, the built-in Sovereign Console at the printed URL (http://localhost:8888 for the multi-agent host, or the agent's own port for a single-agent start) is the easiest way to interact with your agent (see the Web UI section above). If you prefer an external client, point any OpenAI-compatible tool (e.g., Open WebUI) at your server's /v1/chat/completions endpoint. Use the model name from /v1/models.

Auth: every request to /v1/... requires the X-API-Key header (or Authorization: Bearer <key>). The key was written to .env as KESTREL_API_KEY by kestrel setup (or --quickstart). Most OpenAI-compatible clients let you set the key via their OPENAI_API_KEY env var or settings UI; point that at your KESTREL_API_KEY value.

📚 Key Files Reference

FilePurpose
kestrel_sovereign/cli.pyCanonical kestrel CLI entry point
kestrel_sovereign/server.pyFastAPI agent server (root server.py is a re-export shim for source clones)
host.pyMulti-agent multi_agent host (Cloud Run)
kestrel_sovereign/main.pyDirect interactive REPL (root main.py is a re-export shim for source clones)
kestrel.tomlUnified config (LLM, agents, features). [llm] holds provider config.
KESTREL_FEATURES.mdCanonical feature inventory
kestrel_sovereign/kestrel_agent.pyCore agent logic
kestrel_sovereign/agent_config.pyPer-agent config loader
kestrel_sovereign/inception_service.pyNew agent creation (DID + genesis audit)
kestrel_sovereign/data/feature_registry.tomlRuntime feature registry
agent_data/<name>/kestrel.tomlPer-agent configuration
agent_data/<name>/kestrel_prime.dbAgent database
docs/**/*.mdDetailed documentation

Alternative: Direct Commands

```bash

📚 实用指南(长尾问题)
适合谁
  • 需要让 Claude / Cursor 操作本地工具的 AI 工程师
  • 构建多智能体协作系统的 Agent 开发者
  • 构建企业知识库 / RAG 检索应用的团队
  • 做语音类 AI 产品的开发者
最佳实践
  • 配置 MCP 服务器时建议使用 stdio 传输 + JSON-RPC,避免暴露公网
  • 生产部署优先使用 Docker Compose 隔离依赖,并挂载 volume 持久化数据
  • 本地部署优先选 GGUF 量化模型,节省显存并保持响应速度
  • 分块大小建议 256-512 tokens,向量库优选 pgvector 或 Qdrant
  • Agent 任务先做 dry-run 验证工具调用链,再开启自主执行
常见错误
  • API key 直接提交到 git 仓库(请用 .env 并加入 .gitignore)
  • MCP 配置路径拼错或权限不足,重启 Claude Desktop 才生效
  • 容器内无法访问宿主机 localhost — 使用 host.docker.internal
  • embedding 模型与查询模型不一致导致检索失效
  • 显存不足直接 OOM — 优先降低 context 或换更小的量化模型
  • Python 依赖冲突:建议用 venv / uv 隔离环境
部署方案
  • Docker:kestrel-sovereign 提供官方镜像,docker compose up 一键启动
  • CLI:直接 npm install -g / pip install,命令行调用
  • 本地部署:CPU 8GB 起,GPU 推荐 16GB+ 显存
  • 云端托管:可放在 Vercel / Railway / Fly.io 等 PaaS 平台
相关搜索
kestrel-sovereign 中文教程kestrel-sovereign 安装报错怎么办kestrel-sovereign MCP 配置kestrel-sovereign Docker 部署kestrel-sovereign Agent 工作流kestrel-sovereign 与同类工具对比kestrel-sovereign 最佳实践kestrel-sovereign 适合谁用
⚡ 核心功能
👥 适合谁
  • 需要让 Claude / Cursor 操作本地工具的 AI 工程师
  • 构建多智能体协作系统的 Agent 开发者
  • 构建企业知识库 / RAG 检索应用的团队
  • 做语音类 AI 产品的开发者
⭐ 最佳实践
  • 配置 MCP 服务器时建议使用 stdio 传输 + JSON-RPC,避免暴露公网
  • 生产部署优先使用 Docker Compose 隔离依赖,并挂载 volume 持久化数据
  • 本地部署优先选 GGUF 量化模型,节省显存并保持响应速度
  • 分块大小建议 256-512 tokens,向量库优选 pgvector 或 Qdrant
⚠️ 常见错误
  • API key 直接提交到 git 仓库(请用 .env 并加入 .gitignore)
  • MCP 配置路径拼错或权限不足,重启 Claude Desktop 才生效
  • 容器内无法访问宿主机 localhost — 使用 host.docker.internal
  • embedding 模型与查询模型不一致导致检索失效
👥 适合人群
自动化工程师和运维人员项目经理和业务分析师希望减少重复性工作的专业人士数字化转型团队
🎯 使用场景
  • 自动化日常重复性工作,将精力集中于创造性任务
  • 构建数据采集 → 处理 → 输出的完整自动化管线
  • 实现跨平台、跨系统的数据流转和业务协同
⚖️ 优点与不足
✅ 优点
  • +Apache-2.0 协议,可免费商用
  • +大幅减少重复性人工操作
  • +可视化流程,清晰直观
  • +可扩展性强,支持复杂场景
⚠️ 不足
  • 初始配置和调试需投入一定时间
  • 强依赖外部服务的稳定性
  • 复杂场景需具备一定技术基础
⚠️ 使用须知

AI Skill Hub 为第三方内容聚合平台,本页面信息基于公开数据整理,不对工具功能和质量作任何法律背书。

建议在沙箱或测试环境中充分验证后,再部署至生产环境,并做好必要的安全评估。

📄 License 说明

✅ Apache 2.0 — 宽松开源协议,可商用,需保留版权声明和 NOTICE 文件,含专利授权条款。

🔗 相关工具推荐
📰 相关 AI 新闻
🍿 AI 圈相关吃瓜
🗺️ 相关解决方案
🧩 你可能还需要
基于当前 Skill 的能力图谱,自动补全的工具组合
❓ 常见问题 FAQ
Agent 工作流是以 AI 为核心决策节点的自动化流程,AI 可以根据上下文动态调整执行路径,而不是固定按顺序执行。与普通自动化(如 Zapier)相比,Agent 工作流能处理更复杂、需要判断的场景,但配置要求也相对更高。
💡 AI Skill Hub 点评

AI Skill Hub 点评:kestrel-sovereign 的核心功能完整,质量良好。对于自动化工程师和运维人员来说,这是一个值得纳入个人工具库的选择。建议先在非生产环境试用,再逐步推广。

⬇️ 获取与下载
⬇ 下载源码 ZIP

✅ Apache-2.0 协议 · 可免费商用 · 直接从 aiskill88 服务器下载,无需跳转 GitHub

📚 深入学习 kestrel-sovereign
查看分步骤安装教程和完整使用指南,快速上手这款工具
🌐 原始信息
原始名称 kestrel-sovereign
原始描述 开源AI工作流:Constitutional AI Agent Framework with cryptographic identity (DIDs)。⭐7 · Python
Topics workflowpython
GitHub https://github.com/KestrelSovereignAI/kestrel-sovereign
License Apache-2.0
语言 Python
🔗 原始来源
🐙 GitHub 仓库  https://github.com/KestrelSovereignAI/kestrel-sovereign

收录时间:2026-05-21 · 更新时间:2026-05-22 · License:Apache-2.0 · AI Skill Hub 不对第三方内容的准确性作法律背书。