Skip to content

Audit role archetype coverage#92

Merged
SaharPak merged 2 commits into
mainfrom
docs/archetype-gap-audit
Jul 2, 2026
Merged

Audit role archetype coverage#92
SaharPak merged 2 commits into
mainfrom
docs/archetype-gap-audit

Conversation

@SaharPak

@SaharPak SaharPak commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

Summary

Adds a comprehensive audit of the project's role archetype registries
plus the small docs-only corrections the audit calls out. No code
changes to either registry are made by this PR; two follow-up issues
are opened instead.

What was audited

  • Both archetype registries and their types:
    • packages/core/src/archetypes/index.ts (7 archetypes,
      RoleArchetype)
    • packages/intelligence/src/archetypes/index.ts plus the three
      archetype files it imports (3 archetypes, Zod Archetype)
    • packages/schemas/src/archetype.ts (source of the Zod schema)
    • packages/core/src/types.ts (RoleArchetype)
  • Both detector implementations (core.detectArchetype,
    intelligence.detectArchetype)
  • The live evaluator (packages/core/src/evaluator/index.ts) and
    its consumers:
    • packages/cli/src/cli.ts (the archetypes CLI command)
    • apps/web-ui/src/app/results/page.tsx (the Web UI results page)
    • apps/web-ui/src/app/components/EvaluateForm.tsx
  • The eval harness (packages/eval/src/__tests__/fixtures.test.ts)
    and the three golden fixtures (swe-strong, pm-strong,
    data-ml-strong)
  • Planning sources:
    • docs/V1_SCOPE.md, docs/PHASE-1.md, docs/ARCHITECTURE.md
    • scripts/create-issues.sh and docs/ISSUES_SEED.md
    • All open archetype-labeled issues via gh issue list --label archetype
    • The released status doc (docs/MVP_RELEASE_STATUS.md) and
      the cleanup handoff (docs/PR_CLEANUP_HANDOFF.md)

Current implemented archetypes (live, CLI + Web UI)

The core registry (the only one the user-facing evaluation
surface sees):

  1. AI Product Manager
  2. AI Engineer
  3. Backend Engineer
  4. Frontend Engineer
  5. QA / Test Engineer
  6. DevOps / SRE
  7. Data Engineer

The intelligence registry (used by prompts + eval fixtures):

  1. Software Engineer
  2. Product Manager
  3. Data & ML Engineer

The two registries use different types (RoleArchetype vs Zod
Archetype), different IDs (ai-product-manager vs
product-manager, no software-engineer in core, etc.), and
no shared source of truth. Detailed mapping with which
archetype is in which registry is in the audit document.

Missing / high-priority archetypes

Highest priority (live impact, small scope): Plain
Product Manager is missing from core. The live detector
falls back to backend-engineer for non-AI PM CVs, producing
a misleading "Detected archetype: Backend Engineer" on what is
actually a PM resume. Filed as follow-up issue #90.

Architectural (medium-to-large refactor, recommend a dedicated
PR):
Duplicate core vs intelligence registry on divergent
schemas. Until merged, every new archetype has to be added in
two places and stays at risk of drift. Filed as follow-up issue
#91.

Already open (no new issues created for these):

These already have issue templates ready and are good
good first issue candidates for community contributors.

Issues created

What was intentionally NOT implemented

  • No new archetype code. The audit does not add or remove
    archetypes from either registry.
  • No type consolidation. RoleArchetype (plain TS) and the
    Zod Archetype are left as-is; that's the work for the
    follow-up PR on issue Consolidate the duplicate archetype registries (core vs intelligence) #91.
  • No edits to apps/web-ui or packages/cli. Verified their
    consume-paths; not changed.
  • No new evaluation rules. Out of scope.
  • No evaluation of this PR's changes against local CVs. Pure
    docs-and-issue work.

Docs / consistency corrections (in this PR)

README claimed "8 role archetypes" and listed Machine Learning Engineer as currently built-in. The live core registry has 7
archetypes and no ml-engineer (it has ai-engineer instead).
This PR corrects:

  • README.md — "8 role archetypes" → "7 role archetypes",
    removed Machine Learning Engineer line, added a pointer to
    the new audit.
  • docs/MVP_RELEASE_STATUS.md — "8 archetypes" → "7 archetypes"
    in two places, added a pointer to the audit.
  • docs/PR_CLEANUP_HANDOFF.md — "rubric v1 + 8 archetypes" →
    "rubric v1 + 3 archetypes (used by prompts + eval fixtures)
    with a note pointing to the audit and clarifying the 7 in core.

Validation results

Command Result
pnpm lint ✅ No new findings. 1 pre-existing Biome migration info note on biome.json is unchanged from main.
pnpm test ✅ 12/12 successful (cached; docs-only diff).
pnpm build ✅ 6/6 successful (cached).

Confirmation that PR #37 and PR #78 were not touched

Neither PR was checked out, rebased, edited, or commented on by
this work.

@coderabbitai

coderabbitai Bot commented Jul 2, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@SaharPak, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 31 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 59c4b968-7ca2-43ab-b0b4-676611c79470

📥 Commits

Reviewing files that changed from the base of the PR and between 656b2fd and 4285975.

📒 Files selected for processing (4)
  • README.md
  • docs/ARCHETYPE_GAP_AUDIT.md
  • docs/MVP_RELEASE_STATUS.md
  • docs/PR_CLEANUP_HANDOFF.md
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch docs/archetype-gap-audit

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Cleanup Bot added 2 commits July 2, 2026 22:05
Adds a comprehensive audit of the role-archetype registries, plus the
small docs-only corrections called out in the audit.

