ohdearquant/lionagi

An intelligence orchestra

What it solves

lionagi provides a governed framework for orchestrating multi-agent workflows. It eliminates the "black box" nature of many agent frameworks by giving users full control over the execution loop, providing typed and inspectable state, and allowing the composition of both API-based models and subscription-based CLI agents (like Claude Code) into a single workflow.

How it works

The framework uses several core concepts to manage agents:

  • Branches: Individual conversation threads containing history, tools, and configuration.
  • Sessions: Coordinators that run DAG (Directed Acyclic Graph) workflows across multiple branches.
  • Flows: Orchestration patterns where a lead agent plans a DAG of specialist workers who execute as dependencies are resolved.
  • Fan-outs: Parallel execution of multiple workers with an optional synthesis pass to combine results.
  • Persistence: Every run is automatically saved to the local filesystem, allowing users to resume, reattach to, or monitor agents in real-time.

Users can interact with the system via a Python API for custom integration or a powerful CLI (li) for rapid deployment of agents and flows. It also includes "Lion Studio," a web-based UI for managing projects, schedules, and execution graphs.

Who it’s for

It is designed for developers and AI engineers who need precise control over agent state and governance, those who want to mix different LLM providers (API and CLI), and teams requiring durable, resumable agent runs with built-in security guardrails.

Highlights

  • Hybrid Provider Support: Seamlessly integrates REST APIs with CLI-based agents (e.g., Claude Code, Codex).
  • Durable Execution: Automatic persistence of all runs, enabling easy resumption and monitoring.
  • Governance Tools: Built-in permission policies for tool calls, guard hooks to block destructive commands, and git-worktree sandboxing.
  • Structured Output: First-class support for Pydantic-based structured responses.
  • Flexible Orchestration: Supports single agents, parallel fan-outs, and complex DAG-based flows.