@timmyjl12/pi-agy-bridge 0.1.3 → 0.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -4,7 +4,7 @@ Use Google Antigravity models (Gemini, Claude, GPT-OSS) in [pi](https://github.c
4
4
 
5
5
  It follows the design of `pi-claude-code`: **pi keeps the conversation, the approvals and the tool execution; agy is only the model.** Every pi request becomes one ACP prompt turn. When the model wants a pi tool it writes a small tool-call block, pi runs the tool, and the next request carries the result. Nothing is parked between requests, so a slow tool (a long `pytest` run, a user dialog) can take as long as it needs and there is no turn time limit.
6
6
 
7
- > Status: 0.1.3. Every Pi session shutdown now recycles the outgoing runtime instead of permanently latching it shut, so a late pi-advisor retry can start a fresh ACP process; explicit terminal disposal remains terminal. The compatibility probe passed on `agy 1.5.8` and `1.5.9` (identical surface). On 2026-11-14 (agy 1.5.9) the Antigravity backend began refusing pi's default system prompt sent through the append hook with `RESOURCE_EXHAUSTED`; live `gemini-4-hydrogen` turns and pi-subagents runs succeed through the `auto` inline fallback (see `PI_AGY_SYSTEM_PROMPT`). Earlier live bridge checks passed on `agy 1.5.8`. Live turns succeeded on `gemini-3.8-flash`, `gemini-4-hydrogen` (including `xhigh`), and `gemini-pro-orchestrator-g1-pro`. A real pi surface check with the configured extensions also passed. Claude and GPT-OSS have not been exercised in a live model turn.
7
+ > Status: 0.1.5. The default bridge home now honors Pi's configured agent directory (`PI_CODING_AGENT_DIR`). Every Pi session shutdown now recycles the outgoing runtime instead of permanently latching it shut, so a late pi-advisor retry can start a fresh ACP process; explicit terminal disposal remains terminal. The compatibility probe passed on `agy 1.5.8`, `1.5.9` and `1.5.12`; the drift from 1.5.9 to 1.5.12 is additive only (the `gemini-4-neon` family, `gemini-pro-orchestrator-neon`, and `xhigh` as a `thought_level`). The `google-antigravity` SDK is current at `0.1.23` on both PyPI and the SDK repository, and its fingerprint still matches the recorded baseline. On 2026-11-14 (agy 1.5.9) the Antigravity backend began refusing pi's default system prompt sent through the append hook with `RESOURCE_EXHAUSTED`; live `gemini-4-hydrogen` turns and pi-subagents runs succeed through the `auto` inline fallback (see `PI_AGY_SYSTEM_PROMPT`). Earlier live bridge checks passed on `agy 1.5.8`. Live turns succeeded on `gemini-3.8-flash`, `gemini-4-hydrogen` (including `xhigh`), and `gemini-pro-orchestrator-g1-pro`. A real pi surface check with the configured extensions also passed. Claude, GPT-OSS and the `gemini-4-neon` family have not been exercised in a live model turn.
8
8
 
9
9
  ## Requirements
10
10
 
@@ -30,7 +30,8 @@ Models appear as `agy/<id>` in `/model`:
30
30
  | --- | --- |
31
31
  | `agy/gemini-4-argon`, `agy/gemini-3.8-flash`, `agy/claude-opus-5-5`, `agy/claude-sonnet-5-5` | low, medium, high |
32
32
  | `agy/gemini-4-hydrogen` | low, medium, high, xhigh (reported by agy 1.5.8) |
33
- | `agy/gemini-pro-orchestrator-g1-pro` | no selectable reasoning level |
33
+ | `agy/gemini-4-neon` | low, medium, high, xhigh (reported by agy 1.5.12) |
34
+ | `agy/gemini-pro-orchestrator-g1-pro`, `agy/gemini-pro-orchestrator-neon` | no selectable reasoning level |
34
35
  | `agy/gpt-oss-120b-medium` | fixed (medium) |
35
36
 
36
37
  The list is what your agy reports, so new models appear without an update. pi's "off" thinking level is not offered because agy cannot switch thinking off.
package/UPGRADING.md CHANGED
@@ -1,111 +1,121 @@
1
- # Upgrading pi-agy-bridge (agy / SDK drift runbook)
2
-
3
- `agy` ships often (three patch releases in one week of November 2026) and the
4
- `google-antigravity` SDK ships about once a week. None of this needs a model
5
- call or quota: the probes are free.
6
-
7
- ## Triggers
8
-
9
- | Signal | What it means | Go to |
10
- | --- | --- | --- |
11
- | `/agy-bridge doctor`, or the one-time notice shown at the first request, says `untested` / `newer-untested` | a newer agy is installed than the matrix tested | §1, then §3 |
12
- | doctor says `below-minimum`, `known-bad`, `protocol` or `not-agy` | the provider refused to start (it names the fix) | §1 → §4 |
13
- | `npm run compat:probe` exits 1 or 2 | agy's flags/capabilities/models moved | §3 |
14
- | `uv run --project compat/sdk-canary python compat/sdk-canary/canary.py --latest` exits 1 or 2 | the SDK harness contract moved | §5 |
15
- | a contract test or replay fixture fails after an agy update | an ACP exchange changed shape | §4 |
16
- | Windows/uv problems, missing `agy` | environment, not drift | §6 |
17
-
18
- `npm run compat:probe` exit codes: `0` identical, `1` additive only (or no
19
- baseline recorded yet), `2` breaking, `3` the probe could not run. The SDK
20
- canary uses the same codes.
21
-
22
- ## 1. Free drift probe (no prompt, no quota)
23
-
24
- ```powershell
25
- npm run compat:probe # compare installed agy with compat/baselines/agy-<version>.json
26
- npm run compat:probe -- --json # machine-readable (status, breaking[], additive[])
27
- npm run compat:probe -- --record # write compat/baselines/agy-<version>.json
28
- ```
29
-
30
- > **PowerShell:** it consumes the first `--`, so `npm run compat:probe -- --record` silently runs a plain check (and `-- --help` goes to npm). Quote the separator, `npm run compat:probe "--" --record`, or call the script directly: `node compat/probe-cli.ts --record`. The same applies to every `npm run compat:... -- <flag>` in this file; for the SDK canary use `uv run --project compat/sdk-canary python compat/sdk-canary/canary.py --record`.
31
-
32
- The probe uses a temp cwd and `agy acp --gemini-dir <temp>`, so `~/.gemini` is
33
- never written and your login is only used, not copied. It kills only the process
34
- it spawned.
35
-
36
- ## 2. Decide what the drift is
37
-
38
- | Probe result | Meaning | Action |
39
- | --- | --- | --- |
40
- | `identical` | nothing changed | done |
41
- | `additive` | new flags / capabilities / models / config values | review the list (for new models, also check what a real session accepts, see `tests/model-catalog.test.ts`), `-- --record`, add the version to `compat/matrix.json` (§4), commit both |
42
- | `breaking` (removed flag, capability, config option or value, model id, auth method; changed protocolVersion or agent name) | the adapter may now be wrong | **stop**. Read `agy changelog`, adjust the adapter, add/re-record the replay fixture, run `node --test tests/features.test.ts tests/probe.test.ts`, and only then re-record baselines |
43
- | `no baseline` | first run on a new major/minor | `-- --record` after reviewing the printed summary |
44
-
45
- Never re-record a baseline to make a red probe green: it is the reviewed
46
- "known good", not a snapshot of whatever happens to be installed.
47
-
48
- ## 3. Tests after an agy change
49
-
50
- ```powershell
51
- node --test tests/features.test.ts tests/probe.test.ts
52
- npm test # whole package (needs the other suites to exist)
53
- npm run check # tsc --noEmit
54
- ```
55
-
56
- `features.test.ts` pins feature negotiation against the recorded 1.5.3
57
- `initialize` result and its mutations. `model-catalog.test.ts` covers the
58
- `session/new` catalog captured from agy 1.5.8, including per-model `xhigh` and
59
- models with no selectable reasoning level. `probe.test.ts` pins parsers, diff
60
- classification, baseline selection and CLI exit codes through injected
61
- fixtures; these tests never spawn agy.
62
-
63
- ## 4. Add a version to the matrix
64
-
65
- Edit `compat/matrix.json` (JSON, no rebuild needed):
66
-
67
- - `agy.tested`: add the version once its probe diff is reviewed (keep the list
68
- short — the last two or three releases).
69
- - `agy.minimum`: raise only when a lower version provably can no longer work
70
- (record why in the commit message; the refusal message is user-facing).
71
- - `agy.knownBad`: `"1.5.2"` or `{ "version": "1.5.2", "reason": "ACP shutdown hang" }`.
72
- - `acp.protocolVersion`: bump together with the adapter that speaks it.
73
- - `sdk.tested`: the SDK releases whose fingerprint is committed.
74
-
75
- ## 5. SDK contract canary
76
-
77
- ```powershell
78
- uv run --project compat/sdk-canary python compat/sdk-canary/canary.py
79
- uv run --project compat/sdk-canary python compat/sdk-canary/canary.py --record
80
- uv run --project compat/sdk-canary python compat/sdk-canary/canary.py --latest
81
- ```
82
-
83
- First run creates `compat/sdk-canary/.venv` (the pinned `google-antigravity`
84
- version is in `pyproject.toml`; `uv.lock` is committed and `.venv` is gitignored).
85
- As of 2026-11-13, PyPI latest and the recorded SDK baseline are both `0.1.23`, so
86
- there is no newer SDK to adopt. `--latest` needs network (PyPI + uv);
87
- `--record` is deterministic. Additive: re-record, add to `sdk.tested`. Breaking
88
- (removed/renumbered messages, fields or enums): the harness family behind `agy`
89
- changed — check the affected call in the adapter, then re-record after review.
90
-
91
- ## 6. Rollback
92
-
93
- - **agy**: reinstall the previous release and pin it (keep the old version in
94
- `agy.tested`); the provider refuses only below `agy.minimum` or on a protocol
95
- mismatch, so a tested older release keeps working.
96
- - **package**: `npm i -g @timmyjl12/pi-agy-bridge@<previous>` (or `pi` extension
97
- pin) and restore the previous `compat/baselines/*.json` and
98
- `compat/matrix.json` from git — never edit them in place to dodge a failure.
99
- - **fixtures**: replay fixtures are recorded artifacts; revert them with the code
100
- that expects them.
101
-
102
- ## 7. Ground rules (non-negotiable)
103
-
104
- - Never read, store, forward or replace Antigravity credentials, and never
105
- override agy's endpoint or user agent. The bridge is a client, not a proxy.
106
- - Never change the user's `~/.gemini` (`settings.json`, `mcp_config.json`,
107
- agents, login). Per-session state travels in ACP parameters and a private
108
- staged directory.
109
- - Kill only processes the bridge spawned (exact PID, tree kill); never by name.
110
- - Re-recording is one documented command whose diff is reviewed before the
111
- baseline is committed.
1
+ # Upgrading pi-agy-bridge (agy / SDK drift runbook)
2
+
3
+ `agy` ships often (three patch releases in one week of November 2026) and the
4
+ `google-antigravity` SDK ships about once a week. None of this needs a model
5
+ call or quota: the probes are free.
6
+
7
+ ## Triggers
8
+
9
+ | Signal | What it means | Go to |
10
+ | --- | --- | --- |
11
+ | `/agy-bridge doctor`, or the one-time notice shown at the first request, says `untested` / `newer-untested` | a newer agy is installed than the matrix tested | §1, then §3 |
12
+ | doctor says `below-minimum`, `known-bad`, `protocol` or `not-agy` | the provider refused to start (it names the fix) | §1 → §4 |
13
+ | `npm run compat:probe` exits 1 or 2 | agy's flags/capabilities/models moved | §3 |
14
+ | `uv run --project compat/sdk-canary python compat/sdk-canary/canary.py --latest` exits 1 or 2 | the SDK harness contract moved | §5 |
15
+ | a contract test or replay fixture fails after an agy update | an ACP exchange changed shape | §4 |
16
+ | Windows/uv problems, missing `agy` | environment, not drift | §6 |
17
+
18
+ `npm run compat:probe` exit codes: `0` identical, `1` additive only (or no
19
+ baseline recorded yet), `2` breaking, `3` the probe could not run. The SDK
20
+ canary uses the same codes.
21
+
22
+ ## 1. Free drift probe (no prompt, no quota)
23
+
24
+ ```powershell
25
+ npm run compat:probe # compare installed agy with compat/baselines/agy-<version>.json
26
+ npm run compat:probe -- --json # machine-readable (status, breaking[], additive[])
27
+ npm run compat:probe -- --record # write compat/baselines/agy-<version>.json
28
+ ```
29
+
30
+ > **PowerShell:** it consumes the first `--`, so `npm run compat:probe -- --record` silently runs a plain check (and `-- --help` goes to npm). Quote the separator, `npm run compat:probe "--" --record`, or call the script directly: `node compat/probe-cli.ts --record`. The same applies to every `npm run compat:... -- <flag>` in this file; for the SDK canary use `uv run --project compat/sdk-canary python compat/sdk-canary/canary.py --record`.
31
+
32
+ The probe uses a temp cwd and `agy acp --gemini-dir <temp>`, so `~/.gemini` is
33
+ never written and your login is only used, not copied. It kills only the process
34
+ it spawned.
35
+
36
+ ## 2. Decide what the drift is
37
+
38
+ | Probe result | Meaning | Action |
39
+ | --- | --- | --- |
40
+ | `identical` | nothing changed | done |
41
+ | `additive` | new flags / capabilities / models / config values | review the list (for new models, also check what a real session accepts, see `tests/model-catalog.test.ts`), `-- --record`, add the version to `compat/matrix.json` (§4), commit both |
42
+ | `breaking` (removed flag, capability, config option or value, model id, auth method; changed protocolVersion or agent name) | the adapter may now be wrong | **stop**. Read `agy changelog`, adjust the adapter, add/re-record the replay fixture, run `node --test tests/features.test.ts tests/probe.test.ts`, and only then re-record baselines |
43
+ | `no baseline` | first run on a new major/minor | `-- --record` after reviewing the printed summary |
44
+
45
+ Never re-record a baseline to make a red probe green: it is the reviewed
46
+ "known good", not a snapshot of whatever happens to be installed.
47
+
48
+ ## 3. Tests after an agy change
49
+
50
+ ```powershell
51
+ node --test tests/features.test.ts tests/probe.test.ts
52
+ npm test # whole package (needs the other suites to exist)
53
+ npm run check # tsc --noEmit
54
+ ```
55
+
56
+ `features.test.ts` pins feature negotiation against the recorded 1.5.3
57
+ `initialize` result and its mutations. `model-catalog.test.ts` covers the
58
+ `session/new` catalog captured from agy 1.5.8 and the catalog recorded in the
59
+ 1.5.12 baseline, including per-model `xhigh`, models with no selectable reasoning
60
+ level, and that the session-wide `thought_level` option never leaks a level to a
61
+ model whose own variants do not list it. `probe.test.ts` pins parsers, diff
62
+ classification, baseline selection and CLI exit codes through injected
63
+ fixtures; these tests never spawn agy.
64
+
65
+ ## 4. Add a version to the matrix
66
+
67
+ Edit `compat/matrix.json` (JSON, no rebuild needed):
68
+
69
+ - `agy.tested`: add the version once its probe diff is reviewed (keep the list
70
+ short — the last two or three releases). The list may exceed that when an entry
71
+ is an **anchor** rather than a recent release. `1.5.3` is the recorded handshake
72
+ the feature negotiation and probe parser tests are built on, and `1.5.8`/`1.5.9`
73
+ are live-verified with committed baselines: dropping any of them turns working
74
+ installs into `older-untested` and tells the user to `agy update` for no reason.
75
+ Trim older *releases* on the next refresh; never drop an anchor.
76
+ - `agy.minimum`: raise only when a lower version provably can no longer work
77
+ (record why in the commit message; the refusal message is user-facing).
78
+ - `agy.knownBad`: `"1.5.2"` or `{ "version": "1.5.2", "reason": "ACP shutdown hang" }`.
79
+ - `acp.protocolVersion`: bump together with the adapter that speaks it.
80
+ - `sdk.tested`: the SDK releases whose fingerprint is committed.
81
+
82
+ ## 5. SDK contract canary
83
+
84
+ ```powershell
85
+ uv run --project compat/sdk-canary python compat/sdk-canary/canary.py
86
+ uv run --project compat/sdk-canary python compat/sdk-canary/canary.py --record
87
+ uv run --project compat/sdk-canary python compat/sdk-canary/canary.py --latest
88
+ ```
89
+
90
+ First run creates `compat/sdk-canary/.venv` (the pinned `google-antigravity`
91
+ version is in `pyproject.toml`; `uv.lock` is committed and `.venv` is gitignored).
92
+ As of 2026-11-19, PyPI latest, the `main` branch of
93
+ `google-antigravity/antigravity-sdk-python` and the recorded SDK baseline are all
94
+ `0.1.23`, so there is no newer SDK to adopt. Check both upstreams before assuming
95
+ one leads the other: a missing git tag is not a newer release. `--latest` needs
96
+ network (PyPI + uv); `--record` is deterministic. Additive: re-record, add to
97
+ `sdk.tested`. Breaking (removed/renumbered messages, fields or enums): the harness
98
+ family behind `agy` changed — check the affected call in the adapter, then
99
+ re-record after review.
100
+
101
+ ## 6. Rollback
102
+
103
+ - **agy**: reinstall the previous release and pin it (keep the old version in
104
+ `agy.tested`); the provider refuses only below `agy.minimum` or on a protocol
105
+ mismatch, so a tested older release keeps working.
106
+ - **package**: `npm i -g @timmyjl12/pi-agy-bridge@<previous>` (or `pi` extension
107
+ pin) and restore the previous `compat/baselines/*.json` and
108
+ `compat/matrix.json` from git — never edit them in place to dodge a failure.
109
+ - **fixtures**: replay fixtures are recorded artifacts; revert them with the code
110
+ that expects them.
111
+
112
+ ## 7. Ground rules (non-negotiable)
113
+
114
+ - Never read, store, forward or replace Antigravity credentials, and never
115
+ override agy's endpoint or user agent. The bridge is a client, not a proxy.
116
+ - Never change the user's `~/.gemini` (`settings.json`, `mcp_config.json`,
117
+ agents, login). Per-session state travels in ACP parameters and a private
118
+ staged directory.
119
+ - Kill only processes the bridge spawned (exact PID, tree kill); never by name.
120
+ - Re-recording is one documented command whose diff is reviewed before the
121
+ baseline is committed.
@@ -0,0 +1,259 @@
1
+ {
2
+ "schema": 1,
3
+ "agyVersion": "1.5.12",
4
+ "collectedAt": "2026-11-19T14:27:32.780Z",
5
+ "helpFlags": [
6
+ "--add-dir",
7
+ "--agent",
8
+ "--continue",
9
+ "--conversation",
10
+ "--dangerously-skip-permissions",
11
+ "--disable-slash-commands",
12
+ "--effort",
13
+ "--input-format",
14
+ "--json-schema",
15
+ "--log-file",
16
+ "--mode",
17
+ "--model",
18
+ "--new-project",
19
+ "--output-format",
20
+ "--print",
21
+ "--print-timeout",
22
+ "--project",
23
+ "--prompt",
24
+ "--prompt-interactive",
25
+ "--remote-agent",
26
+ "--remote-control",
27
+ "--sandbox",
28
+ "--settings",
29
+ "-c",
30
+ "-i",
31
+ "-p"
32
+ ],
33
+ "acpHelpFlags": [
34
+ "--add-dir",
35
+ "--agent",
36
+ "--app-data-dir",
37
+ "--app_data_dir",
38
+ "--cli_dir_name",
39
+ "--cli_log_file",
40
+ "--cloud_code_endpoint",
41
+ "--dangerously-skip-permissions",
42
+ "--disable-telemetry",
43
+ "--disable_telemetry",
44
+ "--gemini-dir",
45
+ "--gemini_dir",
46
+ "--help",
47
+ "--ide-mcp-port",
48
+ "--ide_mcp_port",
49
+ "--include-default-customizations",
50
+ "--is_google3_workspace",
51
+ "--is_google_internal",
52
+ "--log-file",
53
+ "--login",
54
+ "--override_user_agent_name",
55
+ "--process-per-session",
56
+ "--sandbox",
57
+ "--stdio",
58
+ "--use_stubby_auth",
59
+ "--worker",
60
+ "-h"
61
+ ],
62
+ "models": [
63
+ {
64
+ "id": "claude-opus-5-5-high",
65
+ "label": "Claude Opus 5.5 (High)"
66
+ },
67
+ {
68
+ "id": "claude-opus-5-5-low",
69
+ "label": "Claude Opus 5.5 (Low)"
70
+ },
71
+ {
72
+ "id": "claude-opus-5-5-medium",
73
+ "label": "Claude Opus 5.5 (Medium)"
74
+ },
75
+ {
76
+ "id": "claude-sonnet-5-5-high",
77
+ "label": "Claude Sonnet 5.5 (High)"
78
+ },
79
+ {
80
+ "id": "claude-sonnet-5-5-low",
81
+ "label": "Claude Sonnet 5.5 (Low)"
82
+ },
83
+ {
84
+ "id": "claude-sonnet-5-5-medium",
85
+ "label": "Claude Sonnet 5.5 (Medium)"
86
+ },
87
+ {
88
+ "id": "gemini-3.8-flash-high",
89
+ "label": "Gemini 3.8 Flash (High)"
90
+ },
91
+ {
92
+ "id": "gemini-3.8-flash-low",
93
+ "label": "Gemini 3.8 Flash (Low)"
94
+ },
95
+ {
96
+ "id": "gemini-3.8-flash-medium",
97
+ "label": "Gemini 3.8 Flash (Medium)"
98
+ },
99
+ {
100
+ "id": "gemini-4-argon-high",
101
+ "label": "Gemini 4 Argon (High)"
102
+ },
103
+ {
104
+ "id": "gemini-4-argon-low",
105
+ "label": "Gemini 4 Argon (Low)"
106
+ },
107
+ {
108
+ "id": "gemini-4-argon-medium",
109
+ "label": "Gemini 4 Argon (Medium)"
110
+ },
111
+ {
112
+ "id": "gemini-4-hydrogen-high",
113
+ "label": "Gemini 4 Hydrogen (High)"
114
+ },
115
+ {
116
+ "id": "gemini-4-hydrogen-low",
117
+ "label": "Gemini 4 Hydrogen (Low)"
118
+ },
119
+ {
120
+ "id": "gemini-4-hydrogen-medium",
121
+ "label": "Gemini 4 Hydrogen (Medium)"
122
+ },
123
+ {
124
+ "id": "gemini-4-hydrogen-xhigh",
125
+ "label": "Gemini 4 Hydrogen (XHigh)"
126
+ },
127
+ {
128
+ "id": "gemini-4-neon-high",
129
+ "label": "Gemini 4 Neon (High)"
130
+ },
131
+ {
132
+ "id": "gemini-4-neon-low",
133
+ "label": "Gemini 4 Neon (Low)"
134
+ },
135
+ {
136
+ "id": "gemini-4-neon-medium",
137
+ "label": "Gemini 4 Neon (Medium)"
138
+ },
139
+ {
140
+ "id": "gemini-4-neon-xhigh",
141
+ "label": "Gemini 4 Neon (XHigh)"
142
+ },
143
+ {
144
+ "id": "gemini-pro-orchestrator-g1-pro",
145
+ "label": "Orchestrator (Argon)"
146
+ },
147
+ {
148
+ "id": "gemini-pro-orchestrator-neon",
149
+ "label": "Orchestrator (Neon)"
150
+ },
151
+ {
152
+ "id": "gpt-oss-120b-medium",
153
+ "label": "GPT-OSS 120B (Medium)"
154
+ }
155
+ ],
156
+ "initialize": {
157
+ "protocolVersion": 1,
158
+ "agentName": "Antigravity ACP Server",
159
+ "agentVersion": "1.5.12",
160
+ "capabilities": {
161
+ "_meta.antigravity.systemPrompt.append": true,
162
+ "auth.logout": true,
163
+ "loadSession": true,
164
+ "load_session": true,
165
+ "promptCapabilities.audio": false,
166
+ "promptCapabilities.embeddedContext": true,
167
+ "promptCapabilities.image": true,
168
+ "sessionCapabilities.additionalDirectories": true,
169
+ "sessionCapabilities.close": true,
170
+ "sessionCapabilities.list": true,
171
+ "sessionCapabilities.load": true,
172
+ "sessionCapabilities.resume": true,
173
+ "session_capabilities.additionalDirectories": true,
174
+ "session_capabilities.close": true,
175
+ "session_capabilities.list": true,
176
+ "session_capabilities.load": true,
177
+ "session_capabilities.resume": true
178
+ },
179
+ "authMethodIds": [
180
+ "agent-platform",
181
+ "gemini-api-key",
182
+ "oauth-business",
183
+ "oauth-personal"
184
+ ]
185
+ },
186
+ "session": {
187
+ "configOptions": [
188
+ {
189
+ "id": "mode",
190
+ "type": "select",
191
+ "values": [
192
+ "accept-edits",
193
+ "auto",
194
+ "default",
195
+ "plan"
196
+ ]
197
+ },
198
+ {
199
+ "id": "model",
200
+ "type": "select",
201
+ "values": [
202
+ "claude-opus-5-5",
203
+ "claude-sonnet-5-5",
204
+ "gemini-3.8-flash",
205
+ "gemini-4-argon",
206
+ "gemini-4-hydrogen",
207
+ "gemini-4-neon",
208
+ "gemini-pro-orchestrator-g1-pro",
209
+ "gemini-pro-orchestrator-neon",
210
+ "gpt-oss-120b-medium"
211
+ ]
212
+ },
213
+ {
214
+ "id": "thought_level",
215
+ "type": "select",
216
+ "values": [
217
+ "high",
218
+ "low",
219
+ "medium",
220
+ "xhigh"
221
+ ]
222
+ }
223
+ ],
224
+ "modeIds": [
225
+ "accept-edits",
226
+ "auto",
227
+ "default",
228
+ "plan"
229
+ ],
230
+ "modelIds": [
231
+ "claude-opus-5-5-high",
232
+ "claude-opus-5-5-low",
233
+ "claude-opus-5-5-medium",
234
+ "claude-sonnet-5-5-high",
235
+ "claude-sonnet-5-5-low",
236
+ "claude-sonnet-5-5-medium",
237
+ "gemini-3.8-flash-high",
238
+ "gemini-3.8-flash-low",
239
+ "gemini-3.8-flash-medium",
240
+ "gemini-4-argon-high",
241
+ "gemini-4-argon-low",
242
+ "gemini-4-argon-medium",
243
+ "gemini-4-hydrogen-high",
244
+ "gemini-4-hydrogen-low",
245
+ "gemini-4-hydrogen-medium",
246
+ "gemini-4-hydrogen-xhigh",
247
+ "gemini-4-neon-high",
248
+ "gemini-4-neon-low",
249
+ "gemini-4-neon-medium",
250
+ "gemini-4-neon-xhigh",
251
+ "gemini-pro-orchestrator-g1-pro",
252
+ "gemini-pro-orchestrator-neon",
253
+ "gpt-oss-120b-medium"
254
+ ],
255
+ "metaKeys": [
256
+ "antigravity"
257
+ ]
258
+ }
259
+ }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "schema": 1,
3
3
  "agy": {
4
- "tested": ["1.5.3", "1.5.8", "1.5.9"],
4
+ "tested": ["1.5.3", "1.5.8", "1.5.9", "1.5.12"],
5
5
  "minimum": "1.5.1",
6
6
  "knownBad": []
7
7
  },
