Commit Graph

792 Commits

Author SHA1 Message Date
can1357 c80a531226 refactor(catalog): deduplicated openai-compatible manager builders
- Added one internal generic builder covering the repeated apiKey/baseUrl
  resolution, bundled reference map, providerId and fetchDynamicModels closure.
- Migrated openai, cerebras, novita, aimlApi, alibabaCodingPlan, venice,
  baseten and moonshot, and routed createSimpleOpenAICompletionsOptions
  through it; deleted the duplicate responses-side helper.
- Preserved fetchDynamicModels key PRESENCE per site, since the apiKey spread
  guard omits the key entirely rather than setting it undefined.
2026-08-08 06:32:00 +02:00
can1357 055a5d4f26 chore: bump version to 17.2.11 2026-08-07 23:38:40 +02:00
can1357 a9dcf0f8d1 chore: update changelogs 2026-08-07 23:38:26 +02:00
can1357 9ab6ea6c8f test(catalog): cover discovered Token Plan limits 2026-08-07 13:37:55 +02:00
can1357 ded3bbfce0 Merge PR #7849: fix(catalog): enrich Alibaba Token Plan discovered model limits (@Mustaqeem66) 2026-08-07 13:37:55 +02:00
can1357 0394bf4a29 Merge PR #7865: fix(catalog): update Devin reasoning family routing (@will-bogusz) 2026-08-07 13:37:55 +02:00
Voon Foo 61ff318e6d review: typed compat access, 0-disable lazy watchdog test, changelogs
- Replace the compat cast with an annotated CompatOf<Api> local narrowed
  via the in operator: assignment up-cast, compiler-checked field type,
  no as assertion.
- Cover the 0 sentinel end-to-end through the lazy wrapper with fake
  timers (mirrors the direct-Anthropic 0-disable test): advance 400s
  past the generic budget, assert no watchdog abort, then cancel
  cleanly.
- Add Unreleased changelog entries for pi-ai and pi-catalog with
  external attribution for #7892.
2026-08-07 15:39:04 +08:00
Voon Foo 2f24d4457e fix(ai,catalog): widen Bedrock stream-stall watchdog via model compat
The lazy provider wrapper ignored model.compat.streamIdleTimeoutMs, so
Bedrock reasoning models sat on the generic 300s idle watchdog despite
ConverseStream sending no ping keepalives; long quiet thinking runs died
with "Provider stream stalled while waiting for the next event" during
plan writing and todo execution (issue #4758's Bedrock variant, worst on
Fable 5 where the display default flipped to omitted).

- catalog: BedrockCompat gains streamIdleTimeoutMs; reasoning models get
  a 600s floor, adaptive-thinking Claude (Opus 4.7+, Sonnet/Opus 5,
  Fable/Mythos 5) 900s to match direct Anthropic's ping-extended
  tolerance; explicit compat overrides still win (0 disables).
- ai: forwardStream resolves options -> env -> model.compat -> default,
  and lazy terminal errors carry the structural errorId classification
  so session auto-retry classifies stalls without text matching.
2026-08-07 14:18:46 +08:00
Will 7d6433cffe docs(catalog): correct Devin effort invariant 2026-08-06 21:45:15 -04:00
Will 1ad85b5584 fix(catalog): collapse current Devin reasoning families 2026-08-06 21:36:11 -04:00
Will 7e95b61ffb fix(catalog): route Devin GPT-5.6 fast max effort 2026-08-06 21:35:56 -04:00
Mustaqeem66 b80a888dc8 fix(catalog): enrich Alibaba Token Plan discovered model limits 2026-08-06 17:12:21 +00:00
can1357 43c1b245e7 chore: bump version to 17.2.10 2026-08-06 13:32:34 +02:00
can1357 9e738dc880 chore: reformat + rewrite changelogs 2026-08-06 13:30:08 +02:00
can1357 c5cce0f325 chore: normalized changelogs after merging 14 pull requests 2026-08-05 22:17:01 +02:00
can1357 a6918d3397 Merge PR #7669: fix(catalog): exposed low effort tier for deepseek-v4-flash (@roboomp) 2026-08-05 22:16:29 +02:00
can1357 0b0e7dd530 chore: normalized changelogs after merging 20 pull requests 2026-08-05 21:50:46 +02:00
can1357 e9888367d1 refactor: migrated packages to internal utility modules and removed external dependencies
- Implemented in-house, zero-dependency utility modules in `pi-utils` covering DOM manipulation, markdown parsing, templating, browser automation helpers, and terminal buffers.
- Migrated packages across the repository to consume the new internal utilities and `omptype` schema validators instead of external dependencies.
- Removed multiple external runtime and development dependencies including Zod, Marked, LRU cache, Turndown, and Puppeteer browser packages.
2026-08-05 13:39:09 +02:00
roboomp e97d1fd21a test(catalog): removed tautological effort assertions 2026-08-05 02:34:04 +00:00
roboomp 736b496cc6 fix(catalog): exposed low effort tier for deepseek-v4-flash
DeepSeek's API accepts reasoning_effort low/high/max and only
deepseek-v4-flash supports all three tiers (V4 Pro is high/max). The
identity-derived effort fallback blanket-applied high/max to every
direct-DeepSeek reasoning model, hiding the low tier flash accepts.

