From 1a90fbdf8e5553f49fc21bbb38217c34b6a8b0cd Mon Sep 17 00:00:00 2001 From: Sam Catlow Date: Wed, 29 Jul 2026 07:30:10 +1000 Subject: [PATCH] fix: add missing ModelPersist field to Router --- internal/gateway/gateway.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/internal/gateway/gateway.go b/internal/gateway/gateway.go index 33039417d..1d60b40b8 100644 --- a/internal/gateway/gateway.go +++ b/internal/gateway/gateway.go @@ -133,7 +133,10 @@ type TaskController interface { type Router struct { Store StatusReader Models ModelManager // nil = /model not configured - Tasks TaskCreator // nil = /spawn not configured + // ModelPersist persists the active model selection so it survives + // restarts (e.g. writing back to identity config). nil = not configured. + ModelPersist func(ctx context.Context, modelRef string) error + Tasks TaskCreator // nil = /spawn not configured Controller TaskController // nil = /approve and /cancel not configured LLM LLMResponder // nil = LLM not wired yet // LLMStream is the optional streaming responder. When set, adapters