Skip to content

[action-translation] resync: career.md - #188

Merged
mmcky merged 2 commits into
mainfrom
resync/career
Jul 22, 2026
Merged

[action-translation] resync: career.md#188
mmcky merged 2 commits into
mainfrom
resync/career

Conversation

@mmcky

@mmcky mmcky commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Forward Resync: career.md

Source: QuantEcon/lecture-python.mystlectures/career.md
Source commit: 775c47c
This PR resyncs the translation to match the current source document.

Reason: The Chinese translation uses an entirely different (older) implementation based on NumPy/Numba/quantecon.random instead of the JAX-based implementation in the source. Missing content includes: 'Job Search VI' title (says V), gpu.md include admonition, JAX imports, NamedTuple-based CareerWorkerProblem factory function, jax.vmap-based Bellman operator implementation, jax.lax.while_loop solve_model, the note about JAX scaling to GPU/25000 simulations, jax-based simulate_path and passage_time functions using jr.split/jax.lax.scan/jax.vmap. The target instead has older numba/quantecon-based code for gen_probs, CareerWorkerProblem class, operator_factory, solve_model, gen_path, passage_time, median_time - substantively different implementation details throughout Implementation section and exercises. This represents significant CONTENT_CHANGES since the source has been updated to a JAX-based approach but the translation still reflects the old NumPy/Numba approach.

Changes

Whole-file resync applied. The entire document was resynced in a single pass.


Created by action-translation forward resync

Copilot AI review requested due to automatic review settings July 21, 2026 23:21
@mmcky mmcky added action-translation-sync CLI resync PR (translate forward --github) resync Forward resync labels Jul 21, 2026
@netlify

netlify Bot commented Jul 21, 2026

Copy link
Copy Markdown

Deploy Preview for astonishing-narwhal-a8fc64 ready!

Name Link
🔨 Latest commit 8ae3b2d
🔍 Latest deploy log https://app.netlify.com/projects/astonishing-narwhal-a8fc64/deploys/6a600c99f87f4d0008a16511
😎 Deploy Preview https://deploy-preview-188--astonishing-narwhal-a8fc64.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copilot AI 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.

Pull request overview

This PR forward-resyncs the Chinese translation of lectures/career.md to match the upstream JAX-based implementation in the source repository, replacing the older NumPy/Numba/quantecon.random approach and bringing headings/content back in sync.

Changes:

  • Resynced the lecture content to a JAX-based implementation (imports, Bellman operator via jax.vmap, solver via jax.lax.while_loop, and simulation via jax.lax.scan / jax.vmap).
  • Added GPU include admonition and updated exercise/solution blocks to match current source structure.
  • Added translation sync state metadata for career.md.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.

File Description
lectures/career.md Full-document resync to the upstream JAX-based lecture version, including new code cells, headings, and exercises.
.translate/state/career.md.yml Records the source commit SHA and resync metadata for translation tracking.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread lectures/career.md
v_star, _, _ = solve_model(cw)
greedy_star = get_greedy(v_star, cw)

key = jr.key(42)
Comment thread lectures/career.md
Comment on lines +394 to +396
def draw(key, cdf):
"根据给定的累积分布函数从分布中抽取一个下标。"
return jnp.searchsorted(cdf, jr.uniform(key), side="right")
Comment thread lectures/career.md
return jnp.median(times)


median_passage_time(cw, greedy_star, jr.key(42))
Comment thread lectures/career.md
v_patient, _, _ = solve_model(cw_patient)
greedy_patient = get_greedy(v_patient, cw_patient)

median_passage_time(cw_patient, greedy_patient, jr.key(42))
@github-actions

github-actions Bot commented Jul 21, 2026

Copy link
Copy Markdown

@github-actions
github-actions Bot temporarily deployed to pull request July 21, 2026 23:27 Inactive
@mmcky mmcky added the action-translation PRs created by QuantEcon/action-translation label Jul 21, 2026
@github-actions

