Both Ollama web tools, web_search and web_fetch, were already implemented and wired in the initial PR — they are registered in TOOL_DEFINITIONS, routed in executeTool, filtered by the webEnabled preference, and hitting POST /api/web_search and POST /api/web_fetch.
What was actually missing was coverage. agent.test.ts exercised the loop end to end but only ever with get_datetime, so neither web tool had a single direct test.
Changes
src/__tests__/tools.test.ts (new) pins the contract for both tools:
web_search — endpoint, bearer token, request body, max_results clamped into 1..10, empty result sets, result rendering
web_fetch — endpoint, request body, page content, title fallback, truncation
failure paths for both, including a rejected API key
the webEnabled filter: local tools survive, web tools are removed
src/lib/tools.ts — a trimmed search snippet is now marked [truncated] instead of silently dropping the tail, matching what web_fetch already did. Silent caps read as complete output when they are not.
assets/extension-icon.png — white tile, black bubble, three dots punched out.
Verification
tsc --noEmit clean, eslint . clean, vici build succeeds
96 tests passing across 8 files (was 77 across 7)
Endpoint paths checked against the live Ollama API:
Route
Unauthenticated response
Meaning
POST /api/chat
401
route exists, key required
POST /api/web_search
401
route exists, key required
POST /api/web_fetch
401
route exists, key required
POST /api/tags
405
route exists, GET only
Not verified
No authenticated call was made — there is no OLLAMA_API_KEY in the environment. The request and response shapes follow Ollama's documentation and are covered against mocks, but they have not been exercised against a real key.
## Context
Both Ollama web tools, `web_search` and `web_fetch`, were already implemented and wired in the initial PR — they are registered in `TOOL_DEFINITIONS`, routed in `executeTool`, filtered by the `webEnabled` preference, and hitting `POST /api/web_search` and `POST /api/web_fetch`.
What was actually missing was **coverage**. `agent.test.ts` exercised the loop end to end but only ever with `get_datetime`, so neither web tool had a single direct test.
## Changes
- **`src/__tests__/tools.test.ts`** (new) pins the contract for both tools:
- `web_search` — endpoint, bearer token, request body, `max_results` clamped into 1..10, empty result sets, result rendering
- `web_fetch` — endpoint, request body, page content, title fallback, truncation
- failure paths for both, including a rejected API key
- the `webEnabled` filter: local tools survive, web tools are removed
- **`src/lib/tools.ts`** — a trimmed search snippet is now marked `[truncated]` instead of silently dropping the tail, matching what `web_fetch` already did. Silent caps read as complete output when they are not.
- **`assets/extension-icon.png`** — white tile, black bubble, three dots punched out.
## Verification
- `tsc --noEmit` clean, `eslint .` clean, `vici build` succeeds
- **96 tests passing** across 8 files (was 77 across 7)
- Endpoint paths checked against the live Ollama API:
| Route | Unauthenticated response | Meaning |
| --- | --- | --- |
| `POST /api/chat` | 401 | route exists, key required |
| `POST /api/web_search` | 401 | route exists, key required |
| `POST /api/web_fetch` | 401 | route exists, key required |
| `POST /api/tags` | 405 | route exists, GET only |
## Not verified
No authenticated call was made — there is no `OLLAMA_API_KEY` in the environment. The request and response shapes follow Ollama's documentation and are covered against mocks, but they have not been exercised against a real key.
Both web tools were already implemented and wired, but the suite only
exercised get_datetime, so neither had any direct coverage. Adds
tools.test.ts pinning the contract for both:
- web_search: request shape (endpoint, bearer token, body), max_results
clamped into 1..10, empty result sets, and how results render
- web_fetch: request shape, page content, title fallback, truncation
- failure paths for both, including a rejected API key
- the webEnabled filter, so the local tools survive and the web tools go
Also marks a trimmed search snippet with "[truncated]" rather than
silently dropping the tail, which is what web_fetch already did.
Also replaces the extension icon with a white tile and a black bubble.
Endpoint paths were checked against the live Ollama API: /api/chat,
/api/web_search and /api/web_fetch all return 401 unauthenticated (so
the route exists and demands a key), and /api/tags returns 405 to a
POST, which also confirms the path. No authenticated call was made.
Test count: 77 -> 96.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Context
Both Ollama web tools,
web_searchandweb_fetch, were already implemented and wired in the initial PR — they are registered inTOOL_DEFINITIONS, routed inexecuteTool, filtered by thewebEnabledpreference, and hittingPOST /api/web_searchandPOST /api/web_fetch.What was actually missing was coverage.
agent.test.tsexercised the loop end to end but only ever withget_datetime, so neither web tool had a single direct test.Changes
src/__tests__/tools.test.ts(new) pins the contract for both tools:web_search— endpoint, bearer token, request body,max_resultsclamped into 1..10, empty result sets, result renderingweb_fetch— endpoint, request body, page content, title fallback, truncationwebEnabledfilter: local tools survive, web tools are removedsrc/lib/tools.ts— a trimmed search snippet is now marked[truncated]instead of silently dropping the tail, matching whatweb_fetchalready did. Silent caps read as complete output when they are not.assets/extension-icon.png— white tile, black bubble, three dots punched out.Verification
tsc --noEmitclean,eslint .clean,vici buildsucceedsPOST /api/chatPOST /api/web_searchPOST /api/web_fetchPOST /api/tagsNot verified
No authenticated call was made — there is no
OLLAMA_API_KEYin the environment. The request and response shapes follow Ollama's documentation and are covered against mocks, but they have not been exercised against a real key.