Qwen-Audio-3.1-ASR-Message
Copy success!
Overview
Qwen-Audio-3.1-ASR-Flash-Message is a highly accurate, flexible, and multilingual speech recognition model based on a large language model, featuring long-context capabilities. It not only supports the seamless transcription of ultra-long audio but also allows users to specify multiple languages and specialized industry vocabulary. By integrating two distinct mechanisms for weighting custom keywords, the model achieves precise alignment in complex and specialized scenarios, significantly enhancing speech recognition accuracy in specific domains.
Input
Audio
Output
Text
Features
Prefix Completion
Enable Partial Mode when calling the Qwen API to make the model continue strictly from your provided prefix text.View docsFunction Calling
Use function calling to connect large language models with external tools and systems.View docsCache
Context Cache stores shared prefixes for long-context requests to reduce repeated computation, improve latency, and lower cost.View docsStructured Outputs
Structured Outputs help ensure the model returns a JSON string in the expected format.View docsPricing
- Input$0.93Per 1M tokens
- Output$0.7Per 1M tokens
Rate Limits
- TPMTokens Per Minute6M
- RPMRequests Per Minute1K
API Reference
Call APICopy success!
123456789101112131415161718192021222324252627
from http import HTTPStatus
import dashscope
from dashscope.audio.asr import Recognition
import os
dashscope.api_key = os.environ.get('DASHSCOPE_API_KEY')
dashscope.base_websocket_api_url='wss://ap-southeast-1.maas.qwencloudapi.com/api-ws/v1/inference'
recognition = Recognition(model='qwen-audio-3.1-asr-flash-message',
format='wav',
sample_rate=16000,
callback=None)
result = recognition.call('{YOUR_AUDIO_FILE}')
if result.status_code == HTTPStatus.OK:
print('Recognition result: ')
print(result.get_sentence())
else:
print('Error: ', result.message)
print(
'[Metric] requestId: {}, first package delay ms: {}, last package delay ms: {}'
.format(
recognition.get_last_request_id(),
recognition.get_first_package_delay(),
recognition.get_last_package_delay(),
))