llm
llm copied to clipboard
Support for the web search feature of OpenAI models
I am wondering if there is any method to enable the builtin web search tool for OpenAI models.
For your information, here's the OpenAI interface:
import OpenAI from "openai";
const client = new OpenAI();
const response = await client.responses.create({
model: "gpt-5",
tools: [
{ type: "web_search" },
],
input: "What was a positive news story from today?",
});
console.log(response.output_text);