Avoid tools for direct answer prompts
This commit is contained in:
parent
1291281d7e
commit
282085c384
|
|
@ -18,6 +18,10 @@ Available tools:
|
|||
Args: {"task_description": "what to build or analyze", "language": "python", "context": "optional context"}
|
||||
|
||||
Return actions=[] when the user can be answered directly without tools.
|
||||
Return actions=[] for simple arithmetic, translation, explanation, formatting,
|
||||
summarization, brainstorming, general knowledge, or any request where the
|
||||
thinker can answer from the conversation alone. Do not run shell commands like
|
||||
`echo`, `python`, `bc`, or calculators for simple arithmetic.
|
||||
When tool_observations are already present, request only genuinely missing
|
||||
follow-up information. Return actions=[] when the observations are sufficient
|
||||
for the thinker to answer.
|
||||
|
|
|
|||
|
|
@ -14,3 +14,10 @@ def test_models_config_maps_roles_to_same_qwen_non_mtp_model():
|
|||
|
||||
assert roles["action"]["structured_output"] is True
|
||||
assert roles["thinker"]["max_output_tokens"] == 8192
|
||||
|
||||
|
||||
def test_action_prompt_forbids_tools_for_simple_arithmetic():
|
||||
prompt = Path("prompts/roles/action.md").read_text()
|
||||
|
||||
assert "Return actions=[] for simple arithmetic" in prompt
|
||||
assert "Do not run shell commands like" in prompt
|
||||
|
|
|
|||
Loading…
Reference in New Issue