1broseidon/ketch

Fast, stateless CLI for web search and scrape. Built for AI agents.

What it solves

Ketch simplifies the process of gathering external data for both humans and AI agents by consolidating multiple search, code, and documentation providers into a single, stateless CLI tool. Instead of managing multiple SDKs, authentication methods, and varying response formats for different research tools, users can use one binary to perform web searches, grep open-source code, access library documentation, and scrape web pages into clean markdown.

How it works

Ketch acts as a unified interface that routes requests to various configured backends. It provides several primary surfaces:

  • Web Search: Integrates with providers like Brave, DuckDuckGo, SearXNG, Exa, Firecrawl, and Keenable. It supports "rank-fused" federated searches across multiple backends using Reciprocal Rank Fusion.
  • Code Search: Searches public OSS source code via Grep, Sourcegraph, or GitHub Code Search.
  • Documentation: Provides version-aware library documentation via Context7.
  • Scraping/Crawling: Converts HTML and text-based PDFs into clean markdown. It includes an automatic fallback to a headless Chrome browser for JavaScript-rendered pages (SPAs) and supports custom cookies for authenticated content.

The tool is stateless and produces structured JSON output, making it easy for AI agents to integrate via shell commands or as an MCP (Model Context Protocol) server.

Who it’s for

  • AI Agent Developers: Who need a predictable, single-binary tool for research tasks without writing provider-specific glue code.
  • Power Users/Developers: Who want a fast terminal-based alternative to browser tabs or complex curl | pandoc pipelines for extracting web content.

Highlights

  • Unified Interface: One tool for web search, code search, docs, and scraping.
  • Agent-Optimized: Provides structured JSON output, documented exit codes for control flow, and a discovery command (ketch config) for capabilities.
  • Smart Extraction: Automatic JS-rendering fallback for SPAs and a built-in pure-Go PDF parser.
  • MCP Support: Can be run as an MCP server to provide research surfaces as tools for AI agents.
  • Flexible Configuration: Supports CLI flags, environment variables, and a config file with support for multi-key rotation to manage rate limits.