package/compat/probe.ts CHANGED
@@ -40,7 +40,7 @@ export const PROBE_PROTOCOL_VERSION = 1;
40
40
  export const PROBE_CLIENT_INFO = {
41
41
  name: "pi-agy-bridge-compat-probe",
42
42
  title: "pi-agy-bridge zero-cost compat probe",
43
- version: "0.1.3",
43
+ version: "0.1.5",
44
44
  } as const;
45
45
 
46
46
  /** One failed probe step. `step` names the command or exchange. */
@@ -40,6 +40,12 @@ FINGERPRINT = SCRIPT_DIR / "fingerprint_proto.py"
40
40
  PYPI_JSON = "https://pypi.org/pypi/google-antigravity/json"
41
41
  EPHEMERAL_PYTHON = "3.13"
42
42
 
43
+ # The re-record command, printed verbatim in every hint. Do NOT swap this for
44
+ # `npm run compat:sdk -- --record`: PowerShell consumes the first `--`, so that
45
+ # form silently runs a plain check and records nothing (UPGRADING.md §1). The
46
+ # direct `uv run` form works in every shell.
47
+ RECORD_HINT = "uv run --project compat/sdk-canary python compat/sdk-canary/canary.py --record"
48
+
43
49
  sys.path.insert(0, str(SCRIPT_DIR))
