@gkoreli/ghx 2.4.2 → 2.6.0

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.
Files changed (2) hide show
  1. package/README.md +69 -3
  2. package/package.json +7 -7
package/README.md CHANGED
@@ -68,8 +68,18 @@ you can `ls` and `jq`:
68
68
  logs.jsonl # GenAI-convention message-content records
69
69
  metrics.jsonl # duration, token, report-size metrics
70
70
  tier-decisions.jsonl # escalation policy evaluation per turn (which tier, why)
71
+ live.jsonl # realtime turn activity, appended as it happens
71
72
  ```
72
73
 
74
+ The OTLP artifacts are written when a question completes; `live.jsonl` streams
75
+ turn activity in realtime — turn start/end, text and thought chunks, every tool
76
+ call and update as the agent works — so
77
+ `tail -f ~/.ghx/sessions/<name>/live.jsonl` watches a running question instead
78
+ of waiting minutes for the final report
79
+ (see [ADR-0022.1](docs/adr/0022.1-live-turn-log.md)). `ghx sidecar tail --follow`
80
+ renders that stream as one human-readable line per event, so you rarely need
81
+ the raw `tail -f`.
82
+
73
83
  Sessions persist, so follow-up questions on the same repo are cheaper and
74
84
  context-aware. The traces are **official OpenTelemetry** (OTLP/JSON, GenAI
75
85
  semantic conventions) — any industry tool consumes them in seconds, and
@@ -167,6 +177,57 @@ ghx sidecar config init --claude-acp # writes ~/.ghx/config.json with the ACP
167
177
  Re-running `config init --claude-acp` against an existing config shows a field
168
178
  diff and refuses to overwrite without `--force`.
169
179
 
180
+ **Using your installed Claude Code (toolbox / wrapper builds).** The adapter's
181
+ SDK ships its own bundled Claude Code binary and its own credential store — by
182
+ default your `claude` on PATH (and its `~/.claude/settings.json`, credential
183
+ hooks, model aliases) is **not** what runs. If your organization installs a
184
+ wrapped `claude` that carries work credentials, point the adapter at it with
185
+ `CLAUDE_CODE_EXECUTABLE` (honored by `claude-agent-acp` ≥ 0.55):
186
+
187
+ ```json
188
+ {
189
+ "agent": "env CLAUDE_CODE_EXECUTABLE=/path/to/your/claude npx -y @agentclientprotocol/claude-agent-acp@0.55.0"
190
+ }
191
+ ```
192
+
193
+ `ghx sidecar config init --claude-exe /path/to/your/claude` writes exactly this
194
+ config for you (`--claude-exe auto` resolves `claude` from your PATH; the same
195
+ diff-and-`--force` rules apply).
196
+
197
+ > **Known upstream issue (enterprise wrapper builds):** when
198
+ > `CLAUDE_CODE_EXECUTABLE` points at a *wrapper* script/binary (e.g. a
199
+ > corporate toolbox `claude` that resolves credentials itself), the adapter
200
+ > can hang indefinitely at prompt time: ghx legitimately sends ACP
201
+ > `settingSources: []` for session isolation, and some wrappers stall instead
202
+ > of erroring when settings loading is suppressed (isolated 2026-07-06:
203
+ > `settingSources: []` alone reproduces the hang; `strictMcpConfig` and
204
+ > `tools` do not; mechanism: the native binary resolves Bedrock
205
+ > `modelOverrides` from `~/.claude/settings.json` and stalls instead of
206
+ > erroring when that read is suppressed). The fix is one config line:
207
+ >
208
+ > ```json
209
+ > {
210
+ > "agent": "env CLAUDE_CODE_EXECUTABLE=/path/to/your/claude npx -y @agentclientprotocol/claude-agent-acp@0.55.0",
211
+ > "agentSettingSources": ["user"]
212
+ > }
213
+ > ```
214
+ >
215
+ > `agentSettingSources` opts the spawned agent into loading your user
216
+ > settings (`~/.claude/settings.json`) so the wrapper's model aliases and
217
+ > credential hooks work. It deliberately weakens session isolation — host
218
+ > user settings apply to sidecar sessions — which is why it is opt-in and
219
+ > off by default (ADR-0033.2). Wrapping the *adapter* in a script that
220
+ > exports auth env itself remains a valid alternative.
221
+
222
+ Embedding `env VAR=...` in the agent command makes the setting travel with the
223
+ command itself, so it works no matter which process (CLI or resident daemon)
224
+ spawns the agent. Exporting `CLAUDE_CODE_EXECUTABLE` in your shell also works:
225
+ every ask forwards auth-relevant env to the agent
226
+ ([ADR-0033.1](docs/adr/0033.1-client-auth-env-passthrough.md)), and the same
227
+ applies to Bedrock/Vertex/gateway env (`CLAUDE_CODE_USE_BEDROCK`, `AWS_*`,
228
+ `ANTHROPIC_BASE_URL`, ...). `ghx sidecar doctor` shows exactly which names your
229
+ shell would forward.
230
+
170
231
  ### 3. Verify
171
232
 
172
233
  ```bash
