From 4e89c8aac01283dbddd644896a48af422c9d4c90 Mon Sep 17 00:00:00 2001 From: Ettore Di Giacinto Date: Sun, 1 Feb 2026 09:36:24 +0100 Subject: [PATCH] chore: attach observables for standalone jobs (#399) * chore: add observable for standalone jobs Signed-off-by: Ettore Di Giacinto * chore: update docker compose with latest models Signed-off-by: Ettore Di Giacinto --------- Signed-off-by: Ettore Di Giacinto --- core/agent/agent.go | 19 +++++++++++++++++++ docker-compose.yaml | 4 ++-- 2 files changed, 21 insertions(+), 2 deletions(-) diff --git a/core/agent/agent.go b/core/agent/agent.go index a662318..f60c982 100644 --- a/core/agent/agent.go +++ b/core/agent/agent.go @@ -1184,6 +1184,15 @@ func (a *Agent) periodicallyRun(timer *time.Timer) { "is_reminder": true, } + // Attach observable so UI can show reminder processing state + if a.observer != nil { + obs := a.observer.NewObservable() + obs.Name = "reminder" + obs.Icon = "bell" + a.observer.Update(*obs) + reminderJob.Obs = obs + } + // Process the reminder as a normal conversation a.consumeJob(reminderJob, UserRole) @@ -1228,6 +1237,16 @@ func (a *Agent) periodicallyRun(timer *time.Timer) { types.WithReasoningCallback(a.options.reasoningCallback), types.WithResultCallback(a.options.resultCallback), ) + + // Attach observable so UI can show standalone job progress (decisions, actions, reasoning) + if a.observer != nil { + obs := a.observer.NewObservable() + obs.Name = "standalone" + obs.Icon = "clock" + a.observer.Update(*obs) + whatNext.Obs = obs + } + a.consumeJob(whatNext, SystemRole) xlog.Info("STOP -- Periodically run is done", "agent", a.Character.Name) diff --git a/docker-compose.yaml b/docker-compose.yaml index 3a32c10..b8f61c9 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -9,7 +9,7 @@ services: command: - ${MODEL_NAME:-gemma-3-4b-it-qat} - ${MULTIMODAL_MODEL:-gemma-3-4b-it-qat} -# - ${IMAGE_MODEL:-sd-1.5-ggml} + - ${IMAGE_MODEL:-Z-Image-Turbo} - granite-embedding-107m-multilingual healthcheck: test: ["CMD", "curl", "-f", "http://localhost:8080/readyz"] @@ -112,7 +112,7 @@ services: environment: - LOCALAGI_MODEL=${MODEL_NAME:-gemma-3-4b-it-qat} - LOCALAGI_MULTIMODAL_MODEL=${MULTIMODAL_MODEL:-moondream2-20250414} - - LOCALAGI_IMAGE_MODEL=${IMAGE_MODEL:-sd-1.5-ggml} + - LOCALAGI_IMAGE_MODEL=${IMAGE_MODEL:-Z-Image-Turbo} - LOCALAGI_LLM_API_URL=http://localai:8080 #- LOCALAGI_LLM_API_KEY=sk-1234567890 - LOCALAGI_LOCALRAG_URL=http://localrecall:8080