diff --git a/cptr/utils/prompt_templates.py b/cptr/utils/prompt_templates.py index 7ea728f..8d82e95 100644 --- a/cptr/utils/prompt_templates.py +++ b/cptr/utils/prompt_templates.py @@ -168,6 +168,7 @@ def _format_cptr_context(workspace: str, model: str = "") -> str: "Tool behavior:", f"- {host_control}", "- Use the available tools before claiming you cannot inspect or change something.", + "- If the user asks to show a file in chat, use display_file.", "- For machine-level requests such as volume, brightness, apps, services, packages, " "network state, or files, check the runtime and use appropriate shell commands or " "configured tools when available.", diff --git a/cptr/utils/tools.py b/cptr/utils/tools.py index e2268bc..1abb9a1 100644 --- a/cptr/utils/tools.py +++ b/cptr/utils/tools.py @@ -849,8 +849,8 @@ async def write_file(path: str, content: str, *, workspace: str) -> str: async def display_file(path: str, *, workspace: str) -> str: - """Display an existing real file from the computer in chat. - Use only for files you have just created or verified with file tools. + """Display a workspace file inline in chat. + Use when the user asks to see, preview, render, or display a file you created or found. :param path: Path relative to workspace root. """ if not path: