Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -43,11 +43,15 @@ def call_mcp_server(message, tool_type="knowledge_base"):
|
|
43 |
logger.error(f"MCP call failed: {str(e)}")
|
44 |
return f"Error: {str(e)}"
|
45 |
|
46 |
-
# Initialize CodeAgent with
|
47 |
agent = CodeAgent(
|
48 |
tools=[], # No tools defined here as they're in MCP
|
49 |
model="microsoft/DialoGPT-medium",
|
50 |
-
system_prompt="""
|
|
|
|
|
|
|
|
|
51 |
1. Troubleshooting technical issues (wifi, hardware, software)
|
52 |
2. Finding information through web search
|
53 |
3. Formatting instructions into clear steps
|
|
|
43 |
logger.error(f"MCP call failed: {str(e)}")
|
44 |
return f"Error: {str(e)}"
|
45 |
|
46 |
+
# Initialize CodeAgent with proper system prompt including required tag
|
47 |
agent = CodeAgent(
|
48 |
tools=[], # No tools defined here as they're in MCP
|
49 |
model="microsoft/DialoGPT-medium",
|
50 |
+
system_prompt="""{{authorized_imports}}
|
51 |
+
- requests for API calls
|
52 |
+
- standard Python libraries
|
53 |
+
|
54 |
+
You are an advanced Technical Support Assistant with these capabilities:
|
55 |
1. Troubleshooting technical issues (wifi, hardware, software)
|
56 |
2. Finding information through web search
|
57 |
3. Formatting instructions into clear steps
|