# Antigravity

> Import Antigravity CLI, Antigravity 2.0, and Antigravity IDE history, including tool calls and token usage where Antigravity saved them.

Antigravity keeps separate local histories for its CLI, the Antigravity 2.0
app, and the IDE. Import all three source IDs to cover every place you use it.

## Source IDs

| Source            | Use it for                                                                            |
| ----------------- | ------------------------------------------------------------------------------------- |
| `antigravity-cli` | Antigravity CLI transcript logs, conversation databases, task files, and usage data.  |
| `antigravity`     | Antigravity 2.0 readable records, conversation databases, task files, and usage data. |
| `antigravity-ide` | Antigravity IDE transcript logs, conversation databases, task files, and usage data.  |

## How the import works

Hansard reads each of the three Antigravity histories separately. The CLI
source reads terminal transcript logs and task, plan, and walkthrough files.
The `antigravity` source reads the records Antigravity 2.0 saves, and the IDE
source reads editor logs and a database for each conversation. Each source uses
the session IDs Antigravity recorded to rebuild messages, tool calls and
results, status notices, the working directory, and any model and token data.

When a readable transcript log exists, Hansard uses it for the conversation.
Without one, Hansard rebuilds the conversation from the step types it can read
in the conversation database: your messages and the agent's responses, tool
calls and results, errors, notifications, and subagent launches. The database
also supplies the model and token counts for each response. Step types Hansard
does not recognize are counted and kept in the archive's copy of the original
files. Sessions from the CLI, the app, and the IDE always stay separate
conversations.

Older conversations that Antigravity left only as `conversations/*.pb` files,
summaries, or task files can be recovered through the running app when it still
serves them. With Antigravity open, run:

```sh
hansard import antigravity --recover --since all
```

Hansard asks the app's local language server for each conversation it lists
and for every conversation Hansard knows about only from those older files,
because the app lists a conversation only after it has loaded it. Add
`--session <id>` to recover specific conversations. Recovery only reads, stays
on your computer, keeps each response in the archive, and never stores the
app's access token. A readable transcript log or a complete conversation
database still takes precedence, and later imports keep the recovered
conversation.

## Import and keep current

**Import now**

```sh
hansard import --sources antigravity-cli,antigravity,antigravity-ide --since all
hansard index rebuild
```

**Keep current**

With **Automatic** source selection, the watcher already includes all three
sources. With a **Custom** list, enable them. The watcher picks them up within 30 seconds:

```sh
hansard config sources enable antigravity-cli,antigravity,antigravity-ide
```

## Review the import in the app

1. When the import finishes, open **Conversations** and select **Filter & sort**.
2. Set **Source** to **Antigravity CLI, Antigravity 2.0, or Antigravity IDE** and set **Time** to the window you imported. Use **Folder** to narrow the list when you use this harness in several projects.
3. Select a conversation to check its messages, tool calls, files, commits, model, and token usage.

To keep archiving new sessions from a local harness, open **Settings → Imports**. **Automatic** follows every supported harness installed on this computer. **Custom** lets you turn individual harnesses on or off. Cloud sources and account exports never run from here; each needs its own import command. If a conversation you expect is missing after you reset the filters, run the import command on this page again with `--explain-skips` where the source supports it.

## What Hansard preserves

- Transcript messages, tool calls and results, status notices, task files, and
  exit codes.
- Subagent runs, each linked to its child conversation.
- System, checkpoint, history, generated-message, and error notices.
- Conversation database steps, including tool activity, when no readable
  transcript log exists.
- Recorded response models and input, output, cache-write, cache-read, and
  reasoning counters from the conversation databases. Reasoning is already
  included in output tokens.
- Model-selection changes as settings history, separate from recorded response
  models. A selection alone does not identify which model answered.
- Generation-start times when present, without treating them as completion
  times.
- Copies of the conversation databases with their `-wal` and `-shm` companion
  files, plus matching annotation files when they exist.

## Known limitations

- Older `conversations/*.pb` files are kept in the archive but not decoded
  directly. Their conversations are readable only through
  `hansard import antigravity --recover` while the app is open, and only when
  the app can still return them; a conversation it cannot return is reported
  and keeps its existing archive.
- A recovered conversation stays partial when the app returns fewer steps than
  it reports or includes step types Hansard does not recognize.
- Database step types Hansard does not recognize are counted and kept, but do
  not appear as messages.
- A tool call with no saved result shows no result. A nonzero exit code counts
  as a failure, even when Antigravity reported a general success status.
- A transcript log takes precedence over database messages. A result absent
  from that log can remain only in the preserved database.
- Transcript-log replay uses preserved logs and generated messages. Replay of
  database-only and language-server captures remains unavailable.
- Native checks covered retained CLI history. The inspected app history was
  empty, and no IDE store or legacy conversation protobuf corpus was present.
  This does not establish history completeness on other devices or accounts.

> **Gemini CLI is a separate source:** Antigravity is Hansard's current integration for Google's coding agents.
> History from the retired Gemini CLI imports through the `gemini-cli` source;
> see [Gemini CLI](https://www.hansard.dev/imports/gemini-cli/).

## Refresh an existing archive

Reimport earlier archives to correct token accounting, remove model attribution
inferred from settings changes, and restore tool usage and generic results for
database-only conversations:

```sh
hansard import --sources antigravity-cli,antigravity,antigravity-ide --since all
hansard index rebuild
```
