modelscope-api
SKILL.md
ModelScope API Skill
This skill provides convenient access to ModelScope platform APIs for text generation, image generation, and AI model services.
Quick Start
Text Generation
const { ModelScopeAPI } = require('./scripts/modelscope-api');
// Initialize API client
const api = new ModelScopeAPI('your-modelscope-token');
// Generate text
const response = await api.chatCompletion(
'Qwen/Qwen3-VL-235B-A22B-Instruct',
[{ role: 'user', content: 'Hello' }]
);
console.log(response.choices[0].message.content);
// Generate text with streaming
const stream = await api.chatCompletionStream(
'Qwen/Qwen3-VL-235B-A22B-Instruct',
[{ role: 'user', content: 'Hello' }]
);
// Process streaming response (see examples.js for full implementation)
Image Generation
// Generate image
const imageUrl = await api.generateImage(
'Tongyi-MAI/Z-Image-Turbo',
'A golden cat'
);
console.log('Generated image:', imageUrl);
When to Use References
- API Configuration: See references/api_configuration.md for setup details and supported models
- Advanced Usage: See references/advanced_usage.md for custom parameters, batch operations, and error handling
- Complete Examples: See references/examples.md for detailed usage examples including LoRA models
Key Features
- Text generation with OpenAI-compatible interface
- Image generation with asynchronous processing
- LoRA model support
- Streaming responses for text generation
- Batch image generation capabilities
Weekly Installs
1
Repository
958877748/skillsFirst Seen
5 days ago
Security Audits
Installed on
zencoder1
amp1
cline1
openclaw1
opencode1
cursor1