Files
wechat_crawler/项目说明.md
李顺东 b66bac7ca8 feat: Initialize wxauto WeChat automation project with job extraction tools
- Add wxauto package with WeChat UI automation and message handling capabilities
- Implement job_extractor.py for automated job posting extraction from WeChat groups
- Add job_extractor_gui.py providing graphical interface for job extraction tool
- Create comprehensive documentation in Chinese covering GUI usage, multi-group support, and quick start guides
- Add build configuration files (build_exe.py, build_exe.spec) for packaging as standalone executable
- Include utility scripts for WeChat interaction (auto_send_msg.py, get_history.py, receive_file_transfer.py)
- Add project configuration files (pyproject.toml, setup.cfg, requirements.txt)
- Include test files (test_api.py, test_com_fix.py) for API and compatibility validation
- Add Apache 2.0 LICENSE and comprehensive README documentation
- Configure .gitignore to exclude build artifacts, logs, and temporary files
2026-02-11 14:49:38 +08:00

267 lines
5.6 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 微信群岗位信息提取工具
## 项目简介
这是一个基于wxauto和阿里云百炼API的智能招聘信息提取工具可以自动监听微信群消息提取结构化的岗位信息。
## 项目结构
```
.
├── wxauto/ # wxauto核心库
├── job_extractor.py # 命令行版本
├── job_extractor_gui.py # GUI版本推荐
├── test_api.py # API测试工具
├── view_jobs.py # 数据查看工具
├── config.json # 配置文件
├── jobs_data.json # 岗位数据(自动生成)
├── build_exe.py # 打包脚本Python
├── build_exe.spec # PyInstaller配置
├── build.bat # 打包脚本(批处理)
├── run_gui.bat # 快速启动脚本
├── requirements.txt # 依赖列表
├── 岗位提取使用说明.md # 命令行版使用说明
├── GUI版本使用说明.md # GUI版使用说明
└── 项目说明.md # 本文件
```
## 两个版本对比
### 命令行版本 (job_extractor.py)
优点:
- 轻量级,资源占用少
- 适合服务器部署
- 日志输出清晰
缺点:
- 需要命令行操作
- 无可视化界面
- 不够直观
### GUI版本 (job_extractor_gui.py) ⭐推荐
优点:
- 图形化界面,操作简单
- 实时显示岗位列表
- 可查看岗位详情
- 支持数据导出
- 可打包成exe独立运行
缺点:
- 资源占用稍多
- 打包后文件较大
## 快速开始
### 1. 安装依赖
```bash
# 安装wxauto
pip install -e .
# 安装其他依赖
pip install requests
# 如需打包exe
pip install pyinstaller
```
### 2. 配置
编辑 `config.json`
```json
{
"target_group": "招聘信息群",
"bailian_api_url": "https://dashscope.aliyuncs.com/api/v1/services/aigc/text-generation/generation",
"api_key": "your-api-key-here",
"output_file": "jobs_data.json"
}
```
### 3. 运行
#### 方式一GUI版本推荐
```bash
# 直接运行
python job_extractor_gui.py
# 或双击
run_gui.bat
```
#### 方式二:命令行版本
```bash
python job_extractor.py
```
### 4. 打包成EXE可选
```bash
# 方式一:使用批处理脚本
双击 build.bat
# 方式二使用Python脚本
python build_exe.py
# 方式三直接使用PyInstaller
pyinstaller build_exe.spec
```
生成的exe文件在 `dist` 目录下。
## 功能说明
### 核心功能
1. **微信群监听**
- 自动连接微信
- 监听指定群组消息
- 实时处理新消息
2. **智能信息提取**
- 使用百炼API分析消息
- 提取结构化岗位信息
- 支持多种消息格式
3. **数据管理**
- 自动保存岗位数据
- JSON格式存储
- 支持数据导出
### 提取的信息
- 工作名称 (job_name)
- 工作描述 (job_description)
- 工作地点 (job_location)
- 月薪最低 (salary_min)
- 月薪最高 (salary_max)
- 公司名称 (company_name)
- 联系人 (contact_person)
- 联系方式 (contact_info)
### 元数据
每条岗位信息还包含:
- 来源群组
- 发送者
- 提取时间
- 原始消息
## 使用场景
1. **HR招聘**
- 自动收集招聘信息
- 整理岗位数据
- 分析市场行情
2. **求职者**
- 监控招聘群
- 及时获取岗位信息
- 筛选合适机会
3. **猎头公司**
- 批量收集岗位
- 建立岗位数据库
- 提高工作效率
## 技术栈
- **Python 3.9+**
- **wxauto** - 微信自动化
- **tkinter** - GUI界面
- **requests** - HTTP请求
- **阿里云百炼API** - 智能信息提取
- **PyInstaller** - 打包工具
## 系统要求
- 操作系统Windows 10/11
- 微信版本3.9.x
- Python版本3.9+
- 网络需要访问百炼API
## 注意事项
1. **合规使用**
- 仅用于学习和个人使用
- 遵守微信使用规范
- 不得用于商业用途
2. **隐私保护**
- 妥善保管API密钥
- 注意数据安全
- 不要泄露他人信息
3. **稳定性**
- 保持微信登录状态
- 确保网络连接稳定
- 定期备份数据
## 常见问题
### 打包相关
#### Q: 打包后运行报错 "尚未调用 CoInitialize"
A: 这是COM组件初始化问题已在新版本中修复。解决方法
1. 运行 `修复并重新打包.bat` 自动修复并重新打包
2. 或手动安装 `pip install pywin32` 后重新打包
3. 详见 [打包问题修复说明.md](打包问题修复说明.md)
#### Q: 如何验证修复是否成功
A: 运行测试脚本:
```bash
python test_com_fix.py
```
如果所有测试通过,说明修复成功。
详见各版本的使用说明文档:
- [命令行版使用说明](岗位提取使用说明.md)
- [GUI版使用说明](GUI版本使用说明.md)
## 测试工具
### 1. API测试
```bash
python test_api.py
```
测试百炼API连接和提取功能。
### 2. 数据查看
```bash
python view_jobs.py
```
查看已提取的岗位数据,包括统计信息。
## 开发计划
- [ ] 支持多群组同时监听
- [ ] 添加岗位筛选功能
- [ ] 支持导出Excel格式
- [ ] 添加数据统计图表
- [ ] 支持自定义提取字段
- [ ] 添加消息推送功能
## 更新日志
### v1.0 (2026-02-11)
- 初始版本发布
- 支持命令行和GUI两种模式
- 集成百炼API智能提取
- 支持打包成exe
## 许可证
本项目仅供学习交流使用,请勿用于商业用途。
## 免责声明
本工具基于UIAutomation技术开发仅用于技术交流学习。使用本工具产生的任何法律纠纷均与作者无关。请遵守相关法律法规和平台使用规范。