Skip to content

refactor(runtime): share backend supervision and output capture - #14647

Merged
cv merged 2 commits into
v1from
cv/share-runtime-supervision
Nov 19, 2026
Merged

cv merged 2 commits into
v1from
cv/share-runtime-supervision

Conversation

@cv

@cv cv commented Nov 19, 2026

Copy link
Copy Markdown
Collaborator

Moves vLLM's backend supervision, output capture, writer lock, and credential loading into the runtime's shared execution module, so later managed runtimes reuse them instead of copying vLLM's. Runtime behavior, error messages, and forwarded backend output don't change.

Problem

The vLLM runtime owns its writer lock, memory sampler and readiness task, route-filter supervision, output capture, and credential loading, and Ollama repeats the writer lock. A new managed runtime, such as the llama.cpp and NIM runtimes in #14611, would copy them again.

Part of #14556. Extracted from #14611, which can rebase onto this change.

Change

  • execution::lock opens a lock file and takes its exclusive writer lock with the caller's error messages; vLLM's storage and credential locks and Ollama's storage lock use it.
  • execution::serve runs the memory sampler and readiness task, supervises the backend with or without a route filter, and explains its exit from its output.
  • execution::supervisor::with_filter is vLLM's route-filter supervision, moved from vllm/runtime/routes.rs.
  • execution::output::Output is vLLM's output capture, moved from vllm/runtime/process.rs; it still redacts the one bearer key.
  • vllm/runtime/authentication.rs moves unchanged to execution/authentication.rs.

Ollama keeps its own sampler loop, because its readiness failures feed the sample stream. Streaming output filtering, which only NIM needs, stays in #14611.

Move the writer lock, backend supervision with its memory sampler and
readiness task, the route-filter supervision, output capture, and
credential loading into the execution module, so later managed runtimes
can reuse them. vLLM adopts all of them and Ollama adopts the writer
lock. Error messages and forwarded output are unchanged.

Extracted from #14611.

Co-authored-by: Prekshi Vyas <[email protected]>
@cv

cv commented Nov 19, 2026

Copy link
Copy Markdown
Collaborator Author
Authoring session — opening
Field Status Value Evidence or limit
Harness recorded Pi 1.5.2 (session format 3) Session header and installed release
Skills recorded nemoclaw-contributor-create-pr (complete read) Tool results to cutoff
Instruction files recorded AGENTS.md (injected); WRITING.md (complete read); .github/PULL_REQUEST_TEMPLATE.md (complete read); .github/SESSION_REPORT_TEMPLATE.md (complete read) Startup context and tool results to cutoff
Tool calls recorded typescript: 33 Includes one failed type check; the wrapper hides nested host calls, which are not counted
Tokens recorded input: 1910628; cached input: 1835028; output: 16194 Sum of 36 assistant message.usage entries (input + cacheRead + cacheWrite; cacheRead; output) to cutoff; provider reported nonzero cache counters
Session window recorded 2026-11-19T08:50Z to 2026-11-19T09:07Z; 17 min First event to cutoff (PR creation), including idle time
Compactions recorded 0 Complete record to cutoff
Models recorded claude-opus-5-5 Model change entry and assistant messages; no changes
Reasoning levels recorded medium Thinking-level entry; no changes

@github-actions

Copy link
Copy Markdown
Contributor

@cv
cv enabled auto-merge (squash) November 19, 2026 09:26
@cv
cv merged commit d945c5e into v1 Nov 19, 2026
81 checks passed
@cv
cv deleted the cv/share-runtime-supervision branch November 19, 2026 09:26
@cv cv added this to the Roadmap: GTC DC 2026 milestone Nov 19, 2026
@cv cv added the v1 NemoClaw v1 branch label Nov 19, 2026
cv added a commit that referenced this pull request Nov 19, 2026
Keep v1's shared inference installer and backend supervision code from #14646 and #14647, with this branch's llama.cpp and NIM additions on top. Output keeps the streaming filter NIM uses, and the intent record fingerprint covers v1's widened Ollama proxy engine.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

v1 NemoClaw v1 branch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant