Metaphor API connects your LLM to the internet.

What is the Metaphor API?
The Metaphor API is a one stop shop to connect your LLM to the internet. Using our /search
endpoint, an LLM can query using natural language and return a list of relevant results. The Metaphor search model is especially well-suited for LLMs because its fully neural architecture allows you to query completely in natural language, across our highly curated index. And if a query doesn't benefit from neural search, we also support keyword search.
Once there is a list of results, an LLM can decide which results are relevant and obtain cleaned HTML content. That content can then be fetched using the /contents
endpoint, and your LLM could, for instance, summarize the results for the user. To see this exact flow in action, follow the Recent News Summarizer Example.
Getting Access
Getting a Metaphor API Key
Metaphor is free to use up to 1000 requests per month, for individual developers. Get an API key here.
GPT-assisted implementation
There's no need to learn how to use our API by yourself - you can simply ask ChatGPT. Below are ChatGPT conversation links where if you click "Continue this conversation", you can ask about how to implement anything.
For Python SDK assistance, go here.
For Typescript SDK assistance, go here.
For any other language, go here.
A simple example
from metaphor_python import Metaphor
metaphor = Metaphor("METAPHOR_API_KEY")
results = metaphor.search('hottest AI agent startups', use_autoprompt=True)