chattool 6.2.0__tar.gz → 6.4.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {chattool-6.2.0/src/chattool.egg-info → chattool-6.4.0}/PKG-INFO +15 -6
- {chattool-6.2.0 → chattool-6.4.0}/README.md +14 -5
- {chattool-6.2.0 → chattool-6.4.0}/pyproject.toml +9 -4
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/__init__.py +3 -4
- chattool-6.4.0/src/chattool/cli_warnings.py +24 -0
- chattool-6.4.0/src/chattool/client/__init__.py +13 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/client/main.py +1 -1
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/config/browser.py +1 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/config/cli.py +223 -113
- chattool-6.4.0/src/chattool/config/elements.py +265 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/config/github.py +1 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/config/main.py +17 -4
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/config/test_cmd.py +2 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/const.py +2 -10
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/setup/alias.py +1 -2
- chattool-6.4.0/src/chattool/setup/assets/nvm.sh +4285 -0
- chattool-6.4.0/src/chattool/setup/cc_connect.py +45 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/setup/claude.py +22 -17
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/setup/codex.py +105 -25
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/setup/elements.py +93 -1
- chattool-6.4.0/src/chattool/setup/lark_cli.py +361 -0
- chattool-6.4.0/src/chattool/setup/nodejs.py +356 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/setup/opencode.py +21 -16
- chattool-6.4.0/src/chattool/setup/playground.py +663 -0
- chattool-6.4.0/src/chattool/skill/__init__.py +1 -0
- {chattool-6.2.0/src/chattool/skills → chattool-6.4.0/src/chattool/skill}/cli.py +17 -8
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/cc/cli.py +55 -52
- chattool-6.4.0/src/chattool/tools/github/cli.py +763 -0
- chattool-6.4.0/src/chattool/tools/lark/__init__.py +7 -0
- chattool-6.4.0/src/chattool/tools/lark/bot.py +1721 -0
- chattool-6.4.0/src/chattool/tools/lark/cli.py +209 -0
- chattool-6.4.0/src/chattool/tools/lark/docx_blocks.py +96 -0
- chattool-6.4.0/src/chattool/tools/lark/markdown_blocks.py +110 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/pypi/__init__.py +2 -6
- chattool-6.4.0/src/chattool/tools/pypi/cli.py +278 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/pypi/main.py +6 -98
- {chattool-6.2.0 → chattool-6.4.0/src/chattool.egg-info}/PKG-INFO +15 -6
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool.egg-info/SOURCES.txt +14 -3
- chattool-6.4.0/src/chattool.egg-info/entry_points.txt +3 -0
- {chattool-6.2.0 → chattool-6.4.0}/tests/test_setup_alias.py +2 -2
- chattool-6.4.0/tests/test_setup_cc_connect.py +34 -0
- {chattool-6.2.0 → chattool-6.4.0}/tests/test_setup_interactive_policy.py +6 -0
- chattool-6.4.0/tests/test_setup_nodejs.py +199 -0
- chattool-6.4.0/tests/test_setup_playground.py +317 -0
- chattool-6.4.0/tests/test_setup_runtime_requirements.py +177 -0
- chattool-6.2.0/src/chattool/client/__init__.py +0 -13
- chattool-6.2.0/src/chattool/config/elements.py +0 -147
- chattool-6.2.0/src/chattool/setup/nodejs.py +0 -111
- chattool-6.2.0/src/chattool/skills/__init__.py +0 -0
- chattool-6.2.0/src/chattool/tools/github/cli.py +0 -264
- chattool-6.2.0/src/chattool/tools/lark/__init__.py +0 -5
- chattool-6.2.0/src/chattool/tools/lark/bot.py +0 -797
- chattool-6.2.0/src/chattool/tools/lark/cli.py +0 -727
- chattool-6.2.0/src/chattool/tools/pypi/cli.py +0 -941
- chattool-6.2.0/src/chattool.egg-info/entry_points.txt +0 -5
- {chattool-6.2.0 → chattool-6.4.0}/LICENSE +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/setup.cfg +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/_all.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/client/cert_client.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/client/svg2gif_client.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/config/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/docker/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/docker/cli.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/docker/elements.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/docker/main.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/explore/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/explore/arxiv/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/explore/arxiv/cli.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/explore/arxiv/client.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/explore/arxiv/daily.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/explore/arxiv/harvest.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/explore/arxiv/models.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/explore/arxiv/presets.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/explore/arxiv/query.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/explore/cli.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/explore/github/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/explore/github/client.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/explore/github/models.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/explore/wordpress/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/explore/wordpress/client.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/explore/wordpress/models.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/llm/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/llm/chattype.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/llm/response.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/mcp/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/mcp/catalog.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/mcp/cli.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/mcp/server.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/serve/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/serve/capture.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/serve/cert_server.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/serve/cli.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/serve/lark_serve.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/serve/svg2gif.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/setup/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/setup/chrome.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/setup/cli.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/setup/frp.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/setup/interactive.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/setup/main.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/browser/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/browser/base.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/browser/cli.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/browser/playwright_impl.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/browser/selenium.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/browser/test_browser.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/browser/test_module.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/browser/test_remote.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/browser/xhs_qrcode.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/cc/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/cert/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/cert/acme_dns_tiny.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/cert/cert_server.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/cert/cert_updater.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/cert/cli.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/dns/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/dns/aliyun.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/dns/base.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/dns/cli.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/dns/ip_updater.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/dns/mcp.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/dns/tencent.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/dns/utils.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/github/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/github/client.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/image/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/image/base.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/image/cli.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/image/huggingface.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/image/liblib.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/image/pollinations.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/image/siliconflow.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/image/tongyi.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/interact.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/lark/context.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/lark/elements.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/lark/session.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/network/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/network/cli.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/network/link_check.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/network/mcp.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/network/scanner.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/tplogin.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/tplogin_cli.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/zulip/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/zulip/cli.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/zulip/client.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/zulip/legacy.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/tools/zulip/mcp.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/utils/__init__.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/utils/basic.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/utils/custom_logger.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/utils/fastobj.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/utils/httpclient.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/utils/test_helpers.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/utils/tui.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool/utils/urltool.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool.egg-info/dependency_links.txt +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool.egg-info/requires.txt +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/src/chattool.egg-info/top_level.txt +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/tests/test_chatenv.py +0 -0
- {chattool-6.2.0 → chattool-6.4.0}/tests/test_import.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: chattool
|
|
3
|
-
Version: 6.
|
|
3
|
+
Version: 6.4.0
|
|
4
4
|
Summary: Toolkit for Chat API
|
|
5
5
|
Author-email: Rex Wang <1073853456@qq.com>
|
|
6
6
|
License: MIT license
|
|
@@ -121,8 +121,11 @@ pip install "chattool[dev]" # 含 MCP 等开发依赖
|
|
|
121
121
|
chatenv init -i # 交互式初始化(敏感字段自动隐藏)
|
|
122
122
|
chatenv init -i -t openai # 仅初始化指定服务
|
|
123
123
|
chatenv cat # 查看配置(敏感值打码)
|
|
124
|
+
chatenv cat -t feishu # 查看飞书配置,供 chattool cc init 默认候选值参考
|
|
124
125
|
chatenv set OPENAI_API_KEY=sk-xxx
|
|
125
|
-
chatenv
|
|
126
|
+
chatenv new mini -t feishu # 从当前激活配置新建并切换到 Feishu profile
|
|
127
|
+
chatenv save work -t openai && chatenv use work -t openai # 按类型管理 profile
|
|
128
|
+
chattool lark info -e work # 显式使用 Feishu profile,优先级高于当前 shell 环境变量
|
|
126
129
|
```
|
|
127
130
|
|
|
128
131
|
### LLM 对话 (`chattool.Chat`)
|
|
@@ -151,7 +154,10 @@ async for chunk in Chat().user("写一首诗").async_get_response_stream():
|
|
|
151
154
|
|
|
152
155
|
```bash
|
|
153
156
|
chattool lark send USER_ID "Hello"
|
|
154
|
-
chattool lark send
|
|
157
|
+
chattool lark send "Hello" # 使用 FEISHU_DEFAULT_RECEIVER_ID
|
|
158
|
+
chattool lark send -t chat_id "Hello team" # 使用 FEISHU_DEFAULT_CHAT_ID
|
|
159
|
+
chattool lark info
|
|
160
|
+
chattool setup lark-cli
|
|
155
161
|
chattool serve lark echo # 回显机器人
|
|
156
162
|
chattool serve lark ai --system "你是工作助手" # AI 对话机器人
|
|
157
163
|
```
|
|
@@ -199,9 +205,10 @@ chattool explore arxiv get 1706.03762 -v
|
|
|
199
205
|
| 工具 | 命令 | 说明 |
|
|
200
206
|
|------|------|------|
|
|
201
207
|
| 网络扫描 | `chattool network` | 扫描局域网主机和端口 |
|
|
202
|
-
| PyPI 工具 | `chattool pypi` |
|
|
208
|
+
| PyPI 工具 | `chattool pypi` | 创建、构建、校验、上传与探测 Python 包 |
|
|
203
209
|
| MCP 服务 | `chattool mcp start` | 标准 MCP Server,供 Claude/Cursor 调用 |
|
|
204
|
-
| 环境安装 | `chattool setup codex/claude` | 安装 Codex / Claude Code 并写入配置 |
|
|
210
|
+
| 环境安装 | `chattool setup codex/claude/lark-cli` | 安装 Codex / Claude Code / 官方 lark-cli 并写入配置 |
|
|
211
|
+
| Playground | `chattool setup playground` | 初始化工作区,并可在完成后复用 `chatenv` 中的 GitHub token 配置 Git HTTPS 鉴权 |
|
|
205
212
|
| Skills | `chattool skill install` | 安装 ChatTool skills 到 Codex / Claude Code |
|
|
206
213
|
| CC-Connect | `chattool cc` | cc-connect 快速配置与启动 |
|
|
207
214
|
|
|
@@ -214,9 +221,11 @@ PyPI 发布命令设计草案见 `docs/design/chattool-pypi-cli-design.md`
|
|
|
214
221
|
快速建包可直接运行:
|
|
215
222
|
|
|
216
223
|
```bash
|
|
217
|
-
chattool pypi init
|
|
224
|
+
chattool pypi init mychat
|
|
218
225
|
```
|
|
219
226
|
|
|
227
|
+
`chattool pypi` 现在只保留最小命令集:`init/build/check/upload/probe`。其中 `upload` 只是对原始 `twine upload` 的薄封装,不再接管凭证、仓库和交互逻辑。
|
|
228
|
+
|
|
220
229
|
## 开源协议
|
|
221
230
|
|
|
222
231
|
MIT License
|
|
@@ -38,8 +38,11 @@ pip install "chattool[dev]" # 含 MCP 等开发依赖
|
|
|
38
38
|
chatenv init -i # 交互式初始化(敏感字段自动隐藏)
|
|
39
39
|
chatenv init -i -t openai # 仅初始化指定服务
|
|
40
40
|
chatenv cat # 查看配置(敏感值打码)
|
|
41
|
+
chatenv cat -t feishu # 查看飞书配置,供 chattool cc init 默认候选值参考
|
|
41
42
|
chatenv set OPENAI_API_KEY=sk-xxx
|
|
42
|
-
chatenv
|
|
43
|
+
chatenv new mini -t feishu # 从当前激活配置新建并切换到 Feishu profile
|
|
44
|
+
chatenv save work -t openai && chatenv use work -t openai # 按类型管理 profile
|
|
45
|
+
chattool lark info -e work # 显式使用 Feishu profile,优先级高于当前 shell 环境变量
|
|
43
46
|
```
|
|
44
47
|
|
|
45
48
|
### LLM 对话 (`chattool.Chat`)
|
|
@@ -68,7 +71,10 @@ async for chunk in Chat().user("写一首诗").async_get_response_stream():
|
|
|
68
71
|
|
|
69
72
|
```bash
|
|
70
73
|
chattool lark send USER_ID "Hello"
|
|
71
|
-
chattool lark send
|
|
74
|
+
chattool lark send "Hello" # 使用 FEISHU_DEFAULT_RECEIVER_ID
|
|
75
|
+
chattool lark send -t chat_id "Hello team" # 使用 FEISHU_DEFAULT_CHAT_ID
|
|
76
|
+
chattool lark info
|
|
77
|
+
chattool setup lark-cli
|
|
72
78
|
chattool serve lark echo # 回显机器人
|
|
73
79
|
chattool serve lark ai --system "你是工作助手" # AI 对话机器人
|
|
74
80
|
```
|
|
@@ -116,9 +122,10 @@ chattool explore arxiv get 1706.03762 -v
|
|
|
116
122
|
| 工具 | 命令 | 说明 |
|
|
117
123
|
|------|------|------|
|
|
118
124
|
| 网络扫描 | `chattool network` | 扫描局域网主机和端口 |
|
|
119
|
-
| PyPI 工具 | `chattool pypi` |
|
|
125
|
+
| PyPI 工具 | `chattool pypi` | 创建、构建、校验、上传与探测 Python 包 |
|
|
120
126
|
| MCP 服务 | `chattool mcp start` | 标准 MCP Server,供 Claude/Cursor 调用 |
|
|
121
|
-
| 环境安装 | `chattool setup codex/claude` | 安装 Codex / Claude Code 并写入配置 |
|
|
127
|
+
| 环境安装 | `chattool setup codex/claude/lark-cli` | 安装 Codex / Claude Code / 官方 lark-cli 并写入配置 |
|
|
128
|
+
| Playground | `chattool setup playground` | 初始化工作区,并可在完成后复用 `chatenv` 中的 GitHub token 配置 Git HTTPS 鉴权 |
|
|
122
129
|
| Skills | `chattool skill install` | 安装 ChatTool skills 到 Codex / Claude Code |
|
|
123
130
|
| CC-Connect | `chattool cc` | cc-connect 快速配置与启动 |
|
|
124
131
|
|
|
@@ -131,9 +138,11 @@ PyPI 发布命令设计草案见 `docs/design/chattool-pypi-cli-design.md`
|
|
|
131
138
|
快速建包可直接运行:
|
|
132
139
|
|
|
133
140
|
```bash
|
|
134
|
-
chattool pypi init
|
|
141
|
+
chattool pypi init mychat
|
|
135
142
|
```
|
|
136
143
|
|
|
144
|
+
`chattool pypi` 现在只保留最小命令集:`init/build/check/upload/probe`。其中 `upload` 只是对原始 `twine upload` 的薄封装,不再接管凭证、仓库和交互逻辑。
|
|
145
|
+
|
|
137
146
|
## 开源协议
|
|
138
147
|
|
|
139
148
|
MIT License
|
|
@@ -105,9 +105,7 @@ Repository = "https://github.com/cubenlp/chattool"
|
|
|
105
105
|
|
|
106
106
|
[project.scripts]
|
|
107
107
|
chattool = "chattool.client:main_cli"
|
|
108
|
-
|
|
109
|
-
mcp-server-chattool = "chattool.mcp:main"
|
|
110
|
-
chatskill = "chattool.skills.cli:main"
|
|
108
|
+
chatmcp = "chattool.mcp:main"
|
|
111
109
|
|
|
112
110
|
[tool.setuptools.dynamic]
|
|
113
111
|
version = {attr = "chattool.__version__"}
|
|
@@ -118,6 +116,9 @@ where = ["src"]
|
|
|
118
116
|
[tool.setuptools]
|
|
119
117
|
include-package-data = true
|
|
120
118
|
|
|
119
|
+
[tool.setuptools.package-data]
|
|
120
|
+
"chattool.setup" = ["assets/*.sh"]
|
|
121
|
+
|
|
121
122
|
[tool.pytest.ini_options]
|
|
122
123
|
markers = [
|
|
123
124
|
"integration: mark test as integration test",
|
|
@@ -130,6 +131,10 @@ filterwarnings = [
|
|
|
130
131
|
"ignore::DeprecationWarning:alibabacloud_tea_openapi.*",
|
|
131
132
|
"ignore::DeprecationWarning:tencentcloud.*",
|
|
132
133
|
"ignore::UserWarning:tencentcloud.*",
|
|
134
|
+
"ignore:pkg_resources is deprecated as an API.*:UserWarning",
|
|
135
|
+
"ignore:Deprecated call to `pkg_resources\\.declare_namespace.*:DeprecationWarning",
|
|
136
|
+
"ignore:datetime\\.datetime\\.utcfromtimestamp\\(\\) is deprecated.*:DeprecationWarning",
|
|
133
137
|
"ignore:websockets.legacy is deprecated:DeprecationWarning",
|
|
134
|
-
"ignore:websockets.server.WebSocketServerProtocol is deprecated:DeprecationWarning"
|
|
138
|
+
"ignore:websockets.server.WebSocketServerProtocol is deprecated:DeprecationWarning",
|
|
139
|
+
"ignore:websockets.InvalidStatusCode is deprecated:DeprecationWarning"
|
|
135
140
|
]
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
__author__ = """Rex Wang"""
|
|
4
4
|
__email__ = '1073853456@qq.com'
|
|
5
|
-
__version__ = '6.
|
|
5
|
+
__version__ = '6.4.0'
|
|
6
6
|
|
|
7
7
|
from dotenv import load_dotenv
|
|
8
8
|
|
|
@@ -12,15 +12,14 @@ from .utils import (
|
|
|
12
12
|
create_env_file, setup_logger, setup_jupyter_async,
|
|
13
13
|
HTTPClient, HTTPConfig
|
|
14
14
|
)
|
|
15
|
-
from .const import CHATTOOL_REPO_DIR, CHATTOOL_ENV_FILE
|
|
15
|
+
from .const import CHATTOOL_REPO_DIR, CHATTOOL_ENV_DIR, CHATTOOL_ENV_FILE
|
|
16
16
|
from .config import OpenAIConfig, AzureConfig, AliyunConfig, TencentConfig, ZulipConfig, BaseEnvConfig
|
|
17
17
|
from .tools import LarkBot, AliyunDNSClient, TencentDNSClient, DynamicIPUpdater, SSLCertUpdater
|
|
18
18
|
|
|
19
19
|
setup_jupyter_async()
|
|
20
20
|
load_dotenv(CHATTOOL_REPO_DIR / '.env')
|
|
21
21
|
|
|
22
|
-
|
|
23
|
-
BaseEnvConfig.load_all(CHATTOOL_ENV_FILE)
|
|
22
|
+
BaseEnvConfig.load_all(CHATTOOL_ENV_DIR, legacy_env_file=CHATTOOL_ENV_FILE)
|
|
24
23
|
|
|
25
24
|
|
|
26
25
|
__all__ = [
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"""Shared warning filters for ChatTool CLI entrypoints."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
|
|
5
|
+
import warnings
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
def install_cli_warning_filters() -> None:
|
|
9
|
+
"""Hide noisy third-party warnings that do not affect CLI behavior."""
|
|
10
|
+
warnings.filterwarnings(
|
|
11
|
+
"ignore",
|
|
12
|
+
message="pkg_resources is deprecated as an API.*",
|
|
13
|
+
category=UserWarning,
|
|
14
|
+
)
|
|
15
|
+
warnings.filterwarnings(
|
|
16
|
+
"ignore",
|
|
17
|
+
message=r"Deprecated call to `pkg_resources\.declare_namespace.*",
|
|
18
|
+
category=DeprecationWarning,
|
|
19
|
+
)
|
|
20
|
+
warnings.filterwarnings(
|
|
21
|
+
"ignore",
|
|
22
|
+
message="There is no current event loop",
|
|
23
|
+
category=DeprecationWarning,
|
|
24
|
+
)
|
|
@@ -67,7 +67,7 @@ cli._lazy_commands.update({
|
|
|
67
67
|
"gh": lambda: _load_attr("chattool.tools.github.cli", "cli"),
|
|
68
68
|
"browser": lambda: _load_attr("chattool.tools.browser.cli", "cli"),
|
|
69
69
|
"zulip": lambda: _load_attr("chattool.tools.zulip.cli", "cli"),
|
|
70
|
-
"skill": lambda: _load_attr("chattool.
|
|
70
|
+
"skill": lambda: _load_attr("chattool.skill.cli", "skill_cli"),
|
|
71
71
|
"setup": lambda: _load_attr("chattool.setup.cli", "setup_group"),
|
|
72
72
|
"cc": lambda: _load_attr("chattool.tools.cc.cli", "cli"),
|
|
73
73
|
"docker": lambda: _load_attr("chattool.docker.cli", "docker_cmd"),
|