Commit Graph

77 Commits

Author SHA1 Message Date
can1357 58f319912e feat: introduced dynamic version discovery and rate limit parsing for google
- Added dynamic Antigravity version discovery with environment variable overrides and fallback endpoint support.
- Introduced structured Google RPC `ErrorInfo` rate limit reason parsing and backoff classification.
- Added `gemini-3.7-flash` and `deepseek-v4-pro:preview` model configurations alongside updated pricing.
- Removed system instruction injection logic and dropped unsigned thinking blocks for Antigravity requests.
2026-08-13 23:59:37 +02:00
can1357 1a8caad23e chore: update docs + rename reset to clear 2026-08-03 18:37:23 +02:00
can1357 ebd5e3f86f chore: update stale docs 2026-08-03 16:39:23 +02:00
can1357 f3ae071bb7 docs: clarify kitty placeholder opt-out precedence 2026-07-31 19:07:17 +02:00
roboomp f52ec15a5d docs: documented kitty placeholder environment controls
Added the active Kitty Unicode placeholder overrides to the canonical environment-variable reference, including tmux placement behavior and the unsupported-terminal caveat.

Fixes #7172
2026-07-31 11:47:15 +00:00
can1357 55ac64679e Merge PR #6652: feat(ai): add Exa API key login (@will-bogusz) 2026-07-30 01:26:50 +02:00
can1357 5711b763e0 docs(auth): align remaining credential ladders
(cherry picked from commit c606fe3a106611be413f140310ee47a88324cded)
2026-07-29 23:09:09 +02:00
Wolfgang Schoenberger 031beb1751 docs(auth): correct credential precedence
(cherry picked from commit 33ede5efbc52cedc9819cb65c642cfeab82c337c)
2026-07-29 23:09:09 +02:00
can1357 fae0e5df31 Merge PR #6765: feat(catalog,ai): add SiliconFlow providers with dynamic-only model discovery (@iacore) 2026-07-27 15:57:47 +02:00
roboomp dda720af41 fix(tui): allowed remote raw backspace opt-in
Windows Terminal identity is commonly lost across SSH and container hops,
leaving only the ambiguous raw 0x08 byte. Added the conservative
PI_TUI_RAW_BACKSPACE_IS_CTRL=1 opt-in so those sessions can map it to
ctrl+backspace without changing the default for terminals where 0x08 means
plain Backspace.

Restored the public isWindowsTerminalSession and matchesRawBackspace exports
and route the parser wrappers through matchesRawBackspace. Documented the
runtime flag and covered local WT, remote opt-in, SSH, and 0x7f behavior.

Fixes #6782
2026-07-27 10:28:00 +00:00
iacore dab5934548 feat(catalog,ai): add SiliconFlow providers with dynamic-only model discovery
Adds siliconflow and siliconflow-cn OpenAI-compatible providers
(api.siliconflow.com / api.siliconflow.cn), with the model list fetched
live from each region's /v1/models endpoint instead of a bundled
catalog (dynamicModelsAuthoritative, no models.dev mapping).

SiliconFlow's /v1/models serves every model type (chat, embedding,
reranker, image, audio, video) with no per-model type field, so
discovery filters non-chat ids out of the picker. The filter was
validated against the live catalog to match the server's own
type=text&sub_type=chat classification exactly (64/64, no false
drops, no false keeps).

Wires SILICONFLOW_API_KEY / SILICONFLOW_CN_API_KEY into env-key
discovery and registers API-key login providers so
`omp login siliconflow` / `omp login siliconflow-cn` stores a
credential validated against each region's /v1/models endpoint.
2026-07-27 13:06:50 +08:00
Will 19d7d14a94 feat(ai): add Exa API key login 2026-07-25 19:08:02 -04:00
can1357 aad7ee8fa3 feat(ai): implemented lite response overrides and computer call unrolling for codex
- Updated the OpenAI Codex provider to unroll native computer calls and tool outputs into standard function calls.
- Added support for the `PI_CODEX_RESPONSES_LITE` environment variable override via the request transformer.
- Updated documentation and tests to cover lite response resolution and native computer response unrolling.
2026-07-24 06:10:00 +02:00
can1357 64c78532c2 Merge PR #6447: feat: add native Alibaba Token Plan provider (@eggpeat) 2026-07-24 02:25:25 +02:00
Brent e184fe8f8d feat: add native Alibaba Token Plan provider 2026-07-23 23:04:00 +00:00
Alex TYRODE faabe089e8 feat(ai): add process-scoped OAuth account pools 2026-07-23 19:30:49 +00:00
can1357 c6602de1cf Merge PR #5687: feat(config): add PI_CONFIG_FILES settings overlay env var (@roboomp) 2026-07-18 20:12:48 +02:00
roboomp 6558b5ec05 feat(config): added PI_CONFIG_FILES settings overlay env var
Loaded a platform-delimited (: on Unix, ; on Windows) path-list of settings overlays from PI_CONFIG_FILES before explicit --config overlays, so wrapper-based setups can inject settings without argv surgery.

