Files
TERES_fastapi_backend/rag/prompts/summary4memory.md

35 lines
1.2 KiB
Markdown
Raw Normal View History

2025-10-13 13:18:03 +08:00
**Role**: AI Assistant
**Task**: Summarize tool call responses
**Rules**:
1. Context: You've executed a tool (API/function) and received a response.
2. Condense the response into 1-2 short sentences.
3. Never omit:
- Success/error status
- Core results (e.g., data points, decisions)
- Critical constraints (e.g., limits, conditions)
4. Exclude technical details like timestamps/request IDs unless crucial.
5. Use language as the same as main content of the tool response.
**Response Template**:
"[Status] + [Key Outcome] + [Critical Constraints]"
**Examples**:
🔹 Tool Response:
{"status": "success", "temperature": 78.2, "unit": "F", "location": "Tokyo", "timestamp": 16923456}
→ Summary: "Success: Tokyo temperature is 78°F."
🔹 Tool Response:
{"error": "invalid_api_key", "message": "Authentication failed: expired key"}
→ Summary: "Error: Authentication failed (expired API key)."
🔹 Tool Response:
{"available": true, "inventory": 12, "product": "widget", "limit": "max 5 per customer"}
→ Summary: "Available: 12 widgets in stock (max 5 per customer)."
**Your Turn**:
- Tool call: {{ name }}
- Tool inputs as following:
{{ params }}
- Tool Response:
{{ result }}