Audited:
- packages/core/src/archetypes/index.ts (7 archetypes, RoleArchetype)
- packages/intelligence/src/archetypes/ (3 archetypes, Archetype)
- packages/schemas/src/archetype.ts (Zod Archetype schema)
- packages/core/src/evaluator/index.ts (live evaluator)
- packages/cli/src/cli.ts (CLI archetypes list)
- apps/web-ui/src/app/{results,components}/* (web UI consumer)
- packages/eval/src/__tests__/fixtures.test.ts (eval fixtures)
- issues, scripts/create-issues.sh, docs/ISSUES_SEED.md, ROADMAP
  equivalents in README/docs, V1_SCOPE, PHASE-1, ARCHITECTURE

Key findings:
1. Two parallel archetype registries (core vs intelligence) on
   divergent schemas. CLI + Web UI use core (7); prompts + eval
   fixtures use intelligence (3).
2. README claimed 8 archetypes; core has 7, intelligence has 3.
   Fixed to 7 in README, MVP_RELEASE_STATUS, PR_CLEANUP_HANDOFF.
3. Plain Product Manager detection is broken in the live system:
   core has only ai-product-manager, so a non-AI PM CV falls back
   to backend-engineer.

Files changed:
- docs/ARCHETYPE_GAP_AUDIT.md (new, 200+ lines)
- README.md: '8 role archetypes' -> '7', removed Machine Learning
  Engineer from 'currently built-in' list (not in core), added
  pointer to the audit
- docs/MVP_RELEASE_STATUS.md: 8 archetypes -> 7 in two places
- docs/PR_CLEANUP_HANDOFF.md: clarified 3 archetypes in intelligence
  vs 7 in core
The audit draft was written before the GitHub API assigned the actual
issue numbers. It referenced 'issue #97' in three places for the
plain-Product-Manager follow-up. The real issue number is #90
(verified via gh issue view).

- Line 135: 'issue #97, see footer' -> 'issue #90, see footer'
- Line 194: 'Filed as issue #97' -> 'Filed as issue #90'
- Line 204: 'follow-up to #97' -> 'follow-up to #90'

Also caught by this rebase onto latest main (docs: align repository
documentation with MVP status, PR #88). The rebase was conflict-free
because PR #88 and the audit modified orthogonal sections of the
shared files (README.md, docs/MVP_RELEASE_STATUS.md, and
docs/PR_CLEANUP_HANDOFF.md).

The rebase confirmed that all five audit findings survived intact:

- core registry has 7 live archetypes
- intelligence registry has 3 archetypes
- plain Product Manager is missing from core
- #90 tracks plain Product Manager
- #91 tracks registry consolidation

No code changes. Docs only. PR #37 and PR #78 untouched.

Validates: pnpm test 12/12, pnpm lint 0 errors, pnpm build 6/6.
@SaharPak SaharPak force-pushed the docs/archetype-gap-audit branch from 237944b to 4285975 Compare July 2, 2026 19:06
@SaharPak SaharPak merged commit 4b4bb03 into main Jul 2, 2026
3 checks passed
SaharPak pushed a commit that referenced this pull request Jul 2, 2026
- Update snapshot commit hash: 4e43a3c -> 4b4bb03 (post-#88 + #92)
- Total merged PRs: 26 -> 28 (#88 and #92 both merged by SaharPak)
- Distinct merged-PR authors: 10 (unchanged)
- SaharPak merged-PR count: 6 -> 8
- Open PRs: remove #88 (now merged), add #89 (this PR)
- Notable contribution areas: add 'Docs consistency audit' and 'Archetype gap audit'
- Privacy: drop private-email field from anonymous-contributor refresh recipe
- Last refreshed footer: note PR #88 and PR #92
- Maintainers + Docs sections: credit PR #92 archetype gap audit
- Archetype count: 8 -> 7 in IKetutWidiyane and Mohammadreza-Sarvari sections
SaharPak added a commit that referenced this pull request Jul 2, 2026
* docs: add contributor recognition

* docs: tighten contributor recognition accuracy and privacy

- Fix distinct merged-PR author count: 9 -> 10 (verified via gh pr list)
- Add Cleanup Bot to the Anonymous commits on main table (22 commits)
- Add explicit caveat: counts do not capture review, discussion,
  product thinking, or community support
- Remove private email a.hakimi@mohaymen.ir from caveat 4
- Remove fabricated github.com/a.hakimi link (returns 404)
- Soften 'not a real contributor' to 'not a human contributor'
- Rename 'Top contributors by merged-PR count' to 'Contributors by
  merged-PR count' to reduce ranking feel

* docs: refresh contributor recognition after PR #88 and #92

- Update snapshot commit hash: 4e43a3c -> 4b4bb03 (post-#88 + #92)
- Total merged PRs: 26 -> 28 (#88 and #92 both merged by SaharPak)
- Distinct merged-PR authors: 10 (unchanged)
- SaharPak merged-PR count: 6 -> 8
- Open PRs: remove #88 (now merged), add #89 (this PR)
- Notable contribution areas: add 'Docs consistency audit' and 'Archetype gap audit'
- Privacy: drop private-email field from anonymous-contributor refresh recipe
- Last refreshed footer: note PR #88 and PR #92
- Maintainers + Docs sections: credit PR #92 archetype gap audit
- Archetype count: 8 -> 7 in IKetutWidiyane and Mohammadreza-Sarvari sections

* docs: fix contributor formatting command

---------

Co-authored-by: Cleanup Bot <cleanup-bot@example.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant