pi-media-models 0.1.9 → 0.1.10
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 +0 -43
- package/package.json +1 -1
- package/src/adapters/atlas.ts +1 -1
package/README.md
CHANGED
|
@@ -164,49 +164,6 @@ The extension registers exactly 6 unified tools for the reasoning agent:
|
|
|
164
164
|
|
|
165
165
|
Live catalog discovery is implemented for Google Gemini, Vertex AI Model Garden, OpenAI, xAI, Atlas, and OpenRouter. Providers without a reliable catalog API use their declared fallback candidates; those entries are labeled `source=built-in` and `availability=unknown` rather than being presented as verified.
|
|
166
166
|
|
|
167
|
-
### QwenCloud and DashScope examples
|
|
168
|
-
|
|
169
|
-
Use the flagship image model. Synchronous Qwen Image requests default to a three-minute request timeout; override it with `requestTimeoutMs` when needed:
|
|
170
|
-
|
|
171
|
-
```text
|
|
172
|
-
image_generate({
|
|
173
|
-
provider: "qwencloud",
|
|
174
|
-
model: "qwen-image-3.0-pro",
|
|
175
|
-
prompt: "cinematic moonlit mountains",
|
|
176
|
-
resolution: "1664*928",
|
|
177
|
-
providerOptions: { requestTimeoutMs: 300000 }
|
|
178
|
-
})
|
|
179
|
-
```
|
|
180
|
-
|
|
181
|
-
Wan video resolutions are normalized case-insensitively, so both `"1080p"` and Alibaba's documented `"1080P"` work:
|
|
182
|
-
|
|
183
|
-
```text
|
|
184
|
-
video_generate({
|
|
185
|
-
provider: "qwencloud",
|
|
186
|
-
model: "wan3.0-video",
|
|
187
|
-
prompt: "slow cinematic camera move",
|
|
188
|
-
resolution: "1080p",
|
|
189
|
-
duration: 5,
|
|
190
|
-
generateAudio: true
|
|
191
|
-
})
|
|
192
|
-
```
|
|
193
|
-
|
|
194
|
-
Qwen Audio 3 TTS uses the provider's WebSocket API automatically. `plus` prioritizes output quality; `flash` prioritizes latency. If `voice` is omitted, the adapter uses `longanhuan_v3.6`:
|
|
195
|
-
|
|
196
|
-
```text
|
|
197
|
-
speech_generate({
|
|
198
|
-
provider: "qwencloud",
|
|
199
|
-
model: "qwen-audio-3.0-tts-plus",
|
|
200
|
-
operation: "tts",
|
|
201
|
-
text: "床前明月光,疑是地上霜。",
|
|
202
|
-
language: "zh",
|
|
203
|
-
responseFormat: "mp3",
|
|
204
|
-
providerOptions: {
|
|
205
|
-
instruction: "Read calmly with a classical poetic tone."
|
|
206
|
-
}
|
|
207
|
-
})
|
|
208
|
-
```
|
|
209
|
-
|
|
210
167
|
Avoid forcing `providerOptions.async: true` for Qwen Image unless the account supports asynchronous calls. Paid generation submissions are not retried automatically after ambiguous POST failures, preventing accidental duplicate charges; retry manually after confirming no job was created.
|
|
211
168
|
|
|
212
169
|
## 🔒 Security & Privacy
|
package/package.json
CHANGED
package/src/adapters/atlas.ts
CHANGED
|
@@ -46,7 +46,7 @@ export class AtlasAdapter extends BaseAdapter {
|
|
|
46
46
|
|
|
47
47
|
private async imageGenerate(request: MediaRequest, context: AdapterContext): Promise<AdapterResult> {
|
|
48
48
|
const key = this.key(request)
|
|
49
|
-
const asyncMode = request.providerOptions?.async
|
|
49
|
+
const asyncMode = request.providerOptions?.async === true
|
|
50
50
|
const { async: _async, timeoutMs: _timeoutMs, ...nativeOptions } = request.providerOptions ?? {}
|
|
51
51
|
const payload = mergeOptions({
|
|
52
52
|
model: request.model, prompt: requirePrompt(request), n: request.count ?? 1,
|