github-actions Bot commented Jul 21, 2026

Copy link
Copy Markdown

✅ Translation Quality Review

Verdict: PASS | Model: claude-sonnet-5 | Date: 2026-07-22


📝 Translation Quality

Criterion Score
Accuracy 9/10
Fluency 9/10
Terminology 9/10
Formatting 10/10
Overall 9.2/10

Summary: This is a high-quality, accurate, and fluent translation that faithfully preserves the technical content, mathematical notation, and code structure of the source document. Terminology usage aligns well with the provided glossary, and formatting/MyST directives are fully intact. Minor stylistic differences exist in a few sentences where the translation is slightly more elaborative than the source, but these do not affect accuracy or clarity in any meaningful way. Mathematical notation, LaTeX equations, and code cells are fully preserved and correctly formatted throughout. Technical terminology (贝尔曼算子, 贴现因子, 贪婪策略, 价值函数, etc.) is consistent with the glossary and used correctly across the document. The added translation metadata block and font-loading code insertion are appropriately handled without disrupting document structure. Complex JAX-related technical explanations (vmap, in_axes, while_loop) are translated clearly and accurately, preserving technical precision.

Suggestions:

  • Model Features section: '模型中的个体们通过选择职业和职业内的工作来最大化预期的贴现工资收入' adds interpretive phrasing ('模型中的个体们') not present in the concise English bullet 'Career and job within career both chosen to maximize expected discounted wage flow' — consider a more literal, terse rendering to match the source's telegraphic style.
  • Overview::Model Features heading: the English H3 'Model Features' is translated as '模型特点' which is accurate, but verify consistency with any other occurrences of 'Model Features' elsewhere in the site glossary for uniformity.
  • Section 'And here is the optimal policy' → '这就是最优策略' is accurate but slightly less formal than 'Here is the optimal policy'; minor stylistic point, not a significant issue.
  • In career_ex2 solution, '现在让我们考虑从起点...劳动者需要多长时间才能找到一份永久性工作' slightly rephrases 'how long it takes for the worker to settle down to a permanent job' — acceptable but could more directly mirror 'settle down to a permanent job' as '安定到一份永久性工作' for closer fidelity.

🔍 Diff Quality

Check Status
Scope Correct
Position Correct
Structure Preserved
Heading-map Correct
Overall 10/10

Summary: The resynced target correctly mirrors the current English source's structure, code, and content, with an appropriately updated translation metadata block.


This review was generated automatically by action-translation review mode.

Addresses the terminology-consistency and emphasis suggestions from the AI review on #188. The 维持现状/保持现状 variants predate this resync on main; unified on the definitional term.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@mmcky

mmcky commented Jul 22, 2026

Copy link
Copy Markdown
Contributor Author

Re the review's three suggestions:

Suggestions 1–2 addressed in 8ae3b2d: 'stay put' is now 原地不动 in all ten occurrences (the 维持现状/保持现状 variants predate this resync on main — the resync had already narrowed 10 mixed usages down to 3), and 职业/工作 in the model definition now carry bold emphasis matching the source's **career**/**job**.

Suggestion 3 is a false positive: the FONTPATH/mpl.font_manager block is the approved site-wide CJK convention (#22), not a translation artifact — it's the i18n adaptation the engine deliberately preserves (its removal is the defect class in QuantEcon/action-translation#107). No change needed.

The recurring-phrase consistency gap itself is now a feature request on the engine — see the issue linked below.

@github-actions
github-actions Bot temporarily deployed to pull request July 22, 2026 00:25 Inactive
@mmcky
mmcky merged commit 38dcb2d into main Jul 22, 2026
7 checks passed
@mmcky
mmcky deleted the resync/career branch July 22, 2026 00:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

action-translation PRs created by QuantEcon/action-translation action-translation-sync CLI resync PR (translate forward --github) resync Forward resync

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants