What is AgentGit?
AgentGit, written Agent Git by its authors, is an open-source Python framework that adds Git-style version control to AI agent conversations. It lets developers commit, revert and branch an agent’s state.
The package wraps a LangGraph or LangChain agent in a rollback agent that records checkpoints of its messages and tool calls. When something goes wrong, you roll back to an earlier checkpoint, optionally reversing tool side effects, and the run continues on a new branch. Sessions are organised as external sessions that contain one or more internal sessions, which act as branches.
The documentation credits Li Yang and Wang Siyuan, and the project lists a partnership with the University of Hong Kong’s Lab for AI Agents in Business and Economics. Version 0.2.0-alpha arrived in November 2025, and the repository saw commits into 2026. The README now points production users to a related workflow test bench repository, so expect the project to keep evolving.
Key Features
Rollback with tool reversal is the core of AgentGit, since it restores both the conversation and the outside effects of an agent’s actions.
- Checkpoints: AgentGit saves commit states that capture an agent’s conversation and tool usage at a given moment. Checkpoints can be created manually or automatically after each step, so you always have a restore point.
- State rollback: You can return an agent to any earlier checkpoint and continue from there. The README describes this as travelling back along the agent’s history, which helps when a conversation goes wrong several turns earlier.
- Non-destructive branching: Rolling back creates a new branch instead of deleting later history. The original timeline stays intact, so you can compare two paths from the same checkpoint, much like branches in Git.
- Tool reversal: Developers can register a reverse function for each tool, such as deleting an order the agent created. On rollback, AgentGit calls these functions to undo side effects in databases or external systems.
- Checkpoint diff: A comparison module reports what changed between two checkpoints, including state values, tool invocations and conversation messages. Output can be returned as a dictionary or JSON for logging and review.
- Persistent storage: Sessions and checkpoints are stored through SQLAlchemy, with SQLite as the default and PostgreSQL support in the database configuration. History therefore survives restarts instead of living only in memory.
Pros
Free, inspectable code is the strongest argument for AgentGit: the Apache 2.0 licence lets you add undo and branching to agents without paying for a platform.
- Free and open source: The code is published under the Apache 2.0 licence. Teams can inspect, modify and self-host it without licence fees, paying only for the language model calls their agents make.
- Safer agent experiments: Rollback and branching let you retry a risky step without losing the original run. Developers testing prompts or tool chains can explore alternatives and keep a clean record of each attempt.
- Undo for real actions: Reverse functions give a structured way to compensate for tool side effects. This matters for agents that write to databases, issue refunds or call external APIs during a session.
- Familiar mental model: Commit, revert and branch mirror everyday Git ideas. Engineers who already use version control can reason about agent history quickly, without learning an unfamiliar vocabulary.
- Research backing: The README links a white paper and an academic lab at the University of Hong Kong. It also says the first release was accepted for an AAAI 2026 workshop on language models and multi-agent systems.
Cons
Alpha status is the catch with AgentGit, because the authors themselves describe the release as a pre-release to use with caution.
- Pre-release software: The project labels itself an alpha and asks users to proceed with caution. Interfaces may change between versions, so pin a release and test carefully before relying on it in production.
- Developer-only tool: There is no hosted dashboard or graphical interface. You need Python skills and familiarity with LangChain or LangGraph, which rules it out for non-technical teams wanting a ready-made product.
- Narrow framework support: The documented integration targets LangGraph and LangChain, with OpenAI models as the default configuration. Teams on other agent frameworks would need extra work to adopt it.
- Default credentials: On first run the package creates a default user with a simple, publicly documented password. Change or replace this account before any shared or networked deployment to avoid an obvious security gap.
- Thin support channels: Help comes through GitHub issues, Discord and a Reddit community rather than a support team. Response times are not guaranteed, and the README points to a separate repository for production use.
Who is Using AgentGit?
Python developers and researchers working with LangGraph agents are the intended audience, as the package ships as code rather than a hosted service.
- Agent developers: Engineers building LangGraph agents use it to add checkpoints and undo. It helps them debug multi-step runs without restarting a conversation from the beginning.
- AI researchers: Researchers study agent behaviour by branching from one state and comparing outcomes. The Markov-style framing in the white paper suits experiments with alternative trajectories.
- Prompt and QA testers: Testers run A/B comparisons from a shared checkpoint. They can check how different instructions change an answer while keeping the earlier context identical.
- Operations prototypers: Teams prototyping customer support or order agents test recovery flows. Reverse tools let them undo mistaken refunds or records during trials before production work.
Pricing
AgentGit costs nothing to use, as the code is released under the Apache 2.0 licence with no paid tier (project repository, October 2026).
| Plan | Price | What you get |
|---|---|---|
| Open source | Free | Full source code, pre-release wheel, documentation and examples under Apache 2.0 |
| Model usage | Billed by your provider | An OpenAI-compatible API key is required, so language model calls are charged by that provider |
| Hosting | Your own infrastructure | SQLite by default or PostgreSQL, run on servers you control |
We found no hosted or commercial edition. Budget for model API usage and hosting yourself, and recheck the repository in case a managed offering appears later.
What Makes AgentGit Unique?
Compensating tool reversal is the concrete differentiator. Many agent frameworks can save and reload conversation state, but AgentGit also lets you attach a reverse function to each tool so that rollback can undo database writes or API actions. That pairing of state and side-effect undo is rare in open-source agent tooling.
Its branching model also keeps every timeline. A rollback never overwrites history, which makes the tool useful for audits and experiments where you need to show what an agent did on each path.
Compatibilities and Integrations
LangGraph and LangChain are the frameworks AgentGit documents, with OpenAI-style chat models configured through environment variables.
- Language: Python, installed from a pre-release wheel with pip or uv.
- Frameworks: LangGraph and LangChain agents and tools; the licence note also mentions the Agno ecosystem.
- Models: OpenAI by default, with a configurable base URL for compatible endpoints.
- Storage: SQLAlchemy with SQLite by default and PostgreSQL support.
- Data export: Checkpoint diffs can be produced as dictionaries or JSON.
AgentGit Tutorials
Setting up AgentGit takes six short steps, starting from the wheel file on its GitHub releases page.
- Download the pre-release wheel from the project’s GitHub releases and install it with pip or uv.
- Install LangChain, LangChain OpenAI and LangGraph, then set your OpenAI API key as an environment variable.
- Create a user and an external session, replacing the default account before any shared use.
- Define your tools and, for any with side effects, write a matching reverse function.
- Create a rollback agent or use the simpler AgentService with automatic checkpoints switched on.
- Run the agent, create named checkpoints before risky steps, and roll back or branch when needed.
How We Rated It
AgentGit scores 3.4 out of 5: strong value and flexibility for developers, held back by alpha maturity, limited support and a code-only setup.
| Criterion | Score | Why |
|---|---|---|
| Accuracy and Reliability | 3.4/5 | Alpha release, tests included |
| Ease of Use | 2.8/5 | Python code, wheel install |
| Functionality and Features | 3.8/5 | Rollback, branching, tool reversal |
| Performance and Speed | 3.3/5 | Light SQLite storage |
| Customization and Flexibility | 4.1/5 | Open code, custom reverse tools |
| Data Privacy and Security | 3.2/5 | Self-hosted, default password |
| Support and Resources | 2.7/5 | Docs, Discord, GitHub issues |
| Cost-Efficiency | 4.6/5 | Free, pay only model costs |
| Integration Capabilities | 3.1/5 | LangGraph focus, OpenAI defaults |
| Overall Score | 3.4/5 | Average of the nine criteria |
Summary
AgentGit suits Python developers and researchers who want undo, branching and audit trails for LangGraph agents at no licence cost. Its tool reversal feature is the most useful idea, because it addresses side effects that plain state saving ignores. The main limitation is maturity, as the project is still an alpha with community-only support. Several unrelated projects share similar names, so make sure you install the right package. Try it on a test agent first and change the default user credentials before anyone else can reach the database.

Reviews
Write a Review