@AGENTS.md
For detailed documentation beyond AGENTS.md essentials:
→ docs/KNOWLEDGE_BASE.md - Architecture, code patterns, frontend structure, testing, debugging
- Keep responses concise and action-oriented
- Ask clarifying questions before changes that alter product behavior
- Prefer updating shared UI code in
js/packages/ui; keepjs/appthin - Run
cd js && pnpm run buildbeforerecce serverwhen validating frontend changes
Use gitignored directories for temporary working documents:
docs/plans/- Implementation plans and design docsdocs/tasks/- Task lists and trackingdocs/summaries/- Status reports and progress updates
When asked to "update deps" or "check for updates":
Prerequisites: brew install dependabot + Docker running
- Scan:
make deps-check(runs Dependabot locally, outputsdeps-python.ymlanddeps-frontend.yml) - Audit:
cd js && pnpm audit && pnpm outdated - Present: Group by SECURITY/MAJOR/MINOR with numbered list
- Apply: Update root
js/package.json; addpnpm.overridesfor shared packages - Verify:
pnpm install && pnpm lint && pnpm type:check && pnpm test && pnpm build
Packages requiring overrides (exist in multiple package.json): @emotion/react, @mui/material, @tanstack/react-query, @xyflow/react, axios, date-fns, lodash, tailwindcss, typescript, vitest
When asked to "publish ui" or "release ui package":
- Node version: Use
nave use $(cat js/.nvmrc)for all commands - Version check: Compare local vs published (
npm view @datarecce/ui version) - Verify: Run all quality checks from
js/directory - Publish:
cd js/packages/ui && npm publish --access public - Confirm:
npm view @datarecce/ui version
Commits: Always use --signoff and include a Co-Authored-By: Claude <noreply@anthropic.com> trailer (version pin optional — if included, use the current model)
PRs: Follow .github/PULL_REQUEST_TEMPLATE.md:
- PR checklist (tests, DCO)
- Type, description, linked issues
- Reviewer notes, user-facing changes
- MCP tool description = LLM agent contract. Description MUST match actual response format.
- Prefer additive changes (
_metafields) over modifying existing field types in tool responses. - Row count consumers: frontend (int),
run.py(int comparison),summary.py(int arithmetic),RowCountDiffResultDiffer(3-format compat), MCP agents (description-guided). summary.pyrow count gotcha:base/currcan beNone(TABLE_NOT_FOUND, PERMISSION_DENIED). Guard withis Nonecheck before arithmetic —dict.get(key, 0)does NOT protect when key exists withNonevalue. N/A display includes reason:"N/A (table_not_found)".- Format changes to MCP tool responses require both deterministic tests AND BQ/LLM eval to prove agent behavior unchanged.
- Storybook imports: Never import from
ui/srcinternal paths (e.g.,../../../ui/src/...). Always use@datarecce/ui/componentsor other@datarecce/uipackage exports. This keeps the package boundary intact. - CSS color format: Use space-separated
rgb()syntax:rgb(255 173 21),rgb(0 0 0 / 0.45). Do not use comma-separated legacy format (rgba(0, 0, 0, 0.45)).
- @~/.claude/recce.md