Skip to content

Commit b9ea7e4

Browse files
authored
chore: test (#1617)
* refactor: change translator modal * fix: translator tips * fix: prompt * test
1 parent 9f23c65 commit b9ea7e4

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

.github/workflows/docs.translate.dir.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,3 +56,8 @@ jobs:
5656
languages: "Simplified-Chinese"
5757
prompt: "You are a translation engine that has knowledge of databases and is familiar with SQL, HTML, Markdown and JSON syntax. \ Databend is a cloud-native data warehouse and an alternative to Snowflake. \ I am translating the Databend documentation for helping users.\ Translate the Markdown or JSON content I'll paste later into {targetLanguage}.\ You must strictly follow the rules below.\ - Never change the Markdown markup structure. Don't add or remove links. Do not change any URL.\ - Never change the contents of code blocks even if they appear to have a bug.\ - Always preserve the original line breaks. Do not add or remove blank lines.\ - Never touch the permalink such as `{/*examples*/}` at the end of each heading.\ - Never touch HTML-like tags such as `<Notes>`.\ - Correctly format the document for best rendering. \ - Please do not translate database or computing-specific terms.\ -Keep the structure consistent with the source document and do not delete anything.\ - if you discover to describe the plan 'Personal', please translate to '基础版'.\ -When handling document translations, please adhere to the following specific vocabulary guidelines:'time travel': should consistently be translated as '时间回溯','warehouse' or 'warehouses': should consistently be translated as '计算集群','Data Warehouse': should consistently be translated as '数仓','Self-Hosted':should consistently be translated as '私有化部署', 'Databend Cloud'、'Vector'、'Stage': should remain untranslated.\ -The key of the json object in '_category_.json' is not translated.\ - Do not include any <think> tags or their contents in the output."
5858
basePath: "https://openapi.coreshub.cn/v1"
59+
60+
- name: Remove <think> tags and contents
61+
run: |
62+
find docs/cn/ -type f \( -name '*.md' -o -name '*.json' \) -exec sed -i 's|<think>[^<]*</think>||g' {} +
63+
echo "Removed <think> tags and contents from translated files."

0 commit comments

Comments
 (0)