ship codegen sampler params + escalation ladder per Qwen3.8 card
CodegenClient now sends temperature/top_p/presence_penalty/frequency_penalty (card-endorsed high presence_penalty, temp 0.7 instead of greedy 0.0) and generate_skill_body escalates on invalid parse with an escalated sampler (temp 0.5/presence 2.0) and a fresh short corrective prompt, up to max_attempts. Degeneration aborts are a distinct DegenerationError(CodegenError) that propagates without retry; retry-on-degeneration is left open. Marks guardrail items 5/6 per the model card.
This commit is contained in:
1 parent
7c5cd2b685
commit
d18f0ccdb6
5 files changed
+363
-38
No files matched your search
+6
-1
@@ -13,7 +13,7 @@
|
||||
},
|
||||
"llm": {"base_url": "http://localhost:11434/v1", "model": "qwen3.5:4b"},
|
||||
"codegen": {
|
||||
"_comment": "OpenAI-compatible model that writes runnable skill bodies. Larger/slower than the decision or self-assessment model. The transport always streams so the client-side token budget (output cap / peak total fill) can abort a runaway in real time; stream only toggles console echo of tokens. timeout is total seconds; idle_warn/idle_timeout surface a silent (wedged) stream. The context window is auto-detected via ollama /api/show; context_window is the manual fallback (0 = auto/default 100000). smart_limit/warn_limit and max_fill_ratio/warn_fill_ratio bound total fill; max_output caps streamed output (>=1 absolute tokens, 0<x<1 fraction of window); chars_per_token converts chars to the token estimate.",
|
||||
"_comment": "OpenAI-compatible model that writes runnable skill bodies. Larger/slower than the decision or self-assessment model. The transport always streams so the client-side token budget (output cap / peak total fill) can abort a runaway in real time; stream only toggles console echo of tokens. timeout is total seconds; idle_warn/idle_timeout surface a silent (wedged) stream. The context window is auto-detected via ollama /api/show; context_window is the manual fallback (0 = auto/default 100000). smart_limit/warn_limit and max_fill_ratio/warn_fill_ratio bound total fill; max_output caps streamed output (>=1 absolute tokens, 0<x<1 fraction of window); chars_per_token converts chars to the token estimate. temperature/top_p/presence_penalty/frequency_penalty follow the Qwen3.8 model card's instruct-mode anti-repetition guidance (high presence_penalty, not greedy temperature); generate_skill_body escalates to presence 2.0 / temp 0.5 on retries (max_attempts attempts, fresh short prompt each time).",
|
||||
"base_url": "http://localhost:11434/v1",
|
||||
"model": "qwen38-iq3s",
|
||||
"timeout": 1200,
|
||||
@@ -27,6 +27,11 @@
|
||||
"warn_fill_ratio": 0.7,
|
||||
"max_output": 0.85,
|
||||
"chars_per_token": 4.0,
|
||||
"temperature": 0.7,
|
||||
"top_p": 0.85,
|
||||
"presence_penalty": 1.5,
|
||||
"frequency_penalty": 0.2,
|
||||
"max_attempts": 3,
|
||||
"degeneration": {
|
||||
"_comment": "SemIf degeneration watchdog: while the body streams, a 2-option SemIf decision (continue/stop) is made every `interval` chars against the last `window` chars of content+reasoning (once `min_chars` have accumulated); P(stop) >= threshold aborts the write with a graceful stub. Recorded trace-only (kind `codegen`), never in the decision log. Disabled when no engine is available.",
|
||||
"enabled": true,
|
||||
|
||||
Reference in new issue
Block a user