What is InfiAgent?
InfiAgent, also called MLA (Multi-Level Agent), is a Python framework for agents that run for a very long time on complex tasks. It sits in the Agent Frameworks & Builders category of the Agents & Automation tools and is open-source, written in Python and licensed GPL-3.0. To get started: clone and install.
Overview
InfiAgent, also called MLA (Multi-Level Agent), is a Python framework for agents that run for a very long time on complex tasks. Instead of writing agent classes, you describe an agent system in YAML: a tree of agents across levels (a level-3 orchestrator, level-2 specialists, level-1 executors, level-0 tool definitions and a level -1 judge), each with its own prompt and a minimal tool set. The repository ships two ready-made systems — `Researcher`, a multi-level hierarchy that runs literature search, experiments, figures and LaTeX paper writing, and `OpenCowork`, a flatter computer-work assistant for organising folders, building slide decks, processing invoices and writing code inside a chosen workspace.

The design goal stated in the README is to give the model 'short but high-value context for the next step'. Every output — scraped pages, parsed PDFs, sub-agent results — is written to the file system rather than returned into the conversation. An agent keeps only its recent actions, while a separate thinking module periodically summarises the state of the workspace, so the framework does not depend on compressing a growing chat history. Long documents are queried through tools such as `answer_from_pdf` instead of being loaded whole, and a call graph injected into shared context keeps each agent inside its own scope.
State is persisted under a portable data root with atomic writes, so a task interrupted by a crash, network error or Ctrl+C can be resumed with `/resume`, and launching again in the same workspace gives the agent memory of earlier tasks there. Models are reached through LiteLLM with per-agent model choice and multi-provider failover configured in `llm_config.yaml`, and agents can load skills that follow the Agent Skills open standard. The runtime installs from PyPI as `infiagent`, with a CLI, a JSONL streaming mode for IDE plugins and a Python SDK; a Docker image with a web UI is also published. The project is GPL-3.0 and is described in the arXiv paper 'InfiAgent: An Infinite-Horizon Framework for General-Purpose Autonomous Agents' (2601.03204).
What it does
- Agent systems defined entirely in YAML: a multi-level tree of orchestrators, specialists, executors, tools and a judge agent
- File-centric context: outputs go to the workspace and a periodic thinking step summarises state, instead of compressing chat history
- Crash-safe, resumable tasks with atomic state writes, plus workspace-scoped memory across sessions
- Agent Skills open-standard support: drop skill folders into the skills library and agents load them on demand
- Per-agent model selection and multi-provider failover through LiteLLM, set in llm_config.yaml
- Interactive CLI with human-in-the-loop prompts and optional per-tool confirmation, a JSONL streaming mode and a Python SDK
Getting started
InfiAgent needs Python 3.9 or later (3.10+ for MCP support). You can run the published Docker image with its web UI instead of installing anything locally; the steps below follow the README's local install.
Clone and install
python -m venv venv
source venv/bin/activate
git clone https://github.com/polyuiislab/infiAgent.git
cd infiAgent
pip install -e .Install the browser used for web tasks
playwright install chromiumSet your API key
Models, base URLs and per-agent overrides live in llm_config.yaml; copy llm_config.example.yaml to start from the template.
mla-agent --config-set api_key "your-api-key"Start the interactive CLI in a workspace
The workspace path becomes the task ID, so running again in the same folder resumes its memory. Use @agent_name to switch agents and /resume to continue an interrupted task.
cd /your/workspace
mla-agent --cli
Or run a task from a script
mla-agent \
--task_id /path/to/workspace \
--user_input "Your task description" \
--agent_name alpha_agentEmbed it with the Python SDK
from infiagent import infiagent
agent = infiagent(
user_data_root="/abs/path/to/my_root",
default_agent_system="Researcher",
default_agent_name="alpha_agent",
)
result = agent.run(
"Write a survey paper on Transformers",
task_id="/abs/path/to/tasks/transformer_survey",
)
print(result["status"], result["output"])Commands and code are distilled from the project's own documentation — always check the official repo for the latest.
When to use it
- Run a research pipeline end to end — literature search, experiments, figures and a LaTeX paper — over many hours or days

- Give an assistant a working folder to organise files, build slide decks or sort invoices, with memory of past tasks in that folder

- Build a domain-specific agent by editing YAML prompts and tool lists rather than writing agent code
- Drive a long-running agent from an IDE plugin or dashboard through the JSONL stream or the Python SDK
How InfiAgent compares
InfiAgent alongside other open-source agent frameworks & builders tools AI/TLDR tracks, ranked by GitHub stars.
| Tool | Stars | What it does |
|---|---|---|
| DeepSeek Harness | ★ 289k | DeepSeek AI's open-source agent harness (dsh), built on Cordis, where models, tools, skills, sessions, sandboxes, storage and the UI are all plugins composed through profiles. |
| AutoGPT | ★ 188k | One of the earliest autonomous agent projects, now a platform for building and running agents from reusable blocks and workflows. |
| DeerFlow | ★ 86k | ByteDance's open-source super agent harness built on LangGraph: skills, sub-agents, sandboxes, a filesystem and long-term memory for long-horizon research, coding and content tasks. |
| nanobot | ★ 50.5k | Lightweight self-hosted personal AI agent framework in Python, with a WebUI, terminal and chat-app channels, tools, long-term memory, MCP and scheduled automations. |
| LangGraph | ★ 45.6k | A library from the LangChain team for building stateful, graph-based agent workflows with explicit control over steps, memory, and human-in-the-loop checkpoints. |
| Agno | ★ 43.3k | A fast Python framework (formerly Phidata) for building agents with memory, tools, and multimodal inputs, plus a runtime for deploying them in production. |
| AgentGPT | ★ 36.3k | AgentGPT lets you name a custom AI, give it a goal, and watch it plan tasks, run them, and learn from the results, all from a web browser. |
| InfiAgent | ★ 1.2k | A long-horizon agent framework where agents are YAML configs and state lives in files, so tasks can run for days and resume after a crash |


