From 49c673b683f31a1e178eb1c112bc8a911fe3cb6e Mon Sep 17 00:00:00 2001 From: rene Date: Fri, 3 Apr 2026 00:44:04 +0200 Subject: [PATCH] feat: add ctx_morning_briefing routing rule and prompt template Adds LLM Gateway support for CtxReport daily intelligence reports. Uses qwen2.5:32b to generate German-language morning briefings from infrastructure metrics collected overnight. --- .../templates/ctx_morning_briefing.yaml | 23 +++++++++++++++++++ .../gateway/src/config/routing-rules.yaml | 12 ++++++++++ 2 files changed, 35 insertions(+) create mode 100644 packages/gateway/prompts/templates/ctx_morning_briefing.yaml diff --git a/packages/gateway/prompts/templates/ctx_morning_briefing.yaml b/packages/gateway/prompts/templates/ctx_morning_briefing.yaml new file mode 100644 index 0000000..62aaa80 --- /dev/null +++ b/packages/gateway/prompts/templates/ctx_morning_briefing.yaml @@ -0,0 +1,23 @@ +id: ctx_morning_briefing +version: "1.0.0" +task_type: ctx_morning_briefing +description: Generate AI morning briefing brainstorm for CtxReport +model_preference: qwen2.5:32b +model_minimum: qwen2.5:14b +temperature: 0.7 +max_tokens: 512 +output_format: text + +system_prompt: | + You are the Context X Infrastructure Intelligence AI. + Analyze the infrastructure data and generate a concise morning briefing. + Write in German. Format as 5-7 bullet points starting with an emoji. + Be direct, specific, and actionable. Highlight the most important things that need attention today. + +user_template: | + Infrastructure report data for the last 24 hours: + + {{input}} + + Generate a concise morning briefing in German with 5-7 bullet points. + Focus on: what happened, what needs attention today, what improved. diff --git a/packages/gateway/src/config/routing-rules.yaml b/packages/gateway/src/config/routing-rules.yaml index dd543cc..c3a89d0 100644 --- a/packages/gateway/src/config/routing-rules.yaml +++ b/packages/gateway/src/config/routing-rules.yaml @@ -15,6 +15,18 @@ routing_rules: validators: [] callers: [all] + # ─── CTX-REPORT MORNING BRIEFING ────────────────────────────────────────── + ctx_morning_briefing: + model: qwen2.5:32b + tier: large + prompt_template: ctx_morning_briefing + temperature: 0.7 + max_tokens: 512 + output_format: text + requires_fact_check: false + validators: [] + callers: [ctx-report, internal] + # ─── INTERNAL ───────────────────────────────────────────────────────────── internal_ban_detect: model: qwen2.5:3b