Documentation
¶
Overview ¶
Package antigravity is the Source adapter for Google Antigravity (AGY) session transcripts under ~/.gemini/antigravity-cli/brain/<uuid> (or $ANTIGRAVITY_HOME/brain/<uuid>): one brain directory per conversation, transcript in .system_generated/logs/transcript.jsonl (or transcript_full.jsonl), and workspace associations tracked in history.jsonl.
Subagents spawned via invoke_subagent are lineage-tracked so the index hides them by default and collapses them to their parent session — the same treatment Claude and Codex subagents receive. Antigravity step records carry step indices, from which this adapter mints deterministic, source-stable message uuids.
Index ¶
Constants ¶
const ID = "antigravity"
ID is the stable source name (source_tool column, --source flag).
Variables ¶
This section is empty.
Functions ¶
func ConfigDir ¶
func ConfigDir() string
ConfigDir returns the Antigravity config directory: $ANTIGRAVITY_HOME if set, else ~/.gemini/antigravity-cli.
func GlobalConfigDir ¶
func GlobalConfigDir() string
GlobalConfigDir returns the Antigravity global customization config directory. On disk the config dir is a SIBLING of the CLI state dir, not a child: ~/.gemini/config sits beside ~/.gemini/antigravity-cli (verified against a live install's builtin hooks doc). A plain join under ANTIGRAVITY_HOME — the Codex shape — would therefore point at the wrong tree, so the basename sniff below maps whichever of the two dirs ANTIGRAVITY_HOME names to its config sibling.
func MintUUID ¶ added in v0.10.0
MintUUID derives a stable per-message id from the session id + step index + line ordinal.
func NormalizeRecord ¶ added in v0.10.0
NormalizeRecord maps one transcript step to (role, flattened-text, ok).
func Registration ¶
func Registration() source.Registration
Registration wires the Antigravity adapter into the source registry.
Types ¶
type Adapter ¶
type Adapter struct {
// contains filtered or unexported fields
}
Adapter reads Antigravity transcripts.
func New ¶
func New() *Adapter
New returns a ready Antigravity adapter using the default config directory.
func (*Adapter) Discover ¶
Discover enumerates every Antigravity conversation under BrainRoot(a.root). Returns (nil, nil) when the brain directory is absent.
func (*Adapter) DiscoverRoot ¶
DiscoverRoot enumerates Antigravity sessions under an explicit brain directory.