You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit f826759
Browse filesBrowse the repository at this point in the historyBrowse files
zhansheng.lzs
committed
acli: sync compression visibility, prefix_chars trace, dir checkpoints
- compression_hint: post-compression notice + 40% pre-hint band, riding
the trailing hint message
- llm_call trace gains prefix_chars so prompt-cache drift is measurable
- checkpoint: directory tree backups (256MB ceiling); delete_directory
snapshots and /undo restores the tree
- examples refreshed from agenticCLI-examples
acli subset 297 passed; pre-commit green.
Copy file name to clipboardExpand all lines: dashscope/acli/examples/dashscope-sdk-expert/.acli/skills/multimodal.md
+6-6Lines changed: 6 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,9 +8,9 @@ Locate before answering: understanding tasks use `MultiModalConversation` (sync/
8
8
9
9
## Applicable Models and Scenarios
10
10
11
-
- Understanding (image/video understanding, OCR, function calling): `qwen-vl-max`, `qwen-vl-plus`, qwen-ocr series, etc. (the `Models` class in source only has the constant `qwen_vl_chat_v1`; pass others as strings).
- Video generation (`VideoSynthesis`, task=`video-generation`): `wanx2.1-t2v-turbo/plus` (text-to-video), `wanx2.1-i2v-turbo/plus` (image-to-video), `wanx2.1-kf2v-plus`/`wanx-kf2v` (first/last frame). `wanx-txt2video-pro` and `wanx-img2video-pro` are deprecated.
11
+
- Understanding (image/video understanding, OCR, function calling): `qwen3-vl-flash`, `qwen3-vl-plus`, qwen-ocr series, etc. (the `Models` class in source only has the constant `qwen_vl_chat_v1`; pass others as strings).
Copy file name to clipboardExpand all lines: dashscope/acli/examples/dashscope-sdk-expert/.acli/skills/text-generation.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,7 +10,7 @@ Before answering, verify the user's SDK version and signature: `python -c "impor
10
10
## Applicable Models and Scenarios
11
11
12
12
- Entry point `dashscope.Generation` (sync) / `dashscope.AioGeneration` (async, both top-level exports in `dashscope/__init__.py`), `task = "text-generation"`.
13
-
- Plain text chat/continuation: qwen series. Built-in constants in `Generation.Models`: `qwen_turbo="qwen-turbo"`, `qwen_plus="qwen-plus"`, `qwen_max="qwen-max"`; `qwen_v1` and `qwen_plus_v1` are deprecated (calls only warn).
13
+
- Plain text chat/continuation: qwen series (e.g. `qwen-plus`, `qwen3.8-32b`). `Generation.Models` only carries a few legacy constants; pass the current model name as a plain string.
14
14
- The `model` parameter is just a `str`; the SDK does not validate against a whitelist. For new models like qwen3, pass the model name string directly; refer to the console/docs for exact names.
15
15
-`enable_search` is only supported when `model` starts with `"qwen"`; when it starts with `"bailian"` you must pass `customized_model_id`, otherwise `InputRequired` is raised.
16
16
- Do not use this API for multimodal; use `MultiModalConversation`.
- Then use `read_file` on the specific source file if needed.
65
65
66
+
### Cookbook examples (examples/ directory)
67
+
68
+
The Python SDK repo ships runnable cookbook scripts under `examples/`, organized by API generation. When the user asks you to implement a task, start from the matching script instead of writing from scratch:
- Java cookbook samples are not in this repo; they live in the Java SDK repo (https://github.com/dashscope/dashscope-sdk-java) and are referenced by class name in the skills.
73
+
74
+
### Python repo layout: v1.x vs 2.0 (V2)
75
+
76
+
In the Python SDK repo the 2.0 API is isolated by directory. Only these paths are V2:
77
+
78
+
-`dashscope/v2/` — the 2.0 client and resources
79
+
-`tests/v2/` — V2 tests
80
+
-`examples/v2/` — V2 cookbook
81
+
82
+
Everything else (`dashscope/` top-level modules, the rest of `tests/`, `examples/v1/`) is v1.x code. Match the tree to the user's API generation before reading source or quoting examples: resource-style `dashscope.Client` calls → V2 paths; module-level `dashscope.Generation.call(...)` style → v1.x paths.
83
+
66
84
### Workflow
67
85
68
86
1. Identify the question type (question about you / issue analysis / API question / example).
0 commit comments