Skip to content

Commit f7e7be6

Browse files
committed
feat: migrate pipeline to LangChain and HTML templates
1 parent fe611d6 commit f7e7be6

28 files changed

+7516
-1388
lines changed

README.md

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# <img src="https://res.cloudinary.com/dyknhuvxt/image/upload/f_auto,q_auto/v1736189459/resumecraftr_eb7drc.png" alt="ResumeCraftr Logo" width="100" height="100"> ResumeCraftr - AI-powered ATS Resume Optimization 📄🤖
22

3-
Welcome to [**ResumeCraftr**](https://resumecraftr.app), the open-source tool designed to optimize resumes for ATS (Applicant Tracking Systems) using AI and Markdown formatting. ResumeCraftr extracts, restructures, and formats CVs to ensure they meet ATS requirements while maintaining readability and professionalism.
3+
Welcome to [**ResumeCraftr**](https://resumecraftr.app), the open-source tool designed to optimize resumes for ATS (Applicant Tracking Systems) using modern, Python-only tooling. ResumeCraftr now leans on LangChain graph pipelines, embedded ChromaDB retrieval, and PyMuPDF rendering to extract, tailor, and format CVs while keeping the stack lightweight and future-proof.
44

55
---
66

@@ -14,6 +14,10 @@ ResumeCraftr now fully supports Windows, making it easier for more users to opti
1414

1515
ResumeCraftr now allows you to create and manage CV sections interactively without needing to parse an existing CV. This makes it easier to build your resume from scratch or update specific sections.
1616

17+
### 🌟 LangChain-native RAG & PyMuPDF 📚
18+
19+
LLM interactions now run through LangChain graph pipelines with retrieval backed by an embedded ChromaDB store, and PDFs are rendered via PyMuPDF for precise, dependency-free styling.
20+
1721
---
1822

1923
## What's New? Discover AI Craftr 🌐
@@ -22,9 +26,9 @@ ResumeCraftr now allows you to create and manage CV sections interactively witho
2226

2327
---
2428

25-
## Release Notes v0.4.0
29+
## Release Notes v0.5.0-beta1
2630

27-
You can find the release notes for version `v0.4.0` [here](https://github.com/raestrada/ResumeCraftr/releases/tag/v0.4.0).
31+
You can find the release notes for version `v0.5.0-beta1` [here](https://github.com/raestrada/ResumeCraftr/releases/tag/v0.5.0-beta1).
2832

2933
## Step 1: Install ResumeCraftr
3034

@@ -33,7 +37,7 @@ First, install **ResumeCraftr** using [pipx](https://pypa.github.io/pipx/), a to
3337
To install **ResumeCraftr**, run:
3438

3539
```bash
36-
pipx install git+https://github.com/raestrada/ResumeCraftr.git@v0.4.0
40+
pipx install git+https://github.com/raestrada/ResumeCraftr.git@v0.5.0-beta1
3741
```
3842

3943
## Quick Examples
@@ -91,14 +95,11 @@ poetry run resumecraftr tailor-cv
9195
### Export your CV to PDF:
9296

9397
```bash
94-
# Exportar a PDF (requiere Pandoc y LaTeX)
98+
# Render the most recent tailored sections with PyMuPDF
9599
resumecraftr export-pdf
96100

97-
# Exportar a PDF en español
98-
resumecraftr export-pdf --translate ES
99-
100-
# Exportar a PDF usando un archivo Markdown existente (sin llamar a OpenAI)
101-
resumecraftr export-pdf --skip-md-gen
101+
# Choose a specific tailored file and output path
102+
resumecraftr export-pdf --sections my_cv.tailored_sections.json --output resume.pdf
102103
```
103104

104105
## Full Guide
@@ -143,5 +144,3 @@ Join us in making ResumeCraftr the best AI-powered resume tool! 🚀
143144
![AI Craftr Logo](https://res.cloudinary.com/dyknhuvxt/image/upload/v1730059761/aicraftr_qzknf4.png)
144145

145146
Learn more about **AI Craftr** and discover other tools like **StoryCraftr** for novel writing at [https://aicraftr.app](https://aicraftr.app).
146-
147-

docs/getting_started.md

Lines changed: 82 additions & 84 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Getting Started with ResumeCraftr
22

3-
ResumeCraftr is an ATS-focused minimalist CV generator that leverages OpenAI and Pandoc to parse, optimize, and format resumes. This guide will walk you through the setup and usage of ResumeCraftr, along with tips for customizing your experience.
3+
ResumeCraftr is an ATS-focused minimalist CV generator that now leverages LangChain graph pipelines, an embedded ChromaDB store, and PyMuPDF to parse, optimize, and format resumes using only Python-native tooling. This guide walks you through the modernized setup and usage of ResumeCraftr, along with tips for customizing your experience.
44

55
---
66

@@ -14,9 +14,9 @@ ResumeCraftr now fully supports Windows, making it easier for more users to opti
1414

1515
ResumeCraftr now allows you to create and manage CV sections interactively without needing to parse an existing CV. This makes it easier to build your resume from scratch or update specific sections.
1616

17-
### 🌟 Improved PDF Generation! 📄
17+
### 🌟 Embedded RAG & PyMuPDF! 📄
1818

19-
ResumeCraftr now uses Pandoc to convert Markdown to PDF, making the process more robust and less prone to errors. This also makes it easier to preview and edit your resume before generating the final PDF.
19+
ResumeCraftr now routes every LLM call through LangChain/ LangGraph, persists knowledge in an on-disk ChromaDB (SQLite) store, and renders PDFs directly through PyMuPDF for precise styling.
2020

2121
---
2222

@@ -25,45 +25,31 @@ ResumeCraftr now uses Pandoc to convert Markdown to PDF, making the process more
2525
Ensure you have `pipx` installed, then install ResumeCraftr with:
2626

2727
```bash
28-
pipx install git+https://github.com/raestrada/ResumeCraftr.git@v0.4.0
28+
pipx install git+https://github.com/raestrada/ResumeCraftr.git@v0.5.0-beta1
2929
```
3030

31-
Additionally, make sure you have Pandoc installed:
32-
33-
### 🟢 Windows
34-
1. Download and install [Pandoc](https://pandoc.org/installing.html).
35-
2. Ensure `pandoc` is in your system's PATH by running:
36-
```
37-
pandoc --version
38-
```
39-
If not, restart your computer or manually add the Pandoc directory to your PATH.
40-
41-
### 🍏 macOS
42-
1. Install Pandoc via Homebrew:
43-
```
44-
brew install pandoc
45-
```
46-
2. Verify the installation:
47-
```
48-
pandoc --version
49-
```
50-
51-
### 🐧 Linux
52-
For Debian/Ubuntu:
53-
```
54-
sudo apt update && sudo apt install pandoc
55-
sudo apt-get install texlive-latex-base texlive-latex-extra texlive-latex-recommended texlive-publishers texlive-science texlive-bibtex-extra biber
56-
```
57-
For Arch Linux:
58-
```
59-
sudo pacman -S pandoc
60-
sudo pacman -S texlive-most
61-
```
62-
For Fedora:
63-
```
64-
sudo dnf install pandoc
65-
sudo dnf install texlive-scheme-full
66-
```
31+
PyMuPDF ships with the project, so there is no longer a dependency on Pandoc or LaTeX. You only need:
32+
33+
- Python 3.10+ (3.11 recommended)
34+
- The appropriate API keys in your environment (`OPENAI_API_KEY`, `OPENROUTER_API_KEY`, or local Ollama)
35+
- Basic shell access to export your provider credentials before running the CLI
36+
37+
### Configuring provider API keys
38+
39+
All providers are resolved via LangChain, so credentials live in standard environment variables:
40+
41+
```bash
42+
# OpenRouter (recommended for multi-model routing)
43+
export OPENROUTER_API_KEY="sk-or-v1..."
44+
45+
# OpenAI (only if you selected --provider openai)
46+
export OPENAI_API_KEY="sk-proj-..."
47+
48+
# Optional: override LangChain's base URL for OpenRouter (only needed if you use custom routing)
49+
export OPENAI_BASE_URL="https://openrouter.ai/api/v1"
50+
```
51+
52+
Prefer not to export environment variables? Create `~/.resumecraftr/openrouter_api_key.txt` and paste your OpenRouter key inside—ResumeCraftr will load it from that file first and fall back to the env vars. On Windows PowerShell, use `$env:OPENROUTER_API_KEY = "sk-or-v1..."`. Storing secrets in a `.env` file also works because the CLI loads dotenv automatically at startup.
6753

6854
---
6955

@@ -72,17 +58,19 @@ For Fedora:
7258
ResumeCraftr operates within a dedicated workspace directory called `cv-workspace`. To set up this workspace, run:
7359

7460
```bash
75-
resumecraftr setup --language EN --gpt-model gpt-4o-mini
61+
resumecraftr setup --language EN --provider openrouter --model deepseek/deepseek-chat
7662
```
7763

7864
### Key Options:
7965
- `--language`: Sets the primary language of your CV (e.g., `EN` for English or `ES` for Spanish).
80-
- `--gpt-model`: Specifies the GPT model to use. For testing, we recommend using `gpt-4o-mini`.
66+
- `--provider`: Selects the LangChain provider (`openai`, `openrouter`, or `ollama`).
67+
- `--model`: Specifies the model string compatible with the chosen provider (defaults to `deepseek/deepseek-chat`).
68+
- `--temperature`: Controls the creativity of generations (default `0.4`).
8169

82-
This will create the `cv-workspace` directory with the following files:
83-
- **`cv-workspace/resume_template.md`**: The Markdown template used for PDF generation. You can modify this file to customize the CV layout and style.
84-
- **`cv-workspace/resumecraftr.json`**: The main configuration file.
85-
- **`cv-workspace/custom.md`**: A file for adding supplementary information and custom instructions for ChatGPT.
70+
This will create the `cv-workspace` directory with:
71+
- **`cv-workspace/resumecraftr.json`**: The main configuration file (see below).
72+
- **`cv-workspace/custom.md`**: A file for supplementary information and custom instructions.
73+
- **`cv-workspace/job_descriptions/`** and **`cv-workspace/output/`** directories.
8674

8775
---
8876

@@ -92,29 +80,39 @@ Here's an example of a `resumecraftr.json` configuration file:
9280

9381
```json
9482
{
95-
"primary_language": "ES",
96-
"output_format": "pdf",
97-
"template_name": "resume_template.md",
98-
"chat_gpt": {
99-
"model": "gpt-4o-mini",
100-
"temperature": 0.7,
101-
"top_p": 1.0
83+
"primary_language": "EN",
84+
"llm": {
85+
"provider": "openrouter",
86+
"model": "deepseek/deepseek-chat",
87+
"temperature": 0.4,
88+
"max_tokens": 1200
89+
},
90+
"retrieval": {
91+
"persist_directory": ".chroma",
92+
"embedding_provider": "huggingface",
93+
"embedding_model": "sentence-transformers/all-MiniLM-L6-v2",
94+
"chunk_size": 900,
95+
"chunk_overlap": 200
96+
},
97+
"pdf": {
98+
"font": "helv",
99+
"heading_font_size": 14,
100+
"body_font_size": 11,
101+
"margin": 54
102102
},
103103
"extracted_files": [
104-
"Rodrigo Estrada CV ES.txt"
104+
"Rodrigo Estrada CV EN.txt"
105105
],
106106
"job_descriptions": [
107107
"Principal Engineer Verne.txt"
108108
]
109109
}
110110
```
111111

112-
- **`primary_language`**: The language of the CV and job descriptions (e.g., `EN`, `ES`).
113-
- **`output_format`**: Output format, typically `pdf`.
114-
- **`template_name`**: Name of the Markdown template used for PDF generation.
115-
- **`chat_gpt`**: OpenAI settings such as the model, temperature, and top_p.
116-
- **`extracted_files`**: List of extracted text files from your CVs.
117-
- **`job_descriptions`**: List of job description files used for optimization.
112+
- **`llm`**: LangChain provider/model/temperature/max tokens used for all generations.
113+
- **`retrieval`**: Embedded ChromaDB settings plus embedding model/provider.
114+
- **`pdf`**: Styling knobs consumed by the PyMuPDF renderer.
115+
- **`extracted_files`** & **`job_descriptions`**: Workspace bookkeeping for imported resumes and stored jobs.
118116

119117
---
120118

@@ -221,7 +219,7 @@ After adding the job description, tailor the resume with:
221219
resumecraftr tailor-cv
222220
```
223221

224-
This step ensures that your resume highlights relevant skills and experience based on the job description. ResumeCraftr uses OpenAI to rewrite and structure the content to be ATS-friendly.
222+
This step ensures that your resume highlights relevant skills and experience based on the job description. ResumeCraftr now routes the optimization through a LangChain + LangGraph pipeline backed by ChromaDB retrieval, so every section is grounded in your workspace knowledge base.
225223

226224
### Language Optimization
227225

@@ -238,40 +236,40 @@ For example, if you configured ResumeCraftr with `--language ES` (Spanish), the
238236

239237
## Exporting Your Resume to PDF
240238

241-
Once you're satisfied with your resume, you can export it to PDF using:
239+
Once you're satisfied with your resume, you can export it to PDF using PyMuPDF:
242240

243241
```bash
242+
# Use the default (latest) tailored sections and bundled template
244243
resumecraftr export-pdf
245-
```
246-
247-
By default, the resume will be generated in the language specified in your `resumecraftr.json` file (set during the `setup` command). If you want to generate the resume in a different language, use the `--translate` option:
248244

249-
```bash
250-
resumecraftr export-pdf --translate EN # Generate in English
251-
resumecraftr export-pdf --translate ES # Generate in Spanish
245+
# Specify sections file, template, and destination
246+
resumecraftr export-pdf \
247+
--sections senior-role.tailored_sections.json \
248+
--template modern \
249+
--output output/senior-role.pdf
252250
```
253251

254252
The command will:
255-
1. Find all `.extracted_sections.json` files in your workspace
256-
2. Let you choose which one to use if multiple files exist
257-
3. Generate a Markdown file and convert it to PDF using Pandoc
258-
4. Save the resulting PDF in your workspace
259-
260-
The PDF will be formatted according to the template in `resume_template.md`, which you can customize to match your preferred style.
253+
1. Find tailored/optimized section files inside `cv-workspace`
254+
2. Prompt you to pick one if multiple exist
255+
3. Ask for a template if you haven't specified one (workspace templates take priority)
256+
4. Render the sections into a styled HTML resume and convert it to PDF under `cv-workspace/output`
261257

262258
### 5. Exportar a PDF
263259
```bash
264-
# Exportar a PDF (requiere Pandoc y LaTeX)
260+
# Exportar usando la última versión y el template por defecto
265261
resumecraftr export-pdf
266262

267-
# Exportar a PDF en español
268-
resumecraftr export-pdf --translate ES
269-
270-
# Exportar a PDF usando un archivo Markdown existente (sin llamar a OpenAI)
271-
resumecraftr export-pdf --skip-md-gen
263+
# Exportar eligiendo secciones y template personalizados
264+
resumecraftr export-pdf --sections mi_cv.tailored_sections.json --template modern --output cv-final.pdf
272265
```
273266

274-
La opción `--skip-md-gen` es especialmente útil cuando:
275-
- Necesitas depurar problemas con Pandoc/LaTeX sin tener que esperar a la generación del Markdown
276-
- Quieres hacer ajustes manuales al archivo Markdown y volver a generar el PDF rápidamente
277-
- Ya tienes un archivo Markdown que quieres usar directamente
267+
### Custom templates
268+
269+
You can override the packaged HTML templates by creating `cv-workspace/templates/pdf/` and dropping your own `.html` files there.
270+
271+
1. Copy the bundled `modern.html` into that directory (the CLI copies it automatically during setup).
272+
2. Tweak the CSS/HTML to match your desired layout.
273+
3. Export with `resumecraftr export-pdf --template my_template`.
274+
275+
The CLI searches the workspace directory first, then falls back to the bundled templates.

0 commit comments

Comments
 (0)