[PR #14246] [MERGED] anthropic: enable websearch #14587

Closed
opened 2026-04-13 00:58:39 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ollama/ollama/pull/14246
Author: @ParthSareen
Created: 2/14/2026
Status: Merged
Merged: 2/14/2026
Merged by: @ParthSareen

Base: mainHead: parth-anthropic-websearch


📝 Commits (10+)

  • 500d782 anthropic: add web search tool support
  • 491f1b3 anthropic: clean up types and rename web search API
  • 3399c74 middleware: rewrite web search as intercepting response writer
  • 631a210 middleware: add web search integration and unit tests
  • b0a73d8 anthropic: restore godoc comments removed out of scope
  • b66748f anthropic: gate web search on cloud policy and signed auth
  • 592b46a middleware: rework anthropic web_search loop handling
  • 534e2ed anthropic: trim web_search fields and align auth header
  • d00203a anthropic: harden web_search loop and tool collision handling
  • 3d01e1e anthropic: add trace logging for conversion and web_search loop

📊 Changes

6 files changed (+4276 additions, -31 deletions)

View changed files

📝 anthropic/anthropic.go (+323 -14)
📝 anthropic/anthropic_test.go (+390 -0)
anthropic/trace.go (+352 -0)
📝 middleware/anthropic.go (+817 -17)
📝 middleware/anthropic_test.go (+2372 -0)
middleware/test_home_test.go (+22 -0)

📄 Description

enable websearch for anthropic APIs


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/ollama/ollama/pull/14246 **Author:** [@ParthSareen](https://github.com/ParthSareen) **Created:** 2/14/2026 **Status:** ✅ Merged **Merged:** 2/14/2026 **Merged by:** [@ParthSareen](https://github.com/ParthSareen) **Base:** `main` ← **Head:** `parth-anthropic-websearch` --- ### 📝 Commits (10+) - [`500d782`](https://github.com/ollama/ollama/commit/500d7824ff60586d7d1d9099f6d609de319cb9c8) anthropic: add web search tool support - [`491f1b3`](https://github.com/ollama/ollama/commit/491f1b36f9861de1a68646e92d0aa8c4b25f3f23) anthropic: clean up types and rename web search API - [`3399c74`](https://github.com/ollama/ollama/commit/3399c744bb5411bc5b74bfb12bc8fd15061ca53c) middleware: rewrite web search as intercepting response writer - [`631a210`](https://github.com/ollama/ollama/commit/631a210ce9ac7fdefcf594e4592a4622121d9f88) middleware: add web search integration and unit tests - [`b0a73d8`](https://github.com/ollama/ollama/commit/b0a73d8a2f8232d3c36d87282c6bfccaad8f5343) anthropic: restore godoc comments removed out of scope - [`b66748f`](https://github.com/ollama/ollama/commit/b66748f73dd78611e135a48d43360163c007cb02) anthropic: gate web search on cloud policy and signed auth - [`592b46a`](https://github.com/ollama/ollama/commit/592b46aaa5aa523315f3fece7a24da98abd57091) middleware: rework anthropic web_search loop handling - [`534e2ed`](https://github.com/ollama/ollama/commit/534e2edc0ed346f979010faaedffc6a16e5a2dc5) anthropic: trim web_search fields and align auth header - [`d00203a`](https://github.com/ollama/ollama/commit/d00203a4e3a72a931b97553e868d352251c9a4c2) anthropic: harden web_search loop and tool collision handling - [`3d01e1e`](https://github.com/ollama/ollama/commit/3d01e1e8e9b46ac42136caeff458a99938bdd22f) anthropic: add trace logging for conversion and web_search loop ### 📊 Changes **6 files changed** (+4276 additions, -31 deletions) <details> <summary>View changed files</summary> 📝 `anthropic/anthropic.go` (+323 -14) 📝 `anthropic/anthropic_test.go` (+390 -0) ➕ `anthropic/trace.go` (+352 -0) 📝 `middleware/anthropic.go` (+817 -17) 📝 `middleware/anthropic_test.go` (+2372 -0) ➕ `middleware/test_home_test.go` (+22 -0) </details> ### 📄 Description enable websearch for anthropic APIs --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-13 00:58:39 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/ollama#14587