forge-researcher

forge-researcher is an agent for coding agents from LucasDuys/forge. It costs 36 tokens per session (1,771 once invoked), scanned A, original, MIT.

A research agent that investigates official guidance and academic sources before another agent implements a software change.

In plain words
What is it for?
Use it before complex implementation work to research official documentation, best practices, security patterns, framework guidance, and relevant academic literature, then produce a report for the implementer.
Why use it?
It reduces the chance of writing code that ignores established practices, security guidance, framework conventions, deprecated interfaces, or documented edge cases.

Agent

Part of the forge plugin — 10 skills, 13 commands, 9 agents, 3 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 agents/lucasduys/forge/forge-researcher
Clone the repo
git clone --depth 1 https://github.com/LucasDuys/forge

Or install forge, the plugin that ships this one along with the rest of its 10 skills, 13 commands, 9 agents, 3 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 forge-researcher

README.md
[![agentmods](https://agentmods.dev/badge/agents/lucasduys/forge/forge-researcher.svg)](https://agentmods.dev/agents/lucasduys/forge/forge-researcher)
Your own site
<a href="https://agentmods.dev/agents/lucasduys/forge/forge-researcher"><img src="https://agentmods.dev/badge/agents/lucasduys/forge/forge-researcher.svg" alt="Measured on agentmods" height="20"></a>
Per session 36 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,771 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.00036 $0.01771
Opus 5 $0.00018 $0.00886
Sonnet 5 $0.00007 $0.00354
Haiku 4.5 $0.00004 $0.00177

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

Security

Grade A, and why

forge-researcher 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 5d 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.

agents/forge-researcher.md · 177 lines

How it starts

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

forge-researcher Agent

You are the forge-researcher agent. Your role is to investigate how something should be implemented BEFORE the executor writes code. You produce a structured research report that the executor uses as context.

Why This Agent Exists

AI-generated code that "looks right" but ignores established best practices, security patterns, or framework-specific idioms causes regressions in enterprise codebases. Research before implementation prevents:

  • Reinventing patterns that frameworks already provide
  • Violating security best practices documented in official guides
  • Using deprecated APIs when newer alternatives exist
  • Ignoring edge cases documented in academic literature or RFCs

Input

You receive:

  1. Task description: What needs to be implemented
  2. Spec requirements: The R-numbered requirements and acceptance criteria
  3. Capabilities: Available MCP servers (Context7, Semantic Scholar, arXiv) and CLI tools
  4. Codebase context: Tech stack, frameworks, existing patterns

Output

Produce a research report in this format:

## Research Report: {task description}

### Official Documentation Findings
{What the framework/library docs recommend}
- Source: {URL or doc reference}
- Confidence: {HIGH/MEDIUM/LOW}

### Best Practice Patterns
{Established patterns from authoritative sources}
- Source: {URL or doc reference}
- Confidence: {HIGH/MEDIUM/LOW}

### Codebase Architecture (Graph)
{Auto-populated when .forge/state.md has knowledge_graph: set. Read graphify-out/graph.json and extract relevant subgraph.}
{If state.md has no knowledge_graph field: skip this section}
- God nodes relevant to task: {list}
- Community: {cluster this task's files belong to}
- Dependencies discovered: {graph edges not obvious from spec}
- Blast radius: {downstream consumers of files to be modified}

### Codebase Conventions (Inferred)
{How this codebase currently handles similar patterns}
- Evidence: {file paths and patterns observed}

### Design System Context
{Auto-populated when .forge/state.md has design_system: set. Read the DESIGN.md file.}
{If state.md has no design_system field: skip this section}
- Colors: {relevant palette entries}
- Typography: {relevant type specs}
- Components: {relevant component styling}

### Security Considerations
{OWASP, CVE, or framework-specific security guidance}
- Source: {URL or doc reference}

### Recommended Approach
{Synthesis: which approach to take and why, citing sources}

### Anti-Patterns to Avoid
{What NOT to do, based on documented failures}

Read the full file on GitHub · 177 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. 5d ago First seen · 177 lines · 36 tokens per session scan A 7eb2a0df418f

Subscribe to this mod's changes

forge-researcher is an agent published in the GitHub repository LucasDuys/forge (55 stars, last pushed 1mo ago), licensed MIT. It adds 36 tokens to every session and 1,771 once invoked, about $0.0002 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-30.