| 123456789101112131415161718192021222324252627282930313233343536373839 |
- {
- "model_code": "qwen-image-plus",
- "model_intro": "通义千问系列图像生成模型,参数规模200亿。具备卓越的文本渲染能力,在复杂文本渲染、各类生成与编辑任务中表现出色,在多个公开基准测试中获得SOTA,模型性能大幅提升。",
- "model_tags": ["图片生成"],
- "model_capabilities": {
- "input_modalities": [
- "text"
- ],
- "output_modalities": [
- "image"
- ],
- "features": {
- "model_experience": true,
- "function_calling": false,
- "structured_output": false,
- "internet_search": false,
- "cache": false,
- "batch_inference": false,
- "model_optimization": false
- }
- },
- "model_pricing": {
- "image_generation": {
- "price_cny_per_image": 0.2,
- "unit": "元/每张"
- }
- },
- "model_limits": {
- "max_input_length": null,
- "max_output_length": null,
- "rpm": 120,
- "tpm": 100000
- },
- "api_examples": {
- "python": [
- "import json\\nimport os\\nimport dashscope\\nfrom dashscope import MultiModalConversation\\n\\ndashscope.base_http_api_url = 'https://dashscope.aliyuncs.com/api/v1'\\n\\nmessages = [\\n {\\n \"role\": \"user\",\\n \"content\": [\\n {\"text\": \"一副典雅庄重的对联悬挂于厅堂之中,房间是个安静古典的中式布置,桌子上放着一些青花瓷,对联上左书“义本生知人机同道善思新”,右书“通云赋智乾坤启数高志远”, 横批“智启通义”,字体飘逸,中间挂在一着一副中国风的画作,内容是岳阳楼。\"}\\n ]\\n }\\n]\\n\\n# 若没有配置环境变量,请用百炼API Key将下行替换为:api_key=\"sk-xxx\"\\napi_key = os.getenv(\"DASHSCOPE_API_KEY\")\\n\\nresponse = MultiModalConversation.call(\\n api_key=api_key,\\n model=\"qwen-image-plus\",\\n messages=messages,\\n result_format='message',\\n stream=False,\\n watermark=False,\\n prompt_extend=True,\\n negative_prompt='',\\n size='1328*1328'\\n)\\n\\nif response.status_code == 200:\\n print(json.dumps(response, ensure_ascii=False))\\nelse:\\n print(f\"HTTP返回码:{response.status_code}\")\\n print(f\"错误码:{response.code}\")\\n print(f\"错误信息:{response.message}\")\\n print(\"请参考文档:https://www.alibabacloud.com/help/zh/model-studio/error-code\")"
- ]
- }
- }
|