Where state lives

Persistent bridge state is written under the canonical Git working-tree root's <repo>/.bridge/. The bridge resolves both --repo and the launch directory to that root, so nested launches cannot create competing state or download folders. An explicit non-Git directory remains its own root.

<repo>/.bridge/
├── config.json       # per-repo settings (includes `provider`: chatgpt | gemini)
├── sessions/<id>/    # metadata.json + append-only events.jsonl transcript
├── logs/<date>.jsonl # prompts, replies, and MCP tool-call summaries
├── checkpoints/      # before/after snapshots around each apply_patch
├── exports/          # /export output
├── downloads/<conv>/ # attachment downloads (default when no --out given)
└── screenshots/      # /screenshot and /ui-qa captures

Plain bridge ask and bridge chrome start do not create repo-local state; they only reuse the shared Chrome profile. The bridge creates <repo>/.bridge/ for persistent TUI sessions, tool-enabled asks (bridge ask --tools), checkpoints, exports, screenshots, or default attachment downloads.

The bridge does not create or manage .bridge/.gitignore; ignore policy belongs to the target repository. Chrome cookies for bridge-driven sessions stay in the shared bridge profile under ~/.ai-browser-bridge/chrome-profile, not under .bridge/.

User-authored config meant to apply across all repos lives in your home directory: custom commands in ~/.ai-browser-bridge/commands/*.md and user-level hooks in ~/.ai-browser-bridge/hooks.json.

Migrating from chatgpt-local-bridge

The package was renamed to ai-browser-bridge. Global user config moved from ~/.chatgpt-local-bridge/ to ~/.ai-browser-bridge/: copy your commands/ folder and hooks.json if you had them. Persistent repo-local state stays at <repo>/.bridge/ (unchanged). Re-run /connector or bridge ask --tools once so ChatGPT picks up the renamed MCP connector app.