u/Short_One_9704

Pi refuses to allow / make available my tool to the model

EDIT: Resolved - I have created a skill with a bash script combination and the works perfectly. Just at SKILL.md file + exa_search.sh script. Thank you all for your help!

Hey everyone, this is a cry for help and second post about my extension tool not being able to be used by a model. In short, I have made a very simple extension for web search using the exa.ai search. Nothing fancy, in the extension I register a tool called `exa_web_search` and a slash cmd /exa_web_search. The command works fine, no problem there. But what I always wanted is for the model to automatically lookup things online if it is asked for current info, given URL, API docs or anything that needs up to date info. But for the love of .... I cannot get it to work (kick the model to use it automatically or even when specifically asked to use this exa_web_search tool). The model always says this:
I do not have access to a tool named exa_web_search. My available tools are:
- read
- bash
- edit
- write
- grep
- find
- ls
I cannot perform web searches.

or:

I do not have access to the exa_web_search tool, nor do I have any other tools that allow me to perform web searches or access live news. As previously stated, my capabilities are restricted to local

file system operations using the tools listed in my system prompt (read, bash, edit, write, grep, find, and ls). Therefore, I cannot fulfill this request.

But when I print the system prompt it says this:

System prompt:

You are an expert coding assistant operating inside pi, a coding agent harness. You help users by reading files, executing commands, editing code, and writing new files.

Available tools:

- read: Read file contents

- bash: Execute bash commands (ls, grep, find, etc.)

- edit: Make precise file edits with exact text replacement, including multiple disjoint edits in one call

- write: Create or overwrite files

- exa_web_search: Use exa_web_search to search the web for current information, URLs, documentation, articles, or external content.

In addition to the tools above, you may have access to other custom tools depending on the project.

Guidelines:

- Use bash for file operations like ls, rg, find

- Use read to examine files instead of cat or sed.

- Use edit for precise changes (edits[].oldText must match exactly)

- When changing multiple separate locations in one file, use one edit call with multiple entries in edits[] instead of multiple edit calls

- Each edits[].oldText is matched against the original file, not after earlier edits are applied. Do not emit overlapping or nested edits. Merge nearby changes into one edit.

- Keep edits[].oldText as small as possible while still being unique in the file. Do not pad with large unchanged regions.

- Use write only for new files or complete rewrites.

- Web search: Use exa_web_search whenever the user asks for current information from the internet.

- Web search: Use exa_web_search when the user provides a URL and asks to inspect or summarize it.

- Web search: Use exa_web_search for documentation lookup, APIs, tutorials, or research tasks.

- Web search: Prefer exa_web_search over hallucinating unknown or current information.

- Web search: Always use exa_web_search for queries regarding external links or specific web-based data.
... rest of the prompt

I have asked pi to create me the extension, the code is:

https://preview.redd.it/7e3u3uue0d1h1.png?width=2048&format=png&auto=webp&s=a0bf533260a5a956505f68dca3dd5cb2d06892bb

The extension loads, the slash cmd works (actually fetches 5 results), the tool is in the system prompt, but the model just refuses to use it, it says it is limited to only the built-in tools. I have tried multiple models, same result. I do not have any other extensions. This is a fresh pi install. I run pi without any special flags in a docker sandbox.
I am starting to feel desperate for help... I really want my little pi to work 😢
What am I doing wrong? Thank you ANYone of ANY kind of help 🙏

reddit.com
u/Short_One_9704 — 6 days ago

Custom extensions

Hi, I have a problem I cannot solve. I’m trying to add a web fetch extension to my pi. I have tried:
- asking pi to create one that uses chromium, it created the extension in .pi/agent/extensions, it loads ok, I can see it in the extensions list when pi starts, but when I ask the model to use web fetch to fetch a url, it says it does not have a web fetch and goes for curl,
- so another way I tried the pi-web-fetch from pi.dev/packages, installed via pi install npm:pi-web-fetch, same results, loaded ok, can see it on startup in the extensions list, but the model jist goes for curl.

I have tried debugging and the model says the extensions are correct, registeres themselves as tools according to the docs, but when I ask the model if it can see and use web fetch tool, it says it has no such tool and lists only the basic tools.

What am I doing wrong? The model does not even use the pi-web-fetch extension, which is a published and tested extension that should work 🤷‍♂️
Thank you for any help, I have tried like for 10 hours without any success.

reddit.com
u/Short_One_9704 — 12 days ago