Add LLM system prompt override

Allow overriding the LLM system prompt via the `LLM_SYSTEM_PROMPT`
environment variable. This provides flexibility for customizing LLM
behavior without code changes. A default prompt is used if the
environment variable is unset or empty.
This commit is contained in:
2026-04-15 21:31:21 +02:00
parent 5608c8ba43
commit 70eed20909
4 changed files with 29 additions and 1 deletions
+11
View File
@@ -48,6 +48,17 @@ async fn main() {
);
}
{
let custom = std::env::var("LLM_SYSTEM_PROMPT")
.map(|v| !v.is_empty())
.unwrap_or(false);
info!(
prompt_source = if custom { "env" } else { "default" },
prompt_chars = config.llm_system_prompt.chars().count(),
"system prompt loaded"
);
}
// Shared HTTP client for both downstream pipelines.
let http_client = reqwest::Client::builder()
.build()