Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
b397954
Add changelog entry for 2025-11-24
modernchina123 Nov 26, 2025
98ec23b
Merge branch 'beingzy:main' into Joel_1126_changelog
modernchina123 Nov 27, 2025
c4c78ed
docs: add ecosystem integration section and ERC-8004/x402 post
beingzy Nov 27, 2025
24ec248
add .gitignore file to ignore tracking .DS_store files and unify the …
modernchina123 Nov 27, 2025
32887fc
Merge branch 'Joel_1126_changelog' of https://github.com/codatta/mint…
modernchina123 Nov 27, 2025
7053f69
Add changelog entry for 2025-11-24 (#8)
beingzy Nov 28, 2025
f24b4fe
docs: add ecosystem integration section and ERC-8004/x402 post (#9)
beingzy Nov 28, 2025
7ea17d6
Add changelog entries for Oct-Nov 2025 (10-14 to 12-04)
modernchina123 Dec 7, 2025
58ed02b
Merge branch 'main' into Joel_1207_changelog
modernchina123 Dec 7, 2025
a2bae3f
Add changelog entries for Oct-Nov 2025 (10-14 to 12-04) (#10)
beingzy Dec 7, 2025
e263dbb
docs: add data lineage product page and navigation
beingzy Dec 11, 2025
75e6cec
i18n: add CN/KO data lineage product pages and update Products group
beingzy Dec 11, 2025
7abc672
data lineage (#11)
beingzy Dec 12, 2025
c8330a6
docs: update pre-scan checks to include heuristic checks and AI agent…
beingzy Dec 12, 2025
cd6d002
docs: switch publication target to HuggingFace and add references
beingzy Dec 12, 2025
dc4349a
fix naming issues (data-linage.mdx -> data-lineage.mdx)
beingzy Dec 13, 2025
012bf66
docs: update pre-scan checks to include heuristic checks and AI agent…
paulhandle Dec 13, 2025
94a58fb
Update changelog: Add filters, reorganize entries, and update content…
modernchina123 Dec 22, 2025
5828d4f
Update changelog: Add filters and reorganize 2025 entries (#13)
beingzy Dec 23, 2025
0305792
doc: codatta did
Dec 28, 2025
ba20994
doc: update did
Dec 28, 2025
d72519b
Update roadmap (2026–2028) and sync CN/KO
beingzy Dec 30, 2025
cc69fc0
doc: codatta did (#14)
chababa9 Dec 30, 2025
702c516
add navigation to Codatta DID
Dec 31, 2025
52c00d7
Merge branch 'main' into feature-did
chababa9 Dec 31, 2025
b4d81ed
Update roadmap (2026–2028) and sync CN/KO (#15)
beingzy Dec 31, 2025
8a67ecf
Fix: Add missing 2027 Mesh and 2028 Nexus sections to Chinese roadmap
modernchina123 Dec 31, 2025
a183fbd
Update: Improve Chinese roadmap translation and formatting
modernchina123 Dec 31, 2025
bf1f40a
Merge branch 'main' into feature-did
chababa9 Dec 31, 2025
7943f47
Update community history for 2025–2026
beingzy Jan 4, 2026
e81bd33
Add & Improve Chinese Roadmap Translation and Formatting (#17)
beingzy Jan 4, 2026
5329ccf
add navigation to Codatta DID(cn) (#16)
beingzy Jan 4, 2026
cc19df1
Update Community History (2025 refinement + 2026 Forge) across EN/CN/…
modernchina123 Jan 4, 2026
0b82514
Update translation prompts: improve natural language expression for C…
modernchina123 Jan 4, 2026
eed99a9
chore: auto translate (20260104-110527)
invalid-email-address Jan 4, 2026
5b089ab
Fix changelog issues: unify date formats, fix parsing errors, update …
modernchina123 Jan 4, 2026
98e1c55
chore: auto translate (20260104-115629)
invalid-email-address Jan 4, 2026
b7232fc
Fix: Update translation prompts and correct proper nouns in Chinese c…
modernchina123 Jan 4, 2026
115ca7c
Fix: Correct front matter, result text, and filter labels in Chinese …
modernchina123 Jan 4, 2026
8d5ae12
chore: auto translate (20260104-124604)
invalid-email-address Jan 4, 2026
f931502
Fix: Correct front matter, result text, filter labels, and remove cod…
modernchina123 Jan 4, 2026
fe76250
refactor: Translate code comments and log messages to English
modernchina123 Jan 4, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
68 changes: 68 additions & 0 deletions .github/workflows/auto-translate.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
name: Auto Translate (Push to New Branch)

on:
push:
branches-ignore:
- main

jobs:
translate:
if: "!contains(github.ref_name, 'auto-translate')"
runs-on: ubuntu-latest

permissions:
contents: write

steps:
# 1️⃣ Checkout source branch
- name: Checkout source branch
uses: actions/checkout@v4
with:
ref: ${{ github.ref_name }}

# 2️⃣ Setup Node environment
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 20

# 3️⃣ Install dependencies
- name: Install deps
run: |
npm init -y
npm install openai fs-extra

# 4️⃣ Run translation (generate cn/ ko/ files)
- name: Run translation
env:
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
run: node translate.js
timeout-minutes: 60

# 5️⃣ Create translation branch with timestamp and push
- name: Push translated files
run: |
# Timestamp (UTC, for stability)
TS=$(date -u '+%Y%m%d-%H%M%S')

SRC_BRANCH="${GITHUB_REF_NAME}"
TRANS_BRANCH="${SRC_BRANCH}-auto-translate-${TS}"

git config user.name "github-actions"
git config user.email "github-actions@github.com"

# Create new translation branch (new each time)
git checkout -b "$TRANS_BRANCH"

# Ensure directories exist (prevent glob errors)
mkdir -p cn/changelog
mkdir -p ko/changelog

# Only add translated files
git add cn/** ko/**

# Skip commit if no changes
git diff --cached --quiet || git commit -m "chore: auto translate (${TS})"

# Push new branch
git push origin "$TRANS_BRANCH"
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.DS_Store
**/.DS_Store

109 changes: 109 additions & 0 deletions PR_DESCRIPTION.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
# 添加自动翻译系统并完善多语言 Changelog 支持

## 📋 概述

本次 PR 引入了自动翻译工作流系统,为文档添加了韩文支持,并全面改进了中文和韩文 changelog 的翻译质量和本地化体验。

## ✨ 主要功能

### 1. 自动翻译系统
- **新增 GitHub Actions 工作流** (`.github/workflows/auto-translate.yml`)
- 当推送到非 main 分支时自动触发翻译
- 自动创建翻译分支并提交翻译结果
- **新增翻译脚本** (`translate.js`)
- 使用 OpenAI API 进行智能翻译
- 支持中文和韩文翻译
- 包含重试机制和分块处理

### 2. 翻译质量改进
- **专有名词智能识别**
- 自动识别首字母大写的专有名词(产品名、模块名等)
- 固定术语规则:`Frontier`、`Crypto Frontier`、`Robotics Frontier`、`Model Comparison` 等保持英文
- 特定术语统一翻译:`Lineage` → `血缘`,`How` → `运作方式`,`Timeline` → `活动时间`,`Access` → `参与方式`,`Lock` → `锁仓`
- **自然语言表达**
- 避免直译,根据上下文用符合语言习惯的方式表达
- 例如:`action` 根据上下文翻译为 `操作`、`动作` 等,而非直译为 `行动`
- **日期格式统一**
- 中文:`2025 年 12 月 04 日`(汉字和数字之间保留空格,月份和日期补零)
- 韩文:`2025년 12월 04일`(月份和日期补零)

### 3. 多语言 Changelog 支持
- **新增韩文 changelog** (`ko/changelog/2025.mdx`)
- 完整的 2025 年 changelog 韩文翻译
- 包含所有 UI 元素的本地化
- **更新中文 changelog** (`cn/changelog/2025.mdx`)
- 改进翻译质量
- 统一日期格式
- 修复专有名词翻译
- **更新英文 changelog** (`en/changelog/2025.mdx`)
- 添加 React hooks 导入以支持交互功能

### 4. UI 元素本地化
- **Front matter(元数据)**
- 中文:`title: "变更日志"`,`description: "本文档记录了 Codatta 在 2025 年的所有更新、修复和新功能。"`
- 韩文:`title: "변경 로그"`,`description: "이 변경 로그는 2025년 Codatta의 모든 업데이트, 수정 및 새로운 기능을 문서화합니다."`
- **结果文本**
- 中文:`条结果`
- 韩文:`개 결과`
- **过滤器标签**
- 中文:全部、核心功能发布、调整与优化、修复与功能下线、活动启动
- 韩文:전체、핵심 기능 출시、조정 및 최적화、수정 및 기능 종료、캠페인 시작
- **月份标签**
- 中文:全部月份、十二月、十一月、十月等
- 韩文:전체、12월、11월、10월等

### 5. 配置更新
- **更新 `docs.json`**
- 添加韩文 changelog 导航配置

## 🐛 修复的问题

1. **解析错误修复**
- 修复韩文 changelog 中的代码块标记错误(` ```html` 和多余的 ` ````)
- 修复 JSX 解析错误

2. **翻译一致性**
- 统一专有名词处理规则
- 统一日期格式
- 统一术语翻译

3. **UI 元素翻译**
- 修复过滤器标签未翻译的问题
- 修复结果文本未翻译的问题
- 修复 front matter 未翻译的问题

## 📁 文件变更

- **新增文件:**
- `.github/workflows/auto-translate.yml` - 自动翻译工作流
- `translate.js` - 翻译脚本
- `ko/changelog/2025.mdx` - 韩文 changelog

- **修改文件:**
- `cn/changelog/2025.mdx` - 中文 changelog 更新
- `en/changelog/2025.mdx` - 英文 changelog 更新
- `docs.json` - 导航配置更新

## 🔄 工作流程

1. 开发者推送代码到非 main 分支
2. GitHub Actions 自动触发翻译工作流
3. 工作流运行 `translate.js` 脚本
4. 脚本读取英文 changelog,使用 OpenAI API 翻译为中文和韩文
5. 自动创建翻译分支(格式:`{原分支名}-auto-translate-{时间戳}`)
6. 提交翻译结果到新分支

## 📝 注意事项

- 翻译脚本需要 `OPENAI_API_KEY` 环境变量
- 工作流会自动跳过已包含 `auto-translate` 的分支,避免循环触发
- 翻译提示词已优化,确保专有名词和术语的一致性

## ✅ 测试

- [x] 中文 changelog 显示正常
- [x] 韩文 changelog 显示正常,无解析错误
- [x] 所有 UI 元素已正确本地化
- [x] 日期格式统一
- [x] 专有名词处理正确
- [x] 自动翻译工作流正常运行
Loading