Commit Graph
57 Commits
Author SHA1 Message Date
Patrick Wozniak caa4e8e274 ci(tests): run the Oh My Pi compatibility suite as a required check
tests/test-omp-compat.mjs skipped whenever omp was not on PATH, which
was always the case in CI, so 0.6.1 shipped an import that pi's compat
entrypoint provides but OMP's bundled pi-ai does not (#74).

Add an omp-compat job that installs @oh-my-pi/pi-coding-agent with Bun
and runs the suite with OMP_COMPAT_REQUIRED=1, which turns the skip into
a failure. Add a first phase that loads the extension through
`omp models -e`, the same loader `omp plugin install` validates with;
it fails on the 0.6.1 index.ts and passes with the runtime resolution.
2026-09-02 10:14:59 +02:00
Patrick Wozniak 9b91e5468e fix(core): resolve the compat api registration at runtime for Oh My Pi
0.6.1 imported registerApiProvider from @earendil-works/pi-ai/compat as
a named import. Oh My Pi maps that specifier onto its own pi-ai, which
has no such export and instead registers custom APIs inside
registerProvider, so omp plugin install rejected the extension with
"Export named 'registerApiProvider' not found".

Import the compat module as a namespace and call registerApiProvider
only when the host provides it. pi keeps the sibling-extension fix from
#68; omp loads again and its own custom-api registry covers that case.

Verified with omp 18.1.2: plugin install of the linked checkout succeeds
and tests/test-omp-compat.mjs passes; tests/test-pi-local.mjs still
covers the compat registry path on pi.

Closes #74
2026-09-02 10:06:28 +02:00
Patrick Wozniak 008765f617 chore(release): prepare 0.6.1 2026-09-02 00:34:14 +02:00
Patrick Wozniak d3c9832d28 feat(models): move manual reasoning efforts into a catalog override
PR #69 added efforts for meta/muse-spark-* directly to the generated
catalog, which the drift check flags and the daily sync job reverts.

Keep src/commandcode-catalog.ts byte-identical to upstream and merge a
separate src/commandcode-catalog-overrides.ts over it at load time. A
test fails as soon as upstream publishes efforts for an overridden model
so the override gets removed instead of shadowing the CLI catalog.

Verified against the live endpoint: pi --thinking xhigh sends
reasoning_effort="xhigh" for meta/muse-spark-1.2-contributor and the
request succeeds; --thinking off sends none.

Closes #69
2026-09-02 00:03:45 +02:00
Patrick Wozniak 59322e4ffa perf(models): start from the cached catalog and refresh in the background
Every host start awaited a full catalog request before the provider
registered, costing one HTTPS round-trip (up to the discovery timeout on a
hanging connection) even when a cache written seconds earlier was on disk.

Register the cached catalog immediately and run the live refresh in the
background; the live result re-registers the provider when it arrives. A
first start without a cache still awaits the live catalog. The background
refresh is aborted on session_shutdown so print mode does not wait for it.

Closes #63

(cherry picked from commit 142191f9420fe90460cdc3cbae70e26d0c000860)
2026-09-01 23:29:33 +02:00
Patrick Wozniak 0700d9b61d fix(core): register the custom api in the pi-ai compat registry
pi routes the main chat through the registered provider, but sibling
extensions that call streamSimple from @earendil-works/pi-ai/compat with
the active Command Code model resolve model.api through the compat
api-registry, which only knows built-in APIs. On plain pi that failed
with "No API provider registered for api: commandcode-custom".

Register commandcode-custom there and delegate to the transport router.
The registry resolves no credentials for extension providers, so fall
back to the configured Command Code key when the caller passes none.

Closes #68

(cherry picked from commit 7e9659e672771c6a9223b95938e50fb2a051a0a7)
2026-09-01 23:29:30 +02:00
Patrick Wozniak f17cec0eee fix(pricing): refresh catalog pricing snapshot
Verify display pricing against the official pricing page and the live
provider model list:

- add claude-fable-5-1 and deepseek/deepseek-v4-flash-fast
- remove minimax/minimax-m3-free and minimax/minimax-m2.7-free, which the
  provider no longer lists
- end the claude-sonnet-5 introductory window; the listed rate is unchanged
- google/gemini-3.7-flash returns to list price after the promotion ended
2026-09-01 23:29:16 +02:00
Patrick Wozniak 09faff6e6e Merge pull request #66 from ThomasByr/feat/refresh-model-catalog-skill
chore(QoL): refresh model catalog skill

# Conflicts:
#	CHANGELOG.md
2026-09-01 23:27:40 +02:00
Patrick Wozniak 090d5e5310 Merge pull request #65 from ThomasByr/main
feat(models): add GLM5.3-Flash and Qwen3.8-Flash

# Conflicts:
#	CHANGELOG.md
2026-09-01 23:27:37 +02:00
Thomas Byr 8b5e4d78ba feat(models): add refresh-model-catalog skill
Add an agent skill that walks through a full model catalog refresh: drift
detection, catalog sync, manually reviewed pricing updates, fixture
refresh, and test updates. Its helper scripts run on Windows and Linux:
one snapshots the live model-id list into the test fixture, the other
regenerates the pricing fixture from MODEL_COSTS through prettier so
format:check stays green. Typecheck now covers the skill scripts.
2026-08-28 17:00:39 +02:00
Thomas Byr 425483e0e1 fix(models): spawn npm through the shell on Windows
execFile cannot spawn npm's .cmd shim directly on Windows, so the catalog
sync and drift check failed with spawn npm ENOENT. Route npm invocations
through the shell with argument quoting on Windows and keep direct
execFile calls elsewhere.
2026-08-28 17:00:29 +02:00
Thomas Byr 9945a67bae docs(changelog): document new models and pricing refresh 2026-08-28 16:41:32 +02:00
warc0s 08a7e38089 merge main (0.6.0) into fix/omp-developer-messages
Align the developer-message fix with the Provider API transport router.
The fix stays scoped to the legacy /alpha/generate converter, and the
OMP advisory compat test now forces the upgrade_required fallback so the
advisory is asserted on the generate request body.
2026-08-25 22:52:02 +02:00
Patrick Wozniak f2bfb38996 chore(release): prepare 0.6.0 2026-08-25 18:06:46 +02:00
Patrick Wozniak 45281d693e fix(core): omit historical images for text models 2026-08-25 17:46:41 +02:00
Patrick Wozniak 98ed83fc9c merge main into fix/tool-call-streaming 2026-08-25 17:18:02 +02:00
Patrick Wozniak a624643d90 fix(stream): forward incremental tool-call arguments 2026-08-25 16:58:29 +02:00
Patrick Wozniak cee0d7cc96 test(e2e): cover live Go and GOAT accounts 2026-08-25 16:37:24 +02:00
Patrick Wozniak 804ba5862e docs(core): document Command Code CLI parity 2026-08-25 15:54:37 +02:00
Patrick Wozniak c3a383447c ci(models): open PRs for Command Code catalog updates 2026-08-25 15:08:29 +02:00
Patrick Wozniak f23863d326 ci(models): check Command Code metadata daily 2026-08-25 14:14:44 +02:00
Patrick Wozniak 003d571b5e fix(models): refresh Command Code capabilities 2026-08-25 14:12:00 +02:00
Patrick Wozniak 63dd92da09 Merge remote-tracking branch 'origin/main' into review/pr-52
# Conflicts:
#	CHANGELOG.md
2026-08-25 13:33:55 +02:00
Patrick WozniakandGitHub fdd614c62b Merge branch 'main' into main 2026-08-25 13:04:06 +02:00
Thomas Byr 45565a883f feat(models): add GLM-5.3 pricing and reasoning levels 2026-08-22 23:24:49 +02:00
José Galliano 307714b051 feat(quota): add live commandcode-quota dashboard and OMP auth fix
Fetches live account quota from Command Code alpha usage endpoints
(whoami, billing/credits, billing/subscriptions, usage/summary) and
renders a plain-text dashboard via ui.notify.

- Graceful degradation: optional endpoint transport/timeout/parse
  failures degrade to null sections instead of aborting; only 401/403
  are hard failures. 429 is transient, not fatal.
- Overall deadline bounds the whole command to QUOTA_TIMEOUT_MS
  (per-request controllers are chained; post-deadline phases fail fast).
- OMP auth: filter unresolved $COMMANDCODE_API_KEY placeholder and fall
  back to the host resolver via pickCommandCodeApiKey.
- ZDR privacy header respected on quota requests.
- Redaction reuses redactCommandCodeErrorText plus JSON-quoted
  credential fields; outer-catch errors are redacted too.
- resetAt parsed from seconds, ms, numeric string, or ISO string.
- 21 hermetic unit tests wired into npm test (test:quota).
2026-08-21 11:21:25 -06:00
Omar Iqbal Naru 0d6202aec7 docs(release): note omp custom api registration fix 2026-08-21 19:42:14 +05:00
Patrick Wozniak f07ece7731 docs(api): document provider follow-up fixes 2026-08-20 00:13:56 +02:00
Patrick Wozniak 33c405c060 docs(tests): document live account credentials 2026-08-18 17:20:51 +02:00
Patrick Wozniak 9103272217 docs(api): explain automatic transport selection 2026-08-18 12:11:47 +02:00
Patrick Wozniak 864538e146 fix(ci): satisfy provider audit checks 2026-08-18 11:01:12 +02:00
Patrick Wozniak c04f3907b5 docs(api): document provider api migration 2026-08-18 10:56:12 +02:00
warc0s 16eb5a8dda fix(core): preserve developer messages
OMP converts custom and hook messages (advisor notes, todo reminders,
retry nudges) to role "developer" before calling the provider.
messagesToCC() only handled user, assistant, and toolResult, so those
messages were dropped before params.messages was sent to
/alpha/generate. Steering still interrupted pending tools, but the
model never saw the message content.

/alpha/generate has no developer role: the official command-code CLI
(0.32.3) only emits user, assistant, and tool messages plus a separate
params.system. Forward developer messages as user messages with
identical content in the same chronological position. Hoisting them
into params.system would turn a mid-conversation note into a global
top-priority instruction.
2026-08-17 09:03:32 +02:00
Patrick WozniakandGitHub c4d25d1db1 chore(release): publish 0.5.1 (#44) 2026-08-11 00:31:51 +02:00
Patrick WozniakandGitHub a367aed63c feat(models): add vision input capabilities (#43) 2026-08-11 00:28:03 +02:00
Patrick WozniakandGitHub 4b6e1cd85a chore(release): publish 0.5.0 (#41) 2026-08-07 17:23:47 +02:00
Patrick Wozniak ea55ead662 fix(stream): omit prior reasoning from request history 2026-08-07 16:39:18 +02:00
Patrick Wozniak af2a4d1759 test(tests): add provider hardening end-to-end coverage 2026-08-07 14:06:36 +02:00
Patrick Wozniak 62e51ee9f5 Merge main into feat/isolated-pi-launcher 2026-08-07 10:02:22 +02:00
Patrick Wozniak b100d553c1 feat(tests): add isolated pi launchers 2026-08-07 09:55:02 +02:00
Patrick Wozniak 947915df55 fix(models): refresh model pricing 2026-08-04 13:46:26 +02:00
Patrick Wozniak 877a3003b1 perf(deps): remove local pi-ai runtime copy 2026-08-04 02:13:06 +02:00
Patrick Wozniak 1579bfd4be fix(deps): use host-provided pi core packages 2026-08-04 02:13:06 +02:00
IfkumRfnl 69ba0da305 fix(stream): correct cached input accounting 2026-08-03 05:49:31 +00:00
Patrick WozniakandGitHub 3f734bc280 chore(release): publish 0.4.3 (#29)
Ship the offline model-catalog cache so pi can start when Command Code
model discovery is unavailable.
2026-08-02 13:20:15 +02:00
Patrick Wozniak 070ef3c07a fix(models): cache catalog for offline startup
Persist the last valid Command Code model catalog and use it when live model discovery fails. Keep first-time offline startup non-fatal, surface clear warnings, and cover cached model selection with unit and pi integration regression tests.
2026-08-02 01:16:39 +02:00
K2 811f908918 fix: allow extension to load when offline
The model fetch at startup throws and blocks pi from starting when
there's no network. Catch the error and register the provider with
an empty model list instead.
2026-07-23 11:19:04 +01:00
Patrick WozniakandGitHub 64d538a910 chore(release): publish 0.4.2
Release pi-commandcode-provider 0.4.2.
2026-07-05 03:13:30 +02:00
Patrick WozniakandGitHub e123e84116 fix(omp): avoid unsupported calculateCost import
Fix OMP installation by removing the unsupported calculateCost runtime import from pi-ai.
2026-07-05 03:10:02 +02:00
Patrick WozniakandGitHub 0f6fc17816 docs(release): document deployment process
Add a release/deployment skill and record contributors in the 0.4.1 changelog.
2026-06-16 16:35:25 +02:00