diff --git a/skills/dashscope-image-gen/SKILL.md b/skills/dashscope-image-gen/SKILL.md index 90c0c37..3bfc01c 100644 --- a/skills/dashscope-image-gen/SKILL.md +++ b/skills/dashscope-image-gen/SKILL.md @@ -8,12 +8,12 @@ description: >- Use when 用户提到 生成图片、画图、文生图、创建图片、AI 绘画、 生成插图、画一张、帮我画、设计图片、通义万相、万相、阿里云画图、dashscope 画图。 license: Complete terms in LICENSE.txt -version: 1.1.1 +version: 1.2.0 type: procedural risk_level: low status: enabled disable-model-invocation: false -provider: dashscope +provider: auto tags: - media - image @@ -87,7 +87,7 @@ market: ### Prerequisites -- The user has configured an Alibaba Cloud DashScope provider in Resource Manager → Compute and filled in an API Key +- At least one enabled compute provider supports `image_gen` service type (e.g. DashScope, or the default DesireCore Cloud provider) - agent-service is running ### Step 1: Call the text-to-image API (synchronous) @@ -99,7 +99,6 @@ PORT=$(cat ${DESIRECORE_ROOT}/agent-service.port) curl -sk -X POST "https://127.0.0.1:${PORT}/api/media-proxy" \ -H "Content-Type: application/json" \ -d '{ - "provider": "dashscope", "serviceType": "image_gen", "endpoint": "/chat/completions", "body": { @@ -210,7 +209,7 @@ When `n > 1`, the `choices` array contains multiple entries, each with an image ## Error Handling -- `success: false` + `error: "No matching provider"`: DashScope provider not configured or disabled +- `success: false` + `error: "No matching provider"`: No enabled provider supports `image_gen` service type - `success: false` + `error: "API Key not configured"`: API Key missing - `statusCode: 401`: API Key invalid or expired - `statusCode: 429`: rate limited, retry later diff --git a/skills/dashscope-image-gen/SKILL.zh-CN.md b/skills/dashscope-image-gen/SKILL.zh-CN.md index 0c0a1e7..c973e07 100644 --- a/skills/dashscope-image-gen/SKILL.zh-CN.md +++ b/skills/dashscope-image-gen/SKILL.zh-CN.md @@ -23,7 +23,7 @@ ### 前置条件 -- 用户已在资源管理器-算力中配置阿里云 DashScope Provider 并填写 API Key +- 至少有一个已启用的算力供应商支持 `image_gen` 服务类型(如 DashScope 或默认的 DesireCore Cloud 供应商) - agent-service 正在运行 ### 第一步:调用文生图 API(同步) @@ -35,7 +35,6 @@ PORT=$(cat ${DESIRECORE_ROOT}/agent-service.port) curl -sk -X POST "https://127.0.0.1:${PORT}/api/media-proxy" \ -H "Content-Type: application/json" \ -d '{ - "provider": "dashscope", "serviceType": "image_gen", "endpoint": "/chat/completions", "body": { @@ -146,7 +145,7 @@ curl -sk -X POST "https://127.0.0.1:${PORT}/api/media/upload" \ ## 错误处理 -- `success: false` + `error: "未找到匹配的供应商"`:未配置 DashScope Provider 或未启用 +- `success: false` + `error: "未找到匹配的供应商"`:没有已启用的供应商支持 `image_gen` 服务类型 - `success: false` + `error: "未配置 API Key"`:未填写 API Key - `statusCode: 401`:API Key 无效或已过期 - `statusCode: 429`:频率限制,稍后重试