Skip to content

Add replaceable Chinese Skill variant - #38

Merged
GhostXia merged 5 commits into
mainfrom
codex/chinese-skill
Aug 12, 2026
Merged

Add replaceable Chinese Skill variant#38
GhostXia merged 5 commits into
mainfrom
codex/chinese-skill

Conversation

@GhostXia

@GhostXia GhostXia commented Aug 12, 2026

Copy link
Copy Markdown
Owner

Summary

  • keep .agents/skills/lean-dev-router/SKILL.md byte-identical to the current English main Skill
  • add skill-variants/en/SKILL.md as the exact English restore copy
  • add skill-variants/zhcn/SKILL.md as the compact Chinese test variant
  • document separate one-command PowerShell replacement and restore flows for local testing
  • validate both language variants while ensuring the installed Skill directory exposes only the English root entry

Local replacement

Enable the Chinese test variant:

Copy-Item skill-variants/zhcn/SKILL.md "$env:USERPROFILE/.codex/skills/lean-dev-router/SKILL.md" -Force

Restore the English release default:

Copy-Item skill-variants/en/SKILL.md "$env:USERPROFILE/.codex/skills/lean-dev-router/SKILL.md" -Force

Start a fresh Codex task after either replacement.

Static compression

Metric English Skill Chinese variant Change
Characters 11,907 7,253 -39.1%
Repository regex words 1,500 854 -43.1%

The regex word count is a repository budget metric, not a model-token measurement.

Real-context forward test

Two counterbalanced pairs of fresh subagents (fork_turns: none) read one variant each and answered the same eight routing scenarios. Actual token_count events were used instead of character or regex-word estimates.

Pair English second-call input Chinese second-call input Chinese delta
English launched first 24,271 24,855 +584
Chinese launched first 24,411 25,032 +621
Mean 24,341 24,943.5 +602.5 (+2.48%)

The second call is the first model request containing the loaded Skill. Server cache hits varied, so the comparison uses full input-context tokens, not uncached billing tokens. Launch order reversed between pairs and produced the same direction.

Both variants made the correct authority, revision, repair, scope-escalation, spinning-fuse, and abandoned-audit decisions in all eight cases. A fresh blind judge found no material semantic difference; the Chinese sample was slightly more explicit in two answers, but not behaviorally different.

Decision: retain English as the release default. Chinese did not satisfy the switch criterion of equal-or-better quality and lower measured real-context input usage. It remains available as the replaceable test variant.

Validation

  • python -B -m unittest discover -s tests - 59 passed, 1 skipped on Windows
  • python -B scripts/validate_repo.py - passed
  • Skill Creator quick_validate.py - root, English, and Chinese variants passed under UTF-8 mode
  • git diff --check - passed
  • root English Skill, English variant, and origin/main Skill have the same Git blob hash
  • two counterbalanced fresh-subagent forward-test pairs completed all eight cases per variant
  • blind quality audit found no material semantic difference between variants
  • CodeRabbit review completed; all six review threads were addressed and resolved

@coderabbitai

coderabbitai Bot commented Aug 12, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

The PR adds English and Chinese lean-dev-router Skill variants, expands validation for both documents, synchronizes the root Skill with English, and documents installation, replacement, restoration, and maintenance procedures.

Changes

Router Skill variants

Layer / File(s) Summary
Authority and dispatch contracts
skill-variants/en/SKILL.md, skill-variants/zhcn/SKILL.md
Defines role authority, planning waves, dispatch contracts, result schemas, and mechanical status routing.
Scope, budgets, and streaming execution
skill-variants/en/SKILL.md, skill-variants/zhcn/SKILL.md
Defines scope checks, revision identity, runtime budgets, replay controls, streaming results, and audit registration.
Causal audit and task completion gates
skill-variants/en/SKILL.md, skill-variants/zhcn/SKILL.md
Defines causal audits, bounded repairs, multi-batch integration, human authorization, and terminal states.
Variant-aware repository validation
scripts/validate_repo.py, tests/test_validate_repo.py
Validates both language variants, requires root-to-English equality, applies language-specific checks, and tests non-ASCII handling.
Variant installation and maintenance guidance
README.md, docs/zh-CN/README.md
Documents variant selection, replacement and restoration commands, fresh-task requirements, and maintenance boundaries.

Estimated code review effort: 3 (Moderate) | ~30 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: adding a replaceable Chinese Skill variant.
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/chinese-skill

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@GhostXia GhostXia changed the title Add compact Chinese Skill text Add replaceable Chinese Skill variant Aug 12, 2026
@GhostXia
GhostXia marked this pull request as ready for review August 12, 2026 05:35

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 6

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@docs/zh-CN/README.md`:
- Around line 136-137: 更新 docs/zh-CN/README.md 中相邻的 CI 语言规则说明,使其准确反映
scripts/validate_repo.py 的行为:非 ASCII 检查不适用于
.agents/skills/lean-dev-router/SKILL.md,而不是声称所有 .agents/ 文件都会被拦截。

In `@README.md`:
- Around line 304-307: Separate the Chinese replacement and English restoration
commands into distinct, clearly labeled blocks in README.md lines 304-307 and
docs/zh-CN/README.md lines 112-115, so users can run the Chinese command for
testing without immediately executing the restoration command.

In `@skill-variants/en/SKILL.md`:
- Around line 129-134: Clarify the revision fingerprint wording in
skill-variants/en/SKILL.md lines 129-134 by stating that all authorized tracked
diffs, including text and binary changes using Git’s binary-safe encoding, are
included. Apply the equivalent clarification in skill-variants/zhcn/SKILL.md
line 104, replacing “tracked binary diff” with wording covering both tracked
text and binary diffs.
- Around line 199-205: Update the repair-packet documentation in
skill-variants/en/SKILL.md lines 199-205 to include PLAN_ID, REPAIR_CYCLE,
REVISION, and EVIDENCE_FINGERPRINT alongside the existing identity, acceptance,
affected-path, and evidence fields. Update skill-variants/zhcn/SKILL.md lines
133-134 with the same required fields, or reference the exact runtime-guard
schema; ensure both variants fully document the packet consumed by the runtime
guard.

In `@skill-variants/zhcn/SKILL.md`:
- Around line 112-114: 将中文版本中“技术证据不足时请求 planning_resolution”改为请求
technical_resolution,使其与英文版本及路由表保持一致;保留 planning_resolution 仅用于 Terra 向 Sol
升级规划问题的语义。
- Line 8: 更新该中文 Skill 的代理职责描述,移除“Terra 审计并解决技术问题”中的修复权限,明确 Terra
仅可提供因果证据和有界修复建议;保留 Sol 的规划授权、父代理的机械调度以及 Luna 的写入职责,并与第 19、135 行的只读约束一致。
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 669baa99-299f-478e-935e-f4609af6742c

📥 Commits

Reviewing files that changed from the base of the PR and between af1d45a and 8eba030.

📒 Files selected for processing (6)
  • README.md
  • docs/zh-CN/README.md
  • scripts/validate_repo.py
  • skill-variants/en/SKILL.md
  • skill-variants/zhcn/SKILL.md
  • tests/test_validate_repo.py

Comment thread docs/zh-CN/README.md
Comment thread README.md
Comment thread skill-variants/en/SKILL.md
Comment thread skill-variants/en/SKILL.md
Comment thread skill-variants/zhcn/SKILL.md Outdated
Comment thread skill-variants/zhcn/SKILL.md Outdated
@GhostXia
GhostXia merged commit 242d4e7 into main Aug 12, 2026
2 checks passed
@GhostXia
GhostXia deleted the codex/chinese-skill branch August 12, 2026 11:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant