@agentex/agent 0.0.34 → 0.0.35

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 (81) hide show
  1. package/CHANGELOG.md +185 -0
  2. package/README.md +2 -1
  3. package/dist/providers/claude/discovery.d.ts +64 -0
  4. package/dist/providers/claude/discovery.d.ts.map +1 -0
  5. package/dist/providers/claude/discovery.js +147 -0
  6. package/dist/providers/claude/discovery.js.map +1 -0
  7. package/dist/providers/claude/effort.d.ts +20 -0
  8. package/dist/providers/claude/effort.d.ts.map +1 -0
  9. package/dist/providers/claude/effort.js +32 -0
  10. package/dist/providers/claude/effort.js.map +1 -0
  11. package/dist/providers/claude/execute.d.ts.map +1 -1
  12. package/dist/providers/claude/execute.js +2 -1
  13. package/dist/providers/claude/execute.js.map +1 -1
  14. package/dist/providers/claude/index.d.ts.map +1 -1
  15. package/dist/providers/claude/index.js +2 -1
  16. package/dist/providers/claude/index.js.map +1 -1
  17. package/dist/providers/claude/parse.d.ts.map +1 -1
  18. package/dist/providers/claude/parse.js +26 -4
  19. package/dist/providers/claude/parse.js.map +1 -1
  20. package/dist/providers/claude/session.d.ts.map +1 -1
  21. package/dist/providers/claude/session.js +2 -1
  22. package/dist/providers/claude/session.js.map +1 -1
  23. package/dist/providers/codex/discovery.d.ts +20 -0
  24. package/dist/providers/codex/discovery.d.ts.map +1 -0
  25. package/dist/providers/codex/discovery.js +76 -0
  26. package/dist/providers/codex/discovery.js.map +1 -0
  27. package/dist/providers/codex/execute.d.ts.map +1 -1
  28. package/dist/providers/codex/execute.js +45 -3
  29. package/dist/providers/codex/execute.js.map +1 -1
  30. package/dist/providers/codex/index.d.ts.map +1 -1
  31. package/dist/providers/codex/index.js +2 -1
  32. package/dist/providers/codex/index.js.map +1 -1
  33. package/dist/providers/codex/parse.d.ts +14 -6
  34. package/dist/providers/codex/parse.d.ts.map +1 -1
  35. package/dist/providers/codex/parse.js +51 -16
  36. package/dist/providers/codex/parse.js.map +1 -1
  37. package/dist/providers/codex/session.d.ts +29 -1
  38. package/dist/providers/codex/session.d.ts.map +1 -1
  39. package/dist/providers/codex/session.js +255 -57
  40. package/dist/providers/codex/session.js.map +1 -1
  41. package/dist/providers/cursor/discovery.d.ts.map +1 -1
  42. package/dist/providers/cursor/discovery.js +4 -0
  43. package/dist/providers/cursor/discovery.js.map +1 -1
  44. package/dist/providers/opencode/discovery.d.ts.map +1 -1
  45. package/dist/providers/opencode/discovery.js +11 -8
  46. package/dist/providers/opencode/discovery.js.map +1 -1
  47. package/dist/providers/opencode/event-parse.d.ts +23 -0
  48. package/dist/providers/opencode/event-parse.d.ts.map +1 -1
  49. package/dist/providers/opencode/event-parse.js +44 -0
  50. package/dist/providers/opencode/event-parse.js.map +1 -1
  51. package/dist/providers/opencode/history.d.ts.map +1 -1
  52. package/dist/providers/opencode/history.js +25 -4
  53. package/dist/providers/opencode/history.js.map +1 -1
  54. package/dist/providers/opencode/http-session.d.ts.map +1 -1
  55. package/dist/providers/opencode/http-session.js +59 -8
  56. package/dist/providers/opencode/http-session.js.map +1 -1
  57. package/dist/types.d.ts +19 -5
  58. package/dist/types.d.ts.map +1 -1
  59. package/dist/utils/model-cache.d.ts +33 -0
  60. package/dist/utils/model-cache.d.ts.map +1 -0
  61. package/dist/utils/model-cache.js +57 -0
  62. package/dist/utils/model-cache.js.map +1 -0
  63. package/package.json +1 -1
  64. package/src/providers/claude/discovery.ts +215 -0
  65. package/src/providers/claude/effort.ts +34 -0
  66. package/src/providers/claude/execute.ts +2 -1
  67. package/src/providers/claude/index.ts +2 -1
  68. package/src/providers/claude/parse.ts +27 -5
  69. package/src/providers/claude/session.ts +2 -1
  70. package/src/providers/codex/discovery.ts +91 -0
  71. package/src/providers/codex/execute.ts +42 -3
  72. package/src/providers/codex/index.ts +2 -1
  73. package/src/providers/codex/parse.ts +60 -18
  74. package/src/providers/codex/session.ts +285 -59
  75. package/src/providers/cursor/discovery.ts +5 -0
  76. package/src/providers/opencode/discovery.ts +10 -7
  77. package/src/providers/opencode/event-parse.ts +63 -0
  78. package/src/providers/opencode/history.ts +32 -4
  79. package/src/providers/opencode/http-session.ts +59 -8
  80. package/src/types.ts +19 -5
  81. package/src/utils/model-cache.ts +67 -0
