An agent template for turning a Chinese resume PDF or text resume into an English CV and Overleaf-ready LaTeX.
The workflow is designed for students and early-career candidates who want a clean, focused CV without learning LaTeX first. It preserves the spirit of concise Chinese resume templates such as "职途": clear sections, strong bullet points, compact layout, and no decorative clutter.
- Reads a Chinese resume PDF or pasted resume text.
- Extracts education, experience, projects, skills, awards, and contact details.
- Rewrites the content into polished English CV language.
- Generates LaTeX code that can be pasted into Overleaf.
- Guides the user through Overleaf project creation, code replacement, recompilation, and final checks.
Install the project:
pip install -e .Set your OpenAI API key:
export OPENAI_API_KEY="your-api-key"Run the agent:
python3 -m overleaf_agent --input resume.pdf --target "data analyst internship" --out outputsThe agent writes:
outputs/facts.jsonoutputs/cv_draft.mdoutputs/resume.texoutputs/overleaf_steps.md
You can also use text input:
python3 -m overleaf_agent --input resume.md --target "master's application" --out outputs- Open ChatGPT or your preferred agent builder.
- Copy the instructions from agent/custom-gpt-instructions.md.
- Upload a Chinese resume PDF or paste resume text.
- Ask the agent to first produce the English CV content.
- Ask the agent to generate Overleaf-ready LaTeX.
- Open Overleaf, create a new blank project, delete the starter code, paste the LaTeX, then click Recompile.
Use this prompt:
I uploaded my Chinese resume PDF. Please extract all useful resume information and organize it into a structured English CV outline. Do not generate LaTeX yet.
Use this prompt:
Please rewrite the extracted content into a polished one-page English CV for international job or graduate-school applications. Keep it concise, achievement-oriented, and faithful to the original facts.
Use this prompt:
Please generate complete Overleaf-ready LaTeX code for this English CV. Use a clean one-page layout, compact spacing, and ATS-friendly section names.
- Go to Overleaf.
- Select New Project.
- Choose Blank Project.
- Name the project, such as
English CV. - Delete the default blue starter code.
- Paste the LaTeX code generated by the agent.
- Click Recompile.
- Review the PDF preview and manually adjust details if needed.
overleaf_agent/
cli.py Command-line entry point
loop.py Agent loop: extract -> draft -> latex -> review -> save
llm.py OpenAI Responses API wrapper
pdf.py PDF/text input reader
prompts.py Prompt templates
latex.py LaTeX cleanup and validation helpers
files.py Output file helpers
tests/
test_latex.py
test_loop.py
test_input_reader.py
agent/
custom-gpt-instructions.md Custom GPT builder instructions
system-prompt.md Portable system prompt for other agents
user-prompts.md Copyable prompt sequence for users
templates/
resume.tex Clean Overleaf LaTeX template
resume-cn-to-en-notes.md Translation and editing rules
examples/
input-brief.md Example source resume summary
output-latex.tex Example generated LaTeX
docs/
overleaf-workflow.md Detailed Overleaf guide
quality-checklist.md Final review checklist
The agent should produce CVs that are:
- Fact-faithful: never invent school names, dates, employers, awards, metrics, or technologies.
- Concise: prioritize one page unless the user explicitly asks for two.
- English-native: use natural resume verbs, not literal machine translation.
- ATS-friendly: avoid icons, images, progress bars, and unusual section labels.
- Overleaf-ready: return complete LaTeX, not fragments.
MIT