compshare-cli 0.4.3__tar.gz → 0.5.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.
- compshare_cli-0.5.0/CHANGELOG.md +144 -0
- compshare_cli-0.5.0/MANIFEST.in +4 -0
- {compshare_cli-0.4.3/src/compshare_cli.egg-info → compshare_cli-0.5.0}/PKG-INFO +39 -8
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/README.md +32 -3
- compshare_cli-0.5.0/RELEASING.md +29 -0
- compshare_cli-0.5.0/connector/compshare/connector-meta.json +25 -0
- compshare_cli-0.5.0/connector/compshare/icon.svg +32 -0
- compshare_cli-0.5.0/connector/compshare/mcp.json +25 -0
- compshare_cli-0.5.0/connector/compshare/skills/compshare/SKILL.md +182 -0
- compshare_cli-0.5.0/connector/compshare/token-schema.json +44 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/pyproject.toml +8 -4
- compshare_cli-0.5.0/skills/compshare-cli/SKILL.md +388 -0
- compshare_cli-0.5.0/skills/compshare-cli/agents/openai.yaml +4 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/__init__.py +1 -1
- compshare_cli-0.5.0/src/compshare_cli/commands/minimax.py +1133 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/i18n.py +146 -14
- compshare_cli-0.5.0/src/compshare_cli/mcp_server.py +593 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0/src/compshare_cli.egg-info}/PKG-INFO +39 -8
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli.egg-info/SOURCES.txt +15 -1
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli.egg-info/entry_points.txt +1 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli.egg-info/requires.txt +3 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/tests/test_actions.py +1 -1
- compshare_cli-0.5.0/tests/test_mcp_server.py +213 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/tests/test_minimax.py +51 -2
- compshare_cli-0.5.0/tests/test_minimax_media.py +279 -0
- compshare_cli-0.5.0/tests/test_workbuddy_connector.py +69 -0
- compshare_cli-0.4.3/src/compshare_cli/commands/minimax.py +0 -428
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/LICENSE +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/setup.cfg +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/__main__.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/actions.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/api.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/cli.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/commands/__init__.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/commands/bandwidth.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/commands/common.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/commands/doctor.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/commands/feedback.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/commands/image.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/commands/instance.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/commands/storage.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/commands/team.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/config.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/errors.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/insights.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/instance_templates.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/location.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/output.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/parsing.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/remote_jobs.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/runtime.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/sdk.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/ssh.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli/ssh_cache.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli.egg-info/dependency_links.txt +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/src/compshare_cli.egg-info/top_level.txt +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/tests/test_api.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/tests/test_bandwidth.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/tests/test_cli.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/tests/test_config.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/tests/test_feedback.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/tests/test_instance_templates.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/tests/test_location.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/tests/test_output.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/tests/test_parsing.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/tests/test_release_version.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/tests/test_remote_jobs.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/tests/test_sdk.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/tests/test_ssh.py +0 -0
- {compshare_cli-0.4.3 → compshare_cli-0.5.0}/tests/test_ssh_cache.py +0 -0
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
## Unreleased
|
|
4
|
+
|
|
5
|
+
## 0.5.0
|
|
6
|
+
|
|
7
|
+
- 对齐 MiniMax H3 视频 API:支持 480P、4K、最长 30 秒、Skill、静音、水印和模型筛选,
|
|
8
|
+
并允许只传尾帧或仅用素材生成。
|
|
9
|
+
- 新增 Qwen-Image 图片任务与 IndexTTS 2.5 语音任务命令,支持创建、查询、取消、删除、
|
|
10
|
+
参考素材上传与登记,以及图片价格、语音价格和音色管理。
|
|
11
|
+
- 新增视频 Skill 查询、创建、更新和删除命令,并开放对应 MCP 读写分类。
|
|
12
|
+
|
|
13
|
+
## 0.4.4
|
|
14
|
+
|
|
15
|
+
- 新增 WorkBuddy `MCP + Skill` Token 连接器,通过本地 stdio MCP 安全注入 API 公钥/私钥,
|
|
16
|
+
并区分只读、预演和需用户明确确认的写操作。
|
|
17
|
+
|
|
18
|
+
## 0.4.3
|
|
19
|
+
|
|
20
|
+
- 修复 Typer 0.27.2 环境中 CLI 启动时无法导入 `Abort` 的问题。
|
|
21
|
+
|
|
22
|
+
## 0.4.2
|
|
23
|
+
|
|
24
|
+
- 移除 `compshare ask` 产品知识问答功能。
|
|
25
|
+
|
|
26
|
+
## 0.4.1
|
|
27
|
+
|
|
28
|
+
- 将 `minimax create` 的提示词长度上限从 5000 个字符调整为 7000 个字符。
|
|
29
|
+
|
|
30
|
+
## 0.4.0
|
|
31
|
+
|
|
32
|
+
- 新增 `bandwidth` 命令组,支持查询独享带宽与实例 EIP 带宽归属,并通过先询价、
|
|
33
|
+
再确认的流程完成购买、改配、删除和共享/独享带宽切换。
|
|
34
|
+
- 新增 `minimax` 命令组,覆盖 MiniMax H3 视频任务创建、查询、列表、取消以及积分套餐包和
|
|
35
|
+
余额查询;模型 API Key 从独立环境变量读取,创建支持幂等键与预演。
|
|
36
|
+
- 兼容 Typer 0.27.1 的上下文与命令类型,确保 JSON 确认保护、结构化帮助和命令统计正常工作。
|
|
37
|
+
|
|
38
|
+
## 0.3.6
|
|
39
|
+
|
|
40
|
+
- 将 CLI 使用统计和反馈从旧外网 IP 的 `/v1` 接口迁移到 CompShare 外部网关,
|
|
41
|
+
通过 UCloud SDK 签名调用 `CreateCSCLIEvent` 和 `CreateCSCLIFeedback`。
|
|
42
|
+
- 网关拒绝使用统计或反馈请求时,返回明确的服务端错误信息。
|
|
43
|
+
|
|
44
|
+
## 0.3.5
|
|
45
|
+
|
|
46
|
+
- 精简 README 的安装和快速开始内容,新增 CompShare SDK 多语言示例入口。
|
|
47
|
+
- 新增可通过 `npx skills` 安装的 CompShare CLI Agent Skill,覆盖实例、镜像、存储、团队、
|
|
48
|
+
SSH、文件传输和远程任务等主要工作流。
|
|
49
|
+
- 发布版本校验不再依赖 README 中的硬编码版本号,并修正发布文档中的版本更新位置。
|
|
50
|
+
|
|
51
|
+
## 0.3.4
|
|
52
|
+
|
|
53
|
+
- 统一 JSON 顶层契约为 `ok/schema_version/data/meta/error`:错误提供稳定代码,列表使用精简的
|
|
54
|
+
`data.items` 和一致分页元数据,脱敏时返回字段路径;`--json --version` 与 `--json --help`
|
|
55
|
+
也输出 JSON。实例聚焦查询保留资源身份,并为缺失集合返回空数组。
|
|
56
|
+
- `--json`、`--profile` 和 `--show-sensitive` 支持出现在常见的子命令参数位置;参数预解析
|
|
57
|
+
不会跨越 `--`,避免截取远程命令的同名参数。
|
|
58
|
+
- `config list` 明确显示凭证来自配置文件、环境变量或混合来源;仅使用环境变量时不再把空的
|
|
59
|
+
`default` profile 显示为当前凭证。
|
|
60
|
+
- 包版本改为由 `compshare_cli.__version__` 生成,并在发布前统一校验构建元数据、运行时版本、
|
|
61
|
+
README 和 Changelog。
|
|
62
|
+
- 移除用途有限的 `--show-completion`,保留 `--install-completion` 自动安装命令补全。
|
|
63
|
+
- 增加 `instance schedule show` 定时关机查询和 `instance schedule extend --by` 延期能力;
|
|
64
|
+
延期以原计划为基准,并在更新后重新查询验证。
|
|
65
|
+
- 增加纯客户端的 `instance job` 持久化远程任务管理,支持提交、列表、详情、双路日志及字节
|
|
66
|
+
偏移、等待、取消和历史清理;任务使用远端 XDG state 目录,可在本地终端或网络断开后继续
|
|
67
|
+
运行。
|
|
68
|
+
|
|
69
|
+
## 0.3.3
|
|
70
|
+
|
|
71
|
+
- 将语言设置从 `lang` 子命令调整为全局 `--lang zh|en` 选项,并将 `feedback` 在根命令
|
|
72
|
+
帮助中的位置调整到 `config` 与 `doctor` 之间。
|
|
73
|
+
- 增加 `instance cp` 双向复制;使用 `:/path` 标记实例路径,支持本地与实例之间自动认证、
|
|
74
|
+
自动递归的上传和下载,并保留原有 `instance scp` 上传语法兼容性。
|
|
75
|
+
- `--json instance scp` 现在会真实上传,并返回结构化执行结果;`--print` 保持为仅预览。
|
|
76
|
+
- JSON 模式不再启动凭证或危险操作确认提示;需要确认的操作必须显式传入 `--yes`。
|
|
77
|
+
- 交互确认在空输入或无效输入时最多重试三次。
|
|
78
|
+
- 增加标准 `--version` 选项,并改进全局 `--json` 位置错误提示。
|
|
79
|
+
- 实例列表按地域筛选时要求同时指定 `--region` 和 `--zone`,确保调用正确的 Zone 接口。
|
|
80
|
+
- `instance show` 显示实例软件入口;URL 默认脱敏,使用 `--show-sensitive` 后显示。
|
|
81
|
+
- `instance show` 支持按 IP、软件、规格、磁盘、计费、镜像和状态分组聚焦输出,并允许组合查询。
|
|
82
|
+
- 增加纯客户端的实例配置模板;支持本地创建、列表、查看、删除,以及通过
|
|
83
|
+
`instance create --template NAME` 加载并用显式参数覆盖模板值。
|
|
84
|
+
- 移除当前不可用的 `instance monitor` 和独立 `instance software url` 命令。
|
|
85
|
+
- 修正云盘列表误用实例接口的问题,改用 `DescribeCompshareDisk` 并完整显示
|
|
86
|
+
`ResourceId`;已卸载云盘也可被自动定位。
|
|
87
|
+
- 镜像收藏迁移到 `Create/DeleteCompShareImageFavorite`,使用社区镜像 `GroupId`;平台镜像
|
|
88
|
+
列表按类型执行正确的全局分页。
|
|
89
|
+
- 放宽镜像列表、网络检测、软件端口和模型查询中接口不需要的 Region/Zone 限制。
|
|
90
|
+
- 修正团队账单排序字段/方向的接口值,并让欠费汇总沿用列表的时间范围。
|
|
91
|
+
- 开放 Typer 内置的 Bash、Zsh、Fish 和 PowerShell 命令补全安装选项。
|
|
92
|
+
|
|
93
|
+
## 0.3.2
|
|
94
|
+
|
|
95
|
+
- JSON 模式远程命令返回结构化的退出码、标准输出、标准错误及连接/认证错误,不再只打印 SSH 命令。
|
|
96
|
+
- 实例创建默认等待到 `Running`,SSH 连接也会先等待实例运行,避免把创建接口成功误判为实例已就绪。
|
|
97
|
+
- `--json` 固定输出 UTF-8 字节,不再受 Windows GBK 活动代码页影响。
|
|
98
|
+
- `instance ssh` 增加按 profile 和实例隔离的一小时连接信息缓存,减少重复的实例查询。
|
|
99
|
+
|
|
100
|
+
## 0.3.1
|
|
101
|
+
|
|
102
|
+
- 补充 Windows PowerShell 虚拟环境的激活与未激活调用示例,说明 `&`、`.\` 和路径引号的使用条件。
|
|
103
|
+
- `doctor` 在 Windows 上不再将无效的 POSIX 权限位当作配置泄露,改为提示由 Windows ACL 管理权限。
|
|
104
|
+
- Windows 上的交互式 `instance ssh` 使用 OpenSSH askpass 自动填写 API 返回的密码,不再降级为手动输入。
|
|
105
|
+
|
|
106
|
+
## 0.3.0
|
|
107
|
+
|
|
108
|
+
- `instance ssh` 默认自动填写 API 返回的登录密码,并提供 `--no-auto-password` 手动输入开关。
|
|
109
|
+
- 修正 `instance ssh` 和 `instance scp` 将 API 的 Base64 密码字段误当作明文密码的问题。
|
|
110
|
+
- 自动 SSH 登录现在接受首次出现的主机密钥,同时继续拒绝已记录主机的密钥变更。
|
|
111
|
+
- `instance ssh INSTANCE_ID -- COMMAND` 支持自动认证后非交互执行远程命令并透传退出码。
|
|
112
|
+
- 增加 `instance scp INSTANCE_ID LOCAL_PATH REMOTE_PATH`,支持自动认证上传文件及递归上传目录。
|
|
113
|
+
- 增加 `compshare ask QUESTION` 产品问答命令,支持引用来源和完整 JSON 响应。
|
|
114
|
+
- 增加 `compshare feedback bug|suggest MESSAGE`,直接向 Insights 服务提交分类反馈。
|
|
115
|
+
- 增加只包含指令名称、CLI 版本、操作系统和发生时间的异步使用统计。
|
|
116
|
+
- 移除全局默认 Region/Zone;资源位置仅使用请求参数或 API 响应,生命周期操作不再混用查询地域与实例实际可用区。
|
|
117
|
+
- 创建实例时的镜像选择支持完整 API 分页,并使用 `f`/`b` 前后翻页,不再因匹配超过 50 项而中止。
|
|
118
|
+
- 地域型镜像、网络、模型和软件接口会在 CLI 层要求其必需的 Region/Zone,全局接口不再携带无意义的地域参数。
|
|
119
|
+
- 默认递归隐藏密码、IP、访问 URL、令牌和登录命令;新增全局 `--show-sensitive` 以显式显示原始敏感字段。
|
|
120
|
+
|
|
121
|
+
## 0.2.1
|
|
122
|
+
|
|
123
|
+
- 兼容 API 将空列表返回为 `null` 的情况,空结果不再导致命令异常。
|
|
124
|
+
- 凭证配置改用权限受限的唯一临时文件原子写入,并清理写入失败的临时文件。
|
|
125
|
+
- 损坏的凭证配置和空配置名称现在会返回明确的 CLI 错误。
|
|
126
|
+
- 分页兼容 `TotalCount` 和 `Total` 两种总数字段。
|
|
127
|
+
- 非 UTF-8 镜像 README 文件现在会返回可读错误。
|
|
128
|
+
|
|
129
|
+
## 0.2.0
|
|
130
|
+
|
|
131
|
+
- 覆盖团队、邀请、成员额度、团队账单和操作日志的 17 个公开 Action。
|
|
132
|
+
- 支持批量启动、停止、重启、删除实例,并提供独立的 `instance wait`。
|
|
133
|
+
- 修正跨地域实例聚合后的筛选和分页语义,实例与镜像列表支持 `--all`。
|
|
134
|
+
- 增加只读的 `doctor` 环境诊断。
|
|
135
|
+
- 增加 `instance create --max-price` 价格保护。
|
|
136
|
+
- 最低运行版本继续保持 Python 3.9。
|
|
137
|
+
|
|
138
|
+
## 0.1.3
|
|
139
|
+
|
|
140
|
+
- 兼容新版 Typer 与 Click,直接运行 `compshare` 时显示帮助。
|
|
141
|
+
|
|
142
|
+
## 0.1.0
|
|
143
|
+
|
|
144
|
+
- 首次公开版本,支持 GPU 实例、实例镜像、云盘和 US3 挂载。
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: compshare-cli
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.5.0
|
|
4
4
|
Summary: Command-line client for CompShare GPU compute and MiniMax H3
|
|
5
5
|
Author: CompShare
|
|
6
6
|
License-Expression: Apache-2.0
|
|
7
|
-
Project-URL: Homepage, https://github.com/
|
|
8
|
-
Project-URL: Repository, https://github.com/
|
|
9
|
-
Project-URL: Changelog, https://github.com/
|
|
10
|
-
Project-URL: Issues, https://github.com/
|
|
7
|
+
Project-URL: Homepage, https://github.com/compshare-cn/compshare-cli
|
|
8
|
+
Project-URL: Repository, https://github.com/compshare-cn/compshare-cli
|
|
9
|
+
Project-URL: Changelog, https://github.com/compshare-cn/compshare-cli/blob/master/CHANGELOG.md
|
|
10
|
+
Project-URL: Issues, https://github.com/compshare-cn/compshare-cli/issues
|
|
11
11
|
Requires-Python: >=3.9
|
|
12
12
|
Description-Content-Type: text/markdown
|
|
13
13
|
License-File: LICENSE
|
|
@@ -21,18 +21,20 @@ Provides-Extra: dev
|
|
|
21
21
|
Requires-Dist: pytest<10,>=8; extra == "dev"
|
|
22
22
|
Requires-Dist: pytest-cov<8,>=5; extra == "dev"
|
|
23
23
|
Requires-Dist: ruff<1,>=0.6; extra == "dev"
|
|
24
|
+
Provides-Extra: mcp
|
|
25
|
+
Requires-Dist: mcp<3,>=2.2; extra == "mcp"
|
|
24
26
|
Dynamic: license-file
|
|
25
27
|
|
|
26
28
|
# CompShare CLI
|
|
27
29
|
|
|
28
|
-
在终端管理优云智算 GPU 实例、镜像、云盘、US3 挂载、独享带宽、团队资源和 MiniMax H3
|
|
30
|
+
在终端管理优云智算 GPU 实例、镜像、云盘、US3 挂载、独享带宽、团队资源和 MiniMax H3 视频、图片、语音任务。
|
|
29
31
|
|
|
30
32
|
- 交互式创建实例,实时查询规格、库存和价格
|
|
31
33
|
- 支持批量生命周期操作、等待状态和跨地域查询
|
|
32
34
|
- 支持可断线恢复的远程任务、状态查询和增量日志读取
|
|
33
35
|
- 支持社区/自定义镜像、云盘、团队额度与账单
|
|
34
36
|
- 支持独享带宽询价、购买、改配、退款预估及实例 EIP 切换
|
|
35
|
-
-
|
|
37
|
+
- 支持 MiniMax H3 视频、Qwen-Image 图片和 IndexTTS 2.5 语音任务,以及素材上传、视频 Skill 和积分查询
|
|
36
38
|
- 默认中文帮助,可切换英文;所有命令支持 JSON 输出
|
|
37
39
|
- 可通过 `compshare feedback` 反馈 CLI 问题和建议
|
|
38
40
|
|
|
@@ -86,6 +88,18 @@ compshare --json minimax create '一只猫在海边奔跑' --dry-run
|
|
|
86
88
|
compshare --json minimax create '一只猫在海边奔跑' --yes
|
|
87
89
|
compshare --json minimax points
|
|
88
90
|
|
|
91
|
+
# 图片:查看价格、创建任务、查询结果
|
|
92
|
+
compshare --json minimax image config
|
|
93
|
+
compshare --json minimax image create '一只戴着宇航头盔的猫' --resolution 1K --dry-run
|
|
94
|
+
compshare --json minimax image create '一只戴着宇航头盔的猫' --resolution 1K --yes
|
|
95
|
+
compshare --json minimax image show TASK_ID
|
|
96
|
+
|
|
97
|
+
# 语音:先查询可用音色,再创建任务
|
|
98
|
+
compshare --json minimax audio pricing
|
|
99
|
+
compshare --json minimax audio voices
|
|
100
|
+
compshare --json minimax audio create '你好,欢迎使用优云智算。' --voice-id VOICE_ID --dry-run
|
|
101
|
+
compshare --json minimax audio create '你好,欢迎使用优云智算。' --voice-id VOICE_ID --yes
|
|
102
|
+
|
|
89
103
|
# 查看帮助
|
|
90
104
|
compshare -h
|
|
91
105
|
compshare instance -h
|
|
@@ -101,7 +115,7 @@ compshare instance GPU 实例、规格、库存、价格和生命周期
|
|
|
101
115
|
compshare image 平台、自定义、社区及共享镜像
|
|
102
116
|
compshare storage 云盘和 US3 挂载
|
|
103
117
|
compshare bandwidth 独享带宽和实例 EIP 带宽归属
|
|
104
|
-
compshare minimax MiniMax H3
|
|
118
|
+
compshare minimax MiniMax H3 视频、图片、语音、Skill 和积分
|
|
105
119
|
compshare team 团队、邀请、成员额度、账单和审计
|
|
106
120
|
```
|
|
107
121
|
|
|
@@ -115,6 +129,23 @@ npx skills add compshare-cn/compshare-cli --skill compshare-cli
|
|
|
115
129
|
|
|
116
130
|
完整说明见 [CompShare CLI Skill](skills/compshare-cli/SKILL.md)。
|
|
117
131
|
|
|
132
|
+
## WorkBuddy Connector
|
|
133
|
+
|
|
134
|
+
仓库内置符合 WorkBuddy 规范的 `MCP + Skill` Token 连接器,提交目录为
|
|
135
|
+
[`connector/compshare`](connector/compshare)。用户在 WorkBuddy 表单中填写 API 公钥和
|
|
136
|
+
私钥后,连接器通过本地 stdio MCP 注入凭证,不需要 OAuth,也不会修改已有 CLI 配置。
|
|
137
|
+
|
|
138
|
+
WorkBuddy 配置固定使用 Python 3.11;本地开发需 Python 3.10 或更高版本,可安装 MCP 可选
|
|
139
|
+
依赖并启动服务:
|
|
140
|
+
|
|
141
|
+
```bash
|
|
142
|
+
pip install -e '.[mcp]'
|
|
143
|
+
compshare-mcp
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
正式 Connector 使用 `uvx` 从 PyPI 安装固定版本,并将只读、预演和需要明确确认的写操作
|
|
147
|
+
分开暴露。MiniMax H3 使用表单中可选的独立模型 API Key。
|
|
148
|
+
|
|
118
149
|
## SDK
|
|
119
150
|
|
|
120
151
|
如需通过 SDK 集成 CompShare API,可参考独立的
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
# CompShare CLI
|
|
2
2
|
|
|
3
|
-
在终端管理优云智算 GPU 实例、镜像、云盘、US3 挂载、独享带宽、团队资源和 MiniMax H3
|
|
3
|
+
在终端管理优云智算 GPU 实例、镜像、云盘、US3 挂载、独享带宽、团队资源和 MiniMax H3 视频、图片、语音任务。
|
|
4
4
|
|
|
5
5
|
- 交互式创建实例,实时查询规格、库存和价格
|
|
6
6
|
- 支持批量生命周期操作、等待状态和跨地域查询
|
|
7
7
|
- 支持可断线恢复的远程任务、状态查询和增量日志读取
|
|
8
8
|
- 支持社区/自定义镜像、云盘、团队额度与账单
|
|
9
9
|
- 支持独享带宽询价、购买、改配、退款预估及实例 EIP 切换
|
|
10
|
-
-
|
|
10
|
+
- 支持 MiniMax H3 视频、Qwen-Image 图片和 IndexTTS 2.5 语音任务,以及素材上传、视频 Skill 和积分查询
|
|
11
11
|
- 默认中文帮助,可切换英文;所有命令支持 JSON 输出
|
|
12
12
|
- 可通过 `compshare feedback` 反馈 CLI 问题和建议
|
|
13
13
|
|
|
@@ -61,6 +61,18 @@ compshare --json minimax create '一只猫在海边奔跑' --dry-run
|
|
|
61
61
|
compshare --json minimax create '一只猫在海边奔跑' --yes
|
|
62
62
|
compshare --json minimax points
|
|
63
63
|
|
|
64
|
+
# 图片:查看价格、创建任务、查询结果
|
|
65
|
+
compshare --json minimax image config
|
|
66
|
+
compshare --json minimax image create '一只戴着宇航头盔的猫' --resolution 1K --dry-run
|
|
67
|
+
compshare --json minimax image create '一只戴着宇航头盔的猫' --resolution 1K --yes
|
|
68
|
+
compshare --json minimax image show TASK_ID
|
|
69
|
+
|
|
70
|
+
# 语音:先查询可用音色,再创建任务
|
|
71
|
+
compshare --json minimax audio pricing
|
|
72
|
+
compshare --json minimax audio voices
|
|
73
|
+
compshare --json minimax audio create '你好,欢迎使用优云智算。' --voice-id VOICE_ID --dry-run
|
|
74
|
+
compshare --json minimax audio create '你好,欢迎使用优云智算。' --voice-id VOICE_ID --yes
|
|
75
|
+
|
|
64
76
|
# 查看帮助
|
|
65
77
|
compshare -h
|
|
66
78
|
compshare instance -h
|
|
@@ -76,7 +88,7 @@ compshare instance GPU 实例、规格、库存、价格和生命周期
|
|
|
76
88
|
compshare image 平台、自定义、社区及共享镜像
|
|
77
89
|
compshare storage 云盘和 US3 挂载
|
|
78
90
|
compshare bandwidth 独享带宽和实例 EIP 带宽归属
|
|
79
|
-
compshare minimax MiniMax H3
|
|
91
|
+
compshare minimax MiniMax H3 视频、图片、语音、Skill 和积分
|
|
80
92
|
compshare team 团队、邀请、成员额度、账单和审计
|
|
81
93
|
```
|
|
82
94
|
|
|
@@ -90,6 +102,23 @@ npx skills add compshare-cn/compshare-cli --skill compshare-cli
|
|
|
90
102
|
|
|
91
103
|
完整说明见 [CompShare CLI Skill](skills/compshare-cli/SKILL.md)。
|
|
92
104
|
|
|
105
|
+
## WorkBuddy Connector
|
|
106
|
+
|
|
107
|
+
仓库内置符合 WorkBuddy 规范的 `MCP + Skill` Token 连接器,提交目录为
|
|
108
|
+
[`connector/compshare`](connector/compshare)。用户在 WorkBuddy 表单中填写 API 公钥和
|
|
109
|
+
私钥后,连接器通过本地 stdio MCP 注入凭证,不需要 OAuth,也不会修改已有 CLI 配置。
|
|
110
|
+
|
|
111
|
+
WorkBuddy 配置固定使用 Python 3.11;本地开发需 Python 3.10 或更高版本,可安装 MCP 可选
|
|
112
|
+
依赖并启动服务:
|
|
113
|
+
|
|
114
|
+
```bash
|
|
115
|
+
pip install -e '.[mcp]'
|
|
116
|
+
compshare-mcp
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
正式 Connector 使用 `uvx` 从 PyPI 安装固定版本,并将只读、预演和需要明确确认的写操作
|
|
120
|
+
分开暴露。MiniMax H3 使用表单中可选的独立模型 API Key。
|
|
121
|
+
|
|
93
122
|
## SDK
|
|
94
123
|
|
|
95
124
|
如需通过 SDK 集成 CompShare API,可参考独立的
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
# 发布
|
|
2
|
+
|
|
3
|
+
GitHub Release 发布后,`.github/workflows/release.yml` 会构建 wheel 和源码包,并通过
|
|
4
|
+
PyPI Trusted Publishing 自动上传。仓库不需要保存 PyPI Token。
|
|
5
|
+
|
|
6
|
+
## 首次配置
|
|
7
|
+
|
|
8
|
+
在 PyPI 项目 `compshare-cli` 的 Publishing 设置中添加 GitHub Publisher:
|
|
9
|
+
|
|
10
|
+
| 字段 | 值 |
|
|
11
|
+
| --- | --- |
|
|
12
|
+
| Owner | `compshare-cn` |
|
|
13
|
+
| Repository | `compshare-cli` |
|
|
14
|
+
| Workflow | `release.yml` |
|
|
15
|
+
| Environment | `pypi` |
|
|
16
|
+
|
|
17
|
+
## 发布新版本
|
|
18
|
+
|
|
19
|
+
1. 更新 `src/compshare_cli/__init__.py` 中的版本和 `CHANGELOG.md`。
|
|
20
|
+
2. 运行 `ruff check .`、`ruff format --check .` 和 `pytest`。
|
|
21
|
+
3. 创建与包版本一致的标签,例如 `v0.2.2`。
|
|
22
|
+
4. 发布对应的 GitHub Release。
|
|
23
|
+
|
|
24
|
+
工作流会校验标签与包版本是否一致,并运行 `twine check`。相同版本不能重复上传到
|
|
25
|
+
PyPI;失败时应发布新版本,不能覆盖已有文件。
|
|
26
|
+
|
|
27
|
+
如果 GitHub Release 早于自动发布工作流,可以在 Actions 中手动运行
|
|
28
|
+
`Publish to PyPI`,输入已有的 Release 标签补发。工作流会从该标签构建,避免同一版本
|
|
29
|
+
混入标签之后的改动。
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "CompShare",
|
|
3
|
+
"name_zh": "优云智算",
|
|
4
|
+
"name_en": "CompShare",
|
|
5
|
+
"description": "Manage CompShare GPU instances, images, storage, networking, teams, and MiniMax H3 media tasks.",
|
|
6
|
+
"description_zh": "连接优云智算账户,查询和管理 GPU 实例、镜像、存储、网络、团队及 MiniMax H3 视频、图片和语音任务。",
|
|
7
|
+
"description_en": "Manage CompShare GPU instances, images, storage, networking, teams, and MiniMax H3 media tasks.",
|
|
8
|
+
"source": "compshare",
|
|
9
|
+
"type": "mcp",
|
|
10
|
+
"auth_mode": "token",
|
|
11
|
+
"version": "0.5.0",
|
|
12
|
+
"minWorkbuddyVersion": "5.0.0",
|
|
13
|
+
"examples_zh": [
|
|
14
|
+
"查询上海可用的 RTX 4090 GPU 规格、库存和价格",
|
|
15
|
+
"列出我所有运行中的 GPU 实例",
|
|
16
|
+
"先预演一台单卡 4090 实例的创建方案",
|
|
17
|
+
"查看 MiniMax H3 积分余额和正在运行的视频任务"
|
|
18
|
+
],
|
|
19
|
+
"examples_en": [
|
|
20
|
+
"Find available RTX 4090 GPU specifications and prices in Shanghai",
|
|
21
|
+
"List all of my running GPU instances",
|
|
22
|
+
"Preview a one-GPU 4090 instance before creating it",
|
|
23
|
+
"Show my MiniMax H3 point balance and running video tasks"
|
|
24
|
+
]
|
|
25
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64" role="img" aria-label="CompShare">
|
|
2
|
+
<defs>
|
|
3
|
+
<linearGradient id="top" x1="0" y1="0" x2="1" y2="1">
|
|
4
|
+
<stop offset="0" stop-color="#b8c1ff"/>
|
|
5
|
+
<stop offset="1" stop-color="#7372ff"/>
|
|
6
|
+
</linearGradient>
|
|
7
|
+
<linearGradient id="left" x1="0" y1="0" x2="1" y2="1">
|
|
8
|
+
<stop offset="0" stop-color="#dbe0ff"/>
|
|
9
|
+
<stop offset="1" stop-color="#7585ff"/>
|
|
10
|
+
</linearGradient>
|
|
11
|
+
<linearGradient id="right" x1="0" y1="0" x2="1" y2="1">
|
|
12
|
+
<stop offset="0" stop-color="#5b5cff"/>
|
|
13
|
+
<stop offset="1" stop-color="#3329ec"/>
|
|
14
|
+
</linearGradient>
|
|
15
|
+
</defs>
|
|
16
|
+
<g>
|
|
17
|
+
<path fill="url(#top)" d="M32 4 45 11.5 32 19 19 11.5Z"/>
|
|
18
|
+
<path fill="url(#left)" d="M19 11.5 32 19v14L19 25.5Z"/>
|
|
19
|
+
<path fill="url(#right)" d="M32 19 45 11.5v14L32 33Z"/>
|
|
20
|
+
</g>
|
|
21
|
+
<g transform="translate(-12 25)">
|
|
22
|
+
<path fill="url(#top)" d="M32 4 45 11.5 32 19 19 11.5Z"/>
|
|
23
|
+
<path fill="url(#left)" d="M19 11.5 32 19v14L19 25.5Z"/>
|
|
24
|
+
<path fill="url(#right)" d="M32 19 45 11.5v14L32 33Z"/>
|
|
25
|
+
</g>
|
|
26
|
+
<g transform="translate(12 25)">
|
|
27
|
+
<path fill="url(#top)" d="M32 4 45 11.5 32 19 19 11.5Z"/>
|
|
28
|
+
<path fill="url(#left)" d="M19 11.5 32 19v14L19 25.5Z"/>
|
|
29
|
+
<path fill="url(#right)" d="M32 19 45 11.5v14L32 33Z"/>
|
|
30
|
+
</g>
|
|
31
|
+
<path fill="#fff" d="m28 27.2 10 5.8-10 5.8Z"/>
|
|
32
|
+
</svg>
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
{
|
|
2
|
+
"mcpServers": {
|
|
3
|
+
"compshare": {
|
|
4
|
+
"type": "stdio",
|
|
5
|
+
"command": "uvx",
|
|
6
|
+
"args": [
|
|
7
|
+
"--python",
|
|
8
|
+
"3.11",
|
|
9
|
+
"--from",
|
|
10
|
+
"compshare-cli[mcp]==0.5.0",
|
|
11
|
+
"compshare-mcp"
|
|
12
|
+
],
|
|
13
|
+
"env": {
|
|
14
|
+
"COMPSHARE_PUBLIC_KEY": "${COMPSHARE_PUBLIC_KEY}",
|
|
15
|
+
"COMPSHARE_PRIVATE_KEY": "${COMPSHARE_PRIVATE_KEY}",
|
|
16
|
+
"COMPSHARE_MINIMAX_API_KEY": "${COMPSHARE_MINIMAX_API_KEY}"
|
|
17
|
+
},
|
|
18
|
+
"runtime": {
|
|
19
|
+
"type": "node",
|
|
20
|
+
"version": "20"
|
|
21
|
+
},
|
|
22
|
+
"timeout": 60000
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
}
|
|
@@ -0,0 +1,182 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: compshare
|
|
3
|
+
description: Manage CompShare GPU cloud resources and MiniMax H3 media tasks through the controlled CompShare MCP bridge.
|
|
4
|
+
description_zh: 通过受控 CompShare MCP 桥接查询和管理优云智算 GPU 云资源及 MiniMax H3 视频、图片和语音任务。
|
|
5
|
+
description_en: Manage CompShare GPU cloud resources and MiniMax H3 media tasks through the controlled CompShare MCP bridge.
|
|
6
|
+
version: "0.5.0"
|
|
7
|
+
author: "CompShare"
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# CompShare 优云智算
|
|
11
|
+
|
|
12
|
+
通过本 Connector 提供的 MCP 工具查询和管理 GPU 实例、镜像、云盘、US3、独享带宽、
|
|
13
|
+
团队资源与 MiniMax H3 视频、图片和语音任务。凭证由 WorkBuddy Token 表单注入;不要要求用户在对话中
|
|
14
|
+
发送公钥、私钥或模型 API Key。
|
|
15
|
+
|
|
16
|
+
本 Connector 不提供产品知识库问答。用户询问产品文档或政策时,不要猜测,也不要尝试调用
|
|
17
|
+
已移除的 `ask` 命令。
|
|
18
|
+
|
|
19
|
+
## 总规则
|
|
20
|
+
|
|
21
|
+
1. 每个新会话先调用 `compshare_status`,确认 `ok: true`、CLI 版本和 API 连通性。
|
|
22
|
+
2. 参数或命令不确定时先调用 `compshare_help`,不要猜测当前 CLI 的选项、枚举或位置参数。
|
|
23
|
+
3. 查询、结构化帮助、`--dry-run` 和 `--print` 只调用 `compshare_read`。
|
|
24
|
+
4. 创建、付费、修改、删除、远程执行和文件传输只调用 `compshare_write`。
|
|
25
|
+
5. 调用写工具前,向用户展示准确对象、参数、价格或影响,并取得本次明确同意。参数变化后
|
|
26
|
+
旧确认失效,必须重新确认。
|
|
27
|
+
6. 删除、重装、缩容相关操作和磁盘数据处置属于高风险操作。说明不可逆影响,并在读取当前
|
|
28
|
+
资源后再确认。
|
|
29
|
+
7. 写操作只执行一次。超时或连接中断时结果可能已经生效;先查询资源状态,禁止直接重试。
|
|
30
|
+
8. 不使用 `--show-sensitive`,不展示密码、IP、访问 URL、登录命令或任何 Token。需要连接
|
|
31
|
+
实例时,优先让连接器直接执行用户批准的远程命令。
|
|
32
|
+
9. 列表默认可能分页。需要全集时使用 `--all`,或根据 `meta.total`、`meta.returned`、
|
|
33
|
+
`meta.offset` 继续读取,不能把第一页当作全部。
|
|
34
|
+
|
|
35
|
+
## MCP 工具
|
|
36
|
+
|
|
37
|
+
### `compshare_status`
|
|
38
|
+
|
|
39
|
+
检查 WorkBuddy 是否注入 GPU API 公钥/私钥、当前 CLI 版本和 API 连通性。`minimaxApiKey`
|
|
40
|
+
为 `false` 只影响 MiniMax H3 媒体任务,不影响 GPU 资源。认证失败时,让用户在 Connector 设置中更新
|
|
41
|
+
凭证;不要改用 `compshare config`,也不要索取聊天中的明文密钥。
|
|
42
|
+
|
|
43
|
+
```json
|
|
44
|
+
{"timeout_seconds": 30}
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
### `compshare_help`
|
|
48
|
+
|
|
49
|
+
读取 CLI 的结构化真源帮助。`command` 是零到三个命令名,不包含开头的 `compshare`;
|
|
50
|
+
空数组读取根帮助。
|
|
51
|
+
|
|
52
|
+
```json
|
|
53
|
+
{"command": ["instance", "create"]}
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
重点读取 `result.data.command_path`、`result.data.parameters` 和 `result.data.commands`。
|
|
57
|
+
|
|
58
|
+
### `compshare_read`
|
|
59
|
+
|
|
60
|
+
执行白名单内的只读命令、安全预演或仅打印操作。`args` 是 CLI 参数数组,不包含开头的
|
|
61
|
+
`compshare`,也不要加入 `--json`。默认超时 30 秒,最长 900 秒。
|
|
62
|
+
|
|
63
|
+
```json
|
|
64
|
+
{"args": ["instance", "list", "--all"], "timeout_seconds": 30}
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
对原本会写入的命令,只有受支持的 `--dry-run` 或 `--print` 形式才会被只读工具接受。
|
|
68
|
+
|
|
69
|
+
### `compshare_write`
|
|
70
|
+
|
|
71
|
+
执行白名单内的写入、付费、远程命令或文件传输。调用前必须已取得真实用户确认;字段本身
|
|
72
|
+
不能替代确认。
|
|
73
|
+
|
|
74
|
+
```json
|
|
75
|
+
{
|
|
76
|
+
"args": ["instance", "stop", "uhost-example", "--yes", "--timeout", "600"],
|
|
77
|
+
"user_confirmed": true,
|
|
78
|
+
"confirmation_summary": "用户确认停止 uhost-example,并了解运行任务会中断",
|
|
79
|
+
"timeout_seconds": 660
|
|
80
|
+
}
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
CLI 本身要求确认的操作仍需在 `args` 中加入 `--yes`。若返回 `outcome: "unknown"`,按
|
|
84
|
+
`error.action: "check_existing"` 读取资源状态,不要重放写命令。
|
|
85
|
+
|
|
86
|
+
## 返回值
|
|
87
|
+
|
|
88
|
+
成功执行的桥接响应包含:
|
|
89
|
+
|
|
90
|
+
```json
|
|
91
|
+
{
|
|
92
|
+
"ok": true,
|
|
93
|
+
"exitCode": 0,
|
|
94
|
+
"result": {
|
|
95
|
+
"ok": true,
|
|
96
|
+
"schema_version": "1",
|
|
97
|
+
"data": {},
|
|
98
|
+
"meta": {}
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
同时检查桥接层 `ok`、`exitCode` 和 CLI `result.ok`。CLI 失败时,读取
|
|
104
|
+
`result.error.code`、`result.error.message` 和可选的 `result.error.details`。空 `items` 是
|
|
105
|
+
有效结果,不等于工具故障。
|
|
106
|
+
|
|
107
|
+
## 查询与创建实例
|
|
108
|
+
|
|
109
|
+
先查询可用区、镜像与真实库存:
|
|
110
|
+
|
|
111
|
+
```jsonl
|
|
112
|
+
{"args":["instance","zones"]}
|
|
113
|
+
{"args":["image","list","--source","platform","--region","cn-sh2","--zone","cn-sh2-02","--all"]}
|
|
114
|
+
{"args":["instance","search","--region","cn-sh2","--zone","cn-sh2-02","--gpu","4090","--image","IMAGE_ID","--available"]}
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
`instance search` 只有带 `--image` 时才检查真实库存。创建前必须通过只读工具调用
|
|
118
|
+
`instance create --dry-run`,展示选中的规格、库存、价格和请求参数。用户确认后,使用完全
|
|
119
|
+
相同的参数移除 `--dry-run`,加入 `--yes`,再调用写工具。不要在没有用户给定价格保护时
|
|
120
|
+
自行猜测 `--max-price`。
|
|
121
|
+
|
|
122
|
+
JSON 创建至少提供 GPU、每实例 GPU 数、CPU、内存、镜像、Region 和 Zone;不要触发交互
|
|
123
|
+
向导。创建超时后先 `instance list/show`,按幂等标识或创建时间核对,不能立即再次购买。
|
|
124
|
+
|
|
125
|
+
## 实例生命周期和远程任务
|
|
126
|
+
|
|
127
|
+
列表、详情、价格、账单、退款预估和等待状态使用只读工具。启动、停止、重启、删除、改名、
|
|
128
|
+
密码重置、重装、改配、计费变更、端口和定时关机变更使用写工具。
|
|
129
|
+
|
|
130
|
+
远程同步命令必须放在 `--` 后,并按写操作确认:
|
|
131
|
+
|
|
132
|
+
```json
|
|
133
|
+
{
|
|
134
|
+
"args": ["instance", "ssh", "INSTANCE_ID", "--", "nvidia-smi"],
|
|
135
|
+
"user_confirmed": true,
|
|
136
|
+
"confirmation_summary": "用户确认在 INSTANCE_ID 上执行只读的 nvidia-smi",
|
|
137
|
+
"timeout_seconds": 60
|
|
138
|
+
}
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
交互式 SSH 不受 MCP 支持。需要长时间运行的安装、训练或编译任务时,用
|
|
142
|
+
`instance job submit`,不要用同步 SSH。提交后通过 `job show` 或短轮询读取状态;日志使用
|
|
143
|
+
`job logs --tail` 或字节偏移读取,禁止 `--follow`。等待超时不会取消远程任务。
|
|
144
|
+
|
|
145
|
+
文件传输使用 `instance cp`,实例路径以 `:` 开头。它会读写 WorkBuddy 可访问的本地路径,
|
|
146
|
+
调用前必须确认源、目标和覆盖影响。
|
|
147
|
+
|
|
148
|
+
## 镜像、存储、带宽和团队
|
|
149
|
+
|
|
150
|
+
- 镜像 `list/show/progress/shares/tags` 为只读;`create/update/delete/share/unshare/publish`、
|
|
151
|
+
收藏变更为写操作。发布社区镜像前确认其中不含密钥、密码或用户数据。
|
|
152
|
+
- 云盘 `list/price` 为只读;创建、挂载、卸载、扩容和删除为写操作。卸载前提醒用户先在
|
|
153
|
+
实例内卸载文件系统;云盘只能扩容,不能缩容。
|
|
154
|
+
- 独享带宽 `list/instances` 为只读。购买、改配和删除先通过 `--dry-run` 询价或查看退款,
|
|
155
|
+
再确认执行。购买后已有实例不会自动切换带宽。
|
|
156
|
+
- 团队列表、详情、成员、账单和审计为只读;团队、邀请、成员备注和额度变更为写操作。
|
|
157
|
+
账单 CSV 导出不通过 MCP 提供;改为读取分页后的结构化账单数据。
|
|
158
|
+
|
|
159
|
+
## MiniMax H3
|
|
160
|
+
|
|
161
|
+
MiniMax 使用 Token 表单中的独立 `COMPSHARE_MINIMAX_API_KEY`。缺失时让用户编辑 Connector
|
|
162
|
+
凭证,不要把 GPU API 私钥当作模型 Key。
|
|
163
|
+
|
|
164
|
+
视频创建前先读取积分、套餐、已有任务,再通过只读工具调用 `minimax create --dry-run`。
|
|
165
|
+
图片先读取 `minimax image config`,语音先读取 `minimax audio pricing` 和
|
|
166
|
+
`minimax audio voices`;再用相应的 `create --dry-run` 预演。展示分辨率、时长、比例、
|
|
167
|
+
素材及费用影响后确认,使用相同幂等键调用写工具正式创建。重试不确定请求时必须复用
|
|
168
|
+
原幂等键。取消、删除任务和上传参考素材也属于写操作。
|
|
169
|
+
|
|
170
|
+
视频素材支持公开 URL 或 Data URL;图片和语音参考素材通过 `image upload`、
|
|
171
|
+
`audio upload` 登记后使用资产 ID。生成结果 URL 默认脱敏;不要为了显示它而绕过连接器
|
|
172
|
+
的敏感输出限制。
|
|
173
|
+
|
|
174
|
+
## 故障恢复
|
|
175
|
+
|
|
176
|
+
- `authentication` 或 `configuration_error`:让用户在 WorkBuddy Connector 设置中更新两把
|
|
177
|
+
GPU API 密钥;MiniMax 单独检查可选模型 Key。
|
|
178
|
+
- `invalid_usage`:调用 `compshare_help` 核对参数、位置和枚举后再试。
|
|
179
|
+
- 无库存:带准确镜像重新搜索,并有意识地放宽 GPU、Region、Zone、CPU、内存、计费或
|
|
180
|
+
磁盘条件。
|
|
181
|
+
- 读取超时:可以在等待后有限重试;写入超时:先读回,绝不直接重试。
|
|
182
|
+
- 返回部分失败:逐项报告成功与失败对象,只对明确未执行且用户重新确认的对象继续操作。
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
{
|
|
2
|
+
"title": "连接优云智算账户",
|
|
3
|
+
"title_en": "Connect CompShare",
|
|
4
|
+
"description": "API 密钥仅由 WorkBuddy 保存在本机 ~/.workbuddy,并在连接时注入本地 MCP 进程,不会上传到 WorkBuddy 云端。连接器不会修改已有的 CompShare CLI 凭证配置。",
|
|
5
|
+
"description_en": "API keys are stored locally by WorkBuddy under ~/.workbuddy and injected only into the local MCP process. They are not uploaded to WorkBuddy cloud, and the connector does not change existing CompShare CLI credentials.",
|
|
6
|
+
"docUrl": "https://console.compshare.cn/uaccount/api_manage",
|
|
7
|
+
"docLabel": "前往账户中心获取 API 公钥和私钥",
|
|
8
|
+
"docLabel_en": "Get API public and private keys from Account Center",
|
|
9
|
+
"fields": [
|
|
10
|
+
{
|
|
11
|
+
"key": "COMPSHARE_PUBLIC_KEY",
|
|
12
|
+
"label": "API 公钥",
|
|
13
|
+
"label_en": "API Public Key",
|
|
14
|
+
"type": "password",
|
|
15
|
+
"required": true,
|
|
16
|
+
"placeholder": "账户中心 → API 密钥 → 公钥",
|
|
17
|
+
"placeholder_en": "Account Center -> API Keys -> Public Key",
|
|
18
|
+
"description": "用于签名访问 GPU、镜像、存储、网络和团队 OpenAPI。请勿在对话中发送该密钥。",
|
|
19
|
+
"description_en": "Signs GPU, image, storage, networking, and team OpenAPI requests. Never send this key in chat."
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
"key": "COMPSHARE_PRIVATE_KEY",
|
|
23
|
+
"label": "API 私钥",
|
|
24
|
+
"label_en": "API Private Key",
|
|
25
|
+
"type": "password",
|
|
26
|
+
"required": true,
|
|
27
|
+
"placeholder": "账户中心 → API 密钥 → 私钥",
|
|
28
|
+
"placeholder_en": "Account Center -> API Keys -> Private Key",
|
|
29
|
+
"description": "与 API 公钥配对用于请求签名。仅保存在 WorkBuddy 本机凭证区。",
|
|
30
|
+
"description_en": "Pairs with the public key to sign requests and remains in WorkBuddy's local credential store."
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
"key": "COMPSHARE_MINIMAX_API_KEY",
|
|
34
|
+
"label": "MiniMax H3 API Key(可选)",
|
|
35
|
+
"label_en": "MiniMax H3 API Key (optional)",
|
|
36
|
+
"type": "password",
|
|
37
|
+
"required": false,
|
|
38
|
+
"placeholder": "模型 API 服务 → API KEY(sk-ml-...)",
|
|
39
|
+
"placeholder_en": "Model API Service -> API KEY (sk-ml-...)",
|
|
40
|
+
"description": "仅在通过连接器创建或管理 MiniMax H3 视频、图片或语音任务时需要。",
|
|
41
|
+
"description_en": "Required only for creating or managing MiniMax H3 video, image, or speech tasks through this connector."
|
|
42
|
+
}
|
|
43
|
+
]
|
|
44
|
+
}
|