44
50
  from diff_fingerprint import diff as diff_contracts # noqa: E402
45
51
 
@@ -175,7 +181,7 @@ def print_verdict(old: dict, new: dict, breaking: list[str], additive: list[str]
175
181
  if breaking:
176
182
  print("verdict: BREAKING - read the SDK release notes, adjust the adapter/canary, re-record after review.")
177
183
  return 2
178
- print("verdict: additive only - review, then re-record the baseline (npm run compat:sdk -- --record).")
184
+ print(f"verdict: additive only - review, then re-record the baseline ({RECORD_HINT}).")
179
185
  return 1
180
186
 
181
187
 
@@ -190,7 +196,7 @@ def check_installed() -> int:
190
196
  path, exact = find_baseline(summary["version"])
191
197
  if path is None:
192
198
  print(f"no baseline for google-antigravity {summary['version']}.")
193
- print(" record it once: npm run compat:sdk -- --record")
199
+ print(f" record it once: {RECORD_HINT}")
194
200
  return 1
195
201
  old = json.loads(path.read_text(encoding="utf-8"))
196
202
  breaking, additive = diff_contracts(old, fresh)
@@ -209,7 +215,7 @@ def check_latest() -> int:
209
215
  print("verdict: identical - no SDK contract drift to check.")
210
216
  return 0
211
217
  if newest_baseline is None:
212
- print("no baseline recorded yet; run npm run compat:sdk -- --record first (pinned version).")
218
+ print(f"no baseline recorded yet; run {RECORD_HINT} first (pinned version).")
213
219
  return 1
214
220
  print(f"fingerprinting {newest} in an ephemeral uv env (uv run --no-project --python {EPHEMERAL_PYTHON} --with google-antigravity=={newest}) ...")
215
221
  with tempfile.TemporaryDirectory(prefix="pi-agy-sdk-canary-") as tmp:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@timmyjl12/pi-agy-bridge",
3
- "version": "0.1.3",
3
+ "version": "0.1.5",
4
4
  "description": "pi provider for Google Antigravity (agy) models over the official ACP server, modelled on pi-claude-code: pi keeps the loop, history and tool execution",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -194,7 +194,7 @@ export class AcpProcess {
194
194
  const result = await this.#rpc.request("initialize", {
195
195
  protocolVersion: 1,
196
196
  clientCapabilities: { fs: { readTextFile: false, writeTextFile: false }, terminal: false },
197
- clientInfo: { name: "pi-agy-bridge", title: "pi-agy-bridge", version: "0.1.3" },
197
+ clientInfo: { name: "pi-agy-bridge", title: "pi-agy-bridge", version: "0.1.5" },
198
198
  });
