An automated tool for generating personalized cover letters and organizing job applications using AI. This script uses Anthropic's Claude API to intelligently select relevant experiences and craft tailored cover letters based on job descriptions.
- AI-Powered Cover Letter Generation: Uses Claude to select the most relevant experiences from your portfolio and generate personalized opening paragraphs
- Automated Organization: Creates structured directories for each job application
- Template-Based System: Uses LaTeX templates for professional formatting
- Batch Processing: Process multiple job postings from a single input file
- Python 3.7+
- An Anthropic API key
- LaTeX distribution (for compiling cover letters)
- Required Python packages (see Installation)
-
Clone this repository:
git clone <repository-url> cd application-automater
-
Install required dependencies:
pip install anthropic python-dotenv pyyaml pathvalidate
-
Create a
.envfile in the project root with your Anthropic API key:ANTHROPIC_API_KEY=your_api_key_here -
Configure the paths in
scriptConfig.yaml:- Update
jobApplicationsPathto your desired output directory (default:./job_applications) - Update
jobPostingsPathto point to your job postings file (default:./job_applications/postings.txt) - Update
resumePathentries for each job type to point to your resume files - Update
jobTypesnames to match your job categories
- Update
-
Customize
coverLetterTemplate.tex:- Replace
Your Name,Your Phone Number, andyour.email@example.comwith your actual contact information
- Replace
-
Customize
coverLetterParagraphsRepo.yaml:- Replace the template paragraphs with your own experiences and skills
- Fill in all
[placeholder]brackets with your actual information - Each entry should have a
summary(used for matching) and aparagraph(used in the cover letter) - The
<company>placeholder in paragraphs will be automatically replaced with the target company name
Create a text file (e.g., postings.txt) with job postings separated by the delimiter specified in scriptConfig.yaml (default: $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$).
Each job posting should contain 6 fields in order:
- Title
- Description (full job description)
- Position
- Company
- Location
- Job Type (must match a
nameinjobTypesfromscriptConfig.yaml)
Example:
Software Engineering Intern
We are looking for a software engineering intern...
Intern
Tech Company Inc.
San Francisco, CA
job_type_1
$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
Note: The job type (last field) must match one of the name values in jobTypes from scriptConfig.yaml.
Simply run:
python script.pyThe script will:
- Parse all job postings from the configured file
- For each posting:
- Create a directory structure:
{jobApplicationsPath}/{company}/{title}__{location}/ - Copy the appropriate resume based on job type
- Copy and populate the cover letter template
- Use AI to select the 2 most relevant experiences
- Generate a personalized opening paragraph
- Fill in all placeholders in the cover letter
- Create a directory structure:
After running, you'll have a directory structure like:
job_applications/
└── Company Name/
└── Job Title__Location/
├── Cover_Letter.tex
└── Resume.tex
jobApplicationsPath: Base directory where application folders will be createdjobPostingsPath: Path to the file containing job postingscoverLetterTemplatePath: Path to the LaTeX cover letter templatejobTypes: List of job types, each with anameand correspondingresumePathdelimiter: String used to separate job postings in the input filecoverLetterOpeningParagraphPrompt: Prompt template for generating opening paragraphscoverLetterChooseParagraphsPrompt: Prompt template for selecting relevant experiences
Contains your portfolio of experiences as templates. Each entry has:
summary: A brief description used by AI to match against job descriptionsparagraph: The full paragraph text that will appear in the cover letter
Important: The template paragraphs contain placeholders in brackets like [Company Name], [Your Role], etc. You must replace these with your actual information before using the tool. The <company> placeholder (with angle brackets) will be automatically replaced with the target company name during processing.
- Job Parsing: The script reads job postings from a text file, splitting on the configured delimiter
- Directory Creation: Creates organized folders for each application
- Experience Selection: Uses Claude AI to analyze the job description and select the 2 most relevant experiences from your portfolio
- Opening Paragraph Generation: AI crafts a personalized opening paragraph incorporating the selected skills
- Template Population: Fills in all placeholders in the LaTeX template with job-specific information
Add entries to the jobTypes list in scriptConfig.yaml:
jobTypes:
- name: your_job_type
resumePath: path/to/your/resume.texEdit the prompt templates in scriptConfig.yaml to change how the AI generates content. The prompts use placeholders like {{JOB_DESCRIPTION}} and {{COMPANY_NAME}} that are automatically replaced.
Modify coverLetterTemplate.tex to change the structure and formatting of your cover letters. Placeholders include:
<openingParagraph>: AI-generated opening<firstParagraph>: First selected experience paragraph<secondParagraph>: Second selected experience paragraph<title>,<company>,<location>,<position>: Job details
- The script uses cross-platform path handling and supports both Windows and Unix/Mac systems. Use forward slashes (
/) inscriptConfig.yamlfor Unix/Mac, or backslashes (\\) for Windows. Relative paths (starting with./) work on all platforms. - Ensure your LaTeX distribution is properly installed to compile the generated
.texfiles - The AI uses temperature=1 for more creative outputs; adjust in
script.pyif you want more deterministic results - All template files contain placeholders that must be customized before use