Upgrade @earendil-works/pi-ai to ^0.87.1 for the new model catalog — and fix model discovery to ask live endpoints (incl. defaults) #7660
Replies: 5 comments
|
Patch provenance, for clarity: So rather than applying it against whatever git checkout 00102833dfaee1da9f48a3a8eae9d34005a75218
git apply staged-changes.patchIf |
|
There is a second issue in the same area that should be fixed alongside the pi-ai catalog bump. Reproduction
Root cause
Suggested fix and regression test For an OpenCode route with a non-empty This is separate from refreshing the generated catalog itself: after the catalog update, the discovery path still needs to use the live endpoint. |
|
Follow-up for OpenRouter: the same discovery short-circuit affects this route. |
|
Thanks for the feedback. Lemme check this.
Thanks
…________________________________
From: randomix777 ***@***.***>
Sent: Thursday, 24 September 2026 07:53:19
To: deepseek-ai/deepseek-harness ***@***.***>
Cc: Gnanesh ***@***.***>; Author ***@***.***>
Subject: Re: [deepseek-ai/deepseek-harness] Proposal: upgrade @earendil-works/pi-ai to ^0.87.1 so the new model catalog lands (Discussion #7660)
Follow-up for OpenRouter: the same discovery short-circuit affects this route. https://openrouter.ai/api/v1/models currently returns 459 models, including stealth/space-bunny-alpha; the bundled pi-ai OpenRouter catalog in this checkout has 333 models and does not contain it. Also, an explicit llm-pi-ai.providers.openrouter.models list replaces the inherited catalog, so a newly listed model must either be adopted from live discovery or added to that list. The endpoint-backed discovery path should therefore cover OpenRouter as well as OpenCode, with a regression test for the exact model id.
—
Reply to this email directly, view it on GitHub<#7660?email_source=notifications&email_token=AE2GLX5QGUZ62GOJIOZHQIL5QSARPA5CNFSNUABIM5UWIORPF5TWS5BNNB2WEL2ENFZWG5LTONUW63SDN5WW2ZLOOQXTCOBVG42DQNZWUZZGKYLTN5XKMYLVORUG64VFMV3GK3TUVRTG633UMVZF6Y3MNFRWW#discussioncomment-18574876>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AE2GLX6QNTQOKVHUHU3LBLL5QSARPAVCNFSNUABJKJSXA33TNF2G64TZHMYTGMZTGA3DKMBZGE5UI2LTMN2XG43JN5XDWMJQHA3TINBTGSQXMAQ>.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
|
Follow-up: the discovery short-circuit is fixed — including the no- What changed since the original post — it covers both reports above, plus the case you described as "no base url, it'll take the default one":
The regression tests pin exactly what you asked for: a catalog-backed route with a Also verified in the web UI (Models → openrouter → Fetch available models): with Base URL empty the picker now returns the live ~459-entry OpenRouter list including Alongside this, the discovery reply becomes 📎 discovery-fix.patch (raw) — 29 files, +591/−166. Apply order from the base commit: git checkout 00102833dfaee1da9f48a3a8eae9d34005a75218
git apply staged-changes.patch # the pi-ai ^0.87.1 upgrade (attached above)
git apply discovery-fix.patch # this follow-up |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Summary
Proposing a bump of
@earendil-works/pi-aifrom^0.85.1to^0.87.1inpackages/llm/llm-pi-ai, so the new model catalog lands in the built-in catalog —pnpm-workspace.yamlitself notes that "fresh pi-ai releases carry the model catalog updates that are the whole point of bumping it". 0.87.1 pulls in the new DeepSeek model IDs (deepseek-flash, V4.1-era defaults in place ofdeepseek-v4-flash), themistral-conversationsAPI, and the latest compat metadata.Since MRs/PRs aren't accepted here, I've put the complete upgrade together locally and am attaching the working patch so it can be picked up and landed directly.
What the patch contains (21 files, +376 / −445)
@earendil-works/pi-ai^0.85.1→^0.87.1inpackages/llm/llm-pi-ai/package.json, withpnpm-lock.yamlandpnpm-workspace.yaml(minimumReleaseAgeExcludenow names@earendil-works/pi-ai@0.87.1/@earendil-works/pi-telemetry@0.87.1) refreshed accordingly.deepseek-v4-flash→deepseek-flash; tests, fixtures, and inline snapshots follow (the real-API e2e now targets "V4.1 Flash defaults"). This is the main reason for the bump.packages/llm/llm-pi-ai/src/catalog.ts:MistralConversationsCompattype with its own drift gate (MISTRAL_COMPAT_GATE) and amistral-conversationsentry inCOMPAT_GATES;deferredToolsModeremoved fromOpenAICompletionsCompat, newsupportsMidConvoSystemMessages/supportsMidConvoToolAdditions/supportsMidConvoToolChangesfields gated aswithhold, andsupportsToolReferences→sessionAffinityFormaton the Anthropic gate.packages/llm/llm-pi-ai/src/replay.tsnow types tool-call arguments as pi-ai'sJsonObject.patches/@earendil-works__pi-ai@0.85.1.patch→patches/@earendil-works__pi-ai@0.87.1.patch. It still removes the per-delta full re-parse of the accumulated tool-call argument JSON in every stream adapter (upstream earendil-works/pi#9265); unpatched, a multi-megabyte argument stream costs O(n²) CPU on the event loop and stalls every session in the process. Please keep re-applying it on each pi-ai bump (or retire it once the fix lands upstream).THIRD_PARTY_NOTICES.mdandpackages/llm/llm-pi-ai/README.md/README.zh.md(plus the i18n pairing hashes) point at the renamed patch file.Request
Please land the
^0.87.1bump so the new models (new DeepSeek IDs, Mistral conversations support) reach the built-in catalog. The attached patch is the complete diff against base commit00102833dfaee1da9f48a3a8eae9d34005a75218(00102833df, "Merge pull request #4978 from deepseek-harness/worktree/release-dsh-0.1.7-alpha.2") — apply it there withgit apply staged-changes.patch.Attachment
📎 staged-changes.patch — the full working diff (raw)
All reactions