← 返回
内容创作

AI Video Translation

newtranx CLI for translate MP4 videos, Used for directly translating video files on the terminal. When you want to translate video files from one country's a...
newtranx命令行工具,用于在终端直接翻译MP4视频文件。
wxj127
内容创作 clawhub v1.0.0 1 版本 100000 Key: 无需
★ 1
Stars
📥 660
下载
💾 14
安装
1
版本
#latest

概述

newtranx CLI (newtranx)

Translate videos and podcasts from the terminal using the newtranx API.

Installation

npx --yes newtranx-ai

Usage Process

1. login

npx newtranx-ai login

Automatically obtain device ID, call the registration login interface to obtain token, and save it to ~/. newtranx/config. json . The token is valid for 15 days.

2. Upload videos

Supports local files and HTTP URLs, only supports mp4 format. If the format is not supported, please use ffmepg to transcode to mp4 file size not exceeding 5GB and duration not exceeding 4 hours.

Important: URLs containing ? or & must be quoted to avoid shell glob errors.


npx newtranx-ai upload ./video.mp4

# HTTP URL
npx newtranx-ai upload https://example.com/video.mp4

Restrictions:

-Format: mp4 only

-Size: not exceeding 5GB

Automatically upload videos in 4MB chunks and display upload progress. After uploading, output the task ID.

3. Submit translation task

npx newtranx-ai  translate --id <taskID> \
  --audio-lang en-US \
  --trans-lang zh-CN \
  --max-speakers 2 \
  --export-subtitle

Parameter description:

  • --id (Required): Upload the returned task ID
  • --audio-lang(Required): Call the npx newtranx-ai language command in the original language of the video to view
  • --trans-lang(Required): Call the npx newtranx-ai language command to view the target translation language
  • --max-speakers: Number of speakers
  • --export-subtitle: Do you want to merge subtitles into the video
  • --re-transwrite: Do you want to rewrite it
  • --subtitle-font-size: Subtitle Font Size
  • --subtitle-max-chars: Maximum number of characters per subtitle segment
  • --subtitle-outline-color: Subtitle outline color
  • --subtitle-primary-color: Subtitle main color

4. Regularly query query results

# default output translated video download link
npx newtranx-ai status --id <taskID>

# output original VTT subtitles download link
npx newtranx-cli status --id <taskID> --subtitle

# output translated VTT subtitles download link
npx newtranx-cli status --id <taskID> --targetSubtitle 

# output metadata include speaker information download link
npx newtranx-cli status --id <taskID> --metadata 

When 'iterationStatus==Succeeded', the result contains:

  • Translated video download link
  • Source language subtitle file link
  • Target language subtitle file link
  • Metadata file link

5. Query supported languages


npx newtranx-ai language

npx newtranx-ai language --region CN

Return a list of language codes and names that can be used for the audio lang and trans lang parameters of the translate command.

Usage Tips

  1. If the token expires, call npx newtranx ai login and then retry.
  2. It must be called according to the process.

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-03-19 20:38 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

content-creation

Humanizer

biostartechnology
消除AI写作痕迹,使文本更自然真实。基于维基百科"AI写作特征"指南,识别并修正夸张象征、宣传用语、肤浅-ing分析、模糊归因、破折号滥用、三项排比、AI词汇、负面平行结构及冗长连接词等模式。
★ 857 📥 199,438
content-creation

Baidu Wenku AIPPT

ide-rea
使用百度文库 AI 智能生成 PPT,自动根据内容选择模板。
★ 66 📥 46,148
content-creation

YouTube

byungkyu
使用托管OAuth集成YouTube Data API,支持搜索视频、管理播放列表、获取频道数据及评论互动,适用于用户需要时使用此技能。
★ 142 📥 41,033