AI 驱动的简历分析系统,自动解析 PDF 简历,提取关键信息,并利用大语言模型与岗位需求进行匹配评分。
- PDF 简历解析 - 支持多页 PDF 简历文本提取
- 关键信息提取 - AI 自动提取姓名、联系方式、教育背景、工作经历等
- 岗位匹配评分 - 计算简历与岗位描述的匹配度
- Redis 缓存 - 相同简历避免重复分析
- RESTful API - 便于与其他系统集成
┌─────────────┐ ┌─────────────┐ ┌─────────────┐
│ Streamlit │────▶│ FastAPI │────▶│ LLM API │
│ 前端界面 │ │ 后端服务 │ │ (通义千问) │
└─────────────┘ └──────┬──────┘ └─────────────┘
│
┌─────▼─────┐
│ Redis │
│ 缓存 │
└───────────┘
.
├── backend/ # FastAPI 后端
│ ├── app/
│ │ ├── api/ # API 接口
│ │ ├── core/ # 配置与 Redis
│ │ ├── schemas/ # Pydantic 模型
│ │ ├── services/ # 业务逻辑
│ │ └── main.py # 应用入口
│ ├── .env.example # 环境变量示例
│ ├── Dockerfile # Docker 镜像
│ ├── s.yaml # Serverless Devs 配置
│ └── requirements.txt
│
├── frontend/ # Streamlit 前端
│ ├── .streamlit/ # Streamlit 配置
│ ├── app.py # 主应用
│ └── requirements.txt
│
├── install.sh # Linux/Mac 安装脚本
├── install.bat # Windows 安装脚本
├── .gitignore
├── LICENSE
└── README.md
- Python 3.11+
- Docker(用于部署)
- 阿里云账号:
- 函数计算 FC
- KVStore Redis
- DashScope(通义千问 API)
# 1. 进入后端目录
cd backend
# 2. 创建虚拟环境
python -m venv venv
# 3. 激活虚拟环境
# Linux/Mac:
source venv/bin/activate
# Windows:
venv\Scripts\activate
# 4. 安装依赖
pip install -r requirements.txt
# 5. 配置环境变量
cp .env.example .env
# 编辑 .env 填入你的配置
# 6. 本地运行
python -m app.main
# 服务启动于 http://localhost:8000# 1. 进入前端目录
cd frontend
# 2. 创建虚拟环境
python -m venv venv
# 3. 激活虚拟环境
source venv/bin/activate # Linux/Mac
venv\Scripts\activate # Windows
# 4. 安装依赖
pip install -r requirements.txt
# 5. 运行 Streamlit
streamlit run app.py
# 打开 http://localhost:8501# Linux/Mac
chmod +x install.sh
./install.sh
# Windows
install.batcurl -X POST "https://your-fc-endpoint.aliyuncs.com/api/v1/resume/upload" \
-F "file=@resume.pdf" \
-F "job_description=要求3年以上Python开发经验..."{
"data": {
"resume_info": {
"name": "张三",
"phone": "13800138000",
"email": "zhangsan@example.com",
"job_intention": "Python开发工程师",
"expected_salary": "20K-30K",
"work_years": "5年",
"education": "本科"
},
"match_result": {
"skill_match_rate": 85,
"experience_relevance": 90,
"overall_score": 87,
"matched_skills": ["Python", "FastAPI", "Redis"],
"missing_skills": ["Docker"],
"recommendation": "推荐进入面试环节"
}
},
"cached": false
}cd backend
# 构建镜像
docker build -t your-dockerhub/resume-backend:latest .
# 推送到 Docker Hub
docker push your-dockerhub/resume-backend:latest# 1. 修改 s.yaml 中的镜像地址
# 2. 使用 Serverless Devs 部署
s deploy
# 3. 在 FC 控制台配置环境变量方案一:Streamlit Community Cloud
- 推送到 GitHub
- 连接到 streamlit.io
方案二:Docker 部署
docker run -p 8501:8501 your-dockerhub/resume-frontend:latest| 变量名 | 说明 | 必填 |
|---|---|---|
DASHSCOPE_API_KEY |
阿里云通义千问 API Key | 是 |
REDIS_HOST |
Redis 服务器地址 | 是 |
REDIS_PORT |
Redis 端口(默认:6379) | 是 |
REDIS_PASSWORD |
Redis 密码 | 是 |
REDIS_DB |
Redis 数据库编号(默认:0) | 否 |
- 后端:FastAPI、PyMuPDF、Redis、DashScope
- 前端:Streamlit
- 部署:阿里云函数计算 FC(Custom Container)、Serverless Devs
MIT License - 详见 LICENSE