Dropped the earlier global --config extraction as too risky; --config remains a launch/acp/models flag as before.

Fixes #5685
2026-07-17 10:35:19 +00:00
can1357 1b267ad3fe fix(tui): restored alt-screen borrow for resize drag frames
- v17.0.1 (#5476) rewrote the normal buffer in place per SIGWINCH, so
  the terminal's own width reflow pushed wrapped fragments into native
  scrollback mid-drag and resize smoothness collapsed.
- Throwaway drag frames paint on the alternate screen again; the settle
  full paint fuses the buffer exit ahead of its destructive repaint.
- Kept the #5319 fixes: deferred overlay alt-exit fusing, confirmed-only
  DECRPM 2026 handling, and Warp's in-place resize path.
2026-07-17 05:49:22 +02:00
roboomp 68f84d7c20 fix(tui): prevented stale-buffer flicker
- Kept fullscreen replacement overlays mounted through asynchronous transcript rebuilds.
- Fused alternate-screen exit with destructive repaint and removed resize-time buffer switches.
- Preserved statically detected synchronized output when DECRQM probing is inconclusive.

Fixes #5319
2026-07-14 18:23:45 +00:00
can1357 68c3c7ea9d docs(providers): documented novita support 2026-07-10 12:08:44 +02:00
can1357 bb95fcfafe Merge PR #3732: fix(ai): honor NODE_EXTRA_CA_CERTS on every provider fetch (@roboomp) 2026-07-01 21:42:25 +02:00
roboomp 2c8b723083 fix(coding-agent): forwarded stream timeout settings
Forwarded persisted provider stream timeout settings into model requests so slow local LLM streams can widen or disable first-event and idle watchdogs without environment variables.

Fixes #3878
2026-06-30 07:07:41 +00:00
roboomp 41e9bc861b fix(ai): honored NODE_EXTRA_CA_CERTS on every provider fetch
Bun's fetch ignores NODE_EXTRA_CA_CERTS, so private-CA gateways failed
with `unknown certificate verification error` on every OpenAI-compatible,
Codex, Ollama, Azure Responses, and Google call. The env var was only
plumbed through resolveFoundryTlsOptions() on the Anthropic Foundry path.

Added a shared wrapper (wrapFetchForExtraCa / withExtraCaFetch) that
merges the resolved CA bundle into Bun's RequestInit.tls.ca and seeds
the system root store alongside it (Bun's tls.ca replaces the default
trust store when set). The wrapper composes with the existing proxy /
request-debug stack in streamDispatch and streamSimple, so every
provider call now picks up the env var. Path-mtime cache invalidation
mirrors the Foundry helper so rotating bundles are picked up live.

Fixes #3731
2026-06-28 15:57:44 +00:00
can1357 ac904fc70c fix: patched Kimi model edit mode fallback
- Added a fallback from `hashline` to `replace` mode for Kimi-family models to resolve compatibility issues.
- Introduced `PI_STRICT_EDIT_MODE` environment variable to bypass automatic model-specific edit-mode fallbacks.
- Updated `getEditVariantForModel` to perform case-insensitive matching for model variant configurations.
- Added comprehensive unit tests for edit mode resolution and settings configuration.
2026-06-26 13:17:35 +02:00
oldschoola 13bfc7b9c0 Remove Wafer Pass provider 2026-06-21 02:45:48 +02:00
Can Bölük b7fe6f61a1 Merge branch 'main' into fix/litellm-base-url 2026-06-17 11:37:28 +02:00
can1357 d5b3c78132 chore: update docs 2026-06-17 04:37:39 +02:00
Alexander Kirilin 11e6eb0c2c fix(litellm): support LITELLM_BASE_URL 2026-06-16 20:54:55 -04:00
sorphwer 89fb1b0a49 fix(tui): stop Warp resize feedback-loop redraw storm
The non-multiplexer resize fast path borrows the alternate screen for
throwaway drag frames. Warp reports a terminal height one row different
for the alt buffer, so each alt enter/leave emits a fresh SIGWINCH that
re-enters the fast path — a self-sustaining loop that floods ED3 full
repaints with completely stable geometry (observed ~130
fullPaint(clearScrollback) frames over 15s, continuing after the drag
stopped). PI_FORCE_SYNC_OUTPUT cannot help (it is a loop, not tearing);
tmux works because the multiplexer path never toggles the alt buffer.

Route resize through the in-place repaint path (no alt-screen borrow, no
ED3 rewrap) for multiplexers and for terminals that re-report size on
alt-screen toggles, via resizeRepaintsInPlace(). Default-on for Warp,
overridable with PI_TUI_RESIZE_IN_PLACE=1|0. Tradeoff matches a
multiplexer: scrollback above the window keeps its old wrap.

Tests assert no alt-screen borrow / no ED3 across a Warp resize burst and
that the override toggles both ways; existing direct-terminal resize
tests now pin TERM_PROGRAM so they stay deterministic under Warp.
2026-06-16 12:27:53 +08:00
oldschoola 7d721dc420 Add Umans AI Coding Plan provider 2026-06-15 03:58:20 -07:00
can1357 371846167b docs: update docs 2026-06-12 14:43:35 +02:00
can1357 ae84502b82 fix(coding-agent): bypass LSP for individual conflict resolution
Individual conflict resolution now bypasses the LSP writethrough to prevent formatting from corrupting other unresolved marker blocks and to avoid noisy diagnostics in partially resolved files.
2026-06-12 11:29:38 +02:00
can1357 8c3c68a048 feat(ai): added stateful previous_response_id chaining to the platform Responses provider 2026-06-12 02:33:46 +02:00
can1357 f2137becb8 fix: fixed prompt parsing, startup tracing, and help-command behavior
- 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.
2026-06-10 02:17:35 +02:00
can1357 64e68f173b fix(tui): fixed terminal shrink semantics to preserve immutable committed scrollback
- Handled frame shrink by re-anchoring windowTop and chunkTo at commit boundaries.
- Reset committedRows when the frame shrank into committed content to keep history immutable.
- Treated geometryChanged like overlay when advancing chunkTo to stabilize repaint commit timing.
- Updated regressions to assert stable scrollback prefixes and no clear-home/dclear repaint bytes.
2026-06-09 21:31:58 +02:00
can1357 8f23ba511b fix: close several easy issues 2026-06-08 15:47:21 -03:00
can1357 bad1e2acd6 fix: restricted GitHub Copilot auth to COPILOT_GITHUB_TOKEN
- Changed the `github-copilot` service provider to resolve credentials only from `COPILOT_GITHUB_TOKEN`.
- Updated CLI extra help text to document `COPILOT_GITHUB_TOKEN` as the GitHub Copilot environment variable.
- Reworded environment variable docs to reflect the revised Copilot/GitHub token usage and order.
2026-06-08 00:42:23 +02:00
can1357 78700a2c77 feat(ollama): added OLLAMA_HOST and OLLAMA_CONTEXT_LENGTH support
- Used OLLAMA_HOST for implicit discovery when OLLAMA_BASE_URL is unset.
- Applied OLLAMA_CONTEXT_LENGTH override to discovered context budgeting.
2026-06-05 22:47:40 +02:00
can1357 b8a602ac2a test(auth): switched OAuth ranking tests to weighted selection
- Replaced top-rank assertions with weighted-preference distribution checks.
- Added cases for equal-priority balancing and 2x best-bucket cap.
- Added coding-agent snapshot-cache boot and seed tests.
2026-06-05 11:15:32 +02:00
Can Bölük 9f7c36c36b Merge pull request #1702 from basedcorp99/feat/cmux-terminal-id
Add cmux terminal surface detection to getTerminalId
2026-06-04 06:13:25 +03:00
can1357 86c56d6472 feat(tui): added DECCARA fill optimizer with OSC 66 and DEC 2026/2048
- Added a Kitty-only DECCARA optimizer painting solid bg panels as rectangles, with `PI_NO_DECCARA` kill switch.
- Added OSC 66 text-sizing width handling to slicing, truncation, and wrapping.
- Added DECRQM probes for DEC 2026 sync output and 2048 in-band resize.
- Added structured OSC 99 notification formatting.
2026-06-04 00:27:20 +02:00
can1357 4905e142c1 feat(tui): added PI_NO_SYNC_OUTPUT opt-out for DEC 2026 synchronized output
- Added `PI_NO_SYNC_OUTPUT=1` env var to disable DEC 2026 wrappers while keeping autowrap guards active around paints.
- Removed Termux-specific height-change no-op; all non-multiplexer resizes now repaint to prevent phantom blank rows.
- Added `linux-normal-vteNoSync-small` stress scenario and issue-1765 regression tests.
2026-06-03 11:30:48 +02:00
basedcorp99 3bcc02a19e Prefer cmux surfaces over host terminal ids 2026-06-02 13:18:01 +02:00
basedcorp99 b93be377ba pretty 2026-06-02 12:10:21 +02:00
basedcorp99 656e855e4a Add CMUX_SURFACE_ID to docs
Follow-up to CMUX_SURFACE_ID env var support — document it alongside
KITTY_WINDOW_ID, TMUX_PANE, etc. in environment-variables.md and
session-switching-and-recent-listing.md.
2026-06-02 11:52:19 +02:00
can1357 3c398c7eb1 Merge remote-tracking branch 'origin/farm/48a24745/fix-anthropic-custom-headers-web-search' 2026-06-02 10:11:24 +02:00
roboomp b3ec588921 fix(coding-agent): honored Anthropic search base URL for fallback auth
- Passed ANTHROPIC_SEARCH_BASE_URL through to Anthropic web search calls that use authStorage fallback credentials instead of only applying it with ANTHROPIC_SEARCH_API_KEY.
- Added regression coverage asserting fallback Anthropic credentials use the search-specific base URL.
- Updated the environment and web_search docs to reflect the actual credential and base URL resolution order.

Fixes #1694
2026-06-02 07:57:34 +00:00
roboomp 4bd0fe573c fix(anthropic): forward ANTHROPIC_CUSTOM_HEADERS for non-Foundry enterprise gateways
The Anthropic web search path built request headers via buildAnthropicSearchHeaders, which never threaded model headers through buildAnthropicHeaders, so ANTHROPIC_CUSTOM_HEADERS was dropped from every web-search request regardless of mode. The streaming path's resolveAnthropicCustomHeaders also gated on isFoundryEnabled(), so users with a corporate ANTHROPIC_BASE_URL + ANTHROPIC_CUSTOM_HEADERS (e.g. X-Gateway-Key) got 401s on web_search unless they set CLAUDE_CODE_USE_FOUNDRY=true.

Loosen the resolver to also apply when ANTHROPIC_BASE_URL points to a non-Anthropic host, export the baseUrl-keyed variant, and have buildAnthropicSearchHeaders pass the resolved custom headers as modelHeaders so search and streaming paths behave identically. Stock api.anthropic.com (no Foundry) still omits the headers.

Fixes #1693
2026-06-02 07:52:37 +00:00
roboomp 5b1e5a5c4a docs: documented ANTHROPIC_SEARCH_API_KEY and ANTHROPIC_SEARCH_BASE_URL
- Expanded the existing entries in docs/environment-variables.md so the override-semantics ('search-only, isolates from main ANTHROPIC_API_KEY / ANTHROPIC_BASE_URL / FOUNDRY_BASE_URL') are spelled out, and added a usage note for enterprise-gateway split routing.
- Surfaced the search-only env vars (ANTHROPIC_SEARCH_API_KEY / ANTHROPIC_SEARCH_BASE_URL / ANTHROPIC_SEARCH_MODEL) in the Anthropic provider section of docs/tools/web_search.md, where users were already looking.
- Added ANTHROPIC_SEARCH_BASE_URL alongside ANTHROPIC_SEARCH_API_KEY in 'omp --help' so the pair shows up together in the CLI env-var summary.

Fixes #1694
2026-06-02 07:49:59 +00:00