Extension commands (e.g. /sonnet) and TypeScript custom commands that
consume the input without calling the LLM return early from
session.prompt() with no agent turn. In ACP mode this left the pending
prompt promise unresolved, hanging the client forever.
Change session.prompt() to return Promise<boolean>: true when the LLM
was invoked, false when the command was fully handled locally.
#runPromptOrCommand calls #finishPrompt immediately on a false return so
the ACP turn completes.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
ACP_BUILTIN_SLASH_COMMANDS only carries primary names; the reserved set
passed to getRegisteredCommands was therefore missing aliases like
"models" (/model) and "force:" (/force). An extension registering one
of these aliases would appear in the palette but the builtin would win
at dispatch time (lookupBuiltinSlashCommand searches aliases too).
Export ACP_BUILTIN_RESERVED_NAMES from acp-builtins — the union of all
primary names and aliases for ACP-surfaced builtins — and use it as the
reserved set. Widen getRegisteredCommands parameter to ReadonlySet since
it only calls .has().
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Dispatch in AgentSession runs #tryExecuteExtensionCommand before
#tryExecuteCustomCommand, so the palette must reflect the same order.
Moving the extension-runner block before session.customCommands ensures
that on a name collision the advertised command matches what will
actually execute.
Update the test to assert the extension description wins over the
colliding custom TS description.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Update ordering comment in #buildAvailableCommands to document the
extension tier and explain why skills/custom TS commands intentionally
shadow extension commands (unlike interactive mode)
- Add CHANGELOG entry under [Unreleased]
- Add regression test: verifies extension commands surface in
available_commands_update and that a builtin-colliding extension
command is excluded via the reserved-set, with no duplicates
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
`#buildAvailableCommands` was omitting commands registered by extensions
via `extensionRunner.getRegisteredCommands()`. ACP clients (e.g. Zed)
never saw these in the `available_commands_update` notification, so they
couldn't forward the corresponding slash commands to the agent.
Mirrors the interactive-mode pattern: pass ACP builtin names as the
reserved set so extensions cannot shadow core commands.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
The streaming-spinner relocation in 61a57c1d2 re-added the trailing
"(preview)" label to expanded approval previews whenever a spinner frame
was active, breaking the #1992 contract. Expanded previews now drop the
label but keep the animated glyph so the volatile tail stays live.
- Raised Anthropic provider retries to 10 attempts and used a shared jittered exponential backoff for each retry.
- Updated coding-agent retry defaults and session delay calculation to a 500ms base with an 8,000ms jittered cap.
- Added tests that verify capped ten-step backoff sequences and recovery after repeated 502 errors.
- Separated non-contiguous diff regions with a single blank gap row, normalized after block-context insertion.
- Rendered gap rows as one dim ellipsis in the TUI and HTML export.
- Applied the same blank-separator dedupe and edge-trimming to hashline's compact diff preview.
- Added "available" status so recognized servers show under lazy mode without warmup.
- Rendered full welcome box as pre-TUI splash with fixed slot heights to avoid layout shift.
- Reported lazy servers as available in /status instead of omitting the section.
- Replaced minLevel/maxLevel range with explicit efforts array plus baked effortMap/supportsDisplay wire facts.
- Removed runtime enrichment layer and modelOmitsReasoningEffort; providers now read baked fields.
- Fixed dotted Opus 4.7/4.8 ids missing adaptive display via classifier-based predicates (#1373).
- Bumped model cache schema to v4 to invalidate pre-efforts rows.
- Added an `lsp.lazy` boolean setting with default `true` so LSP servers start on first use.
- Updated session startup logic to run LSP warmup only when `enableLsp`, UI is enabled, and lazy startup is disabled.
- Documented the new lazy LSP initialization behavior and defaults in SDK and LSP tool docs.
Route direct model role resolution through the configured pattern normalizer so comma-separated fallbacks are parsed before thinking selectors. Add resolver coverage for preserving :off and trying later entries.\n\nFixes #2228
- Normalized untrusted `questions` arguments by parsing double-encoded JSON strings and skipping invalid question entries before rendering.
- Added option normalization that dropped malformed option items while preserving valid entries in multi-choice rendering.
- Expanded ask tool renderer tests to verify malformed or unparsable questions no longer crash and now fall back safely.
- Renamed `packages/coding-agent/scripts/dev-launch` to `packages/coding-agent/scripts/omp` and updated the preload script reference in that launcher.
- Renamed `packages/coding-agent/scripts/dev-launch-preload.ts` to `packages/coding-agent/scripts/omp.ts` and adjusted its header comment.
- Updated the `install:dev` script in `package.json` to symlink the global `omp` command from the renamed launcher path.
- Centralized catalog and registry handling on `ModelSpec` and `buildModel`, resolving compatibility at model build time.
- Removed runtime compatibility detectors and switched provider request flows to direct `model.compat` reads.
- Added compat fields (`supportsReasoningParams`, `alwaysSendMaxTokens`, `strictResponsesPairing`, `whenThinking`).
- Persisted explicit compatibility overrides through `compatConfig` in discovery and cache merge paths.
- Switched `bin.omp` to `src/cli.ts` so `bun link`/`install.sh --source` work without a build.
- Added `publishBin` override so release rewrites `bin` to the prepack bundle `dist/cli.js`.
- Exported `applyPublishBin` and packed the agent with its published bin in the install smoke.
- Added Windows batch-command detection and COMSPEC-based cmd.exe resolution for MCP stdio spawns.
- Escaped and quoted batch command arguments, then routed .cmd and .bat commands through cmd /d /s /c.
- Updated the stdio transport tests to assert wrapped cmd.exe command arrays and escaping behavior.
- Updated usage-window reporting to track remaining account quota instead of required-account counts.
- Replaced the computed "needed" metric with a non-negative remaining-quota value derived from each window's total minus used fraction.
- Changed usage output lines from "need" to "capacity" and now show used/total accounts with remaining quota multiplier.
- Added catalog-level host/model predicates and compat resolvers.
- Extended compatibility types and model schema with timeout and replay flags.
- Replaced provider-specific heuristics with shared resolver-based checks.
- Updated host/identity and resolver tests to validate the new behavior.
- Added a `pasteText` handler to `HookEditorComponent` to forward non-bracketed OSC 5522 paste text into its inner editor.
- Added a `pasteText` handler to `HookInputComponent` that forwards text to the input and resets the interaction timeout.
- Extended hook editor and timeout tests to cover enhanced-paste payload absorption and behavior retention.
- Added type-to-search filtering across setting labels, IDs, values, and descriptions.
- Preserved selected item focus by ID when replacing settings during an active filter.
- Displayed search status, empty-filter hints, and no-match messaging while searching.
- Updated Escape handling to clear an active query before cancelling the list.
- Applied selection and navigation to filtered items to keep behavior consistent under search.
Resolved the Windows stdio MCP regression by keeping resolved .cmd shims on the direct argv spawn path instead of rewriting them through cmd.exe /c. Added regression coverage for explicit and PATHEXT-resolved codegraph.cmd commands.\n\nFixes #2220
Move bundled models, model cache/manager, thinking metadata, effort helpers,
provider descriptors/discovery, wire constants, and model identity utilities
into the new @oh-my-pi/pi-catalog package.
Update pi-ai to keep provider runtime/auth concerns, move catalog provider
metadata into CATALOG_PROVIDERS, and migrate coding-agent, agent, stats, docs,
and tests to import catalog values from pi-catalog.
Split coding-agent model registry helpers into discovery, roles, and models
config modules while preserving registry orchestration.
BREAKING CHANGE: @oh-my-pi/pi-ai no longer exports catalog subpaths such as
/models, /model-cache, /model-manager, /model-thinking, /effort,
/provider-models*, discovery helpers, and provider wire constants; use the
matching @oh-my-pi/pi-catalog subpaths instead.
- Added a `/stats` builtin slash command that parses `--port` arguments and reports usage errors.
- Added a stats dashboard helper that syncs sessions, reuses a running server, and opens the local dashboard URL.
- Updated the changelog to document the new `/stats` command behavior for active sessions.
- Added auth-storage regression coverage in `packages/ai` for `markUsageLimitReached` returning the earliest sibling unblock time when all credentials are momentarily blocked.
- Added an agent-session retry-cap test ensuring usage-limit 429 retries wait for sibling unblock and succeed within `retry.maxDelayMs` instead of giving up.
- Updated retry-policy docs and both package changelogs to document the sibling-unblock fallback behavior.
- Added lazy async module loaders for @babel/parser, linkedom, puppeteer/browsers, @mozilla/readability, @xterm/headless, and mnemopi to avoid loading them during cold startup.
- Added an interactive startup splash before session construction and skipped it for resume/fork/continue, quiet mode, timing mode, or non-TTY runs.
- Updated JS import-rewrite and memory tests to match async parser loading and preloaded mnemopi modules for sync state helpers.
- Rerouted sync, tab, js-eval, and tiny workers to re-enter CLI modes via `__omp_*` selectors.
- Adjusted `cli.ts` startup to dispatch worker entrypoints before parsing and exit 1 on uncaught errors.
- Bundled CLI as `dist/cli.js` in prepack, switching `omp` binary and published files.
- Removed explicit Bun `--compile` worker entrypoints from build/release scripts in favor of host-entry dispatch.
- Added `declareWorkerHostEntry()` and `workerHostEntry()` environment helpers and `PI_COMPILED` binary detection.
Project-tagged Hindsight mental-model seeds now use project-qualified ids and legacy bare ids only satisfy the matching project tag. The injected mental-model block also filters tagged models to the active project while retaining untagged models.\n\nFixes #2218
- Introduced memoized dynamic import loaders for Babel parser, mnemopi modules, puppeteer, and HTML-related packages.
- Refactored eval import-rewrite helpers and runtime call sites to use asynchronous wrapping and parsing flows.
- Shifted fetch and web-scraper linkedom usage to on-demand imports so heavy modules load only when needed.
- Returned earliest sibling block expiry from markUsageLimitReached.
- Capped usage-limit retry to whichever frees up first, avoiding multi-hour waits.
- Added 1s buffer so retry lands after the block actually lapses.
- Stored last-seen version in ~/.omp/agent/last-changelog-version so version bumps no longer dirty user configs.
- Migrated the legacy config.yml key into the marker, never clobbering a newer existing marker.
- Added read/write helpers and migration tests.
Updated the read tool's provider-visible path schema, prompt docs, CLI help, and internal URL docs so URL and internal URI targets are advertised consistently. Added schema coverage for the read path description.\n\nFixes #2215
- Fixed help rendering so `--help` no longer triggers unrelated command loaders.
- Fixed startup span logging to emit markers only with PI_DEBUG_STARTUP set.
- Fixed logger startup trace behavior for `:start`, `:done`, and `:fail` phases.
- Fixed prompt template processing with cached raw-template compilation and safer formatting.
- Optimized symbol and tag parsing in prompt templates via manual parsers.
- Rewrote prescriptive prose to MUST/NEVER/SHOULD/MAY phrasing.
- Pruned internal mechanism the agent can't act on from tool prompts.
- Fixed garbled grammar and a stale plan-title placeholder.
- Made ssh tool description synchronous via cached host info.
- Removed restated warnings, dead `rsed` references, and an internal file pointer.
- Dropped blocked `sed -i`/heredoc commands from the replace bash-alternatives table.
- Factored the shared repo-default clause across `gh` search ops.
- Switched gh job-success icon to the status.success symbol.
covers the 16-territory review fixes plus the triage follow-up round in coding-agent, ai, tui, and natives; also rewords the live-region IRC entries with fuller mechanism descriptions.
append-only insertions above the floor no longer arm a permanent promotion freeze; floor index travels with the insertion; documented the floor semantics in the renderer internals doc.
per-block grapheme counts cached (blocks only grow) and in-flight partials bypass the markdown render LRU, removing repeated full Intl.Segmenter walks per 33ms tick and retained stale partial snapshots on long replies.
pr_push invalidates PR+diff rows; current-branch merge/close invalidates without a positional; run_watch polls adaptively, survives rate limits, gives up on zero runs, and evicts completed-run job caches when a rerun is observed; multi-PR checkout uses allSettled; pagination compares raw page length; date qualifiers drop ms precision; leading-dash identifiers cannot become flags; auth key memoized against hosts.yml mtime; diff stored once per row.
clients publish only after initialize; dead readers tear down for respawn instead of permanent 30s timeouts; framing resyncs past junk headers; numeric code-action selectors pick strictly by index; file URIs percent-encode and raw fragment/query chars route to the lax parser; equal-position inserts keep spec order; workspace edits validate before writing; shutdown covers mid-init clients; reload sends notification; writethrough init deadline-bounded with negative caching; DAP pause/breakpoint races fixed, mutations serialized and abort-aware, output buffering O(n) with correct tail retention.
single OutputSink owner per cell artifact; JS parallel() honors its documented barrier (allSettled) instead of orphaning in-flight thunks; Python subprocesses no longer inherit the NDJSON frame pipe (stdout captured and forwarded); JS timeouts annotate the VM reset; console bridge implements dir/time/group/assert/trace; python availability probe cached; runner frames coalesce per write.