Expanded roadmap
Rendered from docs/roadmap-expanded.md at commit 813abb1662f7. The repository file is authoritative.
The owner decided on 2026-12-05 to bring the features that 0.2.0 listed as out of scope onto the roadmap. Tracking issue: #32. This document gives each item a testable outcome, its dependencies and its place in the order. Version 0.2.0 was the starting point. Version 0.3.0 ships the features described below.
Status words used below, and nowhere loosely:
- shipped — in a released version;
- merged, unreleased — on
main, not in a release; - in review — an open pull request with tests;
- planned — designed here, no code.
Evidence is recorded per item in roadmap-matrix.md as fixture (F), entry point (S) or live (L), with who ran it.
What does not change
These hold for every item, including the ones that used to be "out of scope". An item that cannot be built inside them is not built.
- Off by default, on by the operator. Every feature below is inert until a configuration key enables it; new hosted and lifecycle operations need explicit configuration. The served-context cap and observed memory accounting can change admission; see the upgrade notes.
- Authentication and caller isolation. State created through the API (responses, conversations, tool
results, jobs) belongs to the calling key; another key gets
404, not403. - No arbitrary command execution. The gateway runs no shell, no model-written code outside the evaluator's sandbox, and no "code interpreter" tool.
- No unrestricted network fetch. The gateway contacts only hosts the operator listed
(
security.allowed_backend_hostsand per-feature allow-lists). Remote media in requests is still never fetched. - No silent substitution. A request is served by a deployment that can honour it, or refused with the reason. A feature that changes what is computed (an ensemble, a frame-sampled video, a layout stage) says so in the response and the decision record.
- Truthful runtime support. A capability is offered on a runtime only on positive evidence: its documentation, a first-party source reference tied to a version, or a probe — and the record says which.
- Bounded everything. Inputs, fan-out, steps, bytes, wall-clock time and stored state have explicit limits with typed errors.
- The evaluator stays isolated and is not changed by any of this.
Order
foundations (this change set)
├─ F1 resident-memory evidence ───────────┬─► E2 opt-in eviction ──┬─► E8 cluster scheduler
├─ F2 version-gated runtime behaviour ─┬──┘ │
│ └─► E1 native Ollama image/audio embeddings
├─ F3 sandbox check, F4 measurement coverage
0.2.0 pieces
├─ managed lifecycle ─► E2, E3 opt-in downloads ──────────────────┘
├─ response store ───► E4 Conversations API ─► E6 hosted tools
├─ closed-choice vote, judge ─► E5 free-text ensembles
├─ OCR layout stage ─► E7 gateway-side layout
└─ vLLM video route ─► E9 video and multimodal alternatives
Order of delivery: F1–F4 → E1 → E2 → E4 → E3 → E5 → E7 → E6 → E9 → E8. Hosted tools come late because they need the Conversations state and the strictest review; the cluster scheduler is last because it needs eviction, downloads and worker identity to exist first.
Foundations shipped in 0.3.0
| outcome | test | |
|---|---|---|
| F1 | A resident model is counted at the runtime's own figure in the pool's units; cold models, failed queries and unknown residents fall back conservatively; nothing is loaded to be measured | tests/test_memory_evidence.py; live: scripts/ps_memory_check.py next to the machine's own memory figures |
| F2 | A behaviour the documentation does not list is used only at or above the Ollama version it was measured on (logprobs ≥ 0.40.16); older or unreadable versions keep the documented exclusion |
tests/test_ollama_fields.py |
| F3 | modelsaar sandbox check verifies isolation on the host with benign allow/deny checks and names the operator's next step; no backend → skip, never host execution |
tests/test_operator_workflows.py |
| F4 | modelsaar measurements shows measured / thin / prior / none per deployment and task |
same file |
E1 — Image and audio embeddings through Ollama's native API
Status: shipped in 0.3.0 (fixture-tested and independently exercised on the GX10 with Ollama 0.40.21, including a mixed batch). Operator guide: pipelines.md, "Image and audio embeddings through Ollama".
Why now: Ollama 0.40.16 accepts input maps with text, image or audio on POST /api/embed
(api/types.go of that tag; the public endpoint page still describes text only). The owner measured it on
the GX10 with embeddinggemma-2: two images and two audio clips each gave distinct 768-dimensional vectors.
Ollama's OpenAI-compatible /v1/embeddings remains text-only.
- Default: off. Needs the existing
embeddings[].modalitiescontract listing the modality, and the model must be the alias's established identity (an index is tied to one vector space). - Gates: runtime version ≥ 0.40.16 (older, pre-release or unreadable →
501with the reason); modality allowed by the alias contract; the deployment's capability for that modality established (runtime metadata, an operator declaration or a probe); vector width equal to the contract's; inlinedata:media only, with the existing size limits. - Video is not included: the native request type lists text, image and audio. A video item on an
Ollama backend stays
501. - Outcome:
POST /v1/embeddingswithimage_url/input_audioitems against an Ollama-backed multimodal alias returns vectors in input order with the contract's dimension; a mixed text+media batch is one vector space; a 0.40.15 runtime refuses before sending anything. - Tests: fixture server implementing the native map form and a version switch; live: Codex on the GX10.
E2 — Opt-in automatic eviction
Status: shipped in 0.3.0 (fixture-tested; tests/test_auto_evict.py). Operator guide:
lifecycle.md, "Opt-in automatic eviction".
- Depends on: managed lifecycle (0.2), F1.
- Default: off (
backends[].lifecycle.auto_evict: false). Without it a load or dispatch that does not fit the pool is refused, as today. - Rules: only on a managed backend that also set
auto_evict, and only victims on such a backend; only models with no in-flight request, no uncertain hold, no queued request, no explicit lease and no lifecycle operation in progress — judged per physical model (endpoint + name), across every backend entry that names it; least-recently-used first; at mostmax_evictions_per_request, and nothing at all if that cannot free enough; memory counts as free only on confirmed absence (a successful residency listing taken after the unload, from every backend that knows the model); the decision record lists what was evicted. - Outcome: with a 2-model budget and three models, a request for the third unloads the idle least-recently-used one and is served; a leased or busy model is never evicted and the request is refused instead; a failed unload leaves accounting unchanged.
- Live test: two small models on a disposable Ollama, budget for one.
E3 — Opt-in model downloads
Status: shipped in 0.3.0 (fixture-tested and exercised on a disposable Ollama 0.40.21 store). Reference: lifecycle.md, "Opt-in model downloads".
- Depends on: managed lifecycle. Separate switch from E2.
- Default: off (
lifecycle.allow_pull). Never triggered by an inference request: onlymodelsaar lifecycle pull/POST /admin/lifecycle/pullwith the admin key. - Rules: the model name must be on
backends[].lifecycle.pull_allowlist; an expected digest can be pinned, and a pinned name is routable only at that digest (enforced at discovery; failed results remain withheld across restarts); a store budget is checked before starting (the runtime's listed sizes plus the declared size — the runtime reports no size before it downloads); one pull per backend at a time; cancellable; after a restart the job readsinterruptedand can be resumed or cancelled; the registry of the runtime's host is the only network destination, and it is the runtime that connects, not the gateway. - Outcome: an allow-listed pull appears in discovery with the pinned digest; a name off the list is
403; an over-budget pull is refused before any transfer; cancel leaves no registry entry. - Stated limits: partial layers cannot be seen or removed by the gateway; free disk space is not known to it; an existing model is never replaced.
- Live test: Two verified downloads, mid-transfer cancellation, resumption and a digest mismatch.
E4 — Conversations API
Status: shipped in 0.3.0 (fixture-tested; tests/test_conversations.py). Reference:
protocols.md, "Conversations API".
- Depends on: the response store (0.2).
- Default: off (
protocols.conversations.enabled, requires the response store). - Surface:
POST /v1/conversations,GET/DELETE /v1/conversations/{id},POST/GET /v1/conversations/{id}/itemswith cursor pagination,DELETE …/items/{item_id}, andconversationonPOST /v1/responses. - Rules: caller-scoped (
404for another key); bounded items per conversation and bytes per item; TTL; one turn at a time per conversation (a concurrent turn gets409, not an interleaved history); the stored history is what is sent to the model — no hidden summarisation. - Outcome: create → append → respond with
conversation→ list (paginated, stable order) → delete →404; two concurrent turns: one409; another key:404.
E5 — Free-text ensembles
Status: shipped in 0.3.0 (fixture-tested; tests/test_free_text_ensemble.py). Reference:
pipelines.md, "Free-text ensembles".
- Depends on: closed-choice voting and the judge pass (0.2).
- Default: off; explicit endpoint (
POST /v1/ensemble), never applied to an ordinary chat request. - Method: N candidates from distinct deployments under one deadline; then an explicit second step the
caller chooses —
select(a closed-choice vote over the candidate indices by one or more judges) orsynthesize(one named deployment writes a final answer from the candidates). No averaging of text. - Rules: every stage (candidate, judge, synthesiser — an explicit one included) is ranked on the
caller's alias and bound by its restrictions and the locality policy; routing hints are honoured
(
profile) or refused (session affinity), never dropped; the deadline is wall clock across routing, admission and every upstream call, with a cut call accounted as an uncertain hold; bounded N, tokens and deadline; a failed or late candidate is reported, not hidden; the response carries every candidate with its deployment, the method, the judge/synthesiser identity and the tally; a judge is never one of the candidates unless the caller allows it. - Outcome: provenance for every candidate; quorum failure →
424with the partial record;selectreturns one candidate verbatim.
E6 — Hosted tools
Status: shipped in 0.3.0, with fixture and hardware checks. Reference: hosted-tools.md — configuration, wire format, safety properties, audit.
- Depends on: E4.
- Default: off; an empty catalogue means every hosted tool is refused as today.
- Catalogue (operator-declared, nothing else exists):
file_searchover a local document set the operator registered (embeddings through an existing alias);httptools — a fixed method and URL template on an allow-listed host with a declared JSON schema, timeout and response cap; MCP servers on allow-listed local addresses. Not offered: code interpreter, shell, computer use, image generation, open web search (a search tool exists only as anhttptool pointing at the operator's own endpoint). - Rules: bounded steps per response; each call recorded (tool, duration, bytes, outcome — arguments and results only when prompt logging is on); tool output is data, never instructions to the gateway; per-key tool allow-lists.
- Outcome: a Responses request naming a catalogued tool runs the loop to a final answer with an
auditable trace; an uncatalogued tool →
400; a tool host off the allow-list cannot be reached; a step-limit overrun ends withincomplete. - As built: the loop is non-streamed internally (a stream reports each step; a turn's text is one
delta); caller-executed
functiontools keep working in the same request; hosted items replay ininput, stored responses and conversations; MCP is Streamable HTTP on loopback only (no stdio: the gateway starts no processes); documents are registered as text by the administrator. - Hardware evidence: real model, embeddings, HTTP, MCP and a streamed SDK call. Retrieval quality on a representative collection remains unmeasured.
E7 — Gateway-side document layout
Status: both engines shipped in 0.3.0. See tests/test_layout_builtin.py and tests/test_layout_onnx.py.
Reference: pipelines.md, "Layout without a service".
- Depends on: the OCR layout stage (0.2), which calls a layout service the operator runs.
- Step 1 — classical segmentation (no model):
pipelines.ocr.layout.engine: builtinsplits a page into text blocks by projection profiles (recursive X-Y cut) inside the existing pixel and region budgets. It finds blocks and a reading order on clean, axis-aligned pages; it does not classify regions and is labelledlayout.engine: builtin-xycutin the result. - Step 2 — an optional layout model: an extra (
modelsaar[layout-onnx]) running an operator-supplied model file with a pinned SHA-256; nothing is downloaded; absent file or digest mismatch → the stage is unavailable (503), never a silent fallback to step 1. - Outcome: on synthetic pages (one to three columns, a heading and full-width paragraphs between bands of columns) the builtin engine returns the blocks in reading order — done; step 2 matches recorded boxes on a generated detector fixture and refuses a wrong digest.
- Live check: three detected and transcribed lines on a four-line synthetic page. Representative scanned or photographed pages remain unmeasured.
E8 — Cluster scheduler
Placement shipped in 0.3.0. modelsaar lifecycle place uses verified weights, observed residency and per-pool capacity. Two physical workers passed the placement and lease check. The cluster job API persists ownership and its submission boundary in SQLite. It passed the two-machine worker-loss and lost-acknowledgement trials.
- Depends on: E2, E3, replica scheduling (0.2; least-loaded routing across two physical hosts was run live by the owner on 2026-12-05).
- Scope: placement (which worker holds which model), capacity accounting per worker from F1, job ownership with leases, worker loss detection, and retry only for requests that were provably not started. Workers are backends the operator lists; no auto-discovery on the network.
- Outcome: with two workers, a placement request loads the model where it fits; killing a worker mid-queue moves unstarted work and fails started work with a typed error; no request runs twice.
- Distinguish: two fixture servers are not a cluster trial; the live gate is two physical workers.
E9 — Video and multimodal routes where Ollama has no transport
- Shipped in 0.2; subsequently exercised on real vLLM models (run): inline video to vLLM's documented
video_urlform; image, audio and video embedding items to vLLM's chat-style embeddings. - E1 covers image and audio embeddings on Ollama. Video embeddings on Ollama stay unsupported until the runtime lists them.
- Shipped in 0.3.0 — explicit frame sampling: an opt-in pipeline (
pipelines.video_frames) that turns one inline video into K still images for a vision model, with an optional decoder extra. It is a different computation from native video understanding, so it is requested explicitly (modelsaar.video: "frames"), bounded (duration, K, pixels), and labelled in the response. It is never applied to a request that simply contains a video part. - Outcome: a video request without the opt-in on an Ollama-only installation is refused with the alternatives named; with it, the decision record shows the frame count and the vision deployment.