Skip to main content
Glama

search_stories

Read-only

Search all Hacker News history by topic, company, phrase, or date range to retrieve older discussions and recent mentions that current feeds cannot show.

Instructions

Full-text search across all of Hacker News history.

Use this for anything the feeds cannot answer: a topic, a company, a phrase, or anything older than the current front page. The feed tools only see what is on HN right now; this sees everything ever posted.

sort="relevance" is right for topic questions. sort="date" is right for "what is the latest on X", since the best match may be years old.

days_back filters by age, so days_back=30 with sort="date" answers "what has HN said about X recently".

Input Schema

NameRequiredDescriptionDefault
pageNoZero-based page of results.
sortNorelevance ranks by match quality; date is newest first.relevance
limitNoHits to return.
queryYes
days_backNoOnly items from the last N days. Omit to search all history.

Output Schema

NameRequiredDescriptionDefault
resultsYes
returnedYesHits in this response.
total_hitsYesTotal matches, which may exceed `returned`.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.5/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already cover safety (readOnlyHint) and reach (openWorldHint). The description adds genuinely useful behavioral context on top: results span all history, ranked results may be years stale, and days_back constrains age rather than relevance. It stops short of pagination or result-shape behavior, but the output schema covers returns.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core capability, then guidance, then parameter advice in short lines. There is mild redundancy between 'across all of Hacker News history' and 'this sees everything ever posted', but every block still carries actionable content.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With annotations and an output schema present, the description's remaining obligation is selection guidance and mode choice, both of which it satisfies. Only pagination behavior is unaddressed, a minor gap for a 5-parameter read tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 80%, so the baseline is 3, and the description exceeds it by explaining when each sort enum value is the right choice rather than just what it does. It also explains the days_back semantics in combination with sort="date", which the schema does not. Page and limit are left to the schema, which is acceptable.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource (full-text search over stories) plus explicit scope: all of HN history, versus only the current front page. It draws the boundary against the feed siblings (list_stories) without needing the schema opened.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives both directions: use this when the feeds cannot answer, and the feed tools only see current HN. It further routes between the tool's own modes, saying relevance suits topic questions and date suits 'latest on X', including why (best match may be years old). No inference left to the agent.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.