update_critique_context
Persist a compiled critique brief, signals, and policy to the cloud for the AI critic. Use after gathering repo signals to define the critique context.
Instructions
Lightweight write-only path for the layered critique-context system. Use this from /setup and /refresh-brand after the dev agent has gathered repo signals (README, theme tokens, sample copy, competitor URLs, recent resolved pins) and compiled them into a critique brief. Unlike configure_project, this does NOT create a deploy hook, sync members, or validate URLs — it just persists the compiled brief (+ signals + policy) and pushes to cloud. Identify the project by projectId or name. The compiled critiqueContext is what the AI critic actually reads at pin time; critiqueSignals + critiquePolicy are inputs retained for traceability and the next recompile.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | The project display name. Used to look up the project when projectId is not known. | |
| projectId | No | The project ID to update. Mutually exclusive with `name`. | |
| critiquePolicy | No | User-editable policy override (max 4096 chars). Persists across recompiles so users keep hand-tuned rules. Pass null to clear. | |
| critiqueContext | No | The compiled critique brief (max 8192 chars). Markdown encouraged. This is what the AI critic loads at pin time. Pass null to clear and force a recompile on the next run. | |
| critiqueSignals | No | Raw signals JSONB. Recommended shape: { framework: e.g. "next-app-router"|"astro"|"static-html", projectType: "marketing"|"app"|"mixed", pages: [{ url, source, slice, headings, ctas, components, bodyExcerpt }], themeTokens, brandDocs, readmeExcerpt, competitors, mission, audience, tone, tenantContexts (reserved/null in v1), sources }. The agent decides exact shape; the AI critic reads the COMPILED context, not the signals directly. Pass null to clear. |