Commit Graph
14 Commits
Author SHA1 Message Date
jason.woltje 2db4f24fd8 fix(model-proxy): re-check 3: mosaic org update that takes cliproxy off an organization records the removal in the proxy's receipts first and saves nothing if it cannot; Ride all reads the receipts again before each add, so a removal saved during a run is honoured; the bus-running and unreadable skip lines say what to do (#1873, lane ride-default) 2026-11-19 13:13:05 -06:00
jason.woltje 9bfe101176 fix(model-proxy): round 3: a Console save that takes cliproxy off an organization records the removal in the proxy's receipts first, and Ride all skips as removed any organization with any sign it was or may have been on cliproxy; a receipt line that does not parse fails closed; each add records an intent before it starts and an unknown outcome stays recorded; the fixture move and listing read stopped from the bus status and its process id; receipt and change-log reads check owner, mode and no symlink (#1873, lane ride-default) 2026-11-19 13:13:05 -06:00
jason.woltje 869d259036 fix(model-proxy): review round: an organization the proxy once put cliproxy on and that lacks it now is skipped as removed, read from the proxy's own receipts; an organization riding now is already riding whatever its history; a repeated catalogue key keeps the usable row; the page paints a Ride all answer while a load waits, names org-forbidden in plain words and gives a neutral fallback (#1873, lane ride-default) 2026-11-19 13:13:05 -06:00
jason.woltje 8200ea238c feat(model-proxy): Ride all puts the owner's existing organizations on the instance model proxy, and a cliproxy preset starts a new one on the owner's models (#1873, lane ride-default)
A cliproxy organization preset offers a model from the owner's catalogue and says in plain words
why it can't be used: no proxy, no riding bus answered, or no catalogue model is available. The
organization service passes an optional model to a preset's overlay; other presets ignore it.

Ride all, an instance-owner action on the Model proxy page, adds cliproxy to each organization
through that organization's own plugins.set. It skips and names an organization whose change log
shows cliproxy removed, whose bus is down, or whose bus has no proxy client. Proxy admin status
names it as the next step. A fixture organization is listed as using stand-in models; one more
confirmed click moves a stopped one to the owner's models through the organization service's
existing whole-document update at the revision read.

A fenced proxy then refuses each riding organization's launches with proxy-uncertain, a direct
anthropic route included.
2026-11-19 13:13:05 -06:00
jason.woltje 5c975faddd fix(model-proxy): review round: the preflight comment says every v8 proxy applies a key PUT by an async reload; a re-probe waits about the time left, not the client default; the README says the proxy unit reads PIN from the tree it was installed from and names .codex-refresh; two test headers stop naming only 8.0.42 (#1873, lane proxy-pin) 2026-11-19 11:08:23 -06:00
jason.woltje 462215b4bd chore(model-proxy): pin CLIProxyAPI 8.0.79; proxy.json from an earlier PIN stays valid; preflight re-probes a just-issued key's 401 briefly (#1873, lane proxy-pin)
The PIN moves from 8.0.42 to 8.0.79 with the upstream archive checksum and the
extracted binary checksum. The panel stays 1.26.7.

proxy.json keeps the binary path of the PIN it was created under. A path of the
form <dataRoot>/opt/cliproxyapi/<version>/cli-proxy-api now validates and reads
as the current pinned path, so an instance created on 8.0.42 needs no edit. The
runner still runs only the verified pinned install.

8.0.79 applies a key-list PUT by an async reload a few milliseconds after it
answers, so a just-issued key answers 401 at first. Preflight now probes again
on 401 only, for at most ISSUE_PROBE_TIMEOUT_MS (2 s). Any other non-2xx still
refuses on the first answer.
2026-11-19 11:08:23 -06:00
jason.woltje 75f6d5533a fix(proxy): review fixes for the Console proxy setup page (#1873)
Security review:
- Release verification cache keys on ctime as well as mtime, in
  nanoseconds. A same-size rewrite with mtime set back now re-hashes and
  reports proxy-install-invalid.

Build review:
- The setup page hides the account panels on any failed accounts read, not
  only proxy-down, and brings them back once the proxy answers.
- The organizations table shows a dash, not a made-up 0, when a bus does
  not answer or sends no model list (orgCatalogue in proxy-admin.mjs).
- A fence clear the bus did not answer keeps the confirmed restart for a
  retry.
- A fence with no readable time names `mosaic proxy fence clear
  --proxy-restarted` on the page, in the refusal table and in the README.
- CLI `init --generate-key` goes through the setup controller and writes
  the same init receipt as the page.
- Status carries the last ten receipts, so the page shows them after a
  reload. An initialized proxy keeps the init form folded.
- README: proxy-admin-busy is per process; the cross-process locks that
  serialize the writes are named.
2026-11-11 16:32:31 -06:00
jason.woltje f0e11cb342 feat(proxy): Console proxy setup page and CLI parity (#1873)
One Proxy setup panel on the Model proxy settings page takes an owner from
nothing to a running proxy: status with one next-step button per state, the
pinned fetch with hash checks, progress and a receipt, init with a
bus-generated key (a pasted key only over loopback or HTTPS, with a
confirmation), unit render/install/start/stop/restart with health, a fence
clear that the bus re-proves against a confirmed restart, and a stale init
lock clear that names its blockers. Own proxy per organization shows as not
built.

New Console routes under /api/proxy/admin/ use the existing owner proxy
checks; agents, testers and grant holders get human-required. New bus verbs
proxy.init {generate:true} and proxy.fence.clear. Receipts go to
<dataRoot>/state/proxy-admin.jsonl with labels and key ids only. Every new
refusal code has a refusal-table entry.

CLI: mosaic proxy status, unit render|status|install|start|stop|restart,
init --generate-key, fence clear --restart, init-lock status|clear; proxy
fetch keeps its stdout and adds progress and the receipt.

Page fix found in the end-to-end run: a stopped proxy hides the account
panels until the service answers. (The catalogue switch label fix found in
the same run landed upstream as D3 P0-4.)
2026-11-11 16:32:31 -06:00
jason.woltje ccccac2ade feat(plugins): model providers as plugin modules, cliproxy catalogue on Routing (#1858) 2026-11-06 19:11:13 -06:00
jason.woltje 503b91e561 feat: add optional proxy usage and human model-key quotas (row333) 2026-10-26 17:55:26 -05:00
jason.woltje 362893d043 feat: integrate reviewed proxy page and managed model keys
Source-candidate: poe d9a564e6d20f5f0fd75ce45b12cbbf8bb4c9d568\nSource-candidate: magica38ba5762b06716db1dee00d0afec162656488f5c\nValidated321whole-file phase plus whole bus1349/model-proxy100/webui490; final gate tooling checks pending, not landed.
2026-10-26 12:04:21 -05:00
jason.woltje 61ebf2c34d Refuse non-ASCII proxy management keys before initialization 2026-10-24 18:30:11 -05:00
jason.woltje c65fb34ee6 row329: finish pinned model proxy P1 and record final gate (#1827) 2026-10-24 18:30:11 -05:00
jason.woltje 94cde633e2 WIP row329: preserve P1 draft before required base rebase (#1827) 2026-10-24 18:30:11 -05:00