@gajae-code/coding-agent 0.11.7 → 0.11.8
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/CHANGELOG.md +55 -0
- package/dist/types/cli/args.d.ts +0 -2
- package/dist/types/config/keybindings.d.ts +33 -3
- package/dist/types/config/model-profile-activation.d.ts +4 -3
- package/dist/types/config/model-profile-contract.d.ts +38 -0
- package/dist/types/config/settings-schema.d.ts +15 -2
- package/dist/types/edit/modes/patch.d.ts +13 -0
- package/dist/types/edit/path-mutation-lock.d.ts +15 -0
- package/dist/types/eval/py/executor.d.ts +1 -1
- package/dist/types/eval/py/tool-bridge.d.ts +1 -2
- package/dist/types/gjc-runtime/repository-binding.d.ts +63 -0
- package/dist/types/gjc-runtime/ultragoal-guard.d.ts +1 -0
- package/dist/types/gjc-runtime/ultragoal-runtime.d.ts +24 -0
- package/dist/types/main.d.ts +8 -0
- package/dist/types/modes/components/runtime-mcp-add-wizard.d.ts +2 -1
- package/dist/types/modes/components/tool-status-header.d.ts +3 -2
- package/dist/types/modes/components/welcome.d.ts +2 -0
- package/dist/types/modes/controllers/command-controller.d.ts +2 -0
- package/dist/types/modes/controllers/selector-controller.d.ts +2 -1
- package/dist/types/modes/interactive-mode.d.ts +5 -2
- package/dist/types/modes/prompt-action-autocomplete.d.ts +6 -1
- package/dist/types/modes/prompt-suggestion-controller.d.ts +35 -0
- package/dist/types/modes/shared/agent-wire/workflow-gate-broker.d.ts +2 -2
- package/dist/types/modes/types.d.ts +3 -0
- package/dist/types/modes/utils/hotkeys-markdown.d.ts +2 -1
- package/dist/types/runtime-mcp/manager.d.ts +1 -1
- package/dist/types/runtime-mcp/oauth-flow.d.ts +0 -5
- package/dist/types/runtime-mcp/plugin-network-boundary.d.ts +14 -0
- package/dist/types/sdk/broker/broker.d.ts +2 -0
- package/dist/types/sdk/broker/lifecycle.d.ts +6 -0
- package/dist/types/sdk/bus/chat-daemon-control.d.ts +5 -1
- package/dist/types/sdk/bus/config-commands.d.ts +2 -2
- package/dist/types/sdk/bus/config.d.ts +2 -0
- package/dist/types/sdk/bus/conversation-store.d.ts +1 -0
- package/dist/types/sdk/bus/index.d.ts +25 -0
- package/dist/types/sdk/bus/notification-orchestration.d.ts +1 -0
- package/dist/types/sdk/bus/prompt-reconciliation.d.ts +105 -0
- package/dist/types/sdk/bus/telegram-daemon-contract.d.ts +13 -3
- package/dist/types/sdk/bus/telegram-daemon-control.d.ts +5 -1
- package/dist/types/sdk/bus/telegram-daemon.d.ts +128 -1
- package/dist/types/sdk/bus/telegram-reference.d.ts +2 -0
- package/dist/types/sdk/host/control/operations.d.ts +1 -1
- package/dist/types/sdk/host/host.d.ts +1 -1
- package/dist/types/sdk/host/query/handlers.d.ts +9 -0
- package/dist/types/sdk/index.d.ts +2 -0
- package/dist/types/sdk/prompt-status.d.ts +88 -0
- package/dist/types/sdk/session-directory.d.ts +1 -1
- package/dist/types/sdk/startup-capability.d.ts +3 -0
- package/dist/types/session/agent-session.d.ts +2 -0
- package/dist/types/session/internal/managed-session-scope.d.ts +11 -2
- package/dist/types/session/internal/managed-session-storage.d.ts +17 -2
- package/dist/types/session/internal/native-publish-outcome.d.ts +48 -0
- package/dist/types/session/session-storage.d.ts +18 -0
- package/dist/types/task/index.d.ts +3 -1
- package/dist/types/task/receipt.d.ts +2 -0
- package/dist/types/task/types.d.ts +94 -0
- package/dist/types/tools/ask.d.ts +454 -174
- package/dist/types/tools/image-gen.d.ts +47 -1
- package/dist/types/tools/index.d.ts +4 -0
- package/dist/types/utils/prompt-suggestion.d.ts +33 -0
- package/package.json +8 -8
- package/scripts/capture-platform-shortcut-labels-showcase.ts +342 -0
- package/scripts/dogfood-repository-binding.ts +209 -0
- package/scripts/generate-sdk-operation-inventory.ts +2 -0
- package/scripts/run-test-manifest.ts +4 -4
- package/src/cli/args.ts +2 -92
- package/src/cli/notify-cli.ts +5 -38
- package/src/cli.ts +18 -0
- package/src/commands/sdk.ts +2 -2
- package/src/config/keybindings.ts +157 -24
- package/src/config/model-profile-activation.ts +7 -18
- package/src/config/model-profile-contract.ts +161 -0
- package/src/config/model-registry.ts +11 -1
- package/src/config/settings-schema.ts +17 -2
- package/src/coordinator-mcp/model-preset.ts +21 -74
- package/src/defaults/gjc/skills/deep-interview/SKILL.md +2 -2
- package/src/defaults/gjc/skills/ralplan/SKILL.md +3 -1
- package/src/edit/index.ts +3 -6
- package/src/edit/modes/patch.ts +38 -1
- package/src/edit/modes/replace.ts +42 -0
- package/src/edit/path-mutation-lock.ts +112 -0
- package/src/eval/py/executor.ts +30 -11
- package/src/eval/py/prelude.py +2 -2
- package/src/eval/py/tool-bridge.ts +34 -18
- package/src/extensibility/gjc-plugins/runtime-adapters.ts +2 -1
- package/src/gjc-runtime/launch-tmux.ts +1 -1
- package/src/gjc-runtime/managed-owner-supervisor.ts +83 -4
- package/src/gjc-runtime/ralplan-runtime.ts +75 -3
- package/src/gjc-runtime/repository-binding.ts +267 -0
- package/src/gjc-runtime/session-state-sidecar.ts +25 -9
- package/src/gjc-runtime/tmux-owner-isolation.ts +2 -1
- package/src/gjc-runtime/tmux-sessions.ts +45 -6
- package/src/gjc-runtime/ultragoal-guard.ts +5 -5
- package/src/gjc-runtime/ultragoal-runtime.ts +181 -19
- package/src/internal-urls/docs-index.generated.ts +6 -5
- package/src/internal-urls/local-protocol.ts +33 -16
- package/src/internal-urls/mcp-protocol.ts +73 -11
- package/src/main.ts +25 -10
- package/src/modes/DESIGN.md +5 -0
- package/src/modes/acp/acp-agent.ts +50 -16
- package/src/modes/components/model-selector.ts +42 -8
- package/src/modes/components/plan-preview-overlay.ts +1 -1
- package/src/modes/components/runtime-mcp-add-wizard.ts +5 -0
- package/src/modes/components/tool-status-header.ts +20 -4
- package/src/modes/components/welcome.ts +22 -18
- package/src/modes/controllers/command-controller.ts +97 -54
- package/src/modes/controllers/event-controller.ts +10 -0
- package/src/modes/controllers/input-controller.ts +7 -2
- package/src/modes/controllers/runtime-mcp-command-controller.ts +29 -6
- package/src/modes/controllers/selector-controller.ts +46 -54
- package/src/modes/interactive-mode.ts +41 -27
- package/src/modes/prompt-action-autocomplete.ts +32 -13
- package/src/modes/prompt-suggestion-controller.ts +96 -0
- package/src/modes/shared/agent-wire/workflow-gate-broker.ts +2 -2
- package/src/modes/types.ts +3 -0
- package/src/modes/utils/hotkeys-markdown.ts +64 -36
- package/src/modes/utils/ui-helpers.ts +5 -3
- package/src/prompts/agents/architect.md +0 -1
- package/src/prompts/agents/critic.md +0 -1
- package/src/prompts/system/prompt-suggestion-system.md +32 -0
- package/src/prompts/system/system-prompt.md +6 -4
- package/src/prompts/tools/cron.md +3 -1
- package/src/runtime-mcp/manager.ts +51 -53
- package/src/runtime-mcp/oauth-flow.ts +0 -72
- package/src/runtime-mcp/plugin-network-boundary.ts +101 -0
- package/src/runtime-mcp/transports/http.ts +13 -6
- package/src/sdk/broker/broker.ts +34 -20
- package/src/sdk/broker/lifecycle.ts +185 -36
- package/src/sdk/bus/chat-daemon-control.ts +18 -5
- package/src/sdk/bus/config-commands.ts +2 -2
- package/src/sdk/bus/config.ts +9 -1
- package/src/sdk/bus/conversation-store.ts +40 -6
- package/src/sdk/bus/index.ts +240 -65
- package/src/sdk/bus/lifecycle-commands.ts +47 -3
- package/src/sdk/bus/lifecycle-control-runtime.ts +11 -2
- package/src/sdk/bus/lifecycle-orchestrator.ts +32 -1
- package/src/sdk/bus/notification-orchestration.ts +12 -0
- package/src/sdk/bus/notification-service.ts +27 -2
- package/src/sdk/bus/prompt-reconciliation.ts +239 -0
- package/src/sdk/bus/recent-activity.ts +90 -26
- package/src/sdk/bus/telegram-daemon-contract.ts +13 -3
- package/src/sdk/bus/telegram-daemon-control.ts +145 -33
- package/src/sdk/bus/telegram-daemon.ts +835 -110
- package/src/sdk/bus/telegram-reference.ts +20 -2
- package/src/sdk/cli/session-cli.ts +15 -2
- package/src/sdk/host/control/dispatch.ts +1 -1
- package/src/sdk/host/control/operations.ts +1 -1
- package/src/sdk/host/host.ts +2 -6
- package/src/sdk/host/query/handlers.ts +70 -5
- package/src/sdk/index.ts +12 -0
- package/src/sdk/prompt-status.ts +97 -0
- package/src/sdk/protocol/operation-inventory.generated.json +47 -0
- package/src/sdk/protocol/operation-registry.ts +18 -4
- package/src/sdk/session-directory.ts +5 -1
- package/src/sdk/session.ts +2 -0
- package/src/sdk/startup-capability.ts +9 -1
- package/src/session/agent-session.ts +52 -5
- package/src/session/blob-store.ts +7 -2
- package/src/session/internal/managed-session-scope.ts +854 -84
- package/src/session/internal/managed-session-storage.ts +251 -199
- package/src/session/internal/native-publish-outcome.ts +266 -0
- package/src/session/session-manager.ts +310 -327
- package/src/session/session-storage.ts +128 -11
- package/src/task/gjc-command.ts +2 -2
- package/src/task/index.ts +121 -15
- package/src/task/receipt.ts +3 -0
- package/src/task/types.ts +34 -3
- package/src/tools/ask.ts +198 -88
- package/src/tools/ast-edit.ts +2 -2
- package/src/tools/bash-pty-selection.ts +2 -2
- package/src/tools/browser/screenshot-format.ts +6 -1
- package/src/tools/cron.ts +1 -1
- package/src/tools/image-gen.ts +178 -6
- package/src/tools/index.ts +4 -0
- package/src/tools/render-utils.ts +7 -1
- package/src/utils/edit-mode.ts +2 -2
- package/src/utils/prompt-suggestion.ts +265 -0
- package/src/utils/sixel.ts +3 -3
- package/src/web/insane/url-guard.ts +3 -1
- package/src/web/scrapers/docs-rs.ts +30 -5
package/CHANGELOG.md
CHANGED
|
@@ -2,22 +2,67 @@
|
|
|
2
2
|
|
|
3
3
|
## [Unreleased]
|
|
4
4
|
|
|
5
|
+
## [0.11.8] - 2026-07-23
|
|
6
|
+
### Added
|
|
7
|
+
|
|
8
|
+
- Keybinding configuration now keeps portable canonical text while runtime shortcut labels render platform-native, including concise MacBook glyphs in inline surfaces and glyph-plus-text accessibility labels in `/hotkeys` and `/help`; `/hotkeys` remains authoritative for effective remapped bindings.
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
|
|
12
|
+
- Plans and delegated tasks carry an authoritative repository binding (`gjc.repository_binding.v1`). Ultragoal/ralplan stamp identity at creation; task lanes stamp omitted bindings from session cwd **before** agent discovery; ralplan stage writes and handoff re-entry enforce the seed binding; declared paths must stay under the bound root; task receipts include the resolved identity; linked isolation worktrees must match the source repository (#2901).
|
|
13
|
+
|
|
14
|
+
### Fixed
|
|
15
|
+
|
|
16
|
+
- Runtime MCP OAuth credentials are now bound to their authorized server origin and token endpoint, reject redirecting refresh responses, and fail closed when legacy or changed configuration lacks an exact match.
|
|
17
|
+
- `/share` now keeps full-session HTML in owner-private unpredictable staging until the share handler or `gh gist create` process has fully stopped; cancelling a blocked gist upload terminates and awaits that process before reporting cancellation and removing the export.
|
|
18
|
+
- Telegram notification daemon self-heals degraded on-disk state: permanently missing scan roots are pruned (so one deleted worktree no longer disables orphan-topic cleanup), and retained exact-unlink transition/placeholder artifacts are reaped on ownership acquire and each scan. `gjc daemon reload` can recover without manual filesystem surgery (#2956).
|
|
19
|
+
- On macOS, resuming a managed session no longer fails with `identity_mismatch` when the first write-append open changes only file `ctime` (e.g. APFS write-provenance / `com.apple.provenance`). `appendSync` allows a single bounded re-capture + retry when `dev`/`ino`/`size`/`mtime`/SHA-256 remain unchanged, and still rejects real content races and repeated ctime transitions (#2944).
|
|
20
|
+
- Interactive `/resume` / `AgentSession.switchSession()` now awaits verified managed `local://` legacy-root migration for the newly selected session before post-commit lifecycle proceeds, matching cold-start `createAgentSession()` readiness from #2797 so synchronous `local://` resolution no longer fails with "legacy migration must complete before path resolution" after a mid-session switch (#2925).
|
|
21
|
+
- Concurrent edits to the same file path are serialized through a path-scoped mutation lock (in-process always; durable cross-process lock on the real filesystem). Disjoint concurrent `applyPatch` / replace mutations no longer silently overwrite each other, and a commit-time content check rejects writers that observe a mid-flight change (#2900).
|
|
22
|
+
- Concurrent edits to the same file path are serialized through a path-scoped mutation lock (in-process always; durable cross-process lock on the real filesystem). Disjoint concurrent `applyPatch` / replace mutations no longer silently overwrite each other, and a commit-time content check rejects writers that observe a mid-flight change. The production `executePatchSingle` / `LspFileSystem` path explicitly enables the durable lock rather than inferring it from FileSystem object identity (#2900).
|
|
23
|
+
- Lean notification verbosity no longer floods remote clients with intermediate tool-turn `turn_stream` frames. Under `/lean`, the latest assistant answer is deferred until `agent_end` (idle); ask lead-ins still flush immediately before inline buttons, and `/verbose` keeps per-turn streaming (including opt-in live frames) (#2863).
|
|
24
|
+
- Ultragoal `complete-goals` no longer reports contradictory next actions when every incomplete story is `blocked` or `review_blocked`. Text and JSON now agree on `next-action=resolve-blockers` with blocked goal IDs/status; failed-only schedules surface `retry-failed`; `execute-goal` always includes a `goal_id` (#2903).
|
|
25
|
+
- Bound each Python tool bridge bearer capability to one active session registration, reject non-canonical or empty bearer credentials before lookup, and rotate authority whenever a retained session replaces its kernel.
|
|
26
|
+
- Deep Interview now scopes provider-facing `ask` metadata to the persisted workflow stage, including after durable session resume: Round 0 advertises only the locked `intent_contract` branch, later rounds advertise ordinary and `intent_review` branches, foreign workflow gates cannot seed recorder state, and wire-valid empty positive-round reviews reach canonical Zod diagnostics while malformed authority remains fail-closed.
|
|
27
|
+
- Bounded docs.rs rustdoc downloads, legacy cache reads, and gzip expansion before parsing or caching; transport-level content encoding is disabled and rejected so Bun cannot decompress outside the explicit output guard.
|
|
28
|
+
|
|
29
|
+
### Added
|
|
30
|
+
|
|
31
|
+
- Added SDK v3 prompt reconciliation through `turn.prompt_status` with caller-supplied `clientRef` correlation, bounded live-session lifecycle retention, reconnect-safe lookup, and explicit ordered non-replay semantics for `turn.prompt` (#2930).
|
|
32
|
+
- Added `models.profiles.list` discovery of the effective built-in plus `models.yml` profile catalog, exact-ID pre-spawn validation that reloads host configuration for each lifecycle request, and structured `unknown_model_profile` / `model_profile_registry_error` details across lifecycle startup failures (#2931).
|
|
33
|
+
|
|
5
34
|
## [0.11.7] - 2026-07-22
|
|
6
35
|
### Added
|
|
7
36
|
|
|
8
37
|
- `/btw` now opens an ephemeral multi-turn side chat: plain text continues the side thread until Esc returns to the main chat, while visible text-only context stays outside the main transcript and session observability/debug hooks and is scrubbed synchronously on close or abort.
|
|
9
38
|
- Added `statusLine.showActionHints` (default: `true`) to hide contextual action hints while retaining configured status-line segments.
|
|
10
39
|
- `skill_discovery` empty results now carry a `notice` when discovery config caused the emptiness — naming the exact disabled setting (`skills.enabled`, `skills.enablePiProject`, or `skills.enablePiUser`) and the `gjc config set` command to enable it. Previously a disabled config was indistinguishable from "no skills exist", silently hiding freshly written user/project skills.
|
|
40
|
+
- `generate_image` now supports Alibaba Bailian (Token Plan) `wan2.7-image` as an image provider: set `providers.image` to `alibaba` (or let auto-detect find `ALIBABA_TOKEN_PLAN_API_KEY` / a registered `alibaba-token-plan` key), override the model with `providers.imageModel` (e.g. `wan2.7-image-pro`). Short-lived OSS result URLs are downloaded immediately, and image editing works via input images.
|
|
11
41
|
|
|
12
42
|
### Fixed
|
|
43
|
+
- Telegram `/session_recent` now retries one concurrently appended managed transcript and omits only candidates that remain unstable, preserving independently verified recent-session rows.
|
|
44
|
+
- Repeated byte-identical stale SDK broker locks no longer cause startup to loop when a prior tombstone exists.
|
|
45
|
+
- ACP session close now rotates idempotency keys for resumed attachment generations while retaining the same key across terminally uncertain close retries.
|
|
46
|
+
- ConversationStore now tolerates only unsupported Windows parent-directory durability errors after preserving temporary-file fsync and atomic rename.
|
|
47
|
+
- Ralplan no longer re-asks for execution approval when the user already explicitly named `ultragoal` or `team` in the current turn; that naming is the consent.
|
|
13
48
|
|
|
49
|
+
- Cron guidance now routes silent recurring polling and event-driven PR/CI watchers to `monitor`, because every cron firing starts a normal assistant turn and prompt wording cannot reliably suppress its response.
|
|
14
50
|
- Ordinary `ask` calls now normalize a provider-emitted `deepInterview: null` placeholder instead of misclassifying it as malformed Round-0 intent recovery data and rejecting it before coercion.
|
|
51
|
+
- SDK event replay authorization now refreshes the negotiated capability cache synchronously from the native-sanitized replay snapshot before host filtering, preserving initial and repeated-hello capability updates without trusting client frame claims.
|
|
52
|
+
|
|
53
|
+
- Plugin-bundle HTTP and SSE MCP requests now bind every connection to a validated public address and revalidate bounded redirects before following them.
|
|
54
|
+
- Deep Interview now exposes stage-specific provider-facing `ask` metadata: Round 0 advertises only the locked `intent_contract` branch, while later rounds advertise ordinary and `intent_review` branches, preventing strict-schema constraint stripping from making an invalid empty Round 0 review selectable.
|
|
55
|
+
- Deep Interview now exposes stage-specific provider-facing `ask` metadata, including after durable session resume: Round 0 advertises only the locked `intent_contract` branch, while later rounds advertise ordinary and `intent_review` branches. Remaining strict-schema constraints that providers cannot express fail closed with bounded corrective guidance instead of an opaque retry loop.
|
|
56
|
+
- Deep Interview now exposes stage-specific provider-facing `ask` metadata, including after durable session resume: Round 0 advertises only the locked `intent_contract` branch, while later rounds advertise ordinary and `intent_review` branches. Foreign workflow gates can no longer seed Deep Interview recorder state, and remaining strict-schema constraints that providers cannot express fail closed with bounded corrective guidance instead of an opaque retry loop.
|
|
15
57
|
- Documented that custom OpenAI-compatible models omit vision by default: when `input` is unset, GJC treats the model as text-only and strips images with `[image omitted: model does not support vision]`. Vision backends must set `input: [text, image]` in `models.yml`.
|
|
16
58
|
- Restored `/models` preset landing navigation after the Image Generation row and made compaction/pruning regression fixtures use an explicit 200K context boundary instead of a mutable provider descriptor default.
|
|
17
59
|
- Fixed Windows legacy session artifact migration by using native directory identity size, a traversable detached-path alias, and writable file handles for final durability sync.
|
|
18
60
|
- `gjc setup credentials` now auto-imports only OAuth credentials with a finite expiry strictly in the future. Expired or malformed-expiry discoveries remain visible as non-importable records, and existing imported credentials remain recoverable through `/login`.
|
|
19
61
|
- Resumed managed sessions now complete the verified legacy `local://` artifact migration before synchronous path resolution, preserving legacy scratch files instead of failing startup with a migration-order error.
|
|
20
62
|
- Corrected Telegram's uncertain lifecycle guidance so create, close, and resume commands describe their own possible outcome; close and resume no longer display the create-only duplicate-start warning.
|
|
63
|
+
- Telegram ask notifications now preserve the authoritative recommended choice from native asks and workflow gates, marking that option as `(Recommended)` in the message body without changing button indices or submitted answers.
|
|
64
|
+
- Telegram `/session_close` now fails closed when tmux disappearance cannot be confirmed, and publishes the managed owner verdict before locked terminal-state preservation so normal close finalization is not delayed behind that state path.
|
|
65
|
+
- Managed publication now fails closed on malformed, committed, or mutation-unknown native outcomes: it never retries or cleans a destination, and preserves bounded atomic-unavailable/durability diagnostics through managed startup (#2804).
|
|
21
66
|
|
|
22
67
|
## [0.11.5] - 2026-07-20
|
|
23
68
|
### Fixed
|
|
@@ -38,12 +83,14 @@
|
|
|
38
83
|
- Shell environment snapshots now use one process-private temporary root with exclusive private files, trusted cache validation, and whole-root shutdown cleanup instead of a predictable shared directory.
|
|
39
84
|
- Python kernel startup now materializes its bundled runner in one process-private temporary directory with exclusive file creation instead of consulting a predictable shared cache path.
|
|
40
85
|
- SSH command construction and discovery now reject malformed destinations with unsafe prefixes or control characters while preserving normal host, address, username, and alias forms.
|
|
86
|
+
- Bounded MCP resource URI and template matching now skips oversized templates and uses deterministic literal-segment matching instead of dynamically constructed regular expressions.
|
|
41
87
|
- Fixed the `subagent` tool's `resume` action silently swallowing manager failures. Resume outcomes other than `context_unavailable`/`not_found` (`no_runner`, `resume_failed`, `owner_shutdown_in_progress`, …) were dropped and the stale terminal subagent snapshot was returned as if the resume had succeeded, so ralplan's re-review loop believed the persisted Planner had resumed when it had not and never fell back correctly. The resume action now surfaces every non-ok reason (matching the `steer` branch), and the task resume runner marks a resumed subprocess that aborted or exited non-zero as a `failed` job (carrying its rendered failure summary) instead of reporting it `completed`.
|
|
42
88
|
- Daemon timeout flags now reject missing, malformed, non-positive, fractional, whitespace-containing, and unsafe integer values before daemon command side effects instead of partially parsing them.
|
|
43
89
|
- Hardened standalone HTML session exports so session identifiers, provider/model labels, and embedded raster images remain confined to their intended HTML contexts; malformed image payloads are omitted.
|
|
44
90
|
- Restored legacy `gjc coordinator-mcp` and root `gjc --team --team-size <n>` routing to their native MCP and team commands, with strict team-size validation that prevents malformed legacy flags from selecting team lifecycle actions.
|
|
45
91
|
- Fixed the `subagent` tool's `resume` action silently swallowing manager failures. Resume outcomes other than `context_unavailable`/`not_found` (`no_runner`, `resume_failed`, `owner_shutdown_in_progress`, …) were dropped and the stale terminal subagent snapshot was returned as if the resume had succeeded, so ralplan's re-review loop believed the persisted Planner had resumed when it had not and never fell back correctly. The resume action now surfaces every non-ok reason (matching the `steer` branch), and the task resume runner marks a resumed subprocess that aborted or exited non-zero as a `failed` job (preserving its error text) instead of reporting it `completed`.
|
|
46
92
|
- OpenRouter image generation now retrieves provider-returned HTTP(S) images only through connection-bound public-address validation, revalidates bounded redirects, and enforces image content-type and byte limits before buffering.
|
|
93
|
+
- Fixed session resume crashing with `TypeError: undefined is not an object (evaluating 'usage.input')`, and hardened both usage-aggregation paths against silent total corruption, when a persisted transcript contained a parseable-but-malformed assistant or `task` tool-result entry — as produced by torn concurrent multi-writer / NFS appends. `parseSessionEntries` accepts any parseable JSON, so a corrupt `usage` could be absent, `{}` (NaN totals), numeric strings (`"0" + "10"` → `"010"`), negative (silently reducing totals), a present-but-null/incomplete `premiumRequests`/`cost`, a non-record `cost` (e.g. an array), or cumulatively overflow to `Infinity`. Both the resume (`#buildIndex`) and runtime append (`#appendEntry`) paths now route through one shared validator that requires every usage bucket and `cost.total` to be finite non-negative numbers (defaulting only truly-absent `premiumRequests`/`cost`, and rejecting present-but-null/incomplete fields rather than zeroing them) and rejects any record that would overflow cumulative totals, skipping and reporting the malformed record instead of poisoning every `getUsageStatistics()` consumer.
|
|
47
94
|
- Fixed the `subagent` tool's `resume` failing immediately for a persisted ralplan Planner. A subagent that finishes by calling `yield` (or is torn down right after a tool executes) left the saved session ending on an assistant `toolCall` with no matching `toolResult`; replaying that history on resume produced an invalid provider request (a `tool_use` not followed by a `tool_result`) that failed the resumed turn at once. Resumed transcripts now reconcile any trailing unpaired tool call with a synthesized placeholder result before the first resumed prompt. Additionally, a failed/no-op resume leg no longer overwrites the prior run's success output artifact with an empty file.
|
|
48
95
|
- Fixed persisted subagent resumes being rejected before session reconstruction with `Session is inside managed storage but is not an authorized managed candidate`. Child session files intentionally live inside their parent session's artifact directory and are not top-level resume-picker candidates; the task resume path now explicitly opens the exact internally registered child session directory while retaining strict candidate validation for user-selected managed sessions.
|
|
49
96
|
- Managed session resume scans now read only a bounded no-follow header prefix from foreign workspace transcripts, while fully recapturing and revalidating owned candidates before granting migration, receipt, or deletion authority.
|
|
@@ -87,6 +134,10 @@
|
|
|
87
134
|
### Changed
|
|
88
135
|
- The `read` tool is now receipt-by-default: bare and unparseable reads return a bounded receipt (≤50 lines / 10 KiB) with a re-read-with-selector footer only when truncated, `:raw` stays pure verbatim up to a max(2 MiB, spill threshold) ceiling, structural summaries cap unit-granularly at 20 KiB while preserving elision and source-recovery footers, and directories are byte/line capped and never spill. Only an explicit full-content selector (`:raw` or an explicit range) with real content is spill-eligible. Subagent previews now enforce a real byte/code-point cap via per-shape render budgets plus a shape-aware artifact-eligibility tag enforced centrally in output-meta.
|
|
89
136
|
|
|
137
|
+
|
|
138
|
+
### Fixed
|
|
139
|
+
- Ultragoal objective ownership no longer treats arbitrary strings that merely mention `goals.json`/`ledger.jsonl` as Ultragoal-owned; only the exact default aggregate objective qualifies for the known-objective path.
|
|
140
|
+
|
|
90
141
|
### Fixed
|
|
91
142
|
- Workflow-state handoff no longer self-locks the active-state cache, so a same-turn skill handoff (e.g. ultragoal → ralplan) completes instead of stalling behind a lock the handoff itself still holds (#2638).
|
|
92
143
|
- SDK host shutdown now retries a failed broker unregister instead of short-circuiting with a stale broker-index entry, while retained startup-cleanup owner-release failures remain isolated from the red extension-error path (#2625).
|
|
@@ -120,6 +171,7 @@
|
|
|
120
171
|
### Fixed
|
|
121
172
|
- Repository LSP configuration can no longer define process-affecting server behavior: project files may control declarative matching, activation, and capabilities, but cannot set launch fields, initialization options, or opaque server settings. Trusted canonical user configuration outside the project retains those overrides; project-controlled plugin roots and the quarantined `--plugin-dir` surface cannot inject them. Automatic discovery uses trusted external executables and rejects repository-owned lexical paths as well as symlink-resolved project binaries; status uses the session cwd as its lspmux trust root. `GJC_DISABLE_LSPMUX=1` is the canonical opt-out and `PI_DISABLE_LSPMUX=1` is a supported compatibility alias; either truthy value disables lspmux probing and wrapping.
|
|
122
173
|
- Palette slash commands now run only from an empty composer; drafts are never touched.
|
|
174
|
+
- Individual default and named-role model assignments now keep the model selector open for consecutive choices, while batch assignments retain their existing close-on-success behavior.
|
|
123
175
|
- Aborting a session without an enabled active goal no longer suppresses the first reminder when a goal is activated later; active-goal abort suppression is one-shot, goal-owned, and clears across inactive or replacement-goal transitions (#2436).
|
|
124
176
|
- Palette slash submissions no longer clear or rewrite composer text, cursor state, history, or pending images created while an asynchronous input hook is awaiting; canonical keyboard submission cleanup remains unchanged (#2441).
|
|
125
177
|
- Dead browser-tab recovery now expires descriptors without releasing replacement, revived, or differently owned tabs, while exactly-once teardown closes stale targets and releases browser holds without refcount underflow (#2437).
|
|
@@ -145,6 +197,9 @@
|
|
|
145
197
|
### Fixed
|
|
146
198
|
- Connected MCP server instructions now remain untrusted user-role data instead of entering the cached system prompt; hostile file paths, working directories, and workspace-tree metadata are structurally encoded, and volatile project context is removed from durable session history between requests.
|
|
147
199
|
- Restored the strict G002 public-surface quarantine by removing the default README advertisement for the private coordinator MCP runtime.
|
|
200
|
+
### Added
|
|
201
|
+
|
|
202
|
+
- Added opt-in prompt suggestions (Claude Code-style ghost-text autocomplete): with the `promptSuggestions` setting enabled, a smol-model prediction of your likely next prompt renders as dim ghost text in the empty composer after each agent turn; Tab accepts it, typing dismisses it, and a new turn clears it. Predictions are heuristically gated (silence on evaluative/meta/agent-voice/overlong output) and never generated while the composer has text or a turn is streaming.
|
|
148
203
|
|
|
149
204
|
## [0.11.1] - 2026-07-16
|
|
150
205
|
|
package/dist/types/cli/args.d.ts
CHANGED
|
@@ -378,6 +378,10 @@ declare function migrateKeybindingsConfigFile(agentDir: string): void;
|
|
|
378
378
|
export declare class KeybindingsManager extends TuiKeybindingsManager {
|
|
379
379
|
#private;
|
|
380
380
|
constructor(userBindings?: KeybindingsConfig, configPath?: string);
|
|
381
|
+
/**
|
|
382
|
+
* Replace user bindings only after canonical grammar validation.
|
|
383
|
+
*/
|
|
384
|
+
setUserBindings(userBindings: KeybindingsConfig): void;
|
|
381
385
|
/**
|
|
382
386
|
* Create from config file at agentDir/keybindings.json.
|
|
383
387
|
*/
|
|
@@ -386,6 +390,11 @@ export declare class KeybindingsManager extends TuiKeybindingsManager {
|
|
|
386
390
|
* Create an in-memory keybindings manager without file persistence.
|
|
387
391
|
*/
|
|
388
392
|
static inMemory(userBindings?: KeybindingsConfig): KeybindingsManager;
|
|
393
|
+
/**
|
|
394
|
+
* Set the default display context used by composed surfaces that do not
|
|
395
|
+
* supply an explicit context.
|
|
396
|
+
*/
|
|
397
|
+
setDisplayContext(context: KeyDisplayContext): void;
|
|
389
398
|
/**
|
|
390
399
|
* Reload keybindings from the config file.
|
|
391
400
|
*/
|
|
@@ -397,9 +406,30 @@ export declare class KeybindingsManager extends TuiKeybindingsManager {
|
|
|
397
406
|
/**
|
|
398
407
|
* Get display string for a keybinding (e.g., "ctrl+c/escape").
|
|
399
408
|
*/
|
|
400
|
-
getDisplayString(keybinding: Keybinding): string;
|
|
409
|
+
getDisplayString(keybinding: Keybinding, context?: KeyDisplayContext): string;
|
|
410
|
+
/**
|
|
411
|
+
* Get an accessibility-oriented display string for help surfaces.
|
|
412
|
+
* Darwin chords include both the concise glyphs and expanded key names.
|
|
413
|
+
*/
|
|
414
|
+
getAccessibleDisplayString(keybinding: Keybinding, context?: KeyDisplayContext): string;
|
|
415
|
+
/**
|
|
416
|
+
* Format a fixed key chord using this manager's display context.
|
|
417
|
+
*/
|
|
418
|
+
formatKeyHint(key: string): string;
|
|
419
|
+
/**
|
|
420
|
+
* Format a fixed key chord for accessibility-oriented help surfaces.
|
|
421
|
+
*/
|
|
422
|
+
formatAccessibleKeyHint(key: string): string;
|
|
423
|
+
}
|
|
424
|
+
/**
|
|
425
|
+
* Key hint formatting utilities for UI labels.
|
|
426
|
+
*/
|
|
427
|
+
export interface KeyDisplayContext {
|
|
428
|
+
platform: NodeJS.Platform;
|
|
401
429
|
}
|
|
402
|
-
export declare function formatKeyHint(key:
|
|
403
|
-
export declare function
|
|
430
|
+
export declare function formatKeyHint(key: string, context?: KeyDisplayContext): string;
|
|
431
|
+
export declare function formatAccessibleKeyHint(key: string, context?: KeyDisplayContext): string;
|
|
432
|
+
export declare function formatKeyHints(keys: string | readonly string[], context?: KeyDisplayContext): string;
|
|
433
|
+
export declare function formatAccessibleKeyHints(keys: string | readonly string[], context?: KeyDisplayContext): string;
|
|
404
434
|
export type { Keybinding, KeybindingsConfig, KeyId };
|
|
405
435
|
export { migrateKeybindingsConfigFile };
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ThinkingLevel } from "@gajae-code/agent-core";
|
|
2
2
|
import type { Api, Model } from "@gajae-code/ai";
|
|
3
3
|
import type { AgentSession } from "../session/agent-session";
|
|
4
|
+
export { resolveModelProfileName } from "./model-profile-contract";
|
|
4
5
|
import { type GjcModelAssignmentTargetId, type ModelRegistry } from "./model-registry";
|
|
5
6
|
import { type ModelSelectorValue } from "./model-selector-value";
|
|
6
7
|
import type { Settings } from "./settings";
|
|
@@ -17,7 +18,9 @@ type ModelProfileActivationSession = Pick<AgentSession, "model" | "thinkingLevel
|
|
|
17
18
|
};
|
|
18
19
|
export interface PrepareModelProfileActivationOptions {
|
|
19
20
|
session: ModelProfileActivationSession;
|
|
20
|
-
modelRegistry: Pick<ModelRegistry, "getModelProfile" | "getModelProfiles" | "getAvailableModelProfileNames" | "getApiKeyForProvider" | "getAll" | "resolveCanonicalModel" | "getCanonicalVariants" | "getCanonicalId"
|
|
21
|
+
modelRegistry: Pick<ModelRegistry, "getModelProfile" | "getModelProfiles" | "getAvailableModelProfileNames" | "getApiKeyForProvider" | "getAll" | "resolveCanonicalModel" | "getCanonicalVariants" | "getCanonicalId"> & {
|
|
22
|
+
getError?: ModelRegistry["getError"];
|
|
23
|
+
};
|
|
21
24
|
settings: Pick<Settings, "get">;
|
|
22
25
|
profileName: string;
|
|
23
26
|
}
|
|
@@ -78,7 +81,6 @@ export declare class ModelProfileCredentialError extends Error {
|
|
|
78
81
|
constructor(profileLabel: string, providers: readonly string[]);
|
|
79
82
|
}
|
|
80
83
|
export declare function formatModelProfileCredentialError(profileLabel: string, providers: readonly string[]): string;
|
|
81
|
-
export declare function resolveModelProfileName(profileName: string, profiles: ReadonlyMap<string, unknown>): string;
|
|
82
84
|
export declare function prepareModelProfileActivation(options: PrepareModelProfileActivationOptions): Promise<PreparedModelProfileActivation>;
|
|
83
85
|
export declare function applyPreparedModelProfileActivation(prepared: PreparedModelProfileActivation, options?: ApplyModelProfileActivationOptions): Promise<void>;
|
|
84
86
|
export interface MaterializeModelProfileForDeletionResult {
|
|
@@ -99,4 +101,3 @@ export declare function restoreMaterializedModelProfileForDeletion(options: {
|
|
|
99
101
|
snapshot: MaterializeModelProfileForDeletionResult;
|
|
100
102
|
}): Promise<void>;
|
|
101
103
|
export declare function activateModelProfile(options: PrepareModelProfileActivationOptions, applyOptions?: ApplyModelProfileActivationOptions): Promise<void>;
|
|
102
|
-
export {};
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { type ModelProfileDefinition } from "./model-profiles";
|
|
2
|
+
export declare const MODEL_PROFILE_DISCOVERY_QUERY = "models.profiles.list";
|
|
3
|
+
export declare const MODEL_PROFILE_ERROR_DETAIL_MAX_BYTES = 2048;
|
|
4
|
+
export interface ModelProfileCatalogItem {
|
|
5
|
+
id: string;
|
|
6
|
+
displayName: string;
|
|
7
|
+
source: "builtin" | "configured";
|
|
8
|
+
}
|
|
9
|
+
export interface UnknownModelProfileDetails {
|
|
10
|
+
requestedProfile: string;
|
|
11
|
+
availableProfiles: string[];
|
|
12
|
+
discoveryQuery: typeof MODEL_PROFILE_DISCOVERY_QUERY;
|
|
13
|
+
}
|
|
14
|
+
export interface ModelProfileRegistryErrorDetails {
|
|
15
|
+
requestedProfile?: string;
|
|
16
|
+
availableProfiles: [];
|
|
17
|
+
discoveryQuery: typeof MODEL_PROFILE_DISCOVERY_QUERY;
|
|
18
|
+
}
|
|
19
|
+
export type ModelProfileErrorDetails = UnknownModelProfileDetails | ModelProfileRegistryErrorDetails;
|
|
20
|
+
export type ModelProfileErrorCode = "unknown_model_profile" | "model_profile_registry_error";
|
|
21
|
+
export declare class UnknownModelProfileError extends Error {
|
|
22
|
+
readonly code: "unknown_model_profile";
|
|
23
|
+
readonly details: UnknownModelProfileDetails;
|
|
24
|
+
constructor(requestedProfile: string, profiles: ReadonlyMap<string, unknown>);
|
|
25
|
+
}
|
|
26
|
+
export declare class ModelProfileRegistryError extends Error {
|
|
27
|
+
readonly code: "model_profile_registry_error";
|
|
28
|
+
readonly details: ModelProfileRegistryErrorDetails;
|
|
29
|
+
constructor(requestedProfile?: string);
|
|
30
|
+
}
|
|
31
|
+
export declare function resolveModelProfileName(profileName: string, profiles: ReadonlyMap<string, unknown>): string;
|
|
32
|
+
export declare function validateModelProfileName(profileName: string, profiles: ReadonlyMap<string, unknown>, registryError?: unknown): string;
|
|
33
|
+
export declare function projectModelProfileCatalog(profiles: ReadonlyMap<string, ModelProfileDefinition>, registryError?: unknown): ModelProfileCatalogItem[];
|
|
34
|
+
export declare function isModelProfileError(value: unknown): value is {
|
|
35
|
+
code: ModelProfileErrorCode;
|
|
36
|
+
message: string;
|
|
37
|
+
details: ModelProfileErrorDetails;
|
|
38
|
+
};
|
|
@@ -1561,6 +1561,15 @@ export declare const SETTINGS_SCHEMA: {
|
|
|
1561
1561
|
readonly description: "Suggest emojis from `:name:` shortcodes and expand text emoticons like `:D` or `:-)`";
|
|
1562
1562
|
};
|
|
1563
1563
|
};
|
|
1564
|
+
readonly promptSuggestions: {
|
|
1565
|
+
readonly type: "boolean";
|
|
1566
|
+
readonly default: false;
|
|
1567
|
+
readonly ui: {
|
|
1568
|
+
readonly tab: "interaction";
|
|
1569
|
+
readonly label: "Prompt Suggestions";
|
|
1570
|
+
readonly description: "Predict your likely next prompt after each turn (smol-model call) and show it as ghost text; Tab accepts";
|
|
1571
|
+
};
|
|
1572
|
+
};
|
|
1564
1573
|
readonly "startup.quiet": {
|
|
1565
1574
|
readonly type: "boolean";
|
|
1566
1575
|
readonly default: false;
|
|
@@ -3786,7 +3795,7 @@ export declare const SETTINGS_SCHEMA: {
|
|
|
3786
3795
|
};
|
|
3787
3796
|
readonly "providers.image": {
|
|
3788
3797
|
readonly type: "enum";
|
|
3789
|
-
readonly values: readonly ["auto", "openai", "gemini", "openrouter", "antigravity", "custom"];
|
|
3798
|
+
readonly values: readonly ["auto", "openai", "gemini", "openrouter", "antigravity", "alibaba", "custom"];
|
|
3790
3799
|
readonly default: "auto";
|
|
3791
3800
|
readonly ui: {
|
|
3792
3801
|
readonly tab: "providers";
|
|
@@ -3795,7 +3804,7 @@ export declare const SETTINGS_SCHEMA: {
|
|
|
3795
3804
|
readonly options: readonly [{
|
|
3796
3805
|
readonly value: "auto";
|
|
3797
3806
|
readonly label: "Auto";
|
|
3798
|
-
readonly description: "Priority: GPT model image tool > Antigravity > OpenRouter > Gemini";
|
|
3807
|
+
readonly description: "Priority: GPT model image tool > Antigravity > OpenRouter > Gemini > Alibaba";
|
|
3799
3808
|
}, {
|
|
3800
3809
|
readonly value: "openai";
|
|
3801
3810
|
readonly label: "OpenAI";
|
|
@@ -3812,6 +3821,10 @@ export declare const SETTINGS_SCHEMA: {
|
|
|
3812
3821
|
readonly value: "antigravity";
|
|
3813
3822
|
readonly label: "Antigravity";
|
|
3814
3823
|
readonly description: "Requires login with google-antigravity";
|
|
3824
|
+
}, {
|
|
3825
|
+
readonly value: "alibaba";
|
|
3826
|
+
readonly label: "Alibaba Bailian";
|
|
3827
|
+
readonly description: "Requires ALIBABA_TOKEN_PLAN_API_KEY (wan2.7-image via Token Plan)";
|
|
3815
3828
|
}, {
|
|
3816
3829
|
readonly value: "custom";
|
|
3817
3830
|
readonly label: "Custom";
|
|
@@ -41,11 +41,24 @@ export interface ApplyPatchOptions {
|
|
|
41
41
|
fuzzyThreshold?: number;
|
|
42
42
|
allowFuzzy?: boolean;
|
|
43
43
|
fs?: FileSystem;
|
|
44
|
+
/**
|
|
45
|
+
* When false, skip durable cross-process file locks (in-process path mutex
|
|
46
|
+
* still serializes). Defaults to true only for the real `defaultFileSystem`
|
|
47
|
+
* (or when `fs` is omitted). Disk-backed adapters that are not
|
|
48
|
+
* `defaultFileSystem` (notably production `LspFileSystem` via
|
|
49
|
+
* `executePatchSingle`) MUST pass `crossProcessLock: true` explicitly —
|
|
50
|
+
* object identity is not a durable-lock capability probe.
|
|
51
|
+
*/
|
|
52
|
+
crossProcessLock?: boolean;
|
|
44
53
|
}
|
|
45
54
|
/** Default filesystem implementation using Bun APIs */
|
|
46
55
|
export declare const defaultFileSystem: FileSystem;
|
|
47
56
|
/**
|
|
48
57
|
* Apply a patch operation to the filesystem.
|
|
58
|
+
*
|
|
59
|
+
* Concurrent mutations of the same absolute path are serialized (in-process always;
|
|
60
|
+
* cross-process file lock when using the real filesystem) so disjoint concurrent
|
|
61
|
+
* edits cannot silently overwrite each other (#2900).
|
|
49
62
|
*/
|
|
50
63
|
export declare function applyPatch(input: PatchInput, options: ApplyPatchOptions): Promise<ApplyPatchResult>;
|
|
51
64
|
/**
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { type FileLockOptions } from "../config/file-lock";
|
|
2
|
+
export type EditPathMutationOptions = {
|
|
3
|
+
/**
|
|
4
|
+
* When true (default), also acquire a durable cross-process file lock.
|
|
5
|
+
* Disable for injectible/in-memory filesystem tests that do not touch disk.
|
|
6
|
+
*/
|
|
7
|
+
crossProcess?: boolean;
|
|
8
|
+
fileLock?: FileLockOptions;
|
|
9
|
+
};
|
|
10
|
+
/**
|
|
11
|
+
* Run `fn` while holding exclusive mutation rights for every absolute path.
|
|
12
|
+
* Paths are locked in lexicographic order to avoid deadlocks on multi-path ops
|
|
13
|
+
* (e.g. rename source + destination).
|
|
14
|
+
*/
|
|
15
|
+
export declare function withEditPathMutation<T>(absolutePaths: readonly string[], fn: () => Promise<T>, options?: EditPathMutationOptions): Promise<T>;
|
|
@@ -7,7 +7,6 @@ export interface PyToolBridgeEntry {
|
|
|
7
7
|
}
|
|
8
8
|
export interface PyToolBridgeInfo {
|
|
9
9
|
url: string;
|
|
10
|
-
token: string;
|
|
11
10
|
}
|
|
12
11
|
/** Starts the bridge server lazily and returns its connection info. */
|
|
13
12
|
export declare function ensurePyToolBridge(): Promise<PyToolBridgeInfo>;
|
|
@@ -15,6 +14,6 @@ export declare function ensurePyToolBridge(): Promise<PyToolBridgeInfo>;
|
|
|
15
14
|
* Register a tool session for the duration of one execution. The returned
|
|
16
15
|
* function MUST be called to remove the entry once execution finishes.
|
|
17
16
|
*/
|
|
18
|
-
export declare function registerPyToolBridge(sessionId: string, entry: PyToolBridgeEntry): () => void;
|
|
17
|
+
export declare function registerPyToolBridge(sessionId: string, capability: string, entry: PyToolBridgeEntry): () => void;
|
|
19
18
|
/** Stop the bridge and clear registrations. Test-only / shutdown helper. */
|
|
20
19
|
export declare function disposePyToolBridge(): Promise<void>;
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import { type GitRepository } from "../utils/git";
|
|
2
|
+
export declare const REPOSITORY_BINDING_SCHEMA: "gjc.repository_binding.v1";
|
|
3
|
+
export interface RepositoryBinding {
|
|
4
|
+
schema: typeof REPOSITORY_BINDING_SCHEMA;
|
|
5
|
+
/** Canonical realpath of the git worktree root (or resolved cwd root). */
|
|
6
|
+
worktreeRoot: string;
|
|
7
|
+
/** Git common dir realpath when available; null outside a git checkout. */
|
|
8
|
+
commonDir: string | null;
|
|
9
|
+
/** Optional repo-relative subdirectory the lane should operate under. */
|
|
10
|
+
relativeSubdir?: string;
|
|
11
|
+
/** Optional display path (may be non-canonical); never used for authority. */
|
|
12
|
+
displayPath?: string;
|
|
13
|
+
/** Optional baseline HEAD at capture time. */
|
|
14
|
+
head?: string;
|
|
15
|
+
/** Optional branch name at capture time (when not detached). */
|
|
16
|
+
branch?: string;
|
|
17
|
+
}
|
|
18
|
+
export type RepositoryBindingErrorCode = "not_a_repository" | "identity_mismatch" | "path_outside_root" | "invalid_binding";
|
|
19
|
+
export declare class RepositoryBindingError extends Error {
|
|
20
|
+
readonly code: RepositoryBindingErrorCode;
|
|
21
|
+
constructor(code: RepositoryBindingErrorCode, message: string);
|
|
22
|
+
}
|
|
23
|
+
/** Capture a durable binding from the active cwd/worktree. */
|
|
24
|
+
export declare function captureRepositoryBinding(cwd: string, options?: {
|
|
25
|
+
relativeSubdir?: string;
|
|
26
|
+
displayPath?: string;
|
|
27
|
+
}): Promise<RepositoryBinding>;
|
|
28
|
+
/** Parse a binding from JSON/plan payload; fail closed on malformed shapes. */
|
|
29
|
+
export declare function parseRepositoryBinding(value: unknown): RepositoryBinding;
|
|
30
|
+
/** True when two bindings refer to the same repository identity (linked worktrees ok). */
|
|
31
|
+
export declare function repositoryBindingsMatch(left: RepositoryBinding, right: RepositoryBinding): boolean;
|
|
32
|
+
/**
|
|
33
|
+
* Ensure `cwd` is inside the bound repository (or the same linked worktree family).
|
|
34
|
+
* Fails closed on sibling-repo drift.
|
|
35
|
+
*/
|
|
36
|
+
export declare function assertCwdMatchesRepositoryBinding(cwd: string, binding: RepositoryBinding): Promise<RepositoryBinding>;
|
|
37
|
+
/** Ensure a declared target path resolves under the bound worktree root. */
|
|
38
|
+
export declare function assertPathUnderRepositoryBinding(binding: RepositoryBinding, targetPath: string): string;
|
|
39
|
+
/**
|
|
40
|
+
* Public identity snapshot for receipts/handoffs (no display-only fields required).
|
|
41
|
+
* Always includes the schema + durable roots so downstream lanes can re-verify.
|
|
42
|
+
*/
|
|
43
|
+
export declare function publicRepositoryBinding(binding: RepositoryBinding): RepositoryBinding;
|
|
44
|
+
/**
|
|
45
|
+
* Resolve the authoritative binding for a delegated task before discovery/spawn.
|
|
46
|
+
*
|
|
47
|
+
* - Missing declaration → stamp from session cwd (never leave authority implicit).
|
|
48
|
+
* - Declared binding → parse + fail closed unless it matches the active session worktree.
|
|
49
|
+
* - relativeSubdir (when present) must resolve under the bound root.
|
|
50
|
+
*/
|
|
51
|
+
export declare function resolveTaskRepositoryBinding(sessionCwd: string, declared: unknown | undefined): Promise<RepositoryBinding>;
|
|
52
|
+
/**
|
|
53
|
+
* Ensure an execution/isolation root (cwd or worktree) still matches the bound identity.
|
|
54
|
+
* Used after isolation workspace creation so linked worktrees keep the source repository.
|
|
55
|
+
*/
|
|
56
|
+
export declare function assertExecutionRootMatchesRepositoryBinding(executionRoot: string, binding: RepositoryBinding): Promise<RepositoryBinding>;
|
|
57
|
+
/** Optional helper for tests and diagnostics. */
|
|
58
|
+
export declare function bindingFromGitRepository(repository: GitRepository, options?: {
|
|
59
|
+
relativeSubdir?: string;
|
|
60
|
+
displayPath?: string;
|
|
61
|
+
head?: string;
|
|
62
|
+
branch?: string;
|
|
63
|
+
}): RepositoryBinding;
|
|
@@ -25,6 +25,7 @@ export interface CurrentGoalLike {
|
|
|
25
25
|
source: "user";
|
|
26
26
|
};
|
|
27
27
|
}
|
|
28
|
+
export declare function isKnownUltragoalObjective(currentObjective: string): boolean;
|
|
28
29
|
export declare function validateCompletionReceipt(input: {
|
|
29
30
|
plan: UltragoalPlan;
|
|
30
31
|
ledger: readonly UltragoalLedgerEvent[];
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { WorkflowHudSummary } from "../skill-state/active-state";
|
|
2
|
+
import { type RepositoryBinding } from "./repository-binding";
|
|
2
3
|
import { type CriticVerdict } from "./ultragoal-receipt-freshness";
|
|
3
4
|
export { CRITIC_GATE_HARD_STOP_EVENT, CRITIC_GATE_OVERRIDE_EVENT, CRITIC_VERDICT_EVENT, type CriticVerdict, computeUltragoalPlanGeneration, countTerminalCriticVerdicts, receiptRelevantGoals, TERMINAL_CRITIC_CEILING, terminalCriticCeilingReached, terminalCriticGateOverridden, } from "./ultragoal-receipt-freshness";
|
|
4
5
|
export { captureUltragoalRecoverySnapshot, parseStrictTerminalTranscript, persistUltragoalRecoveryDecision, planUltragoalOwnerLossRecovery, type UltragoalOwnerLossReceipt, type UltragoalRecoveryBinding, type UltragoalRecoveryDecision, type UltragoalRecoverySnapshot, validateOwnerLossBinding, validateRawUltragoalEvidence, validateRecoveryAdmission, validateRecoveryPath, } from "./ultragoal-owner-loss-recovery";
|
|
@@ -96,6 +97,8 @@ export interface UltragoalPlan {
|
|
|
96
97
|
gjcObjective: string;
|
|
97
98
|
gjcObjectiveAliases?: string[];
|
|
98
99
|
goals: UltragoalGoal[];
|
|
100
|
+
/** Authoritative repository identity for multi-repo fail-closed spawn (#2901). */
|
|
101
|
+
repositoryBinding?: RepositoryBinding;
|
|
99
102
|
createdAt: string;
|
|
100
103
|
updatedAt: string;
|
|
101
104
|
[key: string]: unknown;
|
|
@@ -308,6 +311,26 @@ export { joinUltragoalPipelineOverlap, rebaselineUltragoalPipelineOverlap, start
|
|
|
308
311
|
export declare function getUltragoalRunCompletionState(plan: UltragoalPlan, options?: {
|
|
309
312
|
retryFailed?: boolean;
|
|
310
313
|
}): UltragoalRunCompletionState;
|
|
314
|
+
/**
|
|
315
|
+
* Discriminated next-action for `complete-goals` handoff (#2903).
|
|
316
|
+
* `none` is reserved for genuine completion; `execute-goal` always carries a goal.
|
|
317
|
+
*/
|
|
318
|
+
export type UltragoalCompleteNextActionKind = "none" | "execute-goal" | "retry-failed" | "resolve-blockers" | "final-aggregate-receipt";
|
|
319
|
+
export type UltragoalCompleteNextAction = {
|
|
320
|
+
kind: UltragoalCompleteNextActionKind;
|
|
321
|
+
goal?: UltragoalGoal;
|
|
322
|
+
blockedGoals?: UltragoalGoal[];
|
|
323
|
+
failedGoals?: UltragoalGoal[];
|
|
324
|
+
};
|
|
325
|
+
/**
|
|
326
|
+
* Resolve the actionable next step after scheduling / complete-goals.
|
|
327
|
+
* Blocked and review_blocked goals remain unschedulable; they surface as
|
|
328
|
+
* `resolve-blockers` instead of a contradictory `execute-goal` without goal_id.
|
|
329
|
+
*/
|
|
330
|
+
export declare function resolveUltragoalCompleteNextAction(plan: UltragoalPlan, options?: {
|
|
331
|
+
retryFailed?: boolean;
|
|
332
|
+
selectedGoal?: UltragoalGoal;
|
|
333
|
+
}): UltragoalCompleteNextAction;
|
|
311
334
|
export declare function startNextUltragoalGoal(input: {
|
|
312
335
|
cwd: string;
|
|
313
336
|
retryFailed?: boolean;
|
|
@@ -316,6 +339,7 @@ export declare function startNextUltragoalGoal(input: {
|
|
|
316
339
|
plan: UltragoalPlan;
|
|
317
340
|
goal?: UltragoalGoal;
|
|
318
341
|
allComplete: boolean;
|
|
342
|
+
nextAction: UltragoalCompleteNextAction;
|
|
319
343
|
}>;
|
|
320
344
|
export declare function qualityGateObject(value: unknown): JsonObject | null;
|
|
321
345
|
export declare function nonEmptyStringArray(value: unknown): string[] | null;
|
package/dist/types/main.d.ts
CHANGED
|
@@ -153,6 +153,14 @@ export interface ModelRoleOverrides {
|
|
|
153
153
|
* invocation never inherits an earlier one's values.
|
|
154
154
|
*/
|
|
155
155
|
export declare function resolveModelRoleOverrides(parsed: Pick<Args, "smol" | "slow" | "plan">): ModelRoleOverrides;
|
|
156
|
+
/**
|
|
157
|
+
* Apply the `--no-pty` / `--no-title` terminal-control flags to the environment.
|
|
158
|
+
*
|
|
159
|
+
* Sets the canonical `GJC_*` name (so an explicit flag wins over a user-set
|
|
160
|
+
* `GJC_*` value under the GJC-first resolver — CLI authority) and the legacy
|
|
161
|
+
* `PI_*` name for backward compatibility. `--acp` mode implies `--no-title`.
|
|
162
|
+
*/
|
|
163
|
+
export declare function applyTerminalControlFlagsToEnv(parsed: Pick<Args, "noPty" | "noTitle" | "mode">, env?: NodeJS.ProcessEnv): void;
|
|
156
164
|
export declare function runRootCommand(parsed: Args, rawArgs: string[], deps?: RunRootCommandDependencies): Promise<void>;
|
|
157
165
|
export declare function main(args: string[]): Promise<void>;
|
|
158
166
|
export {};
|
|
@@ -14,12 +14,13 @@ type Scope = "user" | "project";
|
|
|
14
14
|
*/
|
|
15
15
|
export interface MCPAddWizardOAuthResult {
|
|
16
16
|
credentialId: string;
|
|
17
|
+
tokenEndpoint: string;
|
|
17
18
|
clientId?: string;
|
|
18
19
|
clientSecret?: string;
|
|
19
20
|
}
|
|
20
21
|
export declare class MCPAddWizard extends Container {
|
|
21
22
|
#private;
|
|
22
|
-
constructor(onComplete: (name: string, config: MCPServerConfig, scope: Scope) => void, onCancel: () => void, onOAuth?: (authUrl: string, tokenUrl: string, clientId: string, clientSecret: string, scopes: string) => Promise<MCPAddWizardOAuthResult>, onTestConnection?: (config: MCPServerConfig) => Promise<void>, onRender?: () => void, initialName?: string);
|
|
23
|
+
constructor(onComplete: (name: string, config: MCPServerConfig, scope: Scope) => void, onCancel: () => void, onOAuth?: (endpointUrl: string, authUrl: string, tokenUrl: string, clientId: string, clientSecret: string, scopes: string) => Promise<MCPAddWizardOAuthResult>, onTestConnection?: (config: MCPServerConfig) => Promise<void>, onRender?: () => void, initialName?: string);
|
|
23
24
|
dispose(): void;
|
|
24
25
|
handleInput(keyData: string): void;
|
|
25
26
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type Component } from "@gajae-code/tui";
|
|
2
|
-
import type
|
|
2
|
+
import { type AppKeybinding, type KeybindingsManager, type KeyDisplayContext } from "../../config/keybindings";
|
|
3
3
|
import type { StatusLinePreset, StatusLineSegmentId, StatusLineSeparatorStyle } from "../../config/settings-schema";
|
|
4
4
|
import type { AgentSession } from "../../session/agent-session";
|
|
5
5
|
import { type SkillActiveEntry } from "../../skill-state/active-state";
|
|
@@ -47,6 +47,7 @@ export interface StatusLineComponentOptions {
|
|
|
47
47
|
actionRegistry?: ActionRegistry<void>;
|
|
48
48
|
getKeybindings?: () => KeybindingsManager;
|
|
49
49
|
focusDomain?: FocusDomain;
|
|
50
|
+
keyDisplayContext?: KeyDisplayContext;
|
|
50
51
|
}
|
|
51
52
|
export interface StatusLineActionHint {
|
|
52
53
|
id: AppKeybinding;
|
|
@@ -57,7 +58,7 @@ export interface StatusLineActionHint {
|
|
|
57
58
|
* remains the authority for availability; KEYBINDINGS remains the authority for
|
|
58
59
|
* whether an action has a binding and the active manager supplies overrides.
|
|
59
60
|
*/
|
|
60
|
-
export declare function getAvailableActionHints(actionRegistry: ActionRegistry<void> | undefined, getKeybindings: (() => KeybindingsManager) | undefined, width: number, domain?: FocusDomain): StatusLineActionHint[];
|
|
61
|
+
export declare function getAvailableActionHints(actionRegistry: ActionRegistry<void> | undefined, getKeybindings: (() => KeybindingsManager) | undefined, width: number, domain?: FocusDomain, keyDisplayContext?: KeyDisplayContext): StatusLineActionHint[];
|
|
61
62
|
export declare class StatusLineComponent implements Component {
|
|
62
63
|
#private;
|
|
63
64
|
private readonly session;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { type Component } from "@gajae-code/tui";
|
|
2
|
+
import { type KeyDisplayContext } from "../../config/keybindings";
|
|
2
3
|
export interface RecentSession {
|
|
3
4
|
name: string;
|
|
4
5
|
timeAgo: string;
|
|
@@ -15,6 +16,7 @@ export interface WelcomeComponentOptions {
|
|
|
15
16
|
changelogMarkdown?: string;
|
|
16
17
|
collapseChangelog?: boolean;
|
|
17
18
|
buildLabel?: string;
|
|
19
|
+
keyDisplayContext?: KeyDisplayContext;
|
|
18
20
|
}
|
|
19
21
|
/**
|
|
20
22
|
* GJC-native launch surface with compact command affordances, project
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { type CompactionOutcome } from "@gajae-code/agent-core/compaction";
|
|
2
2
|
import { type ProviderDetails, type UsageReport } from "@gajae-code/ai";
|
|
3
|
+
import type { KeybindingsManager } from "../../config/keybindings";
|
|
3
4
|
import type { CompactOptions } from "../../extensibility/extensions/types";
|
|
4
5
|
import { theme } from "../../modes/theme/theme";
|
|
5
6
|
import type { InteractiveModeContext } from "../../modes/types";
|
|
7
|
+
export declare function buildHelpMarkdown(keybindings: Pick<KeybindingsManager, "getAccessibleDisplayString">): string;
|
|
6
8
|
export declare class CommandController {
|
|
7
9
|
#private;
|
|
8
10
|
private readonly ctx;
|
|
@@ -5,7 +5,7 @@ import type { InteractiveModeContext, OAuthSelectorOptions } from "../../modes/t
|
|
|
5
5
|
import { getNotificationConfig, maskToken } from "../../sdk/bus/config";
|
|
6
6
|
import { proposedTelegramIdentity, reconcileCommittedTelegramConfiguration, removeTelegramConfiguration, saveTelegramInactive } from "../../sdk/bus/notification-orchestration";
|
|
7
7
|
import { buildNotificationStatusReport, checkNotificationHealth, recoverNotifications, sanitizeDiagnostic, sendNotificationTest } from "../../sdk/bus/notification-service";
|
|
8
|
-
import { ensureTelegramDaemonRunningDetailed, unregisterNotificationRoot } from "../../sdk/bus/telegram-daemon";
|
|
8
|
+
import { ensureTelegramDaemonRunningDetailed, resolveTelegramSetupPreflight, unregisterNotificationRoot } from "../../sdk/bus/telegram-daemon";
|
|
9
9
|
import { runTelegramSetup } from "../../sdk/bus/telegram-setup";
|
|
10
10
|
import { type CredentialAutoImportStateStore } from "../../setup/credential-auto-import";
|
|
11
11
|
import { type CommandPaletteAction } from "../components/command-palette";
|
|
@@ -38,6 +38,7 @@ export interface NotificationsEditorOperationDependencies {
|
|
|
38
38
|
sanitizeDiagnostic: typeof sanitizeDiagnostic;
|
|
39
39
|
ensureTelegramDaemonRunningDetailed: typeof ensureTelegramDaemonRunningDetailed;
|
|
40
40
|
runTelegramSetup: typeof runTelegramSetup;
|
|
41
|
+
resolveTelegramSetupPreflight: typeof resolveTelegramSetupPreflight;
|
|
41
42
|
proposedTelegramIdentity: typeof proposedTelegramIdentity;
|
|
42
43
|
reconcileCommittedTelegramConfiguration: typeof reconcileCommittedTelegramConfiguration;
|
|
43
44
|
saveTelegramInactive: typeof saveTelegramInactive;
|