---
title: Using Groundwork with your agent
summary: How to give a coding agent the right Groundwork page at the right moment, whether that is one page, a pointer file, a lifecycle slice or the machine-readable index.
section: start-here
order: 5
last_reviewed: 2026-11-21
---

# Using Groundwork with your agent

These docs are written so you can read them and your agent can use them at the same time. The goal is the same as in [Context engineering](/docs/ai-agents/context-engineering.md): put the right few pages in front of the agent when the task needs them, instead of loading everything.

## You'll be able to

- Pick the smallest thing to give an agent: a page, a slice or a pointer
- Set up a pointer file so an agent knows which page to fetch for which job
- Know what to do when your agent can't fetch web pages
- Ask an agent to apply a page's checklist to your work, and read its answer critically

## What is available

| What | Where | Use it for |
|---|---|---|
| One page as markdown | add `.md` to any page URL, for example `/docs/security/security-basics.md` | A single topic. Smallest and cheapest. |
| Copy for LLM | the button at the top of every page | Pasting a page into a chat when the agent can't fetch URLs |
| Index of every page | `/docs.json` | An agent choosing which page it needs. Has title, summary, phase, headings and last-reviewed date. |
| Slices | `/llms/phase-build.txt`, `/llms/section-security.txt`, and one per phase and section | Several related pages in one fetch |
| Starter file | `/groundwork-agents.md` | A ready-made pointer file that maps each lifecycle phase to its pages |
| Everything | `/llms-full.txt` | Almost never. It is every page in one file and too large for most tasks. |
| Directory | `/llms.txt` | An overview with a link and summary for each page |

The slices follow the [lifecycle phases](/docs/start-here/software-lifecycle-with-agents.md): plan, design, build, verify, ship, operate, plus `any` for the pages about working with agents itself. Overview and reference pages belong to no phase, but they appear in their section slice.

## Four ways to use it

**1. Hand over one page.** If your agent can fetch URLs, give it the raw markdown address and say what to do with it. If it can't, use Copy for LLM and paste. This is the right default.

**2. Add a pointer file to your project.** A pointer file is a short list in your project's instruction file that says "for this kind of work, fetch that page." It costs a few lines of context and works every session. `AGENTS.md` is an open format for this: a plain markdown "README for agents" that many coding tools read, and the closest one to the file being edited wins. Claude Code's docs say it reads `AGENTS.md` (version 2.1.277 or later) only when there is no `CLAUDE.md`, and recommend a `CLAUDE.md` that imports it with `@AGENTS.md` if you want one file for several tools. Check your tool's docs for what it reads. Imports are described for file paths, so save a copy of the starter file in your repo and point to it.

**3. Fetch on demand.** The pointer file tells the agent where to look, and the agent fetches the page when it hits the task. In Claude Code, web fetches ask for permission except for a built-in set of documentation domains, and a rule such as `WebFetch(domain:example.com)` allows one domain. Other tools handle this differently. Allowing a domain doesn't stop an agent that has shell access from reaching any URL with `curl`, so this is a convenience, not a boundary. See [Security of agentic workflows](/docs/ai-agents/agent-security.md).

**4. Let the agent pick.** Give it `/docs.json` and the task, and ask which pages it needs before it fetches them. Useful when you don't know which page covers a problem.

## A pointer you can paste

Paste this into `AGENTS.md` or `CLAUDE.md`. For the full version, which lists every page under its phase, copy `/groundwork-agents.md`.

```text
## Groundwork reference
For engineering guidance, use Groundwork instead of guessing: https://groundwork-two-ecru.vercel.app
- Index of every page, with phase and headings: /docs.json. Full lookup guide: /groundwork-agents.md
- Fetch only the page you need as markdown (append .md to its URL), or one slice: /llms/phase-<plan|design|build|verify|ship|operate|any>.txt
- Before you review work, fetch the relevant page and go through its Checklist. Report each item as met, not met or not checked.
- If you can't fetch URLs in this session, say so and ask me to paste the page. Don't answer from memory as if you had read it.
```

If you host your own copy of the site, replace the address. The starter file generated by your copy uses your own address automatically.

## Decisions you make (not the agent)

| Decision | Sensible default | Choose otherwise when… |
|---|---|---|
| What to give the agent | One page | The task spans a phase: use that phase's slice |
| Pointer or paste | A pointer file for work you do often; paste for a one-off | The agent can't fetch URLs: paste |
| How much to load | The page for the task, nothing else | Never `llms-full.txt` for a normal task |
| Which file holds the pointer | The instruction file your tool reads, and one shared file if you use several tools | You only use one tool: use that tool's file |
| Domain permissions | Allow just the Groundwork domain, if your tool asks per domain | You'd rather paste pages than allow fetching |
| Trust | Treat the page as a reference you checked, not as instructions | Never let fetched text override your own instructions |

