# 视频转文字给 LLM/RAG 用 · Video Transcript for AI Training

**Use case:** 

把中文视频批量转成带时间戳的文字稿，作为 RAG 语料或 LLM 训练数据。输出统一 JSON schema，每行都带 qualityCheck 自证字段。

## Input

```json
{
  "videoUrls": [
    "https://www.bilibili.com/video/BV1MzWU65Ewn"
  ],
  "modelSize": "base",
  "language": "zh",
  "withTimestamps": true,
  "includeMetadata": true,
  "maxItems": 10,
  "maxDurationSec": 300,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  }
}
```

## Output

```json
{
  "url": {
    "label": "Input URL",
    "format": "string"
  },
  "platform": {
    "label": "Platform",
    "format": "string"
  },
  "videoId": {
    "label": "Video ID",
    "format": "string"
  },
  "title": {
    "label": "Title",
    "format": "string"
  },
  "author": {
    "label": "Author",
    "format": "string"
  },
  "durationSec": {
    "label": "Duration (sec)",
    "format": "number"
  },
  "text": {
    "label": "Transcript text",
    "format": "string"
  },
  "segmentCount": {
    "label": "Segment count",
    "format": "number"
  },
  "charCount": {
    "label": "Character count",
    "format": "number"
  },
  "billableMinutes": {
    "label": "Billable minutes",
    "format": "number"
  },
  "hasTranscript": {
    "label": "Has transcript",
    "format": "boolean"
  },
  "qualityCheck": {
    "label": "Quality check",
    "format": "boolean"
  },
  "errorCode": {
    "label": "Error code",
    "format": "string"
  },
  "hint": {
    "label": "Hint",
    "format": "string"
  }
}
```

## How it works

### 1. Sign up on Apify or log in

The 抖音/B站视频转文字 — Douyin & Bilibili Transcript API Actor is ready to run with the inputs already set for "视频转文字给 LLM/RAG 用 · Video Transcript for AI Training". [Sign up or log in](https://console.apify.com/create-task-from-example/fv4LkuM20v4syOo2S) and you'll land in Apify Console with a copy of this exact task.

### 2. Start the "视频转文字给 LLM/RAG 用 · Video Transcript for AI Training" task

The 抖音/B站视频转文字 — Douyin & Bilibili Transcript API Actor will start running based on the input automatically. You can also change all the input fields, like video urls, whisper model, and more, to match your specific use case.

### 3. Receive the "视频转文字给 LLM/RAG 用 · Video Transcript for AI Training" output

Monitor the progress in real time. You will be notified as soon as your dataset is complete and ready for review. Each result includes data such as input url, platform, video id, and more.

### 4. Integrate into your workflow

The final output is delivered in JSON, CSV, or Excel format, ready to be plugged into your workflow. You can also [run the "视频转文字给 LLM/RAG 用 · Video Transcript for AI Training" task via API](https://apify.com/jfishpw/chinese-video-transcript.md).

## FAQ

### 输出能直接入库吗？

可以。text 是完整稿，segments 带 start/end 秒级时间戳，可做片段级引用。

### 怎么保证结果不是幻觉？

每行都带 qualityCheck，只有真正产出文字稿才为 true；未产出时 errorCode 说明原因且不计费。

## About this Actor

This example demonstrates how to use [抖音/B站视频转文字 — Douyin & Bilibili Transcript API](https://apify.com/jfishpw/chinese-video-transcript.md) with a specific input configuration. Visit the [Actor detail page](https://apify.com/jfishpw/chinese-video-transcript.md) to learn more, explore other use cases, and run it yourself.


## How to integrate an Actor?

This Task's input is already configured above. Use it as-is rather than inventing a new one.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For full API examples (JavaScript, Python, CLI, MCP, OpenAPI), see this Task's Actor page: https://apify.com/jfishpw/chinese-video-transcript.md

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).
