<!-- generated by epythet -->

# For AI agents

`ir` ships artifacts for coding agents alongside its code. This page lists
them, says where each lives in the repository, and points at the
machine-readable copies of this documentation.

## Skills

Skills are folders holding a `SKILL.md` (the [Agent Skills](https://agentskills.io) format): a description that tells an agent when to use it and a body with the procedure. Install one into your agent with `gh skill` (any host: `--agent claude-code`, `copilot`, `cursor`, `codex`, `gemini`), or use the copy bundled in the wheel.

### `ir-search`

Find specific documents, packages, skills, or past work with the `ir` retrieval engine — and have the results reviewed for real relevance before they come back. Use whenever the user wants to search/look-up over their own corpora: “find the docs/report about X”, “use ir (or ir discover) to find …”, “which of my packages does Y”, “search my reports/notes/sessions for Z”, “what do I have written about …”, “is there a doc on …”. Covers the `ir` CLI (build/search/discover), the corpus map, the mode/scoring gotchas, and when to delegate to the `ir-discover-agent` subagent for a reviewed, reformulated search vs. running a quick inline lookup. `ir` is a deterministic retrieval substrate with no agent of its own; this skill + the subagent are the Claude-Code-native way to wrap it in agentic query→review→reformulate powers (the coded equivalent is `raglab`).

```bash
gh skill install i2mint/ir ir-search --agent claude-code
```

Source: [`ir/data/skills/ir-search`](https://github.com/i2mint/ir/tree/HEAD/ir/data/skills/ir-search) (bundled with the pip package).

### `ir-dev-workflow`

How to work ON the `ir` package (i2mint/ir): the module map, the hermetic test recipe, the CLI grammar golden, the lint and doc rules CI enforces, the ir-vs-raglab boundary every change must respect, and how a merge publishes. Use when contributing to, fixing, reviewing, or extending `ir` itself: “add a search option to ir”, “fix this ir test”, “where does fusion happen in ir”, “update the ir CLI”, “review this ir PR”, “does this belong in ir or raglab”. Not for USING ir to search corpora (that is the `ir-search` skill).

```bash
gh skill install i2mint/ir ir-dev-workflow --agent claude-code
```

Source: [`skills/ir-dev-workflow`](https://github.com/i2mint/ir/tree/HEAD/skills/ir-dev-workflow).

The bundled skills are also on disk after `pip install ir`, under the package’s `data/skills/` directory; link them into an agent without network access with `skill link-skills <that directory>`.

## Subagents

Subagents are Markdown files with a frontmatter (`name`, `description`, `tools`) and a system prompt as the body. Copy one into your project’s `.claude/agents/` (or your agent host’s equivalent) to delegate the task it describes.

### `ir-discover-agent`

A reviewing search agent over `ir` corpora (reports, packages, skills, sessions, or any registered corpus). Use it whenever the user wants to FIND specific documents, packages, skills, or past work with `ir` / `ir discover` AND wants the results actually checked for relevance before they come back — i.e. “find the docs about X”, “which of my packages does Y”, “search my reports/notes/sessions for Z”, “use ir discover to find …”. It formulates several queries, retrieves candidates, READS and JUDGES each against the real intent, reformulates when results fall short, and returns only the genuinely relevant few (or an honest “nothing sufficiently relevant”). This is a lightweight, Claude-Code-native stand-in for the coded `raglab` search agent: `ir` itself is a deterministic retrieval substrate with no agent of its own — this subagent supplies the query intelligence, the relevance review, and the reformulate loop.

Source: [`.claude/agents/ir-discover-agent.md`](https://github.com/i2mint/ir/tree/HEAD/.claude/agents/ir-discover-agent.md); tools: `Bash, Read, Grep, Glob`.

## Instruction files

Files agents read before working in this repository.

- [`.claude/CLAUDE.md`](https://github.com/i2mint/ir/tree/HEAD/.claude/CLAUDE.md): read by Claude Code

## Machine-readable documentation

This site publishes the same documentation in forms that fit an agent’s context window:

- [`llms.txt`](https://i2mint.github.io/ir/llms.txt): an index of every page with a one-line description ([llms.txt](https://llmstxt.org) format)
- [`ir.md`](https://i2mint.github.io/ir/ir.md): the whole documentation as one Markdown file
- `<page>.html.md`: a rendered Markdown twin of every page, advertised from each page’s `<head>` with `<link rel="alternate" type="text/markdown">`
- [`objects.inv`](https://i2mint.github.io/ir/objects.inv): the Sphinx inventory: a symbol-to-URL index (`sphobjinv convert plain objects.inv -`)
