Pure Search 🔍
A lightweight, robust search skill that requires NO API keys. It uses DuckDuckGo for link retrieval and trafilatura for clean, high-quality markdown extraction.
How It Works
- 1. Queries DuckDuckGo for top N links (bypassing commercial API restrictions).
- Uses
trafilatura to extract only the main content of the web pages, stripping out all navigation bars, footers, sidebars, and ads. - Returns JSON output with search results, containing the title, URL, and the clean markdown body.
Setup
First, make sure the dependencies are installed:
CODEBLOCK0
Quick Start
CODEBLOCK1
Output Format
The output is always in a structured JSON format, making it extremely easy for agents to digest:
CODEBLOCK2
Why Pure Search?
- - Zero configuration: Start using without registering tokens.
- Extreme simplicity: Only one Python script, following the KISS principle.
- Token friendly: Only sends clean Markdown to the LLM agent, avoiding HTML tags and saving context window limits.
Pure Search 🔍
一个轻量级、稳健的搜索技能,无需任何API密钥。它使用DuckDuckGo进行链接检索,并利用trafilatura提取干净、高质量的Markdown内容。
工作原理
- 1. 向DuckDuckGo查询前N个链接(绕过商业API限制)。
- 使用trafilatura仅提取网页的主要内容,去除所有导航栏、页脚、侧边栏和广告。
- 返回包含搜索结果的JSON输出,包括标题、URL和干净的Markdown正文。
设置
首先,确保已安装依赖项:
bash
pip install duckduckgo-search trafilatura
快速开始
bash
基础搜索(默认获取前3条结果)
./scripts/search.py Rust vs Go in 2026
高级搜索,获取更多结果
./scripts/search.py Latest AI trends --max-results 5
输出格式
输出始终采用结构化的JSON格式,使智能体能够轻松解析:
json
{
query: Rust vs Go in 2026,
results: [
{
title: 详细对比...,
url: https://example.com/article,
markdown_content: ## 性能\n...(纯文本)
}
],
errors: []
}
为什么选择Pure Search?
- - 零配置:无需注册令牌即可开始使用。
- 极致简洁:仅一个Python脚本,遵循KISS原则。
- 节省令牌:仅向LLM智能体发送干净的Markdown,避免HTML标签,节省上下文窗口限制。