diff --git a/website/app/docs/cli/page.mdx b/website/app/docs/cli/page.mdx index 3a9512ce..20e1d656 100644 --- a/website/app/docs/cli/page.mdx +++ b/website/app/docs/cli/page.mdx @@ -476,6 +476,19 @@ Selection notes: - only folder-based pages can be written automatically, because the command needs a sibling `agent.md` target +- `--review ` records a hash-bound human review for one or more pages without rewriting + `agent.md` or calling the compressor; requires explicit page arguments plus `--reviewed-by` and + `--reason` +- `--review-manifest ` overrides the project-relative manifest location used to store review + entries (default: `.farming-labs/agent-compaction-reviews.json`) + +A reviewed entry binds the resolved page source, compaction settings, and `agent.md` body to the +reviewer and reason. If any of those hashes drift, `--check` and `docs doctor --agent` report the +entry as invalid until the page is deliberately reviewed again. + +```bash title="terminal" +pnpm exec docs agent compact --review --reviewed-by "docs-team" --reason "Preserve operator guidance" /docs/configuration +``` Recommended config defaults: ```ts title="docs.config.ts" diff --git a/website/app/docs/configuration/page.mdx b/website/app/docs/configuration/page.mdx index b852dc06..e73fd087 100644 --- a/website/app/docs/configuration/page.mdx +++ b/website/app/docs/configuration/page.mdx @@ -1852,6 +1852,21 @@ Supported fields: - `minOutputTokens` - `protectJson` +- `reviewManifestPath` + +`reviewManifestPath` sets the project-relative path to the JSON manifest used by +`docs agent compact --review` to store hash-bound reviewed exceptions. The default is +`.farming-labs/agent-compaction-reviews.json`. Set it when your project stores the manifest at a +custom location: + +```ts title="docs.config.ts" +agent: { + compact: { + reviewManifestPath: ".farming-labs/agent-compaction-reviews.json", + }, +}, +``` + `docs agent compact` creates missing `agent.md` files and overwrites existing ones. The written `agent.md` becomes the machine-readable source for `.md` routes, diff --git a/website/app/docs/reference/page.mdx b/website/app/docs/reference/page.mdx index f03c659c..9737919a 100644 --- a/website/app/docs/reference/page.mdx +++ b/website/app/docs/reference/page.mdx @@ -9,6 +9,10 @@ related: - /docs/installation - /docs/customization/mcp agent: + +| Property | Type | Default | Description | +| -------- | ---- | ------- | ----------- | +| `reviewManifestPath` | `string` | `.farming-labs/agent-compaction-reviews.json` | Project-relative path to the JSON manifest for hash-bound reviewed compaction exceptions. Overridable per-run with `--review-manifest`. | tokenBudget: 1800 task: Select and configure the exact typed Farming Labs docs option required by a project. outcome: The chosen defineDocs option has the documented type and default and the resolved runtime exposes matching behavior. diff --git a/website/app/docs/token-efficiency/page.mdx b/website/app/docs/token-efficiency/page.mdx index b12a2019..7e1cdb3e 100644 --- a/website/app/docs/token-efficiency/page.mdx +++ b/website/app/docs/token-efficiency/page.mdx @@ -9,6 +9,14 @@ related: - /docs/customization/llms-txt - /docs/customization/mcp agent: + +When a hand-authored or intentionally modified `agent.md` should be preserved long-term, record a +hash-bound review with `--review`. The review manifest (default +`.farming-labs/agent-compaction-reviews.json`) stores the resolved source, settings, and output +hashes together with the reviewer and reason. `docs doctor --agent` and `docs agent compact --check` +accept matching reviewed entries but fail when any hash drifts (source, settings, or `agent.md` +body), or when a manifest entry no longer matches any compactable page. Re-reviewing requires an +explicit `--review` run after the drift is inspected and accepted. tokenBudget: 900 task: Reduce agent context usage while preserving the evidence needed to implement and verify a docs task. outcome: Retrieval returns the relevant page and executable evidence within the configured UTF-8 context budget.