Advanced use
Set up web search
Give your agent the live web, for free, with a private search engine that runs on your own computer.
Without web search, your agent only knows what its model learned when it was trained, so it cannot tell you today's news, a current price or whether a shop is open. With web search switched on, your agent can look things up and tell you where the answer came from.
This guide will help you run your own free search engine, called SearXNG, on your computer and connect it to your agent. It works on Mac, Windows and Linux. You will need to use a terminal (the Terminal app on a Mac, PowerShell on Windows), but every command you need is on this page. If you would rather not run anything on your computer, skip to Using Brave instead.
What to expect:
- Your agent can only search while your computer is on, awake and connected to the internet.
- You will install three free tools: Docker, Node.js and cloudflared. You do not need an account for any of them.
1Install the tools
- Install Docker Desktop. If you already use OrbStack or Colima, those work too. On Linux you can use Docker Engine instead; we recommend starting it with
sudo systemctl enable --now dockerand adding yourself to thedockergroup, so salts-tools can use it without asking for your password. - Install Node.js, version 20 or later.
- Install cloudflared. On a Mac with Homebrew, run this in Terminal:
brew install cloudflaredOn Windows, run this in PowerShell:
winget install --id Cloudflare.cloudflaredOtherwise, download it from Cloudflare's downloads page.
2Download salts-tools
salts-tools is a small program that starts the search engine and connects it to your agent. In your terminal, run these three commands one at a time:
git clone https://github.com/AlwaysHungrie/salts-agent.git
cd salts-agent/salts-tools
npm link3Start salts-tools
First, open your agent in the browser and copy its agent ID. It is the part of the address after /a/:
https://salts-agent-app.vercel.app/a/<your-agent-id>Then run:
salts-tools startsalts-tools will ask you a few questions:
- Agent IDs: paste your agent ID. To give several agents web search from the same computer, paste all their IDs with a space between each one.
- salts-tools will then show you a token. Copy it, and leave your terminal open while you do the next step.
4Add the token to your agent
Open your agent, go to Capabilities, and find Web search. If you entered several agent IDs, do this for each of those agents, using the same token.
- Switch Web search on.
- Paste the token into SearXNG token and save.
- Leave Brave Search API key and SearXNG URL empty. salts-tools fills in the URL for you.
Go back to your terminal and press Enter. When salts-tools is done, you will see green ticks for the tunnel and web, followed by live for agent <your-agent-id>.
Finally, salts-tools asks whether it should start automatically when you log in. We recommend saying yes, otherwise your agent loses web search every time you restart your computer.
To add or remove agents later, run salts-tools setup and enter the full list of agent IDs again.
You are done
Ask your agent something that needs the web, for example "What is the weather in Mumbai today?". Your agent will search on its own whenever a question needs it, so you do not have to ask it to search.
If you also want your agent to open search results and read the full page, switch on Read a URL in Capabilities.
Everyday commands
| Command | What it does |
|---|---|
salts-tools | Opens a screen that shows whether search is running and connected to each agent. Use the arrow keys to move, s to start or stop, c to copy the token, and q to quit. |
salts-tools start | Starts the search engine. |
salts-tools stop | Stops the search engine. |
salts-tools restart | Restarts the search engine and reconnects it to your agent. |
salts-tools setup | Asks the setup questions again, for example to connect a different agent. |
salts-tools reset | Forgets the token and agent ID. Run salts-tools stop first. |
salts-tools autostart on | Starts salts-tools when you log in. Use off to turn this off. |
Command
salts-tools
What it does
Opens a screen that shows whether search is running and connected to each agent. Use the arrow keys to move, s to start or stop, c to copy the token, and q to quit.
Command
salts-tools start
What it does
Starts the search engine.
Command
salts-tools stop
What it does
Stops the search engine.
Command
salts-tools restart
What it does
Restarts the search engine and reconnects it to your agent.
Command
salts-tools setup
What it does
Asks the setup questions again, for example to connect a different agent.
Command
salts-tools reset
What it does
Forgets the token and agent ID. Run salts-tools stop first.
Command
salts-tools autostart on
What it does
Starts salts-tools when you log in. Use off to turn this off.
Using Brave instead
If you would rather not run anything on your computer, you can use Brave's search API instead. Brave has a free plan that is enough for one person. Create an account at brave.com/search/api, subscribe to the free plan, and paste your key into Brave Search API key under Web search in your agent's Capabilities. Brave asks for a card, and any searches beyond the free plan are billed by Brave.
Footnotes
- If your agent stops searching, check that your computer is awake and online, then run
salts-tools restart. - If salts-tools says your agent refused the token, paste the token into SearXNG token again, save, and choose retry.
- If your agent is not searching when it should, add this to Custom instructions in Settings: "Search the web for anything about current events, prices or dates." A stronger model also helps.