[PR #3721] feat: Add websearch tool with Perplexity AI integration #10739

Closed
opened 2026-02-16 18:15:29 -05:00 by yindo · 0 comments
Owner

Original Pull Request: https://github.com/anomalyco/opencode/pull/3721

State: closed
Merged: No


Summary

  • Adds websearch tool powered by Perplexity AI for real-time web search
  • Uses llama-3.1-sonar-small-128k-online model for precise, concise answers
  • Requires PERPLEXITY_API_KEY in ~/.local/share/opencode/auth.json
  • Follows OpenCode coding standards (Bun APIs, no try/catch, optional chaining)

Changes

  • packages/opencode/src/tool/websearch.ts: New tool implementation using Bun.file() API
  • packages/opencode/src/tool/websearch.txt: Tool documentation

Testing

Tool has been manually tested with custom Perplexity API key.

**Original Pull Request:** https://github.com/anomalyco/opencode/pull/3721 **State:** closed **Merged:** No --- ## Summary - Adds websearch tool powered by Perplexity AI for real-time web search - Uses llama-3.1-sonar-small-128k-online model for precise, concise answers - Requires PERPLEXITY_API_KEY in ~/.local/share/opencode/auth.json - Follows OpenCode coding standards (Bun APIs, no try/catch, optional chaining) ## Changes - `packages/opencode/src/tool/websearch.ts`: New tool implementation using Bun.file() API - `packages/opencode/src/tool/websearch.txt`: Tool documentation ## Testing Tool has been manually tested with custom Perplexity API key.
yindo added the pull-request label 2026-02-16 18:15:29 -05:00
yindo closed this issue 2026-02-16 18:15:29 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#10739