# How the ModernCV LaTeX Template Generates Tailored CVs in Banking Style

> Learn how the ModernCV LaTeX template creates custom banking style CVs. Discover its placeholder system and color overrides for a polished, two-page resume.

- Repository: [Mads Lorentzen/ai-job-search](https://github.com/MadsLorentzen/ai-job-search)
- Tags: how-to-guide
- Published: 2026-07-14

---

**The repository ships a ready‑to‑use ModernCV LaTeX template that produces a consistent two‑page, banking‑styled CV by combining the `moderncv` document class with custom color overrides and a placeholder‑driven data population system.**

The **MadsLorentzen/ai-job-search** repository automates job applications using a structured LaTeX workflow centered on the ModernCV banking style. This architecture ensures every generated CV maintains professional typography while allowing AI‑driven personalization through token replacement. Understanding how the template configures the document class, overrides default colors, and structures sections reveals how the system produces ATS‑friendly PDFs tailored to specific roles.

## Document Class and Banking Style Configuration

The template establishes its visual foundation in `cv/main_example.tex` by loading the ModernCV class with specific parameters optimized for financial and corporate sectors.

The document header declares:

```latex
\documentclass[11pt,a4paper,sans]{moderncv}
\moderncvstyle{banking}
\moderncvcolor{blue}

```

These commands activate the **banking style**—characterized by horizontal rules, elegant typography, and a conservative layout—while setting a blue accent color scheme. The `sans` option ensures sans‑serif fonts throughout, adhering to modern corporate standards.

## Color Customization and Visual Overrides

ModernCV’s default behavior on LuaLaTeX with MiKTeX renders names and section headings in black, contradicting the blue theme. The template forces consistent accent coloring through three strategic renew commands at lines 13‑18 of `main_example.tex`:

```latex
\renewcommand*{\firstnamestyle}[1]{{\fontsize{34}{36}\bfseries\upshape\color{color1}#1}}
\renewcommand*{\lastnamestyle}[1]{{\fontsize{34}{36}\bfseries\upshape\color{color1}#1}}
\renewcommand*{\sectionstyle}[1]{{\sectionfont\color{color1}#1}}

```

These overrides ensure that **first names**, **last names**, and **section headings** all render in `color1` (the defined blue accent), creating a cohesive visual identity across the two‑page document.

## Personal Data and Placeholder System

The `/setup` command populates the personal data block by replacing placeholder tokens with candidate‑specific information. In `cv/main_example.tex` (lines 33‑38), the template defines:

```latex
\name{[First]}{[Last]}
\address{[Street]}{[City]}{[Country]}
\phone[mobile]{[Phone]}
\email{[Email]}
\extrainfo{\href{[LinkedIn URL]}{LinkedIn}, \href{[GitHub URL]}{GitHub}}

```

When the AI assistant processes a job application, it copies this template and substitutes bracketed placeholders with values from the candidate’s profile stored in [`CLAUDE.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/CLAUDE.md). This separation of structure and content allows the same LaTeX source to generate infinitely tailored variants without manual editing.

## Section Structure and Content Layout

The CV organizes content into clearly delineated sections using standard LaTeX `\section` commands followed by `itemize` environments. Professional experience entries leverage the `\cventry` command, which automatically handles date ranges, job titles, institutions, and location formatting while respecting the two‑page limit.

An experience entry appears as:

```latex
\section{Professional Experience}
\begin{itemize}
  \item{\cventry{2020--Present}{Data Scientist}{Acme Corp}{Copenhagen}{}
    {\begin{itemize}
       \item Developed end‑to‑end ML pipelines reducing processing time by 30\%.
       \item Led a team of 4 engineers to deploy a recommendation system.
     \end{itemize}}}
\end{itemize}

```

The **geometry** package (line 30) scales content to 80 % of page width, providing adequate whitespace for readability while maximizing content density. Meanwhile, the **hyperref** package (lines 20‑29) configures colored links, PDF metadata, and search‑friendly encoding to ensure ATS compatibility.

## Compilation Requirements and PDF Generation

The ModernCV banking style requires **LuaLaTeX** compilation rather than pdfLaTeX. According to the repository’s [`README.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/README.md) (lines 263‑265), pdfLaTeX frequently fails on MiKTeX systems due to font‑expansion errors when processing FontAwesome icons used in the banking theme.

When a user executes the `/apply` command, the framework:

1. Copies `cv/main_example.tex` to a temporary working file
2. Executes string replacement on placeholder tokens using the candidate’s profile data
3. Optionally removes irrelevant sections based on job requirements
4. Compiles with LuaLaTeX to generate a finalized two‑page PDF

The template remains the **default** CV format unless overridden via the `/add-template` command, ensuring consistent output across all applications while allowing customization when needed.

## Summary

- The **ModernCV banking style** is activated via `\moderncvstyle{banking}` in `cv/main_example.tex`, establishing a conservative, professional layout suitable for financial and corporate roles.
- **Color consistency** requires manual overrides of `\firstnamestyle`, `\lastnamestyle`, and `\sectionstyle` to force blue accent coloring under LuaLaTeX compilation.
- The **placeholder system** uses bracketed tokens like `[First]` and `[Last]` that the `/setup` command replaces with actual candidate data during the application workflow.
- **LuaLaTeX** is mandatory for compilation; pdfLaTeX fails due to font‑expansion errors with the banking style’s iconography.
- The template enforces a **two‑page limit** through `\cventry` formatting and geometry scaling at 80 % page width.

## Frequently Asked Questions

### Why does the template require LuaLaTeX instead of pdfLaTeX?

The ModernCV banking style incorporates FontAwesome icons for contact information and social links. According to the repository documentation in [`README.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/README.md) (lines 263‑265), pdfLaTeX on MiKTeX systems encounters font‑expansion errors when processing these vector icons, whereas LuaLaTeX handles the moderncv font subsystem natively without errors.

### How does the template ensure the name and headings appear in blue?

The template overrides three internal ModernCV formatting commands at lines 13‑18 of `cv/main_example.tex`: `\firstnamestyle`, `\lastnamestyle`, and `\sectionstyle`. By wrapping these definitions in `\color{color1}`, the template forces the accent blue color regardless of the engine’s default behavior, which typically renders these elements in black.

### Can I modify the default template for specific job applications?

Yes. While `cv/main_example.tex` serves as the baseline template, the `/add-template` command (documented in [`.claude/commands/add-template.md`](https://github.com/MadsLorentzen/ai-job-search/blob/main/.claude/commands/add-template.md)) allows users to register custom LaTeX templates. However, the stock ModernCV banking template remains the default for all `/apply` operations unless explicitly replaced, ensuring consistency across applications.

### What controls the two‑page limit in the generated CV?

The combination of **geometry** package settings (`\geometry{scale=0.8}` at line 30) and the `\cventry` command’s built‑in formatting constraints prevents content overflow. The banking style automatically handles page breaks, while the AI assistant optionally removes non‑essential sections during the tailoring process to fit role‑specific requirements within the two‑page standard.