Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions packages/core/src/__tests__/evaluator.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,17 @@ describe("evaluate", () => {
expect(issueNames).toContain("Responsibility without ownership");
});

it("flags buzzword overuse when 5+ anti-patterns match", async () => {
const result = await evaluate({
cv: { content: weakCV, format: "markdown" },
});

const buzzwordIssue = result.issues.find((i) => i.element === "Buzzword overuse");
expect(buzzwordIssue).toBeDefined();
expect(buzzwordIssue?.severity).toBe("critical");
expect(buzzwordIssue?.why).toContain("cliche");
});

it("finds strengths in strong CVs", async () => {
const result = await evaluate({
cv: { content: strongCV, format: "markdown" },
Expand Down
10 changes: 10 additions & 0 deletions packages/core/src/evaluator/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,16 @@ function findIssues(cv: string, _archetype: RoleArchetype) {
});
}
}

// Buzzword overuse: if 5+ anti-patterns matched, surface a critical issue
if (issues.length >= 5) {
issues.push({
element: "Buzzword overuse",
why: `Your CV triggered ${issues.length} cliche patterns. This signals AI-generated or template-copied content to screeners.`,
fix: "Replace each flagged phrase with a specific achievement. One real number beats ten adjectives.",
severity: "critical",
});
}
// Word count heuristic: CVs >800 words (~2 pages), >1000 clearly too long
const wordCount = cv.trim() ? cv.trim().split(/\s+/).length : 0;

Expand Down
Loading