Skip to content

feat: add a repeatable PARAM keyword for engine flags - #269

Merged
outofcoffee merged 5 commits into
mainfrom
feat/param-keyword
Oct 26, 2026
Merged

outofcoffee merged 5 commits into
mainfrom
feat/param-keyword

Conversation

@outofcoffee

@outofcoffee outofcoffee commented Oct 14, 2026 •

Copy link
Copy Markdown
Collaborator

Spinloop files can now carry their engine's flags with repeatable PARAM lines, in place of a preset file.

fixes #266

Summary

  • New repeatable PARAM key = value instruction in Spinloop files; keys are read in the engine's own flag dialect, so ngl becomes --n-gpu-layers for llama.cpp while vLLM's and MTPLX's long-form keys pass through unchanged
  • Precedence where the same flag is set in more than one place: the Spinloop's typed instructions, then a PARAM, then the preset
  • A PARAM may name the model where the engine takes it as a flag — llama.cpp's hf/model/hf-file, MTPLX's model — so a Spinloop with no preset file still serves and deploys its model; vLLM takes its model positionally, so a PARAM cannot stand in for MODEL there
  • spinloop cloud deploy and a fleet node wake read PARAMs the way they read a preset, dropping the settings the destination owns from them alike
  • Docs updated (the Spinloop file, serve, cloud) and two new examples: examples/llamacpp/qwen3.8-27b-mtp, PARAM-based with no preset file, and examples/vllm/qwen3.8-27b, the first vLLM example

Implementation details

  • internal/spinloop gains the Param pair and its parse/format; internal/preset gains Dialect.Merge(layers ...) so the PARAM layer is one more layer in the same merge a preset already goes through — the dialect rendering, the owned-flag dropping, and the model-reference handling all fall out of that one change
  • Model sourcing is defined once per engine: modelSourceFlags(runner) lists the flags that name the model (llamacpp hf-repo/model/hf-file, mtplx model, none for vllm), and paramModel is the shared core both the serve and the deploy paths call

@outofcoffee outofcoffee added the enhancement New feature or request label Oct 18, 2026
spinloop-agent added 2 commits October 18, 2026 14:46
A PARAM line sets one engine flag, in the engine's own dialect, so a
Spinloop can carry its serve options without a preset file. Where both
set a flag a PARAM stands over the preset, and the Spinloop's typed
instructions stand over a PARAM. For an engine whose model is a flag
(llama.cpp's hf/model/hf-file, MTPLX's model) a PARAM with that key
names the model in place of MODEL; vLLM takes its model positionally,
so a PARAM cannot stand in for it there. Cloud deploy reads PARAMs the
way it reads a preset, dropping the cloud-owned settings from them.
A `PARAM key` with no ` = value` parses as the empty-value form `PARAM key =`,
so a flag that takes no value can be written bare; `Format` now renders an
empty-valued PARAM bare too, keeping the round-trip idempotent.
The mtplx example shows a PARAM naming the model in place of a MODEL line; the
oMLX one covers the model-directory PARAMs, the paged SSD cache, and why a
PARAM cannot stand in for oMLX's model.
@outofcoffee outofcoffee self-assigned this Oct 26, 2026
@outofcoffee
outofcoffee marked this pull request as ready for review October 26, 2026 11:28
@outofcoffee
outofcoffee merged commit f397137 into main Oct 26, 2026
5 checks passed
@outofcoffee
outofcoffee deleted the feat/param-keyword branch October 26, 2026 20:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: add PARAM keyword to Spinloop file as alternative to preset

1 participant