36 Commits
Author SHA1 Message Date
kyleandClaude Opus 5.5 9ff38dfe4e v2.3 review: drop a duplicate logIdentityMode call; README wording; review notes
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-25 20:17:03 -07:00
kyle 7a12ddcf5a Context refusal in llama-server's exceed_context_size_error shape; README for v2.3
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 20:15:49 -07:00
kyle 15f6c62381 v2.3/04-ctx-error-docs: stopped, protected v2.1 router test conflicts with new body
refuseCtx now emits llama-server's exceed_context_size_error shape (task rule 1:
only top-level key is "error"); the v2.3 replacement ctxguard_test.go passes and
make smoke still finds "prompt too large". But the protected v2.1 copied test
ctxguard_router_test.go still asserts the old top-level "max" field, which rule 1
forbids alongside "error" — the two protected files demand mutually-exclusive
bodies and the gate cannot pass with the task-required shape. README work
(context-guard body, a new "Clients that manage their own slots" section, and the
three route keys in the config table) is correct but left uncommitted alongside
the code for review; the owner must hand over a ctxguard_router_test.go that reads
error.n_ctx instead of a top-level "max".

Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 20:10:09 -07:00
kyle fa1c398fc4 A route may have its own listener: every request there is that route, paths unprefixed
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 19:59:21 -07:00
kyleandClaude Opus 5.5 aea2eeae2c Routes may share one lease (affinity = "route") and skip crossbar's queue (queue = false)
route.go gains Route.Affinity/Queue with PerRoute(), Queues() and affinity
validation (checkRoutes moved here; config.go calls it once). limiter.Track
counts a request without holding or refusing it; a release hands the slot to a
waiter only while in flight <= parallel. The proxy leases a PerRoute() route
under an empty fingerprint (the row keeps the real one) and uses Track when
Queues() is false.

Implemented by Ornith (OpenCode); owner review removed a release-on-first-flush
workaround for a race in the owner's given test (see implementer log).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-25 19:33:46 -07:00
kyle 33fa61bedb Control-plane requests follow the lease but take no slot and write no row
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 17:44:00 -07:00
kyle 8018f67031 Wake: a target may list several broadcast addresses
Config keeps broadcast (one) and adds broadcasts (a list); exactly one must
be present. Wake.Addresses() returns Broadcast then Broadcasts; checkWake
errors on both-set, neither-or-empty, and non-host:port entries. Waker sends
to every address in order, logging/past a failure so one dead address does
not stop the others, and returns false only when none could be sent.

Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 13:45:39 -07:00
kyle 4e1dd03d07 Route templates: a route named x-* serves any request route x-<something>
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 13:38:24 -07:00
kyle 055ab079d4 Learn per-model context from /props?model=; only status "loaded" is loaded
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 11:47:35 -07:00
kyle f3dfdbfa50 Record cancellation from what the reverse proxy observed, not the request context
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 11:32:18 -07:00
kyle d0d3203f73 Wire wake and identity into crossbar; v2 smoke and README
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 11:12:24 -07:00
kyle a942e336d8 Add identity: whois resolver, checker, header mode, middleware; config for wake, peers, identity
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 10:16:51 -07:00
kyle bddf6c93f2 Add the wake package: magic packets and a waiter
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 10:03:07 -07:00
kyle 2fe3b9c865 Proxy: move or refuse prompts that do not fit the leased host's context
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 09:56:46 -07:00
kyle 056a527fd7 Health: learn n_ctx and total_slots from /props
Implemented /props learning in internal/health/health.go (added Status.NCtx/Status.Slots, PerSlotCtx, and a best-effort GET <base>/props appended to the poll after /v1/models; 0/unknown on any failure without failing the poll) and exposed them in internal/admin/admin.go HostView. Copied internal/health/props_test.go and the replacement internal/proxy/helpers_test.go byte-identical to docs/plans/v2/_files/.

Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 09:14:08 -07:00
kyle 5afacbc050 Health: learn n_ctx and total_slots from /props
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 09:10:38 -07:00
kyleandClaude Fable 5.1 6bdcf437f4 v1.1 review: checklist, probes, three findings
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-25 09:02:13 -07:00
kyle 9f5b50acf6 Review fixes: record cancelled requests as 499; empty usage is an array
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 09:00:31 -07:00
kyleandClaude Fable 5.1 d7d8fcfa3b v1 review: checklist, outside probes, five findings; fill the Model column
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-25 07:00:21 -07:00
kyle cf2aa24393 Smoke run for v1; README for leases, admin and accounting
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 06:56:54 -07:00
kyle d82bfba3ec Wire the store, lease table and limiter into crossbar
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 06:38:36 -07:00
kyle 32ac7f549a Admin: leases, pin, release, drain, usage, metrics
cmd/crossbar/main.go calls admin.Handler with the new 6-arg signature, passing nil for the not-yet-wired leases/limiter/store/drainer (task 07 wires them) so go vet and go test ./... pass on cmd/crossbar. This is a compile fix, not the task-07 wiring; noted in the implementer-log.

Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 06:33:29 -07:00
kyle 97f7cdffd9 Route by lease, queue per host and model, record every request
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 05:15:21 -07:00
kyle 9133240cfb Add the sticky lease table
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 04:26:47 -07:00
kyle 7e0dbb4a6f Add the per-host-model limiter and the host chooser
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 03:53:38 -07:00
kyle 463cea18de Add the conversation fingerprint and the v1 config keys
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 03:46:05 -07:00
kyle 816614d6dd Add the SQLite store for leases and accounting
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 03:34:24 -07:00
kyle 091d8d16a5 Stop v1/01-store: gate blocked by pre-existing _files gofmt under Go 1.26.7
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 03:30:36 -07:00
kyle 9e0f906c8b Review fixes: recorder Flush without panic; unreadable config file is an error
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 02:58:17 -07:00
kyleandClaude Fable 5.1 89ab0b8d34 v0 review: checklist, outside probes, six findings; fill the Model column
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-25 02:42:52 -07:00
kyle e436c62a52 Add the smoke run, README and systemd unit
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 02:40:33 -07:00
kyle 4bc5115f24 Add the admin endpoints, the crossbar binary and the fake upstream
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 02:32:50 -07:00
kyle 5b347d9dd9 Add the routing reverse proxy
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 02:26:19 -07:00
kyle 68ad94d693 Add the health poller
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 02:16:38 -07:00
kyle 73b24357dd Add the Go module, the gate and the config package
Implemented-By: OpenCode session (model recorded in docs/implementer-log.md)
2026-09-25 02:09:42 -07:00
kyleandClaude Fable 5.1 89e47d83f8 v0 plan: AGENTS.md, gate, five task files with given tests, run-plan driver
Tests were run against a private reference implementation: gate ok after every
task in order, smoke ok (stream spread ~1000 ms). The reference is not in the
repository.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-25 01:51:53 -07:00