From c6a365d0f552b7412ae6f8a968be7640f4d73c5c Mon Sep 17 00:00:00 2001 From: Ishaan Jaffer Date: Thu, 19 Feb 2026 13:36:39 -0800 Subject: [PATCH] feat: register airline off-topic restriction in policy templates backup --- litellm/policy_templates_backup.json | 45 ++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) diff --git a/litellm/policy_templates_backup.json b/litellm/policy_templates_backup.json index f27f20187f9..1b8b1a0bd25 100644 --- a/litellm/policy_templates_backup.json +++ b/litellm/policy_templates_backup.json @@ -1692,6 +1692,51 @@ "Security" ] }, + { + "id": "airline-off-topic-restriction", + "title": "Airline Off-Topic Restriction", + "description": "Restricts an airline chatbot to airline-related topics only. Blocks off-topic questions about news, sports, coding, politics, entertainment, finance, recipes, homework, and general knowledge using keyword-based detection with no additional LLM calls.", + "icon": "ShieldExclamationIcon", + "iconColor": "text-orange-500", + "iconBg": "bg-orange-50", + "guardrails": [ + "airline-off-topic-filter" + ], + "complexity": "Medium", + "guardrailDefinitions": [ + { + "guardrail_name": "airline-off-topic-filter", + "litellm_params": { + "guardrail": "litellm_content_filter", + "mode": "pre_call", + "categories": [ + { + "category": "airline_off_topic_restriction", + "category_file": "litellm/proxy/guardrails/guardrail_hooks/litellm_content_filter/policy_templates/airline_off_topic_restriction.yaml", + "enabled": true, + "action": "BLOCK", + "severity_threshold": "medium" + } + ] + }, + "guardrail_info": { + "description": "Blocks off-topic questions unrelated to airline services (news, sports, coding, politics, entertainment, finance, recipes, etc.)" + } + } + ], + "templateData": { + "policy_name": "airline-off-topic-restriction", + "description": "Restricts chatbot to airline-related topics. Blocks off-topic questions using keyword matching with no extra LLM calls.", + "guardrails_add": [ + "airline-off-topic-filter" + ], + "guardrails_remove": [] + }, + "tags": [ + "Aviation", + "Topic Restriction" + ] + }, { "id": "uae-regulatory-compliance", "title": "UAE Regulatory Compliance",