package/CHANGELOG.md CHANGED
@@ -1,5 +1,190 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.0.35 — Codex turn-boundary correctness and model discovery
4
+
5
+ ### Fixed
6
+
7
+ - A Codex `send()` issued while the previous turn's result was still being
8
+ delivered is now a turn of its own. It previously joined the finished turn,
9
+ which left it with no interrupt latch: `interrupt()` found nothing to target
10
+ and returned as though it had succeeded, so Stop was a silent no-op — the
11
+ exact failure 0.0.33 set out to remove. The same send could also be settled
12
+ with the *previous* turn's `TurnResult`, so `await send()` resolved
13
+ `completed` while the agent was still working. Turn latches now carry a
14
+ generation, result delivery drains only its own generation, and a superseded
15
+ delivery no longer clears the running turn's state, accumulators, or latch.
16
+ The window is real time: it spans `await this._eventChain` (any host
17
+ persisting events) and the on-disk usage scan when `turn/completed` carries
18
+ no usage.
19
+ - Turn outcomes are now snapshotted at the terminal frame rather than read at
20
+ delivery time. Delivery is asynchronous, so reading the live accumulators
21
+ read whichever turn was running *then*: a turn that started during the window
22
+ inherited the previous turn's failure and reported its own summary alongside
23
+ someone else's error. Clearing on the way out was not an option either — the
24
+ usage-scan path re-reads state after an await.
25
+ - A duplicate terminal frame for an already-delivered turn no longer bypasses
26
+ the generation fence. Codex can report failure through both `turn/completed`
27
+ with a failed status and a separate `turn/failed`; the second arrives with no
28
+ active latch, and exempting that case restored every symptom the fence
29
+ exists to prevent.
30
+ - Claude `task_updated` patches no longer assert `running`. A patch that only
31
+ renames a task said nothing about liveness yet claimed the task was running,
32
+ silently resurrecting a `paused` one. `task_started` and `task_progress` still
33
+ imply `running`, because those events are emitted by a running task.
34
+ - Codex approval requests now carry the right fields. `toolUseId` reads
35
+ `itemId` (the protocol has no `id` here, so it was always `""`), and
36
+ file-change approvals describe themselves from `grantRoot` rather than a
37
+ `path` field that does not exist. Confirmed against
38
+ `codex app-server generate-json-schema` on 0.148.
39
+ - Child-thread approvals and questions no longer drive root session state, and
40
+ carry `agentId` so a host can attribute them to the subagent that asked. This
41
+ covers all three server-to-client request handlers: command-execution
42
+ approval, file-change approval, and `requestUserInput`. Every one of them
43
+ requires `threadId` in the protocol, so the scoping is read from the wire
44
+ rather than inferred.
45
+ - `item/permissions/requestApproval` is handled instead of falling through to
46
+ the generic empty ack, which the schema rejects —
47
+ `PermissionsRequestApprovalResponse` requires a `permissions` profile.
48
+ Allowing echoes the requested profile; refusing, or having no host handler,
49
+ grants nothing.
50
+ - Claude discovery no longer returns an ambiguous empty list. A control probe
51
+ proves the mechanism still works before any candidate is judged, so `[]` now
52
+ means "this CLI recognizes none of them" rather than doubling as "the probe
53
+ broke". A broken mechanism throws, which callers already treat as "use your
54
+ fallback catalog".
55
+ - The redundant direct `startBackgroundTaskPoller` call sites are gone. They
56
+ fired mid-item, before a later line in the same chunk could mark a task
57
+ terminal, which spawned a `thread/read` for a task that was already finished.
58
+ - Collaboration tool calls addressed to several receiver threads now emit a
59
+ `background_task` for every child. Only the first receiver was reported, so
60
+ the rest of a fan-out never existed as far as the host could tell. Added
61
+ `parseCodexStreamLines()`, which returns every event a line produces;
62
+ `parseCodexStreamLine()` remains as a first-event-only wrapper.
63
+ - Root `collabAgentToolCall` items that map to no task edge (`sendInput` to an
64
+ unknown task, metadata-only calls with no change) are forwarded as `unknown`
65
+ events again instead of being dropped, restoring the forward-compat escape
66
+ hatch for wire shapes that are not modeled yet.
67
+ - `executeCodexProvider` now emits a terminal `background_task` edge with
68
+ status `stopped` for children still running when the one-shot process exits.
69
+ The capability is declared provider-wide, but the one-shot path has no
70
+ session to reconcile against, so those children previously stayed `running`
71
+ forever from the host's view.
72
+ - A Claude `task_notification` that reports a live status is no longer forced
73
+ terminal. Every notification produced `phase: "completed"` regardless of the
74
+ status it carried, so an event saying `status: "running"` also told hosts to
75
+ drop the task — the documented contract is to remove a task from the active
76
+ set on `phase === "completed"`. Terminality now follows the status. A
77
+ notification with no status is still the completion signal it has always been.
78
+ - Codex background tasks registered through the parser's `subAgentActivity`
79
+ branch now get a reconciliation poller. Only the collaboration handler
80
+ started one, so those tasks had no safety net and depended entirely on the
81
+ child notification arriving — the exact failure 0.0.34 exists to survive.
82
+ - A Codex child thread announced with no parent thread id now writes a stderr
83
+ notice instead of silently disabling background-task tracking and
84
+ reconciliation for that child.
85
+ - Codex background-task bookkeeping no longer grows without bound. A terminal
86
+ task keeps its identity (that is what suppresses duplicate edges and blocks
87
+ resurrection) and its description (the reactivation path reads it precisely
88
+ because the record is terminal), but releases `summary`, which is the
89
+ genuinely unbounded field — full agent messages, appended per item. Both maps
90
+ are cleared on `close()`.
91
+ - Claude's top reasoning rung is no longer a silent downgrade. `ProviderConfig.effort`
92
+ of `"ultra"` now reaches the CLI as `--effort ultracode`, the token Claude Code
93
+ actually accepts. Previously it was passed through verbatim, and the CLI answered
94
+ with a stderr warning and then ran the turn at the session default, so callers
95
+ asking for maximum reasoning got ordinary reasoning with no error to notice.
96
+ Codex is unaffected: it names that rung `ultra` natively.
97
+ - `ListModelsOptions.cacheTtlMs` is now honored. It has been part of the public
98
+ shape since `listModels()` shipped but nothing read it, so callers passing a TTL
99
+ paid for a fresh CLI round trip every call. A TTL of `0` or `undefined` still
100
+ forces a refresh, and a rejected discovery is never cached.
101
+ - An OpenCode turn that ends with no reply is no longer reported as a clean
102
+ completion. When the upstream provider drops the stream, OpenCode records the
103
+ assistant message with `finish: "unknown"`, no text, and no error, which the
104
+ adapter mapped to a successful empty turn — indistinguishable from a stall.
105
+ Such a turn now resolves `failed` and emits a visible assistant note
106
+ explaining the model returned no content, so the user can retry instead of
107
+ waiting on a turn that already ended. Detection keys on a terminal message
108
+ with no visible text and a non-clean finish reason, so a real answer or a
109
+ clean stop is never touched, and a user interrupt (which OpenCode marks with a
110
+ `MessageAbortedError`) still reports as an error rather than an empty turn.
111
+ Live and reconcile paths share a `${messageId}:incomplete` event id so a
112
+ catch-up dedups the note instead of duplicating it.
113
+ - An OpenCode user prompt is no longer echoed back as an assistant message. The
114
+ live session mapped every streamed text part to assistant output, but OpenCode
115
+ re-streams the user message's own text part once a turn is active, so each
116
+ prompt surfaced a second time as if the agent had said it. The session now
117
+ tracks message roles from `message.updated` frames and drops parts belonging
118
+ to a user message; an as-yet-unknown role still emits, so a frame-ordering
119
+ race can never suppress genuine assistant output.
120
+ - OpenCode's live terminal `result` event now uses the same `${messageId}:result`
121
+ id as the reconcile path. The two paths previously produced different ids for
122
+ the same turn terminus, so a reconcile after a live turn appended a duplicate
123
+ terminal marker instead of deduping against the one already written.
124
+
125
+ ### Added
126
+
127
+ - `codex.listModels()` reads `codex debug models`, so Codex models arrive with the
128
+ reasoning levels each one actually supports and its own default. These are
129
+ genuinely per-model: 5.6 Sol advertises `ultra`, 5.5 stops at `xhigh`.
130
+ - `claude.listModels()` validates the tier aliases (`opus`, `sonnet`, `haiku`,
131
+ `fable`) against the installed binary and reports the efforts it accepts.
132
+ Claude Code ships no catalog command, so this works by asking the CLI to
133
+ validate each value: `--help` enumerates the efforts it documents, and anything
134
+ it accepts without documenting (`ultracode`) is recovered by probing. Probes use
135
+ `--bare` where available so they cannot fire a user's hooks, and pass an empty
136
+ prompt so they exit before reaching the network. No probe costs a token.
137
+ - `claude.listClaudeEfforts()` for hosts that want the effort ladder without a
138
+ model list. Claude applies one `--effort` per session rather than per model.
139
+ - `ProviderModel.description` carries a provider's own one-line blurb through.
140
+ - `capabilities.modelDiscovery` is now `true` for `claude` and `codex`, and the
141
+ contract test now checks both directions so a provider cannot declare
142
+ discovery it does not implement, or implement discovery it does not declare.
143
+
144
+ ### Compatibility
145
+
146
+ - Discovery is curated-list-plus-validation for Claude, not enumeration. A tier
147
+ alias this library has never heard of cannot be discovered, and a recognized
148
+ `--model` value proves the binary knows the name, not that the account is
149
+ entitled to it.
150
+ - A cold Claude discovery spawns the CLI several times: measured ~1.8-3s
151
+ depending on machine load, against ~0.1s for Codex. Two of those spawns
152
+ (`--help` and the control probe) are serial; the rest run concurrently. Pass
153
+ `cacheTtlMs` and keep a static fallback for first paint.
154
+ - Concurrent sends still coalesce into one turn and share its `TurnResult`.
155
+ What changed is that a send arriving after the previous turn has terminated
156
+ is no longer treated as concurrent with it.
157
+ - **Migration note for 0.0.32 and earlier.** 0.0.33 moved Claude task lifecycle
158
+ from `type: "unknown"` to `type: "background_task"`; that was listed under
159
+ Added, but for hosts it is a breaking change. Code shaped like
160
+ `if (event.type === "unknown") { getClaudeTaskDetails(event) }` stops seeing
161
+ tasks. `getClaudeTaskDetails()` still accepts legacy `unknown` events, which
162
+ covers replaying stored history but not a live handler keyed on the old
163
+ discriminator. Branch on `type === "background_task"` and treat the `unknown`
164
+ form as the compatibility path.
165
+ - **`background_task.status` is now `BackgroundTaskStatus | null`.** Null means
166
+ "no change reported" — keep whatever you have. This is a type-level breaking
167
+ change and deliberately so: it fails loudly at compile time rather than
168
+ silently. Only Claude emits it, and only where the wire genuinely says
169
+ nothing; Codex always reports a concrete status.
170
+ - The generic fallback for unhandled Codex server requests still replies `{}`.
171
+ Every server request the protocol defines but this library does not handle
172
+ declares required response fields, so that reply is schema-invalid for all of
173
+ them — the same class as the `item/permissions/requestApproval` fix in this
174
+ release. A JSON-RPC error reply is the honest answer, but `rpcResponse` has no
175
+ error path and adding one is a behavior change (an error can abort a turn
176
+ where `{}` limps along), so it is deferred rather than rushed in. Pre-existing;
177
+ the misleading "ack to unblock the turn" comment has been corrected.
178
+ - Codex child reconciliation still polls `thread/read` every 2s per active
179
+ child regardless of whether notifications are flowing. Unchanged here and
180
+ still an open decision. `thread/status/changed` and `thread/closed` exist in
181
+ the app-server protocol and would allow a push-based design with polling
182
+ demoted to a silence-timeout fallback; worth evaluating before committing to
183
+ polling permanently.
184
+ - Codex child reconciliation still polls `thread/read` every 2s for each active
185
+ child regardless of whether notifications are flowing. That cost is unchanged
186
+ here and remains an open decision, not a regression.
187
+
3
188
  ## 0.0.34 - Codex collaboration task lifecycle
