没有不值得去解决的问题,也没有不值得去学习的技术!

Why I Reassessed the Minimal-Protect Translation Mode After Completing the Chinese Translation of A Tour of Go

[Figure 1: Current official Chinese methods/24 page, example code on the right runs successfully]

作者:

在

The first phase of A Tour of Go in Simplified Chinese is complete.

Currently, all 103 lesson pages have entered the ready state. The public UI, article metadata, production publishing, example code execution and formatting have also been completed one after another. In other words, the current Chinese version is no longer an experimental project waiting to be filled in, but a complete version that can actually be accessed and studied.

However, after completing the first phase, I returned to a previously shelved question:

Does the current protected-token translation mode protect too much?

If we further reduce protection and let GLM-5.2 see more complete, authentic English page context, can we continue to improve translation quality?

Moreover, this question is no longer solely about Simplified Chinese.

The entire project was designed for multilingual support from the very beginning. If we continue to add other languages that are not officially provided, have ceased maintenance, or need to be retranslated, the translation methods developed now will likely continue to be used.

Therefore, revisiting minimal-protect mainly aims to answer two questions:

Can we continue to improve translation quality?

And:

Which protection capabilities can serve as shared infrastructure across languages, and which rules should be determined by the specific language itself?

[Figure 1: Current official Chinese methods/24 page, example code on the right runs successfully]
[Figure 1: Current official Chinese methods/24 page, example code on the right runs successfully]

1. The first phase is complete; it is finally time to revisit the translation input architecture

The entire first phase of A Tour of Go in Simplified Chinese consists of 103 lesson pages.

The current status is:

Plaintext
total=103
ready=103
pending=0
blocked=0
[Figure 2: zh-CN 103 / 103 ready]
[Figure 2: zh-CN 103 / 103 ready]

Before the first phase of translation was complete, I had actually already explored a more open translation input method once.

But at that time, the most important goal of the project remained:

First, stably translate all 103 official lesson pages.

Therefore, between the mature protected-token mode verified across many pages and the minimal-protect mode which still had unknown issues, it was reasonable to continue using the mature solution at the time.

The situation is now different.

After all 103 pages are complete, even if we continue experimenting with the translation architecture, it will no longer block the first phase release.

Thus, now is the perfect time to answer this question again:

While ensuring page structure safety, exactly how much content needs to be protected?

2. What level is the current Chinese translation roughly at?

Before deciding whether it is worth retranslating, I first reviewed the current Chinese translation quality.

The score here is not a formal rating from a professional translation agency, nor is it a statistical result from sentence-by-sentence manual proofreading of all 103 pages. Rather, it is an engineering estimate based on representative pages, existing official translations, the English original, and the long translation process.

If we use 100 as the full score, my current estimate for the official zh-CN version is:

About 94 points, with a reasonable range of roughly 93–95 points.

The main current advantages include:

  • Mostly accurate conveyance of the English original meaning;
  • Relatively stable Go technical terminology;
  • Very little obvious machine translation tone in the Chinese text;
  • Generally coherent context across the whole page;
  • Relatively natural tutorial-style expressions;
  • All 103 pages pass the unified structure and page validation.

So the reason for revisiting minimal-protect now is not because the current translation quality is poor.

Quite the opposite:

It is about continuing to find room for improvement after achieving relatively high quality.

If minimal-protect eventually matures, my expected goal for it is currently around:

96–97 points.

In other words, I do not expect it to bring a massive improvement of over ten points.

A more realistic goal might just be:

Plaintext
Current official version: ~94
        ↓
Mature minimal-protect: ~96–97

But for a project where “translation” is the core product, these two or three points are still worth researching.

In an ordinary software project, a 94-point translation might be sufficient.

But one of the core values here has always been:

Bringing the official A Tour of Go to more languages with the highest possible quality.

Therefore, further improving translation quality is itself a product upgrade.

3. A historical quality reference: the discontinued Go-zh

While rethinking translation quality, I also looked back at the former Go-zh Chinese Tour.

Go-zh once maintained a rather high-quality Chinese translation of A Tour of Go, and it was one of the more representative projects in the Chinese Go community in the past.

The corresponding website is no longer functional, the code repository has been archived, and the content remains from an earlier era, without covering all the lessons in the current new version of A Tour of Go.

In fact, its discontinuation was one of the reasons that later prompted me to seriously consider creating a sustainably maintainable version.

If we temporarily ignore whether the project is currently online and only evaluate the Chinese text completed back then, my current engineering estimate is approximately:

90–93 points.

Many of its translations clearly bear the marks of human translation and long-term maintenance; the Chinese expression is quite mature, and some technical concepts are handled very well.