@@ -222,6 +283,7 @@ ghx sidecar sessions list # all sessions
222
283
  ghx sidecar sessions show <session> # details + report history
223
284
  ghx sidecar sessions ledger <session> # the accumulated evidence ledger
224
285
  ghx sidecar sessions reroute <s> <turn> <dest> # move a mis-routed turn; both ledgers rebuilt by replay
286
+ ghx sidecar tail [session] --follow # human-readable live view of a running question
225
287
  ghx sidecar view [session] # spawn a local trace UI over the session's artifacts
226
288
  ghx sidecar view --list # sessions with turn/report counts
227
289
  ghx sidecar view --port 9000 # viewer UI port (default 8000)
@@ -366,6 +428,7 @@ ghx sidecar sessions list # List persisted sidecar sessions
366
428
  ghx sidecar sessions show <session> # Metadata + report history
367
429
  ghx sidecar sessions ledger <session> # Accumulated evidence ledger JSON
368
430
  ghx sidecar sessions reroute <s> <turn> <dest> # Move a mis-routed turn and rebuild ledgers
431
+ ghx sidecar tail [session] --follow # Human-readable live view of turn activity (live.jsonl)
369
432
  ghx sidecar view [session] # Local OTel viewer over session artifacts
370
433
  ghx sidecar evals export --format sft --run <dir> --out <file> # Export committed eval episodes
371
434
  ghx sidecar report-sink --out <path> # Internal report-sink MCP server used by ACP turns
@@ -405,9 +468,12 @@ the binary codemap needs for `--importers`/`--deps`), and `local:repomap`
405
468
  stolen with attribution from
406
469
  [aider's repo map](https://github.com/Aider-AI/aider), Apache-2.0 — an
407
470
  algorithm, not a dependency; deterministic given the same snapshot and
408
- query). If a tool binary is missing, ghx prints the install hint and exits
409
- before any clone; answers fall back to remote Tier-1 evidence — never a
410
- silent or faked Tier-2 result. `astgrep` follows grep parity: exit `1` with
471
+ query). Only `local:repomap` works with zero extra installs; codemap and
472
+ ast-grep are optional external binaries, and `ghx sidecar doctor` reports
473
+ which tier-2 backends resolve on your machine with install hints for the
474
+ missing ones. If a tool binary is missing, ghx prints the install hint and
475
+ exits before any clone; answers fall back to remote Tier-1 evidence — never
476
+ a silent or faked Tier-2 result. `astgrep` follows grep parity: exit `1` with
411
477
  `[]` means the search ran and found nothing.
412
478
 
413
479
  When the sidecar answers a question, escalation is never vibes: every turn
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gkoreli/ghx",
3
- "version": "2.4.2",
3
+ "version": "2.6.0",
4
4
  "description": "Agent-first GitHub code exploration. GraphQL batching, code maps, codemode TypeScript sandbox, MCP server.",
5
5
  "bin": {
6
6
  "ghx": "npm/bin/ghx"
@@ -28,11 +28,11 @@
28
28
  "node": ">=16"
29
29
  },
30
30
  "optionalDependencies": {
31
- "@gkoreli/ghx-darwin-arm64": "2.4.2",
32
- "@gkoreli/ghx-darwin-x64": "2.4.2",
33
- "@gkoreli/ghx-linux-arm64": "2.4.2",
34
- "@gkoreli/ghx-linux-x64": "2.4.2",
35
- "@gkoreli/ghx-win32-arm64": "2.4.2",
36
- "@gkoreli/ghx-win32-x64": "2.4.2"
31
+ "@gkoreli/ghx-darwin-arm64": "2.6.0",
32
+ "@gkoreli/ghx-darwin-x64": "2.6.0",
33
+ "@gkoreli/ghx-linux-arm64": "2.6.0",
34
+ "@gkoreli/ghx-linux-x64": "2.6.0",
35
+ "@gkoreli/ghx-win32-arm64": "2.6.0",
36
+ "@gkoreli/ghx-win32-x64": "2.6.0"
37
37
  }
38
38
  }