File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -14,12 +14,11 @@ To install the DashScope Python SDK, simply run:
1414pip install dashscope
1515```
1616
17- The base install covers SDK API calls only. Optional feature groups are
18- available as extras:
17+ The base install covers SDK API calls and the ` dashscope ` CLI command.
18+ Optional feature groups are available as extras:
1919
2020| Extra | Provides | Install |
2121| -------| ----------| ---------|
22- | ` cli ` | ` dashscope ` command subcommands (generation, files, ...) | ` pip install "dashscope[cli]" ` |
2322| ` acli ` | Interactive AI assistant (DashScope SDK Expert) | ` pip install "dashscope[acli]" ` |
2423| ` rl ` | Agentic RL fine-tuning | ` pip install "dashscope[rl]" ` |
2524| ` tokenizer ` | Local tokenizer without downloads | ` pip install "dashscope[tokenizer]" ` |
Original file line number Diff line number Diff line change @@ -15,12 +15,11 @@ DashScope Python SDK 提供了访问[阿里云百炼(Model Studio)](https://
1515pip install dashscope
1616```
1717
18- 基础安装仅包含 SDK API 调用 。可选功能组通过 extras 安装:
18+ 基础安装包含 SDK API 调用和 ` dashscope ` CLI 命令 。可选功能组通过 extras 安装:
1919
2020| Extra | 提供的能力 | 安装命令 |
2121| -------| ----------| ---------|
22- | ` cli ` | ` dashscope ` 命令子命令(generation、files 等) | ` pip install "dashscope[cli]" ` |
23- | ` acli ` | 交互式 AI 助手(DashScope SDK Expert) | ` pip install "dashscope[acli]" ` |
22+ | ` acli ` | 交互式 AI 助手(DashScope SDK Expert) | ` pip install "dashscope[acli]" ` |
2423| ` rl ` | Agentic RL 微调 | ` pip install "dashscope[rl]" ` |
2524| ` tokenizer ` | 本地 tokenizer(无需下载) | ` pip install "dashscope[tokenizer]" ` |
2625
Original file line number Diff line number Diff line change 1717 category = Warning ,
1818)
1919
20- try :
21- import typer # noqa: E402
22- except ImportError as _cli_dep_err : # noqa: E402
23- raise ImportError (
24- "The `dashscope` command needs optional dependencies. "
25- "Install them with: pip install 'dashscope[cli]' "
26- "(or 'dashscope[acli]' for the interactive assistant)" ,
27- ) from _cli_dep_err
20+ import typer # noqa: E402
2821
2922import dashscope # noqa: E402
3023from dashscope .cli .common import err_console # noqa: E402
Original file line number Diff line number Diff line change 33websocket-client
44cryptography
55certifi
6+ typer >= 0.9.0
7+ rich >= 13.0.0
68httpx >= 0.25.0
79httpx-sse >= 0.4.0
Original file line number Diff line number Diff line change @@ -67,15 +67,8 @@ def readme():
6767 include_package_data = True ,
6868 extras_require = {
6969 "tokenizer" : ["tiktoken" ],
70- # Classic `dashscope` CLI subcommands (generation, files, ...)
71- "cli" : [
72- "typer>=0.9.0" ,
73- "rich>=13.0.0" ,
74- ],
75- # Interactive AI assistant (dashscope.acli), includes the cli extra
70+ # Interactive AI assistant (dashscope.acli); typer/rich are core deps
7671 "acli" : [
77- "typer>=0.9.0" ,
78- "rich>=13.0.0" ,
7972 "prompt-toolkit>=3.0" ,
8073 "textual>=0.50" ,
8174 "PyYAML>=6.0" ,
@@ -86,8 +79,6 @@ def readme():
8679 "acli-voice" : ["sounddevice>=0.4" , "numpy>=1.20" ],
8780 "acli-camera" : ["opencv-python>=4.5" ],
8881 "acli-all" : [
89- "typer>=0.9.0" ,
90- "rich>=13.0.0" ,
9182 "prompt-toolkit>=3.0" ,
9283 "textual>=0.50" ,
9384 "PyYAML>=6.0" ,
You can’t perform that action at this time.
0 commit comments