fix(config): config writer silently dropped router.narration.model_id
Every TUI config-editor save regenerates the TOML through CorrexConfigWriter, whose [router.narration] section never wrote model_id — one save and narration silently fell back to the main model, queueing every narration behind slow 9B inferences (live QA: approval narrations arrived minutes late, after the workflow had already failed). The writer now persists it and the field is editable in the TUI (blank clears it).
This commit is contained in:
@@ -80,6 +80,7 @@ object CorrexConfigWriter {
|
||||
b.kv("top_p", cfg.router.narration.topP)
|
||||
b.kv("max_tokens", cfg.router.narration.maxTokens)
|
||||
b.kv("max_per_run", cfg.router.narration.maxPerRun)
|
||||
cfg.router.narration.modelId?.let { b.kv("model_id", str(it)) }
|
||||
|
||||
b.section("orchestration")
|
||||
b.kv("stage_timeout_ms", cfg.orchestration.stageTimeoutMs)
|
||||
|
||||
@@ -135,6 +135,11 @@ object EditableConfig {
|
||||
getString = { it.router.narration.maxPerRun.toString() },
|
||||
withString = { c, v -> nar(c) { it.copy(maxPerRun = int("router.narration.max_per_run", v)) } },
|
||||
),
|
||||
EditableField(
|
||||
"router.narration.model_id", ConfigFieldType.STRING,
|
||||
getString = { it.router.narration.modelId.orEmpty() },
|
||||
withString = { c, v -> nar(c) { it.copy(modelId = v.trim().ifBlank { null }) } },
|
||||
),
|
||||
EditableField(
|
||||
"personalization.enabled", ConfigFieldType.BOOL,
|
||||
getString = { it.personalization.enabled.toString() },
|
||||
|
||||
Reference in New Issue
Block a user