AgentGit

AgentGit is an open-source Python framework that adds Git-style version control to AI agents built with LangGraph and LangChain. Developers can checkpoint conversations, roll back to earlier states, branch into alternative paths and reverse tool side effects. It is an alpha release aimed at technical users. The code is free under Apache 2.0, with model costs billed separately.

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.

  1. Download the pre-release wheel from the project’s GitHub releases and install it with pip or uv.
  2. Install LangChain, LangChain OpenAI and LangGraph, then set your OpenAI API key as an environment variable.
  3. Create a user and an external session, replacing the default account before any shared use.
  4. Define your tools and, for any with side effects, write a matching reverse function.
  5. Create a rollback agent or use the simpler AgentService with automatic checkpoints switched on.
  6. 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.

FAQ

Frequently Asked Questions

Find answers to the most common questions about our services, reviews, tools, platforms, and more.

AgentGit is used to add version control to AI agents. Developers create checkpoints of an agent's conversation and tool calls, roll back to earlier states, branch into alternative paths and reverse tool side effects when an agent makes a mistake.

Yes. AgentGit is open source under the Apache 2.0 licence, so the code is free to use and modify. You still pay your model provider for API calls, and you host the database and application on your own infrastructure.

AgentGit documents support for LangGraph and LangChain agents and tools. Its default setup uses OpenAI chat models through an API key, with a configurable base URL. Teams on other frameworks should expect extra integration work before adopting it.

Not fully. The authors label current releases as alpha and ask users to proceed with caution. The README also points production users to a separate workflow test bench repository, so test thoroughly and pin versions before relying on it.

AgentGit lets you register a reverse function for each tool. When you roll back with tool reversal switched on, it calls those functions to compensate for earlier actions, such as deleting a created record or refunding a payment.

No. GitAgent by Lyzr and the agentsgit package from AgentCulture are separate projects with similar names. AgentGit, or Agent Git, is the LangGraph rollback framework linked to the University of Hong Kong lab and its GitHub repository.

AgentGit stores users, sessions and checkpoints through SQLAlchemy, using SQLite by default with PostgreSQL support. Because you host it yourself, data stays on your infrastructure, but you are responsible for securing access and replacing the default account.

LangGraph's own checkpointers and time travel cover basic state saving without tool reversal. Letta offers persistent agent memory, while LangSmith helps trace and debug runs. For coding agents, Git itself with sandboxed branches remains a simple fallback.

AgentGit is used to add version control to AI agents. Developers create checkpoints of an agent's conversation and tool calls, roll back to earlier states, branch into alternative paths and reverse tool side effects when an agent makes a mistake.

Yes. AgentGit is open source under the Apache 2.0 licence, so the code is free to use and modify. You still pay your model provider for API calls, and you host the database and application on your own infrastructure.

AgentGit documents support for LangGraph and LangChain agents and tools. Its default setup uses OpenAI chat models through an API key, with a configurable base URL. Teams on other frameworks should expect extra integration work before adopting it.

Not fully. The authors label current releases as alpha and ask users to proceed with caution. The README also points production users to a separate workflow test bench repository, so test thoroughly and pin versions before relying on it.

AgentGit lets you register a reverse function for each tool. When you roll back with tool reversal switched on, it calls those functions to compensate for earlier actions, such as deleting a created record or refunding a payment.

No. GitAgent by Lyzr and the agentsgit package from AgentCulture are separate projects with similar names. AgentGit, or Agent Git, is the LangGraph rollback framework linked to the University of Hong Kong lab and its GitHub repository.

AgentGit stores users, sessions and checkpoints through SQLAlchemy, using SQLite by default with PostgreSQL support. Because you host it yourself, data stays on your infrastructure, but you are responsible for securing access and replacing the default account.

LangGraph's own checkpointers and time travel cover basic state saving without tool reversal. Letta offers persistent agent memory, while LangSmith helps trace and debug runs. For coding agents, Git itself with sandboxed branches remains a simple fallback.

Reviews (0)

Write a Review

Write a Review

Your email address will not be published. Required fields are marked *

Your rating *
Select a rating