199
199
  return (result ?? {}) as AcpInitializeResult;
200
200
  }
package/src/config.ts CHANGED
@@ -4,6 +4,10 @@
4
4
  import os from "node:os";
5
5
  import path from "node:path";
6
6
 
7
+ function agentDir(env: Record<string, string | undefined>): string {
8
+ return env.PI_CODING_AGENT_DIR?.trim() || path.join(os.homedir(), ".pi", "agent");
9
+ }
10
+
7
11
  /** How pi's system prompt reaches agy. `append`: `_meta.antigravity.systemPrompt.append` on `session/new`. `inline`: at
8
12
  * the top of the first prompt (the conversation resource). `auto`: append, but when the backend answers a fresh appended
9
13
  * session with RESOURCE_EXHAUSTED before any output, retry that turn once inline and keep using inline if it worked. */
@@ -36,7 +40,7 @@ export interface AgyConfig {
36
40
 
37
41
  export const DEFAULT_CONFIG: Readonly<AgyConfig> = Object.freeze({
38
42
  command: "agy",
39
- home: path.join(os.homedir(), ".pi", "agent", "pi-agy-bridge"),
43
+ home: path.join(agentDir(process.env), "pi-agy-bridge"),
40
44
  idleExitMs: 10 * 60_000,
41
45
  sessionTtlMs: 5 * 60_000,
42
46
  toolTtlMs: 30 * 60_000,
@@ -80,7 +84,7 @@ function positiveInt(value: string | undefined, fallback: number, scale = 1): nu
80
84
  /** Resolve configuration from an environment. Pure: pass `process.env` or a test double. */
81
85
  export function loadConfig(env: Record<string, string | undefined> = process.env): AgyConfig {
82
86
  const command = env.PI_AGY_COMMAND?.trim() || env.AGY_BIN?.trim() || DEFAULT_CONFIG.command;
83
- const home = env.PI_AGY_HOME?.trim() || DEFAULT_CONFIG.home;
87
+ const home = env.PI_AGY_HOME?.trim() || path.join(agentDir(env), "pi-agy-bridge");
84
88
  return {
85
89
  command,
86
90
  home,