Home / Companies / Context.dev / Blog / Post Details
Content Deep Dive

How to Add Web Search to an AI Agent with Context.dev: Return Only the Relevant Passages

Blog post from Context.dev

Post Details
Company
Date Published
Author
Yahia Bakour
Word Count
1,770
Company Posts That Month
10
Language
English
Hacker News Points
-
Post removed?
No
Summary

Context.dev presents a web-search and content-extraction API designed for AI agents, combining ranked search results, relevance labels, page highlights, Markdown scraping, and multi-page answers under one API key. Its central feature, Highlights, extracts only query-relevant passages from pages or known URLs, including YouTube transcripts, helping agents avoid large volumes of navigation, ads, boilerplate, and other web noise that can consume context windows, raise costs, weaken reasoning, and increase prompt-injection exposure. The guide cites academic and company-reported benchmarks suggesting that retrieval-stage pruning can substantially reduce token use while preserving or improving task accuracy and grounding. Developers can use TypeScript, HTTP, or function-calling integrations to search up to 100 results, set character and cache-freshness limits, and request focused text in page order with headings and source information preserved. It also emphasizes resilient agent behavior through explicit per-result status codes for successful reads, timeouts, blocked sites, oversized content, and other failures, advising developers to retain URLs, titles, and descriptions even when content extraction is unavailable.

Trends Found in this Post
Trend Post Mentions Total Month Mentions Posts Companies MoM
AI Agents 5 2,096 365 132 -70%
LLM 3 982 244 100 -85%
MCP 1 3,402 292 104 -71%
Use This Data

Use this post, company, and trend context to find content marketing opportunities, perform competitive analysis, or address product feature gaps via the Plushcap MCP server or the Plushcap API.