search-engine

search-engine is a skill for Claude Code, Codex from Pierry/harness-kit. It costs 54 tokens per session (1,985 once invoked), scanned A, original, MIT.

A system-design guide for building a web-scale search engine: software that discovers, processes, indexes, and retrieves documents from a large collection such as the public web.

In plain words
What is it for?
Use it for web search, web crawlers, site or document search at scale, and large retrieval systems. For a small internal document search, it helps identify when a managed search service may be enough.
Why use it?
It helps break a search system into decisions about what to discover, fetch, store, index, rank, and serve while accounting for scale and freshness.

Skill for Claude CodeCodex

Part of the harness-kit plugin — 14 skills, 17 commands, 4 agents, 4 hooks shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/pierry/harness-kit/search-engine
Any agent
npx skills add Pierry/harness-kit --skill search-engine
Clone the repo
git clone --depth 1 https://github.com/Pierry/harness-kit

Made for: Claude Code, Codex.

Or install harness-kit, the plugin that ships this one along with the rest of its 14 skills, 17 commands, 4 agents, 4 hooks.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for search-engine

README.md
[![agentmods](https://agentmods.dev/badge/skills/pierry/harness-kit/search-engine.svg)](https://agentmods.dev/skills/pierry/harness-kit/search-engine)
Your own site
<a href="https://agentmods.dev/skills/pierry/harness-kit/search-engine"><img src="https://agentmods.dev/badge/skills/pierry/harness-kit/search-engine.svg" alt="Measured on agentmods" height="20"></a>
Per session 54 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,985 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00054 $0.01985
Opus 5 $0.00027 $0.00992
Sonnet 5 $0.00011 $0.00397
Haiku 4.5 $0.00005 $0.00198

Measured 3d ago against content hash ad0a2325be14, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

search-engine scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/agents/system-architect/skills/search-engine/SKILL.md · 167 lines

How it starts

The opening of the file, as written. The whole thing — 167 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Design a search engine. Topic playbook. The agent loads this canned reference architecture and adapts it to the user's actual scale and constraints, then emits the SDD via the generic template.

Use when the problem is: web search, site/doc search at scale, a crawler, or a large retrieval system. For internal doc search at small scale, say so and simplify (often a managed engine is the whole answer).

Ask once if missing: corpus scope (internal docs vs open web), target QPS, freshness SLO, build vs buy appetite.

Read:

  • guides/design-method.md
  • guides/writing-style.md
  • guides/templates/system-design.md
  • guides/pipeline.md

Generate the SDD using the template, filled with the reference below, adapted to user scale.

Save to .claude/runtime/outputs/architect/design/{feature_id}.md. Sensors: sensors/design-structure.md, sensors/design-rigor.md. Evals: evals/design-quality.md.


Reference architecture (adapt, do not copy blindly)

One line: a search engine is a distributed factory that turns URLs into rankable documents. It is a chain of decisions: what to discover, fetch, store, index, retrieve, promote. Each stage kills bad cost and keeps useful signal.

Four subsystems + two support planes

  • Crawler: discover and fetch pages.
  • Processing pipeline: parse, clean, extract, enrich.
  • Indexing pipeline: build the indexes.
  • Query serving: analyze query, retrieve candidates, rank, assemble result.
  • Support: metadata/policy (robots.txt, politeness, canonical, scheduling, dedup) and observability/control (metrics, debugging, reprocess, backfill, allow/blocklists).

Crawler (the heart)

  • URL frontier is not one queue. Split into: URL-seen store (Bloom filter + persistent), crawl-state store (status, hash, next-recrawl), scheduler priority queues.
  • Multi-queue per host: one pending queue per host + a next_eligible_timestamp; a global heap orders hosts by lowest eligible time and highest priority. Gives fairness + politeness together. A single global queue creates hot domains and looks like a DDoS.
  • URL canonicalization before enqueue (lowercase host, drop fragments, default ports, clean tracking params, resolve relative, drop session ids). Skipping this explodes duplicates.
  • robots.txt cached per host with TTL; respect allow/disallow and crawl-delay. Timeouts, redirect limits, max download size.
  • Politeness is not a fixed sleep. Next request after max(min_delay, k * observed_latency, robots_delay); max concurrency per host; exponential backoff on errors.
  • Fetcher stateless: async I/O, connection pool, gzip/brotli, conditional GET (ETag / If-Modified-Since) for cheap recrawl, content-type sniffing, body checksum.
  • Crawler traps: infinite calendars, e-commerce facets, param explosions, pagination loops. Guardrails: crawl budget per host, fan-out limit per page, param regex blocklists, template-repeat score, depth limit. Without these, 80% of cost goes to the worst 5% of the web.

Read the full file on GitHub · 167 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 167 lines · 54 tokens per session scan A ad0a2325be14

Subscribe to this mod's changes

search-engine is a skill published in the GitHub repository Pierry/harness-kit (3 stars, last pushed 1mo ago), licensed MIT. It adds 54 tokens to every session and 1,985 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

api-test-suite-builder

Scans API route definitions across frameworks (Next.js App Router, Express, FastAPI, Django REST) and auto-generates comprehensive test suites covering auth, input validation, error codes, pagination, file uploads, and rate limiting. Outputs ready-to-run test files for Vitest+Supertest (Node) or Pytest+httpx (Python).

seaworld008/Commonly-used-high-value-skills · 75 tokens

arena

Specialist orchestrating codex exec / Antigravity CLI through dual paradigms — COMPETE (multi-variant comparison, select best) and COLLABORATE (decompose tasks across engines, integrate). Supports Solo/Team/Quick execution modes.

seaworld008/Commonly-used-high-value-skills · 53 tokens

clay

AI 3D model generation agent. Generates text-to-3D and image-to-3D code (Python/JS/OpenSCAD) using Meshy, Tripo, Hunyuan3D, Rodin, Sloyd, and Stability APIs. Handles game pipeline integration, LOD, retopology, UV, and QC validation.

seaworld008/Commonly-used-high-value-skills · 73 tokens

comply

Regulatory compliance and audit agent. Maps business regulatory requirements (SOC2/PCI-DSS/HIPAA/ISO 27001), checks control implementations, designs audit trails, and implements Policy as Code. Use when compliance auditing is needed.

seaworld008/Commonly-used-high-value-skills · 51 tokens

agent-workflow-designer

Design production-grade multi-agent orchestration systems. Covers five core patterns (sequential pipeline, parallel fan-out/fan-in, hierarchical delegation, event-driven, consensus), platform-specific implementations, handoff protocols, state management, error recovery, context window budgeting, and cost optimization.

seaworld008/Commonly-used-high-value-skills · 61 tokens

app-store-optimization

App Store Optimization toolkit for researching keywords, optimizing metadata, and tracking mobile app performance on Apple App Store and Google Play Store.

seaworld008/Commonly-used-high-value-skills · 30 tokens