# How CV Language is Determined and Mismatches are Handled in the AI Job Search Repository

> Discover how CV language is determined and mismatches handled in the AI Job Search repository. Learn about keyword matching and synonym-only flags.

- Repository: [Mads Lorentzen/ai-job-search](https://github.com/MadsLorentzen/ai-job-search)
- Tags: deep-dive
- Published: 2026-07-19

---

**The AI Job Search framework determines CV language once during the interactive `/setup` command, persists it as a profile setting in [`CLAUDE.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/CLAUDE.md), maintains it consistently across all generated CVs, and handles mismatches by performing keyword matching in the posting's language while flagging cross-language terms as synonym-only matches.**

The MadsLorentzen/ai-job-search repository treats language configuration as a persistent profile attribute rather than a per-application variable. This architecture ensures candidates maintain consistent personal branding across multiple job applications while the system intelligently adapts cover letters and handles keyword analysis across language boundaries.

## Setting the CV Language Profile

The foundation of language handling begins during the initial configuration phase where the user defines their preferred CV language once for all future applications.

### Interactive Setup Command

During the **`/setup`** command execution, the system prompts the user to specify their CV language preference. According to the source code in [`.claude/commands/setup.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/.claude/commands/setup.md) at line 317, the interactive prompt asks: *"Should your CVs be written in English (the default, accepted in most markets), or in your market's language?"*

The user's response is then recorded in the **Identity** section of [`CLAUDE.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/CLAUDE.md) using the format:

```markdown
CV language: <language>

```

This establishes the profile-level setting that all subsequent application commands reference.

### Default Fallback to English

If the user skips the language configuration during setup, the system implements a defensive fallback strategy. As shown in [`CLAUDE.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/CLAUDE.md) at line 22, the placeholder defaults to **English** when no explicit language declaration exists in the Identity section. This ensures the framework remains functional without requiring mandatory language input while maintaining a sensible default for international job markets.

## Consistent CV Language Across Applications

Once established, the CV language setting becomes immutable for generated documents. According to [`.claude/commands/apply.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/.claude/commands/apply.md) at line 73, the system explicitly maintains the CV language from the profile across every application, regardless of individual job posting requirements.

This architectural decision ensures that:

- **CVs remain consistent** and reusable across multiple applications
- **Personal branding** stays uniform in the candidate's strongest language
- **Document versioning** remains manageable with single-language assets

The following excerpt from the apply command logic demonstrates this constraint:

```markdown
- In the CV language from the profile (the `CV language:` line in CLAUDE.md's Identity section).
  When the profile does not set one, default to English. Never switch language per posting.

```

## Handling Language Mismatches

When the job posting's language differs from the CV language (for example, a Danish posting paired with an English CV), the system implements specific mismatch handling protocols to maintain application quality.

### Cover Letter Language Adaptation

Unlike CVs, cover letters adapt dynamically to each opportunity. As specified in [`.claude/commands/apply.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/.claude/commands/apply.md) at line 80, cover letters are automatically generated in the **posting's language** rather than the CV language. This ensures direct communication with hiring managers in their native tongue while keeping the CV in the candidate's preferred language.

### Cross-Language Keyword Matching

The system performs sophisticated keyword analysis even across language boundaries. When processing applications where the posting language differs from the CV language, the framework:

1. **Matches keywords in the posting's language** against the extracted job description text
2. **Flags cross-language matches** as synonym-only matches when required terms appear only in the CV's language
3. **Documents the discrepancy** explicitly in the generated report

According to [`.claude/commands/apply.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/.claude/commands/apply.md) at line 253, this logic treats concepts covered only in the CV's language as synonym matches rather than direct matches, ensuring the recruiter understands the language difference when reviewing keyword coverage reports.

The implementation handles this scenario as follows:

```markdown
- Match each keyword against the extracted text, in the posting's language.
  When the posting's language differs from the CV language (e.g., Danish posting vs. English CV),
  a concept covered only in the CV's language counts as a synonym-only match; note the language difference.

```

This approach allows the system to identify relevant experience across languages while transparently flagging potential communication gaps for the recruiter's consideration.

## Key Source Files

The language determination and mismatch handling logic spans several critical files in the repository:

- **[`.claude/commands/setup.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/.claude/commands/setup.md)** – Implements the interactive language selection during profile creation (line 317)
- **[`CLAUDE.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/CLAUDE.md)** – Stores the persistent `CV language:` declaration in the Identity section (line 22)
- **[`.claude/commands/apply.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/.claude/commands/apply.md)** – Contains the application generation logic and mismatch detection (lines 73, 80, and 253)
- **[`.claude/skills/job-application-assistant/05-cv-templates.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/.claude/skills/job-application-assistant/05-cv-templates.md)** – Defines keyword coverage rules specific to language handling

## Summary

- **CV language is determined once** during the `/setup` command and stored in [`CLAUDE.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/CLAUDE.md)
- **English serves as the default** when users do not explicitly configure a language preference
- **CVs maintain consistent language** across all applications, never changing per posting
- **Cover letters adapt dynamically** to each job posting's native language
- **Language mismatches are flagged** during keyword matching, with cross-language terms treated as synonym-only matches and noted in reports

## Frequently Asked Questions

### What happens if I don't specify a CV language during setup?

If you skip the language configuration, the system defaults to **English** as specified in the Identity section placeholder of [`CLAUDE.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/CLAUDE.md). This ensures the framework remains operational while using a globally accepted language for your documents.

### Can I generate CVs in different languages for different job applications?

No, the framework intentionally prevents per-posting language changes for CVs. As implemented in [`.claude/commands/apply.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/.claude/commands/apply.md), the system uses the constant profile language from [`CLAUDE.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/CLAUDE.md) for all CV generation to maintain document consistency and personal branding across your job search.

### How does the system handle keywords when my CV is in English but the job posting is in another language?

When a language mismatch occurs, the system performs keyword matching in the posting's language. If a required skill or experience appears only in your CV's English text, the framework treats this as a **synonym-only match** and explicitly notes the language discrepancy in the coverage report, allowing recruiters to understand the context mismatch.

### Why are cover letters generated in the posting's language while CVs remain in the profile language?

Cover letters target specific communication with hiring managers and must demonstrate immediate relevance to the local market, while CVs represent your comprehensive professional history that maintains consistency across all applications. This separation allows you to present a stable personal brand in your strongest language while tailoring immediate engagement to each employer's linguistic context.