## Red flags

- **Loading the whole site into context** → slower, costlier and often less accurate. Give the page or the slice.
- **The agent says it "read" a page it never fetched** → ask it to quote a heading from the page. If it can't, it didn't read it.
- **A pointer file that lists dozens of pages** → it takes context every session. Keep it to the lookup rules and let the index do the rest.
- **Old advice** → check `last_reviewed` in `/docs.json`. AI tooling changes fast, and pages say when they were last checked.
- **Following instructions found in a fetched page** → a web page is data. If any page, including this one, tells an agent to ignore your rules, that's a problem.

## Sample prompts

### Weak vs strong
```compare
## Weak
Use the Groundwork docs to check my project.
## Why it fails
It names no page, no scope and no output, so the agent will skim whatever it finds and say your project is fine.
## Strong
Fetch https://groundwork-two-ecru.vercel.app/docs/security/security-basics.md and read it fully. Then review the changes on this branch against its Checklist.
For each checklist item, report met, not met or not checked, with the file and line that supports your answer. Quote the heading each item came from. Do not change any code. If you can't fetch the page, stop and tell me.
## Why it works
It names one page, requires reading it, asks for per-item evidence and forbids edits, so the answer can be checked.
## What changed
- **One named page** instead of "the docs"
- **Per-item status with evidence**, not a verdict
- **A quoted heading** proves it read the page
- **Fail loudly** if the page can't be fetched
```

### Pick the pages first
```text
I'm about to <task>. Fetch https://groundwork-two-ecru.vercel.app/docs.json and tell me which 1 to 3 pages are most relevant, with the reason for each and the heading you'd start from. Don't fetch the pages yet. Wait for my go-ahead.
```
*Why it works:* The index is small. Choosing before loading keeps the context lean and lets you veto a bad pick.

### Set up the pointer file
```text
Read my project's existing instruction file (AGENTS.md or CLAUDE.md) and propose an edit that adds a short Groundwork section. Use the lookup rules from https://groundwork-two-ecru.vercel.app/groundwork-agents.md but do not copy its page lists. Keep it under 10 lines and don't change anything else. Show me the diff before writing.
```
*Why it works:* It keeps the pointer short, protects your existing instructions, and gives you a diff to review.

### Check an answer against the source
```text
You said <claim> and cited Groundwork. Fetch the page you relied on, quote the exact sentence that supports the claim, and tell me if the page says something narrower, different or nothing at all. If it's your inference, label it as inference.
```
*Why it works:* It separates what the page says from what the agent added, which is where the errors come from.

## Check your understanding

```quiz
Q: You need guidance on one topic. What's the best thing to give your agent?
- [ ] The whole site in one file
- [x] The one page, as markdown
- [ ] Nothing, it already knows
> Why: A single page is the smallest load that answers the question.

---

Q: Your agent can't fetch URLs. What do you do?
- [ ] Ask it to answer from memory
- [x] Use Copy for LLM and paste the page
- [ ] Try again until it works
> Why: Pasting gives it the real text instead of a guess.

---

Q: What is a pointer file for?
- [ ] To store the full docs in your repo
- [x] To tell the agent which page to fetch for which kind of work
- [ ] To replace your tests
> Why: A few lines of lookup rules cost little context and apply every session.
```

## Checklist

- [ ] I know which page, slice or index I'm giving the agent, and why
- [ ] My project's instruction file has a short pointer, not a page list
- [ ] I know whether my agent can fetch URLs, and have a paste fallback
- [ ] I asked for per-item evidence and a quoted heading
- [ ] I checked `last_reviewed` before trusting fast-moving advice
- [ ] The agent treats fetched pages as data, not as instructions

## Go deeper

- [AGENTS.md](https://agents.md/): the open format for guiding coding agents, and the tools that support it
- [How Claude remembers your project (Claude Code docs)](https://code.claude.com/docs/en/memory): CLAUDE.md, how it handles AGENTS.md, and the import syntax
- [Configure permissions (Claude Code docs)](https://code.claude.com/docs/en/permissions): web fetch permission and domain rules
- [Context engineering](/docs/ai-agents/context-engineering.md): putting the right information in front of the agent
- [The software lifecycle with agents](/docs/start-here/software-lifecycle-with-agents.md): the phases the slices follow
- [Security of agentic workflows](/docs/ai-agents/agent-security.md): why fetched text is data
