Favicon of AgentFlow

AgentFlow

A Python framework for AI agent workflows that connects Codex, Claude, Kimi, and Pi in dependency graphs and runs agents in local Docker or on remote machines.

AgentFlow is a Python framework for developers coordinating coding agents across tasks that depend on one another. It runs Codex, Claude, Kimi, and Pi agents in workflows that can split work and bring the results back together.

  • Dependency graphs: Arrange agents so planning, implementation, and review run in the needed order, with independent tasks running in parallel.
  • Fanout and review cycles: Send work across multiple inputs, merge results by batch or group, and return failed work for revision until it meets a stop condition.
  • Shared context: Give agents a common scratchboard file, or turn a completed Codex run into a reusable tuned agent for local targets.
  • Browser interface: Run pipelines through a web UI that binds to localhost by default.

Agents can run in local Docker containers or on remote machines through SSH, EC2, and ECS. Docker tasks don't inherit host credentials by default. On Linux hosts with KVM access, Cloud Hypervisor offers temporary virtual machines for individual tasks.

Model inference is a separate choice from where an agent runs. Through Pi, AgentFlow can connect to local Ollama and LMStudio endpoints using OpenAI-compatible or Anthropic-compatible protocols. Pi also connects to cloud providers including OpenAI and Anthropic, which receive the model requests sent to them. SkyPilot integration can run shared vLLM or SGLang inference services on supported clouds. AgentFlow is open source under the MIT license.

Similar to AgentFlow