MirrorMind is a dual-agent LLM-powered framework that simulates dynamic, multi-turn interview interactions through resume parsing, context-aware generation, and automated evaluation.
Important: All required models (e.g., DeepSeek-R1-Distill-Qwen-14B, gte-qwen-1.5) must be downloaded manually to the specified cache_dir before running. The evaluation script (05_Evaluation.py) also requires a valid DeepSeek API key to function correctly. Please update the corresponding variable in the code (DEEPSEEK_API_KEY) prior to execution.
| Script File | Role Description |
|---|---|
01_OCR_extract_1.py |
Extracts raw and cleaned text from resume PDFs using OCR, saves to ./CV/ |
02_LLM_infer_1.py |
Uses local LLM to structure cleaned resume text (*_cleaned.txt) into JSON |
03_MAIN_1.py |
Combines OCR + structuring into one integrated pipeline from PDF to JSON |
04_MaterialsGen_1Model.py |
Performs 10-round dual-agent RAG-enhanced interview simulation using CV.json and require.txt |
05_Evaluation.py |
Uses LLM API to perform multidimensional evaluation of dialogue in chat.txt |
./CV/
├── 1.pdf ← Input: Resume PDF
├── 1.txt ← OCR raw output
├── 1_cleaned.txt ← Cleaned lines for LLM structuring
├── 1RESULT.txt ← Output: Resume info in JSON format
./Recordings/
├── CV.json ← Resume structuring result
├── require.txt ← Job description
chat.txt ← Chat history (for evaluation)
entire.txt ← Full model output logs
monitor.txt ← Resource usage logs
- Python 3.8+
- Dependencies:
pip install torch transformers openai pynvml pytesseract pdf2image opencv-python scikit-learn
Extract resume text from PDF using OCR and text cleaning.
python 01_OCR_extract_1.py./CV/YourResume.pdf
./CV/YourResume.txt → → → Raw OCR text output
./CV/YourResume_cleaned.txt → → → Cleaned lines used for LLM structuring
- Tesseract OCR via pytesseract
- pdf2image for PDF-to-image conversion
- OpenCV (cv2) for grayscale processing
Use a local large language model (LLM) to extract and structure key resume information into JSON format.
python 02_LLM_infer_1.py./CV/YourResume_cleaned.txt
./CV/YourResumeRESULT.txt → → → Resume structuring result
./Recordings/CV.json → → → Resume structuring result from combined script 03_MAIN_1.py
- THUDM/glm-4-9b-chat-hf
- PyTorch (CUDA enabled)
Simulate a 10-round interview between an LLM-powered interviewer and interviewee using structured resume data and job descriptions. The system leverages retrieval-augmented generation (RAG) to enhance context relevance.
python 04_MaterialsGen_1Model.py./Recordings/CV.json → → → Structured resume (from Step 2)
./Recordings/require.txt → → → Job description text
chat.txt → → → Final 10-round interactions (for evaluation)
entire.txt → → → Raw prompt + LLM response logs
monitor.txt → → → System resource usage per stage
- deepseek-ai/DeepSeek-R1-Distill-Qwen-14B (LLM for roles)
- thenlper/gte-qwen-1.5-7b-instruct (retriever model for RAG)
- cosine_similarity from scikit-learn for vector matching
- Resource monitor: psutil, torch.cuda, datetime
Automatically evaluate the most recent multi-turn interview session from chat.txt using an LLM-based qualitative assessment framework. The evaluator provides feedback across realism, question quality, answer quality, and overall performance.
python 05_Evaluation.pychat.txt → → → Multi-turn interview interactions generated from Step 3
Console Output → → → JSON-formatted evaluation result
- DeepSeek Reasoner API (deepseek-reasoner)
- OpenAI-compatible Python SDK (openai)
