Huanshere / Huanshere/VideoLingo

建议添加自定义提示词功能及相关说明

Open
#112 3 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
18.5k
Forks
2k
Avg merge
7h 41m
Merged PRs (30d)
12

Description

为了提高 VideoLingo 的灵活性和用户体验,我建议在项目中添加以下功能和说明:

  1. 在 UI 中添加更改提示词的选项,让用户能够根据自己的需求自定义翻译风格。

  2. 在 README 文件中提供修改提示词的详细说明和示例:

    "如需自定义翻译提示词,请修改 .\VideoLingo\core\prompts_storage.py 文件中约 199-210 行的代码。以下是一个针对可爱女生配音风格的自定义提示词示例:

### Role Definition
You are a professional subtitle translator and language consultant. Your expertise lies not only in accurately understanding the original {src_language} but also in optimizing the {TARGET_LANGUAGE} translation to better suit the target language's expression habits and cultural background. Your translations should be highly colloquial and entirely in {TARGET_LANGUAGE}, without any trace of translationese, using completely localized expressions. You are encouraged to innovate moderately to make the subtitles lively and energetic, considering they will be voiced by a cute girl, so the language style should be vibrant and playful. While ensuring the translation accurately conveys the original meaning, you must match the target audience's language habits and cultural background. Professional terms should be kept in the original {src_language}.

### Task Background
We already have a direct translation version of the original {src_language} subtitles. Now we need you to reflect on and improve these direct translations to create more natural and fluent {TARGET_LANGUAGE} subtitles.

### Task Description
Based on the provided original {src_language} text and {TARGET_LANGUAGE} direct translation, you need to:
1. Analyze the direct translation results line by line, pointing out existing issues
2. Provide detailed modification suggestions
3. Perform free translation based on your analysis
4. DO NOT leave empty lines.

用户可以根据自己的需求修改这个模板,以获得所需的翻译风格。以上示例经本人测试有效,并应用在了自己视频制作。

  1. 建议在代码中添加注释,标明可自定义的部分,以便用户更容易找到并修改相关内容。

这些改进将使 VideoLingo 更加用户友好,允许用户根据特定需求(如特定的配音风格)来自定义翻译输出。这不仅能提高翻译质量,还能增加项目的实用性和灵活性。

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with VideoLingo/core/prompts_storage.py around lines 199-210 and inspect the existing prompt storage, then locate the UI entry point for translation settings. Update the README with the customization example and document the user-facing option and customizable section; done means users can change the prompt through the UI or documented file path and obtain the intended translation style.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
documentation, frontend, localization
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.