Skip to main content
Docs
Web Search

Web Search

Enable real-time internet search to get current information in AI responses.

Web search integration allows AI models to access real-time information from the internet, providing up-to-date answers with source citations.

How It Works

When web search is enabled:

  1. AI analyzes if your question needs current information
  2. Searches the web for relevant sources
  3. Synthesizes information from multiple sources
  4. Provides a response with citations

In Studio Chat

  1. Click the settings icon in the chat interface
  2. Toggle Web Search on
  3. Ask questions that require current information

With Alvin Routing

When using Alvin with web search enabled:

  • Alvin automatically routes to web-search capable models
  • Perplexity Sonar is commonly used for search queries
  • Results include source citations

Use Cases

Web search is ideal for:

Use CaseExample
Current events"What happened in tech news today?"
Latest data"What's the current price of Bitcoin?"
Recent releases"What's new in React 19?"
Real-time info"What's the weather in San Francisco?"

Source Citations

Responses include clickable source citations:

Based on recent reports [1][2], the new framework offers...

Sources:
[1] https://example.com/article1
[2] https://example.com/article2

Supported Models

Web search is available with:

ModelSearch Quality
Perplexity SonarExcellent - native search
GPT-4o with searchGood - integrated search
Claude with searchGood - integrated search

Best Practices

When to Use

  • Questions about current events
  • Queries requiring recent data
  • Fact-checking and verification
  • Research and information gathering

When to Disable

  • Code generation tasks
  • Creative writing
  • Tasks using your provided context
  • Privacy-sensitive queries

Limitations

  • Search results depend on public web content
  • Some information may be behind paywalls
  • Real-time data may have slight delays
  • Not suitable for all query types

API Usage

Enable web search in API requests:

curl -X POST https://api.elyxir.ai/v1/chat/completions \
  -H "Authorization: Bearer elyxir_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "perplexity/sonar",
    "messages": [{"role": "user", "content": "What are the latest AI developments?"}]
  }'
Web Search | elyxir