自动解析微信窗口的聊天内容,结合AI大模型,生成回复建议。
Project description
wechat-copilot
自动解析微信窗口的聊天内容,结合 AI 大模型,生成回复建议。
快速安装
pip install wechat-copilot
配置
- 创建配置文件:
mkdir -p ~/.wechat-copilot
touch ~/.wechat-copilot/config.env
- 编辑配置文件
~/.wechat-copilot/config.env:
# 必填:OpenAI API密钥
OPENAI_API_KEY=your_key_here
# 可选:OpenAI API地址(默认为 https://api.openai.com/v1)
OPENAI_BASE_URL=https://api.openai.com/v1
# 可选:快捷键设置(默认为 cmd+shift+space)
SHORTCUT=cmd+shift+space
使用方法
- 运行助手:
wechat-copilot
- 打开微信聊天窗口
- 快捷键:
cmd+shift+space触发 - GPT 会根据聊天内容生成回复建议,以系统通知的方式展示,自动复制到剪贴板
- 粘贴文本到聊天框,自行决定二次编辑
开发者指南
如果你想参与开发:
git clone https://github.com/yourusername/wechat-copilot.git
cd wechat-copilot
pip install -e ".[dev]"
核心思路
- 使用
pyobjc获取微信窗口的聊天内容 - 使用
openai的 API 生成回复建议 - 使用
osascript生成系统通知 - 使用
pyperclip自动复制到剪贴板
喜欢的话,可以点个 ��star🌟 支持一下。感谢感谢。
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
wechat_copilot-0.0.1.tar.gz
(8.1 MB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file wechat_copilot-0.0.1.tar.gz.
File metadata
- Download URL: wechat_copilot-0.0.1.tar.gz
- Upload date:
- Size: 8.1 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ba2fa48a581d36c49dc23b2802569a53cbeb4a1981d4b10d4645f0e852a00cd9
|
|
| MD5 |
293e87dc2c67b7b81a9fa9e63af50a77
|
|
| BLAKE2b-256 |
911c6ab75fe5500c837a43e3ff1839753b1a64d8e836492fe1cd874eb8dda79f
|
File details
Details for the file wechat_copilot-0.0.1-py3-none-any.whl.
File metadata
- Download URL: wechat_copilot-0.0.1-py3-none-any.whl
- Upload date:
- Size: 8.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d69f89a173d92daa5b79d715fdd58e71f4b0d441e9157a55247e3f7410e8ec22
|
|
| MD5 |
b0e0b5f030997cbacf0266d175eccc3e
|
|
| BLAKE2b-256 |
2ab518ce73e07a7af3f755c8da697e9ed793e80d5bd0f320383527f60be34039
|