File tree Expand file tree Collapse file tree 3 files changed +27
-3
lines changed
Expand file tree Collapse file tree 3 files changed +27
-3
lines changed Original file line number Diff line number Diff line change 110110- No emojis in tables
111111- Separate each config section with 80 equals signs.
112112
113- **Remember:**
113+ **Remember:**
114114- The tools provide percentage changes - use them as provided
115115- CHECK thresholds (5% and 10%) before categorizing
116116- SORT by absolute percentage change (highest first) - this is mandatory
129129}
130130# Jira tool prompt - used when Jira MCP tools are available
131131JIRA_TOOL_PROMPT = {
132- "system_suffix " : (
132+ "system " : (
133133 "\n \n IMPORTANT: You have access to JIRA search tools. After analyzing the error, "
134134 "ALWAYS search for related issues in JIRA using the search_jira_issues tool with the OCPBUGS project. "
135135 "Extract key error terms, component names, or operators from the log summary to search for similar issues. "
Original file line number Diff line number Diff line change 1212 INFERENCE_MAX_TOOL_ITERATIONS ,
1313)
1414from bugzooka .integrations .inference import InferenceAPIUnavailableError
15+ from bugzooka .analysis .prompts import JIRA_TOOL_PROMPT
1516
1617
1718logger = logging .getLogger (__name__ )
@@ -364,8 +365,14 @@ async def analyze_log_with_gemini(
364365 error_summary [:150 ] + "..." if len (error_summary ) > 150 else error_summary ,
365366 )
366367
368+ # Append Jira prompt if Jira MCP tools are available
369+ system_prompt = prompt_config ["system" ]
370+ if tools and any (getattr (t , "name" , "" ) == "search_jira_issues" for t in tools ):
371+ logger .info ("Jira MCP tools detected - injecting Jira prompt" )
372+ system_prompt += JIRA_TOOL_PROMPT ["system" ]
373+
367374 messages = [
368- {"role" : "system" , "content" : prompt_config [ "system" ] },
375+ {"role" : "system" , "content" : system_prompt },
369376 {"role" : "user" , "content" : formatted_content },
370377 {"role" : "assistant" , "content" : prompt_config ["assistant" ]},
371378 ]
Original file line number Diff line number Diff line change 1+ apiVersion : v1
2+ kind : Service
3+ metadata :
4+ labels :
5+ app.kubernetes.io/instance : jira-mcp
6+ name : jira-mcp
7+ namespace : ${BUGZOOKA_NAMESPACE}
8+ spec :
9+ ports :
10+ - name : http
11+ port : 3031
12+ protocol : TCP
13+ targetPort : 3031
14+ selector :
15+ app.kubernetes.io/instance : jira-mcp
16+ app.kubernetes.io/name : jira-mcp
17+ type : ClusterIP
You can’t perform that action at this time.
0 commit comments