Generate job-targeted CV variants with built-in quality gates. Queries knowledge base, customizes content, runs eval/redteam pipeline.
Trigger phrases: "variant", "tailor", "customize CV", "apply for [company]", "job application"
From Galaxy Variant Exercise:
— with {Company})Goal: Extract NON-GENERIC requirements using the deterministic analyze:jd script.
If user provides JD text, save it first:
# Save JD to source-data/jd-{company}.txt
echo "[JD TEXT]" > source-data/jd-{company}.txt
USE THE SCRIPT — it automatically filters 47+ generic phrases and extracts specific requirements:
npm run analyze:jd -- --file source-data/jd-{company}.txt --save
This outputs to capstone/develop/jd-analysis/{slug}.yaml with:
extracted.company, extracted.role, extracted.yearsRequiredmustHaves[] with category and specificity (high/medium/low)niceToHaves[]ignoredGeneric[] — what was filtered outdomainKeywords[] — crypto, fintech, developer_tools, etc.searchTerms[] — ready for knowledge base searchWhat the script filters automatically:
scripts/analyze-jd.ts:GENERIC_PHRASES)# Read the generated analysis
cat capstone/develop/jd-analysis/{slug}.yaml
Check for:
ls content/variants/ | grep -i {company}
Output: JD analysis summary to user for confirmation before proceeding.
Goal: Score alignment BEFORE investing time in content generation using the search:evidence script.
USE THE SCRIPT — it searches the knowledge base and generates an alignment report:
npm run search:evidence -- --jd-analysis capstone/develop/jd-analysis/{slug}.yaml --save
This outputs to capstone/develop/alignment/{slug}.yaml with:
summary.alignmentScore — 0.0 to 1.0summary.recommendation — PROCEED | REVIEW | SKIPsummary.strongMatches — count of high-relevance matches (≥70%)summary.moderateMatches — count of medium-relevance matches (40-70%)matches[] — sorted by relevance with evidence snippetsgaps[] — search terms with no matchesIf you have specific terms not from JD analysis:
npm run search:evidence -- --terms "crypto,staking,infrastructure,api" --threshold 0.5 --save
cat capstone/develop/alignment/{slug}.yaml
| Score | Recommendation | Action |
|---|---|---|
| ≥ 0.50 + 2 strong | PROCEED | Generate variant |
| ≥ 0.30 or 1 strong | REVIEW | Show gaps, ask user if worth pursuing |
| < 0.30 and 0 strong | SKIP | Recommend not applying, show why |
For REVIEW/SKIP cases, the script surfaces:
gaps[] — terms with no matching evidenceSurface honestly:
PAUSE: Show alignment score and recommendation. Get explicit GO/NO-GO from user.
Goal: Find matching achievements and stories.
Search achievements:
ls content/knowledge/achievements/
Read relevant achievement files matching JD requirements
Look for existing client relationships:
Rank matches by relevance (0.0-1.0):
Output: List of relevant achievements with relevance scores.
Goal: Ensure experience highlights cover all 7 PM competency bundles using the check:coverage script.
USE THE SCRIPT — it automatically categorizes bullets into the 7 PM competency bundles:
npm run check:coverage
For JSON output (easier to process):
npm run check:coverage -- --json
To save report:
npm run check:coverage -- --save
The script categorizes based on keywords (see scripts/check-coverage.ts:BUNDLES):
| Bundle | Keywords Detected |
|---|---|
| 1. Product Design | shipped, launched, built, designed, UX, prototyped, improved |
| 2. Leadership | led, managed, coordinated, E2E, cross-functional, stakeholders |
| 3. Strategy | strategy, vision, roadmap, prioritized, market analysis |
| 4. Business | revenue, ARR, GTM, partnerships, growth, B2B, pricing |
| 5. Project Mgmt | delivered, timeline, Agile, risk, milestones, on-time |
| 6. Technical | architecture, API, SDK, data, metrics, trade-offs, system |
| 7. Communication | presented, documented, collaborated, aligned, storytelling |
The script outputs:
gaps[] — bundles with <2 bulletsoverweight[] — bundles with 5+ bullets| Gap Level | Action |
|---|---|
| 0 gaps | Proceed — well-rounded |
| 1-2 gaps | Surface gaps to user — may want to emphasize in bio/tagline |
| 3+ gaps | Warning — resume may appear unbalanced |
Cross-reference gaps with JD must-haves:
Note: Not all variants need all 7 bundles. A technical PM role may not care about "Business & Marketing." Use the JD must-haves to determine which gaps matter.
IMPORTANT: Invoke dmitrii-writing-style skill before writing bio content.
hero:
status: "Open to Product Roles" # Keep simple
headline:
- text: "Building"
style: "italic"
- text: "at the edge of"
style: "muted"
- text: "trust"
style: "accent"
companyAccent: # REQUIRED
- text: "with"
style: "muted"
- text: "{Company}"
style: "accent"
subheadline: >
[Tailored elevator pitch mentioning company connection]
about:
tagline: >
[One-line positioning statement]
bio:
- >
[Paragraph 1: Recent experience, relevant achievements, company connection]
- >
[Paragraph 2: Career arc leading to this opportunity + vision]
stats:
- value: "[X]+"
label: "[Relevant metric]"
- value: "[Y]"
label: "[Relevant metric]"
- value: "[Z]"
label: "[Relevant metric]"
relevance:
caseStudies:
- slug: "[most-relevant]"
relevanceScore: 1.0
reasoning: "[Why this matches JD]"
# ... ranked list
skills:
- category: "[Top category]"
relevanceScore: 1.0
# ... ranked list
PAUSE: Show generated content to user for review before proceeding.
Create variant YAML:
# Write to content/variants/{slug}.yaml
Sync to JSON:
npm run variants:sync -- --slug {slug}
Verify JSON created:
ls content/variants/{slug}.json
Run evaluation:
npm run eval:variant -- --slug {slug}
Review extracted claims (metrics with anchors)
For each unverified claim, verify against knowledge base:
npm run eval:variant -- --slug {slug} --verify {claim-id}={source-path}
Target: 100% claims verified
PAUSE: Show claims status to user before proceeding.
Run red team scan:
npm run redteam:variant -- --slug {slug}
Review findings:
Common issues and fixes:
| Check | Issue | Fix |
|---|---|---|
| RT-ACC-CLAIMS | Unverified claims | Run Phase 5 verification |
| RT-SEC-SECRETS | Tokens in content | Remove sensitive data |
| RT-TONE-SYCOPHANCY | Flattery detected | Rewrite objectively |
| RT-PRIV-JD | Long JD exposed | Truncate in YAML |
PAUSE: Show redteam results to user for approval.
Start dev server if not running:
npm run dev
Open variant in browser:
http://localhost:5173/{company}/{role}
Visual checklist:
Offer to commit if approved.
Goal: Generate a variant-specific resume PDF and link it to the variant.
Generate variant resume:
npm run generate:resume -- --variant {slug}
This will:
/{company}/{role}/resumepublic/resumes/{slug}.pdfresumePath: /resumes/{slug}.pdfSync the updated variant:
npm run variants:sync -- --slug {slug}
Verify resume was generated:
ls -la public/resumes/{slug}.pdf
Note: The variant resume uses the merged profile/experience data, so it reflects the tailored content (bio, stats, tagline) specific to this role.
Goal: Regenerate the CV dashboard to include the new variant.
Regenerate dashboard HTML:
DASHBOARD_PASSWORD=<password> npm run generate:dashboard
Or use the combined command (syncs variants AND regenerates dashboard):
DASHBOARD_PASSWORD=<password> npm run variants:sync:dashboard
Verify the new variant appears in the dashboard output:
public/cv-dashboard/index.htmlCommit the updated dashboard:
git add public/cv-dashboard/index.html
Note: The dashboard is password-protected. The DASHBOARD_PASSWORD env var is required. Check .env.local or ask the user for the password.
Before marking variant complete:
resumePath in variant metadata)| File | Purpose |
|---|---|
content/variants/{slug}.yaml |
Variant source (canonical) |
content/variants/{slug}.json |
Runtime artifact |
content/variants/_template.yaml |
Template reference |
capstone/develop/evals/{slug}.claims.yaml |
Claims ledger |
capstone/develop/evals/{slug}.eval.md |
Eval report |
capstone/develop/redteam/{slug}.redteam.md |
Redteam report |
content/knowledge/achievements/*.yaml |
Achievement sources |
content/knowledge/stories/*.yaml |
Story sources |
public/resumes/{slug}.pdf |
Variant-specific resume PDF |
public/cv-dashboard/index.html |
Dashboard HTML (password-protected) |
public/cv-dashboard/variants-manifest.json |
Dashboard data source |
# ═══════════════════════════════════════════════════════════════
# PHASE 1: JD Analysis (deterministic)
# ═══════════════════════════════════════════════════════════════
npm run analyze:jd -- --file source-data/jd-{company}.txt --save
npm run analyze:jd -- --file jd.txt --json # JSON output
# ═══════════════════════════════════════════════════════════════
# PHASE 1.5: Evidence Search (deterministic)
# ═══════════════════════════════════════════════════════════════
npm run search:evidence -- --jd-analysis capstone/develop/jd-analysis/{slug}.yaml --save
npm run search:evidence -- --terms "crypto,staking,api" --threshold 0.5
# ═══════════════════════════════════════════════════════════════
# PHASE 2.5: Coverage Check (deterministic)
# ═══════════════════════════════════════════════════════════════
npm run check:coverage
npm run check:coverage -- --json
npm run check:coverage -- --save
# ═══════════════════════════════════════════════════════════════
# PHASE 4-6: Variant Pipeline
# ═══════════════════════════════════════════════════════════════
npm run variants:sync -- --slug {slug}
npm run eval:variant -- --slug {slug}
npm run eval:variant -- --slug {slug} --verify {id}={path}
npm run redteam:variant -- --slug {slug}
# ═══════════════════════════════════════════════════════════════
# PHASE 8: Resume Generation
# ═══════════════════════════════════════════════════════════════
npm run generate:resume -- --variant {slug}
npm run variants:sync -- --slug {slug} # Sync after resume path update
# ═══════════════════════════════════════════════════════════════
# PHASE 9: Dashboard Update
# ═══════════════════════════════════════════════════════════════
DASHBOARD_PASSWORD=<password> npm run generate:dashboard
# Or combined sync + dashboard:
DASHBOARD_PASSWORD=<password> npm run variants:sync:dashboard
# ═══════════════════════════════════════════════════════════════
# PREVIEW
# ═══════════════════════════════════════════════════════════════
npm run dev
open "http://localhost:5173/{company}/{role}"
open "http://localhost:5173/{company}/{role}/resume" # Preview resume page
Job: Director, Technical Program Manager at Galaxy
Key Learnings Applied:
trust — with Galaxy (inline, subtle)Result: All 6 claims verified, redteam passed, variant shipped.
See Quality Gate Template for universal checks.
Variant-specific: