Volcengine ASR(lecture-to-md 子 skill)
Use the deterministic scripts in scripts/; do not reproduce API requests manually.
本 skill 是
lecture-to-md的云端 ASR 子 skill。日常请走local-asr/(sherpa-onnx X-ASR,免费、跨平台、隐私友好);只有当用户明确要求云端准确率,或本地模型不足以应对时,才启用本 skill。
Choose a mode
- For
turbo-v1, runscripts/turbo_transcribe.py. It accepts a local audio/video file, extracts a 16 kHz mono MP3, sends Base64 in one synchronous request, and writes JSON/TXT/SRT/Markdown. - For
standard-v1,idle-v1, orstandard-v2, first runscripts/upload_submit.py, then runscripts/poll_transcript.pywith the resultingjob.json. - Prefer
standard-v2when the user has opened 豆包录音文件识别模型 2.0. - Local asynchronous inputs require TOS credentials. If a direct-download HTTP(S) URL already exists, pass
--audio-urland skip TOS.
Read references/api-modes.md before changing endpoints, resource IDs, limits, or request fields.
Credentials
Read credentials from .secret in this skill directory. Never print or copy credential values into results. .secret must remain gitignored and mode 0600.
The ASR v3 calls use only VOLCENGINE_ASR_APP_ID and VOLCENGINE_ASR_ACCESS_TOKEN. VOLCENGINE_ASR_SECRET_KEY is retained locally but not sent. TOS uses a separate account-level AK/SK, endpoint, region, and bucket.
Commands
When .venv is absent, prepare the optional TOS dependency once:
bashpython3 -m venv .venv .venv/bin/python -m pip install -r requirements.txt
upload_submit.py automatically re-executes with this environment for local TOS uploads.
Turbo 1.0:
bashpython3 scripts/turbo_transcribe.py "/absolute/path/video.mp4"
Submit a local 2.0 standard job through TOS:
bashpython3 scripts/upload_submit.py \ --mode standard-v2 \ --input "/absolute/path/video.mp4"
Poll the generated job:
bashpython3 scripts/poll_transcript.py "/absolute/path/job.json"
For a pre-existing direct URL:
bashpython3 scripts/upload_submit.py \ --mode standard-v2 \ --audio-url "https://example.com/audio.mp3"
Operating rules
- Check that the requested service is open before a paid call. Do not invent undocumented
seedasrTurbo or idle resource IDs. - When testing multiple modes, use different source videos so paid/free ASR time produces useful, non-duplicate transcripts.
- Keep the TOS bucket private and use only short-lived pre-signed GET URLs.
- Leave a reusable
job.jsonwhen polling times out. Delete the TOS object only after a terminal success/failure unless the user passes--keep-upload. - Report the absolute paths of
transcript.txt,transcript.srt, andresult.jsonafter success.


