bailian-cli 1.9.0 → 1.10.0

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.
package/README.md CHANGED
@@ -30,6 +30,7 @@ Equip your AI Agent out-of-the-box with these capabilities, composable across co
30
30
  - **Video generation & editing** — happyhorse-1.1 series: text-/image-/reference-to-video and natural-language video editing (up to 9-image reference)
31
31
  - **Speech synthesis & recognition** — CosyVoice streaming TTS, voice cloning from 5–20s samples; FunAudio-ASR covers 30 languages including 7 Chinese dialects and 20+ Mandarin accents
32
32
  - **Image & video understanding** — Qwen-VL: long-form video analysis, chart/document parsing, visual reasoning, multilingual OCR
33
+ - **Coding agent setup** — Configure Claude Code, Qwen Code, OpenCode, OpenClaw, Hermes Agent, or Codex to use DashScope with `bl config agent`
33
34
 
34
35
  > **Note:** The features below are currently available only to China site (aliyun.com) account holders and are not yet supported for international / global site accounts.
35
36
 
@@ -91,6 +92,12 @@ bl auth login --console
91
92
  # Or authenticate with an API key
92
93
  bl auth login --api-key sk-xxxxx
93
94
 
95
+ # Or use Token Plan (Base URL built in; the key is tested during login)
96
+ bl auth login --config token-plan --api-key sk-sp-xxxxx
97
+
98
+ # Configure a coding agent to use DashScope
99
+ bl config agent --agent codex --base-url https://dashscope.aliyuncs.com/compatible-mode/v1 --api-key sk-xxxxx --model qwen3-coder-plus
100
+
94
101
  # Chat with Qwen
95
102
  bl text chat --message "What is DashScope?"
96
103
 
@@ -159,6 +166,15 @@ bl auth login --api-key sk-xxxxx
159
166
  bl text chat --api-key sk-xxxxx --message "Hello"
160
167
  ```
161
168
 
169
+ ### Token Plan API Key
170
+
171
+ Get or copy the API key from the [Token Plan subscription overview](https://bailian.console.aliyun.com/cn-beijing?tab=plan#/efm/subscription/overview).
172
+ The CLI has the default Token Plan Base URL built in. Login tests the key first, then saves and activates the `token-plan` config only when validation succeeds.
173
+
174
+ ```bash
175
+ bl auth login --config token-plan --api-key sk-sp-xxxxx
176
+ ```
177
+
162
178
  ### Console Login (OAuth)
163
179
 
164
180
  Required for console capability commands (`model list`, `app list`, `usage summary/free/stats`, `workspace list`, `quota list/request/check/history`). Opens the Bailian console in your browser to sign in.
@@ -209,6 +225,7 @@ Config file location: `~/.bailian/config.json`
209
225
  | Qwen Model List | https://help.aliyun.com/zh/model-studio/getting-started/models |
210
226
  | Aliyun Model Studio Console | https://bailian.console.aliyun.com/?source_channel=cli_github |
211
227
  | Get API Key | https://bailian.console.aliyun.com/cn-beijing/?source_channel=key_github&tab=app#/api-key |
228
+ | Get Token Plan API Key | https://bailian.console.aliyun.com/cn-beijing?tab=plan#/efm/subscription/overview |
212
229
  | Get AccessKey | https://ram.console.aliyun.com/manage/ak |
213
230
 
214
231
  ## Changelog
package/README.zh.md CHANGED
@@ -30,6 +30,7 @@ _专为 AI Agent 打造,每个命令均可作为结构化工具调用。_
30
30
  - **视频生成与编辑** — happyhorse-1.1 系列,支持文生 / 图生 / 参考生(最多 9 张图参考)/ 自然语言视频编辑
31
31
  - **语音合成与识别** — CosyVoice 实时流式合成,5-20s 样本即可克隆;FunAudio-ASR 覆盖 30 种语种,含汉语七大方言与 20+ 口音官话
32
32
  - **图像与视频理解** — Qwen-VL:长视频解析、复杂图表与文档识别、视觉推理、多语种 OCR
33
+ - **Coding Agent 配置** — 使用 `bl config agent` 将 Claude Code、Qwen Code、OpenCode、OpenClaw、Hermes Agent 或 Codex 配置为使用 DashScope
33
34
 
34
35
  > **注意:** 以下功能目前仅对中国站(aliyun.com)账号开放,国际站 / 全球站账号暂不支持。
35
36
 
@@ -89,6 +90,12 @@ bl auth login --console
89
90
  # 或使用 API key 认证
90
91
  bl auth login --api-key sk-xxxxx
91
92
 
93
+ # 或使用 Token Plan(已内置 Base URL,登录时自动测试 Key)
94
+ bl auth login --config token-plan --api-key sk-sp-xxxxx
95
+
96
+ # 配置 Coding Agent 使用 DashScope
97
+ bl config agent --agent codex --base-url https://dashscope.aliyuncs.com/compatible-mode/v1 --api-key sk-xxxxx --model qwen3-coder-plus
98
+
92
99
  # 和通义千问对话
93
100
  bl text chat --message "你好,介绍一下阿里云百炼平台"
94
101
 
@@ -157,6 +164,15 @@ bl auth login --api-key sk-xxxxx
157
164
  bl text chat --api-key sk-xxxxx --message "你好"
158
165
  ```
