# Branches and commits

> Understand how an agent keeps its history in branches and commits, and how that lets your team change the agent without changing what customers get.

- Source: https://www.aui.io/help/branches/branches-and-commits
- Section: Branches and going live
- Last updated: November 23, 2026

Every agent keeps its history the way a Git repository does. A **branch** is a line of work on the agent. Each time you push changes from the Agent Builder or the CLI, a new **commit** is added to the branch you are on, tagged with the next number in order. Exactly one commit is **live**: customers get exactly that commit until someone makes another one live.

[Video: Branches, commits and going live (40 seconds)](https://www.aui.iohttps://pxjl3qwxvjcixvl1.public.blob.vercel-storage.com/help/branches/branches-and-commits/walkthrough-ed955afc28c1.mp4)

Video transcript:

> Every agent has branches, and each push adds a commit. The branch pill in the top bar shows which one you are on.
> Click it to open the Branches window. You see each branch, its commits, and which commit is live.
> Compare takes two commits, and the builder explains what changed between them. Nothing is changed by asking.
> New branch starts a draft from any commit, so you can work without touching what customers get.
> When a commit is ready, make it live. Customers get exactly that commit until someone makes another one live.

The developer docs, the API and the CLI call a branch a *version* and a commit a *revision*. They are the same things (`apollo version` is the same command as `apollo branch`).

## Why it works this way

- **Several people can work at once.** Each person can work on their own branch and test it in the Playground while customers keep getting the live commit.
- **Pushing never changes what customers get.** A push only adds a commit. Making a commit live is a separate, deliberate action.
- **Any commit can be made live,** including an older one. That is how you roll back.

## The branch pill

The top bar's breadcrumb ends with the branch pill. It shows the tag of the commit you have open. Select it to open the **Branches** window. A **Beta** chip beside the pill means this branch runs on the [Beta runtime](https://www.aui.io/help/branches/beta-runtime).

What you have open decides three things:

- which commit a new conversation in the Apollo-1 Runtime pane runs against,
- which program files the **Program files** view (`</>`) in the builder shows,
- which branch the Agent Builder works on, and so where your next push lands.

![Close crop of the Playground top bar in dark mode: the AUI logo, then the organization Acme Inc., the workspace Airline Agents, the agent ACME Air Rebooking Agent, and a branch pill with a branch icon and the tag v0.1.](https://www.aui.io/assets/help/branches/branches-and-commits/branch-pill.png)

*The branch pill shows the commit you have open.*

## The Branches window

The header counts the agent's branches and commits and names the branch that is open. Below it:

- A search field (**Search by name, user, branch or commit message…**), **Compare** and **New branch**.
- **Currently open**: the branch you are on, pinned at the top.
- **Other branches**: the branch holding the live commit first, then the most recently changed.
- **Archived**, folded at the bottom: branches someone retired, each with **Restore**.

![The Branches window in dark mode over the Playground. The header reads 2 branches in total, 4 commits, Initial Branch is open. Below the search field are the Compare and New branch buttons. The Currently open card is Initial Branch with Draft and Live labels, its newest commit v0.3 and a Pull from button, with 3 commits folded below. Under Other branches, a draft branch named New Version with a Beta chip has one commit, v1.1, and an Open button.](https://www.aui.io/assets/help/branches/branches-and-commits/branches-window.png)

*The open branch is pinned at the top, with other branches listed below it.*

### What a branch card shows

- **Its name and state.** **Draft** means commits can still land on it; **Locked** means they cannot. **Live** means it holds the live commit. Locked and live are independent: a draft branch can hold the live commit.
- **Its newest commit** with the commit message, who pushed it and when, and the commit it was cut from (**from** followed by that commit's tag).
- **How far it is from live.** An up arrow counts commits on this branch that live does not have; a down arrow counts commits on live that this branch does not have.
- **Its commits.** Select the commit count to list them, newest first. The newest carries **HEAD**; the live one carries **Live**.

### What you can do

On a branch card:

| Control | What it does |
|---|---|
| **Open** | Work on this branch. See [Work on another branch, start a draft, and compare commits](https://www.aui.io/help/branches/work-on-another-branch). |
| **Pull from** | On the open branch only: bring another branch's changes into it. |
| Rocket icon | Make this branch's newest commit live. |
| Pencil icon | **Rename branch**. |
| Lock icon | Lock the branch, or unlock a locked one. |
| Archive icon | **Archive branch**. Not offered on the branch holding the live commit. |

On a commit row:

| Control | What it does |
|---|---|
| The row itself | Open this exact commit. |
| Compare icon | Ask the builder what changed since the previous commit. |
| Branch icon | **New draft from this commit**: start a new branch from it. |
| Merge icon | On another branch's commits: bring that commit into the branch you have open. |
| Rocket icon | Make this commit live. |

Hover over any icon to see what it does. Making a commit live, locking and archiving are covered in [Make a commit live, lock a branch, and roll back](https://www.aui.io/help/branches/make-a-commit-live).