4
189
 
5
190
  ### Fixed
package/README.md CHANGED
@@ -545,7 +545,8 @@ first-class `background_task` event. Its normalized contract is:
545
545
  taskId: string;
546
546
  taskType: "subagent" | "process" | "unknown";
547
547
  phase: "started" | "progress" | "completed";
548
- status: "pending" | "running" | "paused" | "completed" | "failed" | "stopped";
548
+ // null = "no change reported" — keep the status you already have.
549
+ status: "pending" | "running" | "paused" | "completed" | "failed" | "stopped" | null;
549
550
  description: string | null;
550
551
  summary: string | null;
551
552
  parentTaskId: string | null;
@@ -0,0 +1,64 @@
1
+ /**
2
+ * Claude Code model and effort discovery.
3
+ *
4
+ * Claude Code ships no catalog subcommand and its SDK init frame reports only
5
+ * the resolved model, so there is nothing to read the way `codex debug models`
6
+ * can be read. What the CLI *will* do is validate `--model` and `--effort`
7
+ * eagerly, before any API call, and say so on stderr when it does not
8
+ * recognize a value. That turns discovery into two different jobs:
9
+ *
10
+ * Efforts are enumerable. `--help` prints the accepted values inline, so the
11
+ * installed binary names them itself. Values it accepts but omits from help
12
+ * (`ultracode` today) are recovered by probing the canonical list.
13
+ *
14
+ * Models are not enumerable. Probing can only answer "do you know this one?"
15
+ * for names we already ship, so `CLAUDE_MODEL_CANDIDATES` stays a curated
16
+ * list. What probing buys is that a name the installed CLI does not know is
17
+ * dropped instead of offered and silently ignored at run time.
18
+ *
19
+ * Probes run with `--bare` when the binary supports it. The reason is side
20
+ * effects, not speed: `--bare` skips hooks, LSP, plugin sync, auto-memory, and
21
+ * keychain reads, so asking "do you know this flag value" cannot fire a user's
22
+ * SessionStart hook four times. Argument validation still runs under it.
23
+ * Probes also pass `-p ""`, so the process exits on empty input long before it
24
+ * would reach the network. No probe costs a token.
25
+ *
26
+ * Budget: two serial spawns, then one concurrent batch. `--help` and the
27
+ * control probe below are each on the critical path; only the per-candidate
28
+ * probes run in parallel. Measured cold against 2.1.232 that is ~1.8-3s
29
+ * depending on machine load, against ~0.1s for Codex's single-command
30
+ * catalog.
31
+ * Worth caching for minutes rather than seconds: callers should pass
32
+ * `cacheTtlMs` and keep a static fallback for first paint rather than blocking
33
+ * a picker on this.
34
+ */
35
+ import type { ListModelsOptions, ProviderModel } from "../../types.js";
36
+ /**
37
+ * Tier aliases rather than pinned versions, so each one keeps meaning "the
38
+ * newest model in this tier" and the list does not rot between releases. A
39
+ * genuinely new tier is one line here, gated by the probe so older CLIs that
40
+ * have never heard of it simply do not show it.
41
+ */
42
+ export declare const CLAUDE_MODEL_CANDIDATES: ReadonlyArray<{
43
+ id: string;
44
+ name: string;
45
+ description: string;
46
+ }>;
47
+ /**
48
+ * Read the effort values `--help` advertises.
49
+ *
50
+ * The option's accepted list is rendered inline and commander wraps it onto a
51
+ * continuation line, so the scan joins whitespace and stops at the next flag
52
+ * to avoid swallowing a later option's parenthetical.
53
+ */
54
+ export declare function claudeEffortsFromHelp(output: string): string[];
55
+ /**
56
+ * Effort values the installed binary accepts, in canonical vocabulary.
57
+ *
58
+ * Exported separately because efforts are a property of the CLI rather than of
59
+ * any one model: Claude takes a single `--effort` flag and applies it to
60
+ * whatever model the turn runs on.
61
+ */
62
+ export declare function listClaudeEfforts(options?: ListModelsOptions): Promise<string[]>;
63
+ export declare function listClaudeModels(options?: ListModelsOptions): Promise<ProviderModel[]>;
64
+ //# sourceMappingURL=discovery.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"discovery.d.ts","sourceRoot":"","sources":["../../../src/providers/claude/discovery.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,OAAO,KAAK,EAAE,iBAAiB,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAOvE;;;;;GAKG;AACH,eAAO,MAAM,uBAAuB,EAAE,aAAa,CAAC;IAAE,EAAE,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,WAAW,EAAE,MAAM,CAAA;CAAE,CAKpG,CAAC;AAaF;;;;;;GAMG;AACH,wBAAgB,qBAAqB,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,EAAE,CAa9D;AAkED;;;;;;GAMG;AACH,wBAAsB,iBAAiB,CAAC,OAAO,GAAE,iBAAsB,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC,CAM1F;AA2BD,wBAAsB,gBAAgB,CAAC,OAAO,GAAE,iBAAsB,GAAG,OAAO,CAAC,aAAa,EAAE,CAAC,CAuBhG"}
@@ -0,0 +1,147 @@
1
+ import { findBinary } from "../../utils/binary.js";
2
+ import { buildEnv, ensurePathInEnv } from "../../utils/env.js";
3
+ import { runChildProcess } from "../../utils/process.js";
4
+ import { withModelCache } from "../../utils/model-cache.js";
5
+ import { CLAUDE_EFFORTS, claudeEffortFlagValue, claudeEffortFromFlagValue } from "./effort.js";
6
+ /**
7
+ * Tier aliases rather than pinned versions, so each one keeps meaning "the
8
+ * newest model in this tier" and the list does not rot between releases. A
9
+ * genuinely new tier is one line here, gated by the probe so older CLIs that
10
+ * have never heard of it simply do not show it.
11
+ */
12
+ export const CLAUDE_MODEL_CANDIDATES = [
13
+ { id: "opus", name: "Opus", description: "Always resolves to the newest Opus release" },
14
+ { id: "sonnet", name: "Sonnet", description: "Always resolves to the newest Sonnet release" },
15
+ { id: "haiku", name: "Haiku", description: "Always resolves to the newest Haiku release" },
16
+ { id: "fable", name: "Fable", description: "Always resolves to the newest Fable release" },
17
+ ];
18
+ /**
19
+ * The error a probe earns when the flag value was accepted: the CLI got far
20
+ * enough to care that the prompt was empty. Treated as the positive signal so
21
+ * an unexpected failure (missing binary, unknown flag, changed wording) reads
22
+ * as "unsupported" rather than "supported". Discovery that fails open would
23
+ * offer values the CLI then ignores, which is the exact failure this replaces.
24
+ */
25
+ const ACCEPTED = /input must be provided/i;
26
+ const UNKNOWN_EFFORTS = /unknown --effort value/i;
27
+ const UNKNOWN_MODEL = /is not a model this version of claude code recognizes/i;
28
+ /**
29
+ * Read the effort values `--help` advertises.
30
+ *
31
+ * The option's accepted list is rendered inline and commander wraps it onto a
32
+ * continuation line, so the scan joins whitespace and stops at the next flag
33
+ * to avoid swallowing a later option's parenthetical.
34
+ */
35
+ export function claudeEffortsFromHelp(output) {
36
+ const index = output.indexOf("--effort");
37
+ if (index === -1)
38
+ return [];
39
+ const tail = output.slice(index + "--effort".length);
40
+ const stop = tail.search(/\n\s*(?:-[a-z]|--[a-z])/i);
41
+ const block = (stop === -1 ? tail : tail.slice(0, stop)).replace(/\s+/g, " ");
42
+ const list = block.match(/\(([^)]+)\)/);
43
+ if (!list?.[1])
44
+ return [];
45
+ const values = list[1]
46
+ .split(",")
47
+ .map((value) => value.trim().toLowerCase())
48
+ .filter((value) => /^[a-z][a-z0-9-]*$/.test(value));
49
+ return [...new Set(values.map(claudeEffortFromFlagValue))];
50
+ }
51
+ /** Order a discovered set by the canonical ladder, unknown values last. */
52
+ function ordered(values) {
53
+ const seen = [...new Set(values)];
54
+ const rank = (value) => {
55
+ const index = CLAUDE_EFFORTS.indexOf(value);
56
+ return index === -1 ? CLAUDE_EFFORTS.length : index;
57
+ };
58
+ return seen.sort((left, right) => rank(left) - rank(right));
59
+ }
60
+ async function runClaude(runtime, args, timeoutSec = 30) {
61
+ const result = await runChildProcess({
62
+ runId: "claude-discovery",
63
+ command: runtime.resolved.bin,
64
+ args: [...runtime.resolved.prefixArgs, ...args],
65
+ cwd: runtime.cwd,
66
+ env: runtime.env,
67
+ timeoutSec,
68
+ });
69
+ return `${result.stdout}\n${result.stderr}`;
70
+ }
71
+ async function probeFlag(runtime, flag, value) {
72
+ const output = await runClaude(runtime, [...(runtime.bare ? ["--bare"] : []), flag, value, "-p", ""]);
73
+ if (!ACCEPTED.test(output))
74
+ return false;
75
+ return !(flag === "--effort" ? UNKNOWN_EFFORTS : UNKNOWN_MODEL).test(output);
76
+ }
77
+ /**
78
+ * Prove the probe mechanism itself still works, with no flag under test.
79
+ *
80
+ * Without this, an empty result is ambiguous: it means both "this CLI
81
+ * recognizes none of our candidates" and "the probe broke" — a renamed flag, a
82
+ * reworded error, a binary that will not start. Failing closed only helps if
83
+ * the caller can tell those apart, and it cannot: falling back to a static list
84
+ * on a broken probe offers exactly the unvalidated names that failing open
85
+ * would have. So a broken mechanism throws, and an empty list becomes a real
86
+ * answer rather than a shrug.
87
+ */
88
+ async function probeMechanismWorks(runtime) {
89
+ const output = await runClaude(runtime, [...(runtime.bare ? ["--bare"] : []), "-p", ""]);
90
+ return ACCEPTED.test(output);
91
+ }
92
+ /**
93
+ * Effort values the installed binary accepts, in canonical vocabulary.
94
+ *
95
+ * Exported separately because efforts are a property of the CLI rather than of
96
+ * any one model: Claude takes a single `--effort` flag and applies it to
97
+ * whatever model the turn runs on.
98
+ */
99
+ export async function listClaudeEfforts(options = {}) {
100
+ const runtime = await probeRuntime(options);
101
+ if (!await probeMechanismWorks(runtime)) {
102
+ throw new Error("Claude Code effort discovery failed: the CLI did not respond as expected to a probe");
103
+ }
104
+ return discoverEfforts(runtime);
105
+ }
106
+ async function probeRuntime(options) {
107
+ const resolved = await findBinary("claude", options.config?.command);
108
+ const env = buildEnv(options.env);
109
+ ensurePathInEnv(env);
110
+ const base = { resolved, env, cwd: options.cwd ?? process.cwd() };
111
+ // One spawn answers two questions: which efforts the binary advertises, and
112
+ // whether it understands `--bare` well enough to probe without side effects.
113
+ const help = await runClaude(base, ["--help"], 15);
114
+ return { ...base, bare: /--bare\b/.test(help), help };
115
+ }
116
+ async function discoverEfforts(runtime) {
117
+ const advertised = claudeEffortsFromHelp(runtime.help);
118
+ // Anything help omits still gets a probe, so a value the CLI accepts without
119
+ // documenting is not lost. When help parsing yields nothing this degrades to
120
+ // probing the whole ladder rather than to returning nothing.
121
+ const unlisted = CLAUDE_EFFORTS.filter((effort) => !advertised.includes(effort));
122
+ const confirmed = await Promise.all(unlisted.map(async (effort) => (await probeFlag(runtime, "--effort", claudeEffortFlagValue(effort)) ? effort : null)));
123
+ return ordered([...advertised, ...confirmed.filter((effort) => effort !== null)]);
124
+ }
125
+ export async function listClaudeModels(options = {}) {
126
+ return withModelCache("claude", options, options.cacheTtlMs, async () => {
127
+ const runtime = await probeRuntime(options);
128
+ // Throwing rather than returning [] keeps "no models" meaningful. Callers
129
+ // already treat a discovery failure as "use your fallback catalog".
130
+ if (!await probeMechanismWorks(runtime)) {
131
+ throw new Error("Claude Code model discovery failed: the CLI did not respond as expected to a probe");
132
+ }
133
+ const [supportedEfforts, recognized] = await Promise.all([
134
+ discoverEfforts(runtime),
135
+ Promise.all(CLAUDE_MODEL_CANDIDATES.map(async (candidate) => (await probeFlag(runtime, "--model", candidate.id) ? candidate : null))),
136
+ ]);
137
+ return recognized
138
+ .filter((candidate) => candidate !== null)
139
+ .map((candidate) => ({
140
+ id: candidate.id,
141
+ name: candidate.name,
142
+ description: candidate.description,
143
+ ...(supportedEfforts.length > 0 ? { supportedEfforts } : {}),
144
+ }));
145
+ });
146
+ }
147
+ //# sourceMappingURL=discovery.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"discovery.js","sourceRoot":"","sources":["../../../src/providers/claude/discovery.ts"],"names":[],"mappings":"AAmCA,OAAO,EAAE,UAAU,EAAuB,MAAM,uBAAuB,CAAC;AACxE,OAAO,EAAE,QAAQ,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAC/D,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AACzD,OAAO,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAC5D,OAAO,EAAE,cAAc,EAAE,qBAAqB,EAAE,yBAAyB,EAAE,MAAM,aAAa,CAAC;AAE/F;;;;;GAKG;AACH,MAAM,CAAC,MAAM,uBAAuB,GAAqE;IACvG,EAAE,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,WAAW,EAAE,4CAA4C,EAAE;IACvF,EAAE,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,8CAA8C,EAAE;IAC7F,EAAE,EAAE,EAAE,OA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AAO,EAAE,OAAO,CAAC,UAAU,EAAE,KAAK,IAAI,EAAE;QACtE,MAAM,OAAO,GAAG,MAAM,YAAY,CAAC,OAAO,CAAC,CAAC;QAC5C,0EAA0E;QAC1E,oEAAoE;QACpE,IAAI,CAAC,MAAM,mBAAmB,CAAC,OAAO,CAAC,EAAE,CAAC;YACxC,MAAM,IAAI,KAAK,CAAC,oFAAoF,CAAC,CAAC;QACxG,CAAC;QACD,MAAM,CAAC,gBAAgB,EAAE,UAAU,CAAC,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC;YACvD,eAAe,CAAC,OAAO,CAAC;YACxB,OAAO,CAAC,GAAG,CAAC,uBAAuB,CAAC,GAAG,CAAC,KAAK,EAAE,SAAS,EAAE,EAAE,CAAC,CAC3D,MAAM,SAAS,CAAC,OAAO,EAAE,SAAS,EAAE,SAAS,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,IAAI,CACrE,CAAC,CAAC;SACJ,CAAC,CAAC;QACH,OAAO,UAAU;aACd,MAAM,CAAC,CAAC,SAAS,EAAyD,EAAE,CAAC,SAAS,KAAK,IAAI,CAAC;aAChG,GAAG,CAAC,CAAC,SAAS,EAAE,EAAE,CAAC,CAAC;YACnB,EAAE,EAAE,SAAS,CAAC,EAAE;YAChB,IAAI,EAAE,SAAS,CAAC,IAAI;YACpB,WAAW,EAAE,SAAS,CAAC,WAAW;YAClC,GAAG,CAAC,gBAAgB,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,gBAAgB,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;SAC7D,CAAC,CAAC,CAAC;IACR,CAAC,CAAC,CAAC;AACL,CAAC"}
@@ -0,0 +1,20 @@
1
+ /**
2
+ * Reasoning-effort vocabulary for Claude Code.
3
+ *
4
+ * `ProviderConfig.effort` is one shared scale across providers, but the CLIs
5
+ * do not agree on what to call its top rung: Codex accepts `ultra`, Claude
6
+ * accepts `ultracode`. Translating at the flag boundary keeps that difference
7
+ * out of every caller.
8
+ *
9
+ * This is not cosmetic. `claude --effort ultra` does not fail — it prints a
10
+ * warning to stderr and runs the turn at the session default. An untranslated
11
+ * value is therefore a silent downgrade, indistinguishable at the API surface
12
+ * from having worked.
13
+ */
14
+ /** Canonical effort ids, weakest to strongest, in the shared vocabulary. */
15
+ export declare const CLAUDE_EFFORTS: readonly ["low", "medium", "high", "xhigh", "max", "ultra"];
16
+ /** The token to pass to `--effort` for a canonical effort id. */
17
+ export declare function claudeEffortFlagValue(effort: string): string;
18
+ /** Inverse of `claudeEffortFlagValue`, for reading a CLI-advertised list. */
19
+ export declare function claudeEffortFromFlagValue(value: string): string;
20
+ //# sourceMappingURL=effort.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"effort.d.ts","sourceRoot":"","sources":["../../../src/providers/claude/effort.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,4EAA4E;AAC5E,eAAO,MAAM,cAAc,6DAA8D,CAAC;AAO1F,iEAAiE;AACjE,wBAAgB,qBAAqB,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAE5D;AAED,6EAA6E;AAC7E,wBAAgB,yBAAyB,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAK/D"}
@@ -0,0 +1,32 @@
1
+ /**
2
+ * Reasoning-effort vocabulary for Claude Code.
3
+ *
4
+ * `ProviderConfig.effort` is one shared scale across providers, but the CLIs
5
+ * do not agree on what to call its top rung: Codex accepts `ultra`, Claude
6
+ * accepts `ultracode`. Translating at the flag boundary keeps that difference
7
+ * out of every caller.
8
+ *
9
+ * This is not cosmetic. `claude --effort ultra` does not fail — it prints a
10
+ * warning to stderr and runs the turn at the session default. An untranslated
11
+ * value is therefore a silent downgrade, indistinguishable at the API surface
12
+ * from having worked.
13
+ */
14
+ /** Canonical effort ids, weakest to strongest, in the shared vocabulary. */
15
+ export const CLAUDE_EFFORTS = ["low", "medium", "high", "xhigh", "max", "ultra"];
16
+ /** Canonical id -> the token `claude --effort` accepts. Identity when absent. */
17
+ const WIRE_VALUES = {
18
+ ultra: "ultracode",
19
+ };
20
+ /** The token to pass to `--effort` for a canonical effort id. */
21
+ export function claudeEffortFlagValue(effort) {
22
+ return WIRE_VALUES[effort] ?? effort;
23
+ }
24
+ /** Inverse of `claudeEffortFlagValue`, for reading a CLI-advertised list. */
25
+ export function claudeEffortFromFlagValue(value) {
26
+ for (const [canonical, wire] of Object.entries(WIRE_VALUES)) {
27
+ if (wire === value)
28
+ return canonical;
29
+ }
30
+ return value;
31
+ }
32
+ //# sourceMappingURL=effort.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"effort.js","sourceRoot":"","sources":["../../../src/providers/claude/effort.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,4EAA4E;AAC5E,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,KAAK,EAAE,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,KAAK,EAAE,OAAO,CAAU,CAAC;AAE1F,iFAAiF;AACjF,MAAM,WAAW,GAA2B;IAC1C,KAAK,EAAE,WAAW;CACnB,CAAC;AAEF,iEAAiE;AACjE,MAAM,UAAU,qBAAqB,CAAC,MAAc;IAClD,OAAO,WAAW,CAAC,MAAM,CAAC,IAAI,MAAM,CAAC;AACvC,CAAC;AAED,6EAA6E;AAC7E,MAAM,UAAU,yBAAyB,CAAC,KAAa;IACrD,KAAK,MAAM,CAAC,SAAS,EAAE,IAAI,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,WAAW,CAAC,EAAE,CAAC;QAC5D,IAAI,IAAI,KAAK,KAAK;YAAE,OAAO,SAAS,CAAC;IACvC,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"execute.d.ts","sourceRoot":"","sources":["../../../src/providers/claude/execute.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAcxE,wBAAsB,qBAAqB,CAAC,GAAG,EAAE,gBAAgB,GAAG,OAAO,CAAC,eAAe,CAAC,CA4R3F"}
1
+ {"version":3,"file":"execute.d.ts","sourceRoot":"","sources":["../../../src/providers/claude/execute.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAexE,wBAAsB,qBAAqB,CAAC,GAAG,EAAE,gBAAgB,GAAG,OAAO,CAAC,eAAe,CAAC,CA4R3F"}
@@ -6,6 +6,7 @@ import { runChildProcess, deriveErrorCode } from "../../utils/process.js";
6
6
  import { detectAuth } from "../../utils/auth.js";
7
7
  import { buildSkillsDir, cleanupSkillsDir } from "../../utils/skills.js";
8
8
  import { claudeFeatureArgs, cleanupMcpConfig, stageMcpConfig } from "./mcp.js";
9
+ import { claudeEffortFlagValue } from "./effort.js";
9
10
  import { createToolNameTracker } from "../../utils/tool-names.js";
10
11
  import { uuidv7 } from "../../utils/uuid.js";
11
12
  import { prepareWorkspace } from "../../utils/workspace.js";
@@ -105,7 +106,7 @@ export async function executeClaudeProvider(ctx) {
105
106
  if (model)
106
107
  args.push("--model", model);
107
108
  if (config.effort)
108
- args.push("--effort", config.effort);
109
+ args.push("--effort", claudeEffortFlagValue(config.effort));
109
110
  if (config.maxTurns && config.maxTurns > 0)
110
111
  args.push("--max-turns", String(config.maxTurns));
111
112
  if (config.instructionsFile)
@@ -1 +1 @@
1
- {"version":3,"file":"execute.js","sourceRoot":"","sources":["../../../src/providers/claude/execute.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,IAAI,MAAM,WAAW,CAAC;AAElC,OAAO,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AACnD,OAAO,EAAE,QAAQ,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAC/D,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAC5D,OAAO,EAAE,eAAe,EAA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2BAA2B,EAC3B,qBAAqB,EACrB,2BAA2B,EAC3B,qBAAqB,EACrB,gBAAgB,GACjB,MAAM,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/providers/claude/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAA2D,MAAM,gBAAgB,CAAC;AAkB9G,eAAO,MAAM,cAAc,EAAE,cAsE5B,CAAC;AAEF,OAAO,EACL,uBAAuB,EACvB,+BAA+B,EAC/B,oBAAoB,EACpB,oBAAoB,EACpB,mBAAmB,EACnB,mBAAmB,EACnB,iBAAiB,EACjB,eAAe,EACf,oBAAoB,GACrB,MAAM,iBAAiB,CAAC;AACzB,YAAY,EACV,8BAA8B,EAC9B,wBAAwB,EACxB,2BAA2B,EAC3B,qBAAqB,EACrB,2BAA2B,EAC3B,qBAAqB,EACrB,gBAAgB,GACjB,MAAM,iBAAiB,CAAC"}
@@ -17,7 +17,7 @@ export const claudeProvider = {
17
17
  type: "claude",
18
18
  capabilities: {
19
19
  sessions: true,
20
- modelDiscovery: false,
20
+ modelDiscovery: true,
21
21
  quotaProbing: true,
22
22
  mcp: true,
23
23
  skills: true,
@@ -52,6 +52,7 @@ export const claudeProvider = {
52
52
  execute: async (ctx) => (await import("./execute.js")).executeClaudeProvider(ctx),
53
53
  createSession: async (ctx) => (await import("./session.js")).createClaudeSession(ctx),
54
54
  resolveAuth: (ctx) => resolveAuthForProvider("claude", ctx),
55
+ listModels: (options) => import("./discovery.js").then((m) => m.listClaudeModels(options)),
55
56
  sessionCodec: claudeSessionCodec,
56
57
  checkQuota,
57
58
  transcript: claudeTranscriptOps,
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/providers/claude/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,sBAAsB,EAAE,MAAM,qBAAqB,CAAC;AACzE,OAAO,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AA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