Skip to content

Commit c505b92

Browse files
committed
Add Week 12 Report by Aman Chadha
1 parent f0459e0 commit c505b92

File tree

1 file changed

+93
-0
lines changed

1 file changed

+93
-0
lines changed
Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
---
2+
title: "DMP '25 Week-12 Report by Aman Chadha"
3+
excerpt: "Concluding my DMP '25 project: Migrating Music Blocks’ localization from webL10n.js to i18next and building an AI-assisted translation system with contextual support."
4+
category: "DEVELOPER NEWS"
5+
date: "2025-09-08"
6+
slug: "2025-09-08-dmp-25-aman-chadha-week12"
7+
author: "@/constants/MarkdownFiles/authors/aman-chadha.md"
8+
tags: "dmp25,sugarlabs,finalreport,aman-chadha"
9+
image: "assets/Images/c4gt_DMP.png"
10+
---
11+
12+
<!-- markdownlint-disable -->
13+
14+
# Final Report by Aman Chadha
15+
16+
Project: [JS Internationalization with AI Translation Support](https://github.com/sugarlabs/musicblocks/pull/4731)
17+
Mentors: [Walter Bender](https://github.com/walterbender), [Devin Ulibarri](https://github.com/devinulibarri)
18+
Duration: July – September 2025
19+
20+
---
21+
22+
## Project Overview
23+
24+
The aim of this project was to modernize the internationalization (i18n) system of Music Blocks by migrating from the legacy `webL10n.js` framework to i18next, and to introduce an AI-assisted translation workflow to reduce the burden on human translators.
25+
26+
Key goals included:
27+
- Making the i18n workflow cleaner, modular, and maintainable.
28+
- Automating missing translations with AI + context-awareness.
29+
- Supporting community-driven refinements of translations.
30+
31+
---
32+
33+
## Achievements
34+
35+
1. Migration from webL10n.js to i18next
36+
- Replaced outdated framework with i18next for modern i18n support.
37+
- Added flexible fallback strategies (cleaned text, lowercase, title case, hyphenated).
38+
- Enabled JSON-based translation files for better maintainability.
39+
40+
2. AI-Assisted Translation System
41+
- Designed a pipeline to parse `.po` files and extract `msgid`s.
42+
- Generated context automatically by analyzing where each string occurs in the codebase.
43+
- Built a RAG (Retrieval-Augmented Generation) model to store these contexts.
44+
- Integrated Google Translate API to auto-fill missing translations using this context.
45+
46+
3. Contributor-Friendly Workflow
47+
- Human translators can review AI-generated suggestions instead of starting from scratch.
48+
- New language files can be created or updated automatically.
49+
- Significantly lowers the barrier for contributors to help Music Blocks reach more learners.
50+
51+
---
52+
53+
## Challenges & Solutions
54+
55+
- Challenge: Extracting meaningful context for each translation key.
56+
Solution: Implemented a RAG approach that links `msgid`s to their source code usage.
57+
58+
- Challenge: Ensuring migration didn’t break existing functionality.
59+
Solution: Incremental testing with sample `.json` files and stepwise replacement of webL10n.
60+
61+
---
62+
63+
## Key Learnings
64+
65+
- Infrastructure-level improvements (like i18n) may not be flashy, but they unlock global accessibility.
66+
- Context is essential for high-quality translations — raw machine translation alone isn’t enough.
67+
- Clean migration strategy + thorough testing makes adoption smoother for the community.
68+
69+
---
70+
71+
## Future Work
72+
73+
- Add support for more AI translation providers (e.g., DeepL, OpenAI).
74+
- Build a simple web-based review UI for translators to accept/refine AI suggestions.
75+
- Automate detection of new/changed strings via GitHub Actions and update translation files dynamically.
76+
77+
---
78+
79+
## Closing Thoughts
80+
81+
This project was a unique opportunity to contribute infrastructure that strengthens Music Blocks for a global user base. By combining modern i18n practices with AI translation support, I hope this work helps learners worldwide access Music Blocks in their own languages with greater ease.
82+
83+
I’m deeply grateful to my mentors Walter and Devin, and to the Sugar Labs community, for their support and guidance throughout this journey.
84+
85+
---
86+
87+
## Resources & References
88+
89+
- Music Blocks Repository: [github.com/sugarlabs/musicblocks](https://github.com/sugarlabs/musicblocks)
90+
- GitHub PR: [#4731](https://github.com/sugarlabs/musicblocks/pull/4731)
91+
- i18next Documentation: [i18next.com](https://www.i18next.com/)
92+
93+
---

0 commit comments

Comments
 (0)