werk1112

Five-model implementation report

Evidence checked on 2026-10-13. See the audit for official sources and the matrix for exact IDs, mode-specific status, requirements and reproducible commands. No real inference of these five models was performed; no new path is VERIFIED_LOCAL or VERIFIED_REMOTE.

Design and changed surfaces

Latest startup preload behavior

src/api/preload.rs runs an ordered, deduplicated startup sequence and stops at the first failed target. The CLI exits on failure instead of starting a partially prepared service. Successful handles remain owned by the server until shutdown.

Kolibri uses the existing vLLM runtime-cache transaction and a real short warmup with reasoning_effort:none / enable_thinking:false, so hidden reasoning does not consume the entire 32-token preload response. FLUX Action loads/prepares the policy, predicts once on synthetic observations, then pins its worker in the same runtime-cache mechanism. Fresh failed warmups roll back their worker; multiple pinned policies survive the ordinary cache capacity of one. Tests use fake policies/processes and do not verify model inference.

Cloud preloading for Mistral, BFL and ElevenLabs validates local credential syntax and pins a reusable HTTPS client. It makes zero network requests. Its separate serve.preload.remote_prepared event explicitly states that it did not warm provider weights or test account access. The ordinary readiness count therefore means preparation succeeded, not that hosted inference was verified. This avoids an implicit billable generation every time werk serve --preload starts.

Verification evidence

Environment: Linux x86_64, Rust/Cargo 1.98.0, Python 3.12.8, RTX 3090 with 24 GiB VRAM and about 98 GiB host RAM. The official Kolibri/FLUX Action Python runtimes, checkpoint packages and all three provider keys were absent. This GPU does not meet Kolibri’s documented minimum. No paid API requests were made.

Commands executed:

cargo check --locked
cargo fmt --all --check
git diff --check
python3 -m unittest discover -s runtime -p 'test_werk*.py'
RUST_MIN_STACK=16777216 cargo test --lib --quiet -- --test-threads=1
RUST_MIN_STACK=16777216 cargo test --lib --locked kolibri -- --test-threads=1
RUST_MIN_STACK=16777216 cargo test --lib --locked provider -- --test-threads=1
cargo clippy --all-targets --locked -- -D warnings
cargo build --locked --bin werk

The full Rust library run passed 1,306 tests, with 4 ignored, in 180.67s. The Python run passed 87 tests, including DROID validation and the Schnell loader fixture. An earlier ordinary parallel Rust run failed in existing process/cache tests and then overflowed a CLI parser test’s stack. The passing run used the larger stack configured by .github/workflows/observability.yml and serial execution to isolate shared-process tests. This is a test-environment limitation, not evidence that the parallel run passed.

The new mock tests cover provider registration/status, schema rejection, tools and tool-result continuation, structured-output request mapping, Mistral SSE, reasoning blocks, binary audio, BFL polling/moderation/download, 429 retry, ambiguous-failure non-replay, stalled-request timeout, credential isolation, authentication and invalid HTTP requests. Resident-worker tests exercise warmup, reuse, pinning beyond cache capacity, failed-warmup rollback and process cleanup. Additional Kolibri tests check launch parameters and the non-reasoning preload request; they do not execute a real Kolibri tool call.

Strict Clippy is not clean repository-wide: existing warnings in untouched code include collapsible conditionals, type complexity, clone-on-copy and suspicious open options. Warnings introduced in the new provider/API code were fixed. The final check results below distinguish these existing warnings from the completed focused checks and CLI/server smoke.

Final focused checks and server smoke

Limits and follow-up