159
166
 
167
+ ### Token Plan API Key
168
+
169
+ 前往 [Token Plan 订阅详情](https://bailian.console.aliyun.com/cn-beijing?tab=plan#/efm/subscription/overview) 获取或复制 API Key。
170
+ CLI 已内置 Token Plan 的默认 Base URL;登录命令会先测试 Key,通过后才保存并激活 `token-plan` 配置。
171
+
172
+ ```bash
173
+ bl auth login --config token-plan --api-key sk-sp-xxxxx
174
+ ```
175
+
160
176
  ### 控制台登录(OAuth)
161
177
 
162
178
  控制台能力命令(`model list`、`app list`、`usage summary/free/stats`、`workspace list`、`quota list/request/check/history`)需要使用此登录方式。打开浏览器跳转百炼控制台完成登录。
@@ -207,6 +223,7 @@ bl update
207
223
  | 通义千问模型列表 | https://help.aliyun.com/zh/model-studio/getting-started/models |
208
224
  | 阿里云百炼控制台 | https://bailian.console.aliyun.com/?source_channel=cli_github |
209
225
  | 获取 API Key | https://bailian.console.aliyun.com/cn-beijing/?source_channel=key_github&tab=app#/api-key |
226
+ | 获取 Token Plan API Key | https://bailian.console.aliyun.com/cn-beijing?tab=plan#/efm/subscription/overview |
210
227
  | 获取 AccessKey | https://ram.console.aliyun.com/manage/ak |
211
228
 
212
229
  ## 更新日志
package/dist/bailian.mjs CHANGED
@@ -1,3 +1,3 @@
1
1
  #!/usr/bin/env node
2
2
 
3
- import{createCli as e}from"bailian-cli-runtime";import{advisorRecommend as t,appCall as n,appList as r,authGenerateAccessToken as i,authLogin as a,authLogout as o,authStatus as s,configList as c,configSet as l,configShow as u,configUi as d,configUse as f,consoleCall as p,datasetDelete as m,datasetGet as h,datasetList as g,datasetUpload as _,datasetValidate as v,deployAudioCreate as y,deployDelete as b,deployGet as x,deployImageCreate as S,deployList as C,deployModels as w,deployScale as T,deployTextCreate as E,deployUpdate as D,fileUpload as O,finetuneAudioCreate as k,finetuneCancel as A,finetuneCapability as j,finetuneCheckpoints as M,finetuneDelete as N,finetuneExport as P,finetuneGet as F,finetuneImageCreate as I,finetuneList as L,finetuneLogs as R,finetuneTextCreate as z,finetuneWatch as B,imageEdit as V,imageGenerate as H,knowledgeChat as U,knowledgeRetrieve as W,knowledgeSearch as G,mcpCall as K,mcpList as q,mcpTools as J,memoryAdd as Y,memoryDelete as X,memoryList as Z,memoryProfileCreate as Q,memoryProfileGet as $,memorySearch as ee,memoryUpdate as te,modelList as ne,pipelineRun as re,pipelineValidate as ie,pluginInstall as ae,pluginLink as oe,pluginList as se,pluginRemove as ce,quotaCheck as le,quotaHistory as ue,quotaList as de,quotaRequest as fe,searchWeb as pe,speechRecognize as me,speechSynthesize as he,textChat as ge,textOmni as _e,tokenPlanAddMember as ve,tokenPlanAssignSeats as ye,tokenPlanCreateKey as be,tokenPlanListSeats as xe,update as Se,usageFree as Ce,usageFreetier as we,usageStats as Te,usageSummary as Ee,videoDownload as De,videoEdit as Oe,videoGenerate as ke,videoRef as Ae,videoTaskGet as je,visionDescribe as Me,workspaceInit as Ne,workspaceList as Pe}from"bailian-cli-commands";e({"auth login":a,"auth status":s,"auth logout":o,"auth generate-access-token":i,"text chat":ge,omni:_e,"image generate":H,"image edit":V,"video generate":ke,"video edit":Oe,"video ref":Ae,"video task get":je,"video download":De,"vision describe":Me,"config show":u,"config set":l,"config list":c,"config use":f,"config ui":d,update:Se,"app call":n,"app list":r,"memory add":Y,"memory search":ee,"memory list":Z,"memory update":te,"memory delete":X,"memory profile create":Q,"memory profile get":$,"knowledge retrieve":W,"knowledge search":G,"knowledge chat":U,"mcp call":K,"mcp list":q,"mcp tools":J,"search web":pe,"speech synthesize":he,"speech recognize":me,"file upload":O,"console call":p,"usage free":Ce,"usage freetier":we,"usage stats":Te,"usage summary":Ee,"pipeline run":re,"pipeline validate":ie,"advisor recommend":t,"model list":ne,"workspace list":Pe,"quota list":de,"quota request":fe,"quota history":ue,"quota check":le,"dataset upload":_,"dataset list":g,"dataset get":h,"dataset delete":m,"dataset validate":v,"finetune text create":z,"finetune audio create":k,"finetune image create":I,"finetune list":L,"finetune get":F,"finetune cancel":A,"finetune delete":N,"finetune logs":R,"finetune checkpoints":M,"finetune export":P,"finetune watch":B,"finetune capability":j,"deploy text create":E,"deploy audio create":y,"deploy image create":S,"deploy list":C,"deploy get":x,"deploy models":w,"deploy scale":T,"deploy update":D,"deploy delete":b,"token-plan list-seats":xe,"token-plan create-key":be,"token-plan assign-seats":ye,"token-plan add-member":ve,"workspace init":Ne,"plugin install":ae,"plugin link":oe,"plugin list":se,"plugin remove":ce},{binName:`bl`,version:`1.9.0`,clientName:`bailian-cli`,npmPackage:`bailian-cli`,quickStartTasks:[`Help me generate a set of Amazon e-commerce main images for baseball caps (white background + lifestyle shots + model wear shots)`,`Help me generate a 3-minute humorous crosstalk audio clip`,`Help me generate a Little Red Riding Hood picture-book PDF (with illustrations)`,`Help me analyze this video and write a Xiaohongshu-style post`],commandPacks:{supported:{"@ali/bailian-plugin-agent":{commandPrefixes:[`agent`],credentialAccess:[`apiKey`]},"@ali/bailian-plugin-inner-console-call":{commandPrefixes:[`inner-console`]}}}}).run();export{};
3
+ import{createCli as e}from"bailian-cli-runtime";import{advisorRecommend as t,appCall as n,appList as r,authGenerateAccessToken as i,authLogin as a,authLogout as o,authStatus as s,configAgent as c,configList as l,configSet as u,configShow as d,configUi as f,configUse as p,consoleCall as m,datasetDelete as h,datasetGet as g,datasetList as _,datasetUpload as v,datasetValidate as y,deployAudioCreate as b,deployDelete as x,deployGet as S,deployImageCreate as C,deployList as w,deployModels as T,deployScale as E,deployTextCreate as D,deployUpdate as O,fileUpload as k,finetuneAudioCreate as A,finetuneCancel as j,finetuneCapability as M,finetuneCheckpoints as N,finetuneDelete as P,finetuneExport as F,finetuneGet as I,finetuneImageCreate as L,finetuneList as R,finetuneLogs as z,finetuneTextCreate as B,finetuneWatch as V,imageEdit as H,imageGenerate as U,knowledgeChat as W,knowledgeRetrieve as G,knowledgeSearch as K,mcpCall as q,mcpList as J,mcpTools as Y,memoryAdd as X,memoryDelete as Z,memoryList as Q,memoryProfileCreate as $,memoryProfileGet as ee,memorySearch as te,memoryUpdate as ne,modelList as re,pipelineRun as ie,pipelineValidate as ae,pluginInstall as oe,pluginLink as se,pluginList as ce,pluginRemove as le,quotaCheck as ue,quotaHistory as de,quotaList as fe,quotaRequest as pe,searchWeb as me,speechRecognize as he,speechSynthesize as ge,textChat as _e,textOmni as ve,tokenPlanAddMember as ye,tokenPlanAssignSeats as be,tokenPlanCreateKey as xe,tokenPlanListSeats as Se,update as Ce,usageFree as we,usageFreetier as Te,usageStats as Ee,usageSummary as De,videoDownload as Oe,videoEdit as ke,videoGenerate as Ae,videoRef as je,videoTaskGet as Me,visionDescribe as Ne,workspaceInit as Pe,workspaceList as Fe}from"bailian-cli-commands";e({"auth login":a,"auth status":s,"auth logout":o,"auth generate-access-token":i,"text chat":_e,omni:ve,"image generate":U,"image edit":H,"video generate":Ae,"video edit":ke,"video ref":je,"video task get":Me,"video download":Oe,"vision describe":Ne,"config show":d,"config set":u,"config list":l,"config use":p,"config ui":f,"config agent":c,update:Ce,"app call":n,"app list":r,"memory add":X,"memory search":te,"memory list":Q,"memory update":ne,"memory delete":Z,"memory profile create":$,"memory profile get":ee,"knowledge retrieve":G,"knowledge search":K,"knowledge chat":W,"mcp call":q,"mcp list":J,"mcp tools":Y,"search web":me,"speech synthesize":ge,"speech recognize":he,"file upload":k,"console call":m,"usage free":we,"usage freetier":Te,"usage stats":Ee,"usage summary":De,"pipeline run":ie,"pipeline validate":ae,"advisor recommend":t,"model list":re,"workspace list":Fe,"quota list":fe,"quota request":pe,"quota history":de,"quota check":ue,"dataset upload":v,"dataset list":_,"dataset get":g,"dataset delete":h,"dataset validate":y,"finetune text create":B,"finetune audio create":A,"finetune image create":L,"finetune list":R,"finetune get":I,"finetune cancel":j,"finetune delete":P,"finetune logs":z,"finetune checkpoints":N,"finetune export":F,"finetune watch":V,"finetune capability":M,"deploy text create":D,"deploy audio create":b,"deploy image create":C,"deploy list":w,"deploy get":S,"deploy models":T,"deploy scale":E,"deploy update":O,"deploy delete":x,"token-plan list-seats":Se,"token-plan create-key":xe,"token-plan assign-seats":be,"token-plan add-member":ye,"workspace init":Pe,"plugin install":oe,"plugin link":se,"plugin list":ce,"plugin remove":le},{binName:`bl`,version:`1.10.0`,clientName:`bailian-cli`,npmPackage:`bailian-cli`,quickStartTasks:[`Help me generate a set of Amazon e-commerce main images for baseball caps (white background + lifestyle shots + model wear shots)`,`Help me generate a 3-minute humorous crosstalk audio clip`,`Help me generate a Little Red Riding Hood picture-book PDF (with illustrations)`,`Help me analyze this video and write a Xiaohongshu-style post`],commandPacks:{supported:{"@ali/bailian-plugin-agent":{commandPrefixes:[`agent`],credentialAccess:[`apiKey`]},"@ali/bailian-plugin-inner-console-call":{commandPrefixes:[`inner-console`]}}}}).run();export{};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bailian-cli",
3
- "version": "1.9.0",
3
+ "version": "1.10.0",
4
4
  "description": "CLI for Aliyun Model Studio (DashScope) AI Platform.",
5
5
  "keywords": [
6
6
  "agent",
@@ -36,9 +36,9 @@
36
36
  "registry": "https://registry.npmjs.org/"
37
37
  },
38
38
  "dependencies": {
39
- "bailian-cli-commands": "1.9.0",
40
- "bailian-cli-core": "1.9.0",
41
- "bailian-cli-runtime": "1.9.0"
39
+ "bailian-cli-commands": "1.10.0",
40
+ "bailian-cli-core": "1.10.0",
41
+ "bailian-cli-runtime": "1.10.0"
42
42
  },
43
43
  "devDependencies": {
44
44
  "@clack/prompts": "^0.7.0",