Added isDeepseekV4FlashModelId and route flash to the low/high/max ladder
on every host; non-flash DeepSeek keeps high/max (high-only on OpenRouter).

Fixes #7668
2026-08-05 02:22:27 +00:00
can1357 f7f8e040ee chore: bump version to 17.2.9 2026-08-05 03:07:47 +02:00
Pete Samwel fce059930e fix(catalog): emit AWS GovCloud us-gov Bedrock Claude inference profiles
Bare anthropic.claude-* Bedrock rows already derived eu.* selectors; also
emit us-gov.* so GovCloud accounts can resolve system inference profiles
without requiring a full partition ARN.
2026-08-04 13:13:18 -05:00
can1357 003bb5548c chore: bump version to 17.2.8 2026-08-04 05:53:35 +02:00
can1357 a5090f1f81 chore: bump version to 17.2.7 2026-08-04 01:19:36 +02:00
can1357 60acbee44a docs(changelog): normalized and regenerated unreleased changelogs 2026-08-04 01:19:08 +02:00
roboomp 58ced35dc0 fix(catalog): honored disabled DeepSeek thinking
Moved the direct DeepSeek enabled toggle into the thinking-only compat variant and normalized stale cached compat metadata before request encoding.

Fixes #7559
2026-08-03 21:48:40 +00:00
can1357 bc39ffa265 feat: introduced omptype validation package and migrated workspace dependencies
- Introduce `@oh-my-pi/omptype` as a new ArkType-compatible schema validation package featuring a lazy JIT runtime, JSON Schema emission, and compatibility adapters.
- Replace `arktype` across workspace packages and test utilities with `@oh-my-pi/omptype`.
- Add benchmark suites, tests, and documentation for the new validation engine and adapters.
- Update workspace build, test runner, and release configurations to include the new package.
2026-08-03 21:56:48 +02:00
can1357 01c1f91ff5 chore: bump version to 17.2.6 2026-08-03 16:44:19 +02:00
can1357 4ddc2d2cd4 chore: rewrite changelogs + fix stale tests 2026-08-03 15:32:19 +02:00
can1357 9fdb989c63 docs(changelog): restored released sections and normalized unreleased entries
- Union changelog merges interleaved stale pre-17.2.5 PR-branch entries into
  released sections; released bodies are restored byte-for-byte from the
  pre-merge main state.
- [Unreleased] now carries exactly the entries for PR #7080 and the nine
  merged fixes (#7495, #7460, #7466, #7468, #7473, #7481, #7477, #7368, #7453).
2026-08-03 14:51:01 +02:00
can1357 35ed5db9e1 Merge PR #7473: fix(catalog): use live Copilot default-tier prices (@roboomp) 2026-08-03 14:46:23 +02:00
can1357 11559395c2 Merge PR #7468: fix(catalog): add reasoning config for deepseek-v4 family in alibaba-token-plan (@21307369) 2026-08-03 14:46:23 +02:00
can1357 c48376d8f0 fix(catalog): made bedrock-mantle dynamic discovery authoritative
- Account-scoped bearer /v1/models responses now replace the static seed
  instead of merging, so models disabled for the account are not selectable.
- Extended the catalog regression to run a real online refresh and assert
  the static seeds are pruned to the fetched IDs.
2026-08-03 14:36:57 +02:00
can1357 e06ccbd907 Merge PR #7080: fix(ai): add authenticated Bedrock Mantle routing (@anatoli-tsinovoy)
# Conflicts:
#	packages/ai/src/registry/registry.ts
#	packages/catalog/scripts/generated-policies.ts
#	packages/catalog/src/models.json
2026-08-03 14:36:52 +02:00
roboomp 27c1d6e8d4 fix(catalog): used live copilot default-tier prices
Applied GitHub Copilot's discovered default token-price tier to base models while preserving the provider fallback for unreported cache-write costs. Added regression coverage for GPT-5.6 Luna base and long-context pricing.

Fixes #7471
2026-08-03 08:38:14 +00:00
lsmir2 7beee683b9 fix(catalog): add reasoning config for deepseek-v4 family in alibaba-token-plan
Dynamically discovered deepseek-v4* models (e.g. deepseek-v4-flash-0731)
now receive reasoning: true and [high, max] thinking efforts via prefix
matching in the discovery mapper.
2026-08-03 15:55:14 +08:00
can1357 c53b85aaf4 chore: bump version to 17.2.5 2026-08-03 05:53:12 +02:00
can1357 63b07f8ec0 chore: rewrite changelogs 2026-08-03 05:52:53 +02:00
can1357 a7f3bc2a17 chore: normalized changelog entries after merges 2026-08-02 21:01:11 +02:00
can1357 3177f6bdf7 test(catalog): cover DeepSeek policy without bundled models 2026-08-02 20:55:16 +02:00
can1357 46ca4c6095 Merge PR #7317: fix(catalog): downgrade forced tool choice for deepseek reasoning models (@roboomp) 2026-08-02 20:55:16 +02:00
can1357 990ec2b0e8 fix(catalog): exclude Token Plan speech recognition models 2026-08-02 20:53:35 +02:00
roboomp ac403dbb71 fix(catalog): excluded token plan embedding models
Filtered text-embedding model IDs from authoritative Alibaba Token Plan chat discovery.

Covered text-embedding-v4 alongside the existing media-only discovery fixtures.

Fixes #7391
2026-08-02 16:16:24 +00:00
roboomp 3224245e98 fix(catalog): admitted discovered token plan chat models
Replaced the stale static discovery allowlist with explicit filters for media-only model families.

Covered newly advertised DeepSeek, Kimi, and MiniMax chat models while retaining image, audio, and video exclusions.

Fixes #7391
2026-08-02 16:09:07 +00:00
can1357 d595332fc6 chore: bump version to 17.2.4 2026-08-02 00:19:30 +02:00
roboomp 93fe2ca9a9 fix(catalog): match opencode gateway by url for deepseek downgrade
Use isOpenCodeHost (provider id + baseUrl markers) instead of the built-in
provider-id check so DeepSeek reasoning models declared under a custom provider
id pointed at the OpenCode gateway URL also downgrade a forced tool_choice to
auto.

Fixes #7315
2026-08-01 20:23:07 +00:00
roboomp 879d8276c1 fix(catalog): scoped deepseek forced choice downgrade
Limit the DeepSeek forced tool-choice downgrade to the OpenCode Zen and Go
gateways whose default thinking mode rejects named selectors. Preserve forced
tool selection on NVIDIA and other gateways that can disable thinking for the
request.

Add regression coverage for both the affected OpenCode path and an unaffected
NVIDIA DeepSeek route.

Fixes #7315
2026-08-01 20:17:16 +00:00
roboomp 114a10d340 fix(catalog): downgrade forced tool choice for deepseek reasoning models
DeepSeek reasoning models on the OpenCode Zen/Go gateways 400 with
"Thinking mode does not support this tool_choice" when a specific tool is
forced. The compat descriptor already drops reasoning_effort via
disableReasoningOnToolChoice, but that does not turn off the gateway's
default thinking mode, so the forced named selector still trips DeepSeek's
thinking+tool_choice guard.

Mark forced tool_choice unsupported for DeepSeek reasoning models so
buildParams downgrades the selector to "auto" while keeping the tool
advertised, mirroring the Anthropic and direct-DeepSeek paths.

Fixes #7315
2026-08-01 20:05:27 +00:00
can1357 8fe2b8f9ba Merge PR #7311: fix(catalog): honor openrouter deepseek effort metadata (@roboomp) 2026-08-01 21:29:35 +02:00
can1357 e154c8ed0b fix(catalog): sourced antigravity claude pricing from google vertex
- Claude ids now alias to google-vertex suffixed entries (claude-opus-4-6@default etc.) so Antigravity follows Google's price if it diverges from Anthropic's list price; plain-id anthropic lookup remains as dangling-alias fallback.
- Regenerated models.json via gen:models.
2026-08-01 21:27:51 +02:00