feat: DLT-3049 add code review rules, skill, agent, and command#1154
feat: DLT-3049 add code review rules, skill, agent, and command#1154belumontoya merged 2 commits intostagingfrom
Conversation
Add Dialtone code review tooling based on the review checklist defined in DLT-3049. Includes path-scoped rules (9 categories, 25 rules), a /review skill with agent fallback for large diffs, and a slash command trigger.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 87501e4a9e
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "Codex (@codex) review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "Codex (@codex) address that feedback".
| For each file: | ||
|
|
||
| 1. Read the full file for context | ||
| 2. Read the diff for that file: `git diff -- <filepath>` |
There was a problem hiding this comment.
Include staged hunks in per-file review diff
This step uses git diff -- <filepath>, which only shows unstaged working-tree changes; it omits staged changes (and can be empty when the review scope came from staged/base-branch diffs). In the 10+ file path where this agent is used, that can produce false "clean" results because the agent never sees the actual modified hunks it is supposed to evaluate.
Useful? React with 👍 / 👎.
| 2. If there are staged changes → `git diff --cached --name-only` | ||
| 3. If there are unstaged changes → `git diff --name-only` |
There was a problem hiding this comment.
Merge staged and unstaged file scopes
The scope detection is written as an ordered conditional sequence, so when staged files exist the flow can stop at git diff --cached --name-only and skip unstaged files. That contradicts the documented /review behavior (“all staged and unstaged changes”) and causes partial reviews whenever developers keep some edits unstaged.
Useful? React with 👍 / 👎.
| |---|---| | ||
| | `*.vue` | Reuse & Duplication, Code Quality, Vue Correctness, API & Library Design, i18n & Assets, Accessibility | | ||
| | `*.less` | CSS / Styling | | ||
| | `*.test.js` | Testing | |
There was a problem hiding this comment.
Cover TypeScript test files in rule mapping
The testing category mapping only matches *.test.js, but this repo contains Dialtone tests named *.test.ts (for example under packages/dialtone-tokens/sync-scripts). Those files will miss Testing-rule checks, so reviews for token test changes become systematically incomplete.
Useful? React with 👍 / 👎.
Brad Paugh (braddialpad)
left a comment
There was a problem hiding this comment.
amazing thanks!
- Use git diff HEAD in agent to capture both staged and unstaged hunks - Merge staged and unstaged file scopes in skill scope detection - Add *.test.ts to testing category mapping
# [9.176.0](dialtone/v9.175.2...dialtone/v9.176.0) (2026-03-31) ### Bug Fixes * **Rich Text Editor:** DLT-3190 replace custom JSON-to-markdown converter with @tiptap/static-renderer ([#1148](#1148)) ([9629c70](9629c70)) ### Documentation * DLT-3151 blog post for ui-kits migration and script ([#1156](#1156)) ([069ad3c](069ad3c)) * **Editor:** DLT-3050 updated editor docs with recent changes ([#1139](#1139)) ([04bfabb](04bfabb)) * **Icons:** DLT-3220 update contributing and add claude rules and skill ([#1151](#1151)) ([296a83d](296a83d)) ### Features * **Dialtone Cli,dialtone Query Core:** DLT-3163 extract query core and add CLI ([#1142](#1142)) ([65090e6](65090e6)) * DLT-3049 add code review rules, skill, agent, and command ([#1154](#1154)) ([6bdef46](6bdef46)) * **Icons:** DLT-3219 align star/sparkle icons with dp brand star ([#1152](#1152)) ([ef39afc](ef39afc))

Summary
.claude/rules/code-review.md— path-scoped rules file with 9 categories (25 rules) from Brad's DLT-3049 checklist. Auto-loads when editing files in dialtone-vue, dialtone-css, dialtone-tokens, dialtone-icons..claude/skills/review.md— review logic skill that reads the rules file, detects scope from git diff, maps files to rule categories, and outputs findings. Delegates to a background agent for diffs with 10+ files..claude/agents/review.md— background agent fallback for large reviews. Runs in isolated context to protect the main conversation..claude/commands/review.md—/reviewslash command trigger.Ticket
https://dialpad.atlassian.net/browse/DLT-3049
Test plan
/reviewwith staged changes on a few.vuefiles — verify findings reference the correct rule categories/review accessibility— verify only accessibility rules are appliedpackages/dialtone-vue/— verifycode-review.mdrules load alongsidevue-components.md/reviewappears in skill listing