So I think it is still very suitable as a historical quality benchmark.

This also sets a rather clear requirement for the current project.

The new project cannot simply assume that the translation work is complete just because of:

Plaintext
Source code updates
+
Website accessibility
+
More lessons

At least for Simplified Chinese, what I hope to achieve is:

Plaintext
Updated content
+
Complete coverage
+
Functional features
+
Reliable structure
+
Translation quality that meets or exceeds past mature human works

I currently believe the official zh-CN version has basically achieved this goal.

Next, researching minimal-protect is about continuing to seek a higher quality ceiling.

4. Why protected-token guarantees stability

The current mature default translation process can be roughly understood as:

Plaintext
Complete English lesson page
↓
Identify high-risk structures
↓
Replace with protected tokens
↓
GLM-5.2 full-page translation
↓
Restore protected tokens
↓
present parsing
↓
Structure comparison
↓
Page validation
↓
ready

The biggest advantage of this method is stability.

Content like the following can be protected before translation:

Plaintext
.play directive
link target
inline code
preformatted code
other machine structures easily modified by the model

The model is mainly responsible for the natural language content that actually needs translating.

This is also a key reason why the first phase was ultimately able to achieve 103 / 103 ready.

However, a stronger protection mechanism also implies another issue:

The model can directly see less and less of the original page context.

For example, if an English technical term originally appears simultaneously in the body text, links, inline code, and other structures, and many of these parts are replaced with:

Plaintext
__PROTECTED_TOKEN_001__
__PROTECTED_TOKEN_002__

Then from the model’s perspective, the originally continuous semantic environment is effectively partially severed.

For Simplified Chinese, this impact might not be particularly obvious yet.

But if we expand to more languages later, different languages may also involve:

  • Word order;
  • Singular and plural forms;
  • Gender;
  • Case;
  • Articles;
  • Inflection;
  • Contextual references.

At that point, whether the model can see the complete context will become even more important.

5. What really attracts me to minimal-protect: leaving more real context for the model

So the most important reason for revisiting minimal-protect remains translation quality.

Its basic idea is not:

To protect as much potentially variable content as possible.

But rather:

Only remove the machine structures that the model absolutely must not modify, and hand over the rest of the real page as completely as possible for the model to understand.

This means the model no longer sees a page heavily fragmented by placeholders, but context much closer to the actual source file.

From a translation perspective, this is very important.

Because what language models are truly good at has always been:

Understanding what a sentence actually means based on context.

If we artificially cut out a large amount of context before feeding it to the model, then even if the structure is safer, we might sacrifice language understanding space.

So I now lean more towards:

Plaintext
Preserve as much complete context as possible
+
Only prohibit modifications to a few machine structures
+
Ultimately let a strict validator judge whether it passes

6. raw-input proved the direction, but also proved that zero protection is unfeasible

The most radical experiment is raw-input.

It basically stops doing extensive structural protection and directly hands the raw page to GLM-5.2:

Plaintext
Complete raw page
↓
GLM-5.2
↓
validator

The benefits of this approach are very obvious:

The model can see the most complete context.

But the problems are equally obvious.

On the methods/24 page, the raw content includes:

Plaintext
.play methods/images.go

In the raw-input experiment, the model successively modified it into something like:

Plaintext
.play methods/images.go /zh-cn/methods/24

And:

Plaintext
.play methods/images.go /src/methods/images.go

For a natural language model, these changes might just be a “seemingly reasonable” addition.

But for present, .play is a machine instruction.

It is not natural language, nor can it be freely rewritten by the model.

So while raw-input maximized context, it also opened up modification permissions that the model should never have had.

This shows that:

Zero protection is not the right answer either.

What really needs to be found is a middle ground.

7. minimal-protect: Only protect structures proven to be dangerous

And so we have minimal-protect.

For example, in methods/24, we first only protect the complete .play:

Plaintext
.play methods/images.go

This entire line is given to the model as an unmodifiable token.

The experimental results are clear.

The .play rewrites that occurred twice in a row in raw-input disappeared in minimal-protect.

Plaintext
.play protected/restored: OK
.play mutated: NO

That is to say:

This layer of .play issues has been successfully resolved by minimal protection.

[Figure 3: methods/24 raw-input and minimal-protect experiments]
[Figure 3: methods/24 raw-input and minimal-protect experiments]

However, this page still did not pass final validation.

The validator then found:

Plaintext
link inline-code count mismatch
expected=0 actual=1

After continuing the experiment, we encountered:

Plaintext
font span count mismatch
expected=10 actual=9

This is actually a very valuable part of the minimal-protect experiment.

Because it shows the validator is working as expected:

Plaintext
Reduce protection
↓
Let the model handle more real context
↓
Real structural errors occur
↓
Validator pinpoints the problem
↓
Then determine if this type of structure really needs restriction

Rather than assuming from the start:

All structures that could theoretically cause problems must be protected in advance.

8. Same page: 15 protected tokens reduced to 1

methods/24 also provides a very intuitive comparison.

On the same page, with the same source SHA and the same glm-5.2 model, the default protected-token used:

Plaintext
15 protected tokens

Including:

Plaintext
9 inline-code spans
4 link targets
1 preformatted code block
1 .play directive

The actual request record at that time was:

Plaintext
prompt_tokens=1660

While in the minimal-protect attempt-005, only the following is protected:

Plaintext
1 complete .play directive

Corresponding to:

Plaintext
prompt_tokens=1449

That is:

Plaintext
15 → 1

14 fewer protected tokens.

The raw page structures the model can directly see are also clearly more abundant.

[Figure 4: protected-token vs. minimal-protect protection scope comparison]
[Figure 4: protected-token vs. minimal-protect protection scope comparison]

A special note here is needed:

The drop in prompt_tokens from 1660 to 1449 is the result observed across two real requests.

It cannot simply be assumed that this 211-token gap is entirely caused by the reduction in the number of protected tokens.

Token reduction is certainly a side benefit.

But more important than saving tokens is:

More raw content re-enters the context that the model can actually understand.

9. Across languages, how much can the protection rules actually be reused?

There is another question here for which I am not ready to draw premature conclusions:

If other languages are added in the future, how much of the existing protected-token and minimal-protect implementations can actually be reused?

Structurally speaking, I currently believe it can at least be divided into two layers.

The first layer consists of machine structures that are clearly language-independent.

For example:

Plaintext
.play directive
code paths
unmodifiable link targets
static code blocks
present directives
page structure parsing
token restoration integrity
structure count comparison

Regardless of whether translating to Chinese, Japanese, German, or any other language, these remain essentially the same kind of machine structures.

Therefore, their:

Plaintext
Identification
Placeholder substitution
Restoration
Validation
Testing

Most likely have high reuse value.

This is also a significant asset accumulated by protected-token so far.

But the second layer might not be entirely reusable.

For example:

Plaintext
Whether a certain inline code definitely needs protection
Whether a certain emphasis structure is allowed to change position
How terminology is handled
Spacing between natural language and code
Punctuation habits
Inflection
Which language-specific errors the model is prone to make

These issues are very likely dependent on the target language.

So a more realistic architecture in the future might not be:

Plaintext
All languages share the exact same protection rules

But rather:

Plaintext
Shared machine structure protection capabilities
+
Each language chooses its own minimal protection strategy

For example:

Plaintext
Universal layer
├─ .play identification and restoration
├─ present structure parsing
├─ link target validation
├─ code block validation
└─ validator

zh-CN
└─ zh-CN minimal protection policy

Future language A
└─ language-A minimal protection policy

Future language B
└─ language-B minimal protection policy

This is more accurate than simply claiming “minimal-protect definitely makes the multilingual architecture simpler.”

What really needs to be verified now is:

To what extent can universal machine structure capabilities be reused, and to what extent do protection strategies for different languages need to be differentiated.

If we ultimately find that most underlying capabilities can be shared, and each language only needs to maintain a few policy differences, then the long-term maintenance value of minimal-protect will be very clear.

If actual results prove that different languages require a large number of completely different rules, then the architectural design should also be adjusted based on the real situation.

So for now, this point is better treated as:

An engineering problem to be verified in the next phase.

Rather than a proven conclusion.

10. protected-token will not be deprecated

Even if minimal-protect is ultimately chosen, the extensive work done previously by protected-token will not go to waste.

Many mature capabilities have already been accumulated during the first phase of development:

Plaintext
Structure identification
Token placeholder substitution
Restoration
Count validation
Structure comparison
Error classification
Regression testing

These capabilities themselves and “how many protection rules are enabled by default” are two different things.

So the ideal relationship going forward might be:

Plaintext
protected-token
=
A library of protection capabilities verified across many real pages

minimal-protect
=
Enabling the minimum necessary rules from the capability library
based on the target language and real failures

For example, .play already has very clear experimental backing.

Then minimal-protect has no need to reinvent the identification and restoration methods for .play.

It can just directly reuse the existing mature implementation.

If future experiments later prove that:

A certain structure indeed must be protected.

We would likewise first check if protected-token already has a mature capability for it.

This way, the experience accumulated in the first phase can continue to play a role, rather than starting from scratch.

11. Next step: re-verify the original 7 representative pages

Even if the minimal-protect direction is very appealing, I am not currently planning to directly retranslate all 103 pages.

First, we will still use the 7 representative pages that were continuously verified during the first phase of development:

Plaintext
generics/1
flowcontrol/8
methods/16
methods/20
concurrency/7
concurrency/11
methods/24

Continuing to use the same set of pages has a major benefit:

It keeps the experimental criteria consistent between the first phase and the next phase.

Next, the key aspects to observe are:

Plaintext
Language quality
Validator pass rate
Retry count
Blocked status
Number of protection rules
Token usage

The most important among them remains a single question:

Is the language quality improvement brought by minimal-protect enough to offset the potentially increased structural failures and retry costs?

If it ultimately only improves slightly from around 94 points, but clearly increases the failure rate, then the significance of retranslating all pages is quite limited.

But if the representative pages can stably approach:

96–97 points

While the validator pass rate and retry costs remain acceptable, then this path is worth pursuing further.

12. What truly decides whether to switch is not just whether the validator passes

For this project, I am increasingly clear on one thing:

Structural correctness is merely a publishing threshold, not translation quality itself.

Even if a page has:

Plaintext
present parse = PASS
directive = PASS
link = PASS
inline code = PASS
render = PASS

It only proves that:

The page was not broken by translation.

It does not prove:

This is the best translation that can be achieved.

If a translation project solely pursues long-term:

Plaintext
Structural integrity

It will easily end up with “correct but stiff” translations.

And what I truly hope this project pursues is:

Plaintext
Accuracy
+
Naturalness
+
Complete context
+
Terminology consistency
+
Clear instructional expression
+
Structural safety

So the validator and translation quality actually play different roles:

Plaintext
validator
=
Determines if the translation is eligible for publishing

Translation quality
=
Determines the ultimate level this project can achieve

Neither can be missing.

13. If minimal-protect is ultimately adopted, we will still proceed in batches of 10 pages

If the 7 representative pages ultimately prove that minimal-protect is stable enough and the actual translation quality is indeed better, then when retranslating zh-CN later, I still plan to follow the pace that has become quite familiar in the first phase:

Plaintext
Batch of 10 regular pages
↓
GLM-5.2 full-page translation
↓
Unified validator
↓
Handle real failures
↓
Next batch

We will not rerun all 103 pages all at once.

This pace has proven to be quite suitable for the current project.

It neither progresses too slowly due to batches being too small, nor does it allow a new structural issue to affect a large number of pages at once due to an overly large scope.

When encountering a new type of failure, we will first pause expanding the scope and determine:

Is this an occasional model behavior, or a structural risk that indeed needs to be added to minimal-protect?

If protection is indeed needed, we will prioritize reusing the implementation experience already accumulated by protected-token.

14. What we really need to find now is the “minimum necessary protection set”

The problem solved in the first phase was:

How to stably complete 103 Chinese pages.

The problem we hope to solve now goes a step further:

While ensuring the safety of all machine structures, what is the exact minimum content that needs to be protected?

I currently hope the final translation process will be:

Plaintext
As complete original page context as possible
↓
A few machine structures proven necessary to protect through real failures
↓
GLM-5.2 full-page translation
↓
Minimal restoration
↓
Strict unified validator
↓
Retry for real failures

For Simplified Chinese, this path first needs to prove one thing:

Can we stably improve the current ~94-point translation to closer to 96–97 points.

For other future languages, another question will need continued verification:

Which underlying structural capabilities can be fully shared, and which minimal protection rules must be adjusted per language.

It is not yet time to declare that minimal-protect will definitely become the final default mode.

The 7 representative pages still need re-verification, new failure types still need continued observation, and the final translation quality still needs real comparison.

But after completing the 103 pages in the first phase, we can finally stop considering only:

How to safely translate the pages.

And start seriously studying:

How to translate them better.

And:

After adding more languages, how to maximize the reuse of machine structure protection, without imposing unnecessary uniform restrictions on different languages.

This is the true significance of returning to minimal-protect this time.

关于作者 · 持续学习与技术实践

我是一名拥有 15 年以上开发经验的技术从业者,自 2013 年起持续运营个人技术博客,记录工作与个人项目中遇到的真实问题,以及解决问题过程中的探索、实践和思考。

除了技术写作,我也在持续开发和维护自己的独立项目,探索新技术和新工具在实际场景中的应用。我始终相信,没有不值得去解决的问题,也没有不值得去学习的技术。

如果这篇文章对你有所帮助,欢迎浏览博客中的其他文章,也欢迎交流技术经验与想法。

关于我  ·  GitHub  ·  邮件联系