# The manual supports implementation recommendations for internationalization

**URL:** <https://discuss.tvm.apache.org/t/the-manual-supports-implementation-recommendations-for-internationalization/11035>\
**Category:** RFC\
**Created:** [September 14, 2021, 2:39pm UTC](https://discuss.tvm.apache.org/t/the-manual-supports-implementation-recommendations-for-internationalization/11035 "2021-09-14T14:39:53Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![oneflyingfish](https://discuss.tvm.apache.org/user_avatar/discuss.tvm.apache.org/oneflyingfish/32/3012_2.png) [@oneflyingfish](https://discuss.tvm.apache.org/u/oneflyingfish)\
**Post date:** [September 14, 2021, 2:39pm UTC](https://discuss.tvm.apache.org/t/the-manual-supports-implementation-recommendations-for-internationalization/11035/1 "2021-09-14T14:39:53Z")

</div>

Hello! Two weeks have passed since I proposed the [Establishment of Chinese Language Manual](https://discuss.tvm.apache.org/t/establishment-of-chinese-language-manual/10933/8)

Thanks all for your support and suggestions, I finally found a way to synchronously generate multilingual manuals without changing the structure of the original manuals. We might be able to take advantage of Sphinx’s nationalization support, and I’ve been testing Chinese document generation on a copy of the TVM project, and it works fine.

Here gives the example:

 ![image](https://discuss.tvm.apache.org/uploads/default/original/2X/3/3d5aea017bc5b64132743adf5f7983aa398ed975.png)

- First I want to present the schematic, which is from official website of Sphinx.

- In the example above, I have translated only one file (\*.po), which reads as follows:

```auto
# ...

#: ../../_staging/index.rst:21
msgid ""
"TVM is an open deep learning compiler stack for CPUs, GPUs, and "
"specialized accelerators. It aims to close the gap between the "
"productivity-focused deep learning frameworks, and the performance- or "
"efficiency-oriented hardware backends."
msgstr ""
"Apache TVM是用于深度学习系统的编译器堆栈。它旨在缩小以生产力为中心的深度学习框架与以性能和效率为中心的硬件后端之间的差距。TVM与深度学习框架配合使用，为不同的后端提供端到端编译。"

#: ../../_staging/index.rst:25
msgid "Get Started"
msgstr "开始吧！"

#: ../../_staging/index.rst:27
msgid "Follow the :doc:`instructions <install/index>` to install TVM."
msgstr "依据 :doc:`介绍 <install/index>` 来安装TVM"

# ...

# msgid gives the source document, which is generate automatically
# msgstr gives the aim document, we work here!

```

- Finally, I gives the change to the source code and TVM website-code generate process:

1. add code to `docs/conf.py`

```auto
# I put them to line 54-55.
locale_dirs = ['locale/']   
gettext_compact = False  

```

2. generate gettext

```auto
cd docs/
make -j20 gettext

# you will find a fold named "locale" generated in docs/_build/ 

```

3. create `.po`文件

```auto
cd docs/_staging/
sphinx-intl update -p _build/locale/ -l zh_CN -l en # It will set up internationalization support for English and Chinese

# then docs/_staging/locale will be generated. For the Chinese manual, we only need to translate docs/_staging/locale/zh_CN/LC_MESSAGES/*.po
# Of course, when run "make clean", the locale should not be delete. 

```

4. generate static-website-code for multi-language (Chinese for example):

```auto
make -e SPHINXOPTS="-D language='zh_CN'" html 

# the fold "html", written in Chinese, will be generated in docs/_build/. We can deploy it normally

```

What’s more, co-translation can be performed using `transifex`, which provides a good division of work between translators and reviewers. I only test the service from `transifex.com`, but it comes at a high cost. It seems that `transifex` is an open-source-software? Can we deploy it and work on it?

We look forward to the preparation of the Chinese handbook as soon as possible, and look forward to the official response and your participation.

(We have already contacted some people working on the Chinese manual, if you are interested, please join us or guide us. Group entry will be given in the comments section)

---

<div class="post-metadata">

**Author:** ![oneflyingfish](https://discuss.tvm.apache.org/user_avatar/discuss.tvm.apache.org/oneflyingfish/32/3012_2.png) [@oneflyingfish](https://discuss.tvm.apache.org/u/oneflyingfish)\
**Post date:** [September 14, 2021, 2:40pm UTC](https://discuss.tvm.apache.org/t/the-manual-supports-implementation-recommendations-for-internationalization/11035/2 "2021-09-14T14:40:49Z")

</div>

schematic：

 ![image](https://discuss.tvm.apache.org/uploads/default/original/2X/e/e8258c9946beec9f16a84abfcbfce07098c27083.png)

---

<div class="post-metadata">

**Author:** ![junrushao](https://discuss.tvm.apache.org/user_avatar/discuss.tvm.apache.org/junrushao/32/205_2.png) [@junrushao](https://discuss.tvm.apache.org/u/junrushao)\
**Post date:** [September 14, 2021, 5:55pm UTC](https://discuss.tvm.apache.org/t/the-manual-supports-implementation-recommendations-for-internationalization/11035/4 "2021-09-14T17:55:07Z")

</div>

@tqchen @hogepodge Hey I would love to ask about our policy on hosting internationalized documents? Shall we use [https://github.com/apache/tvm-site](https://github.com/apache/tvm-site)?

---

<div class="post-metadata">

**Author:** ![tqchen](https://discuss.tvm.apache.org/user_avatar/discuss.tvm.apache.org/tqchen/32/5_2.png) [@tqchen](https://discuss.tvm.apache.org/u/tqchen)\
**Post date:** [September 14, 2021, 6:30pm UTC](https://discuss.tvm.apache.org/t/the-manual-supports-implementation-recommendations-for-internationalization/11035/5 "2021-09-14T18:30:52Z")

</div>

Feel free to start with a separate place then we can look into bring things back to official once it gets into a good shape, at that point we can simply bring to tvm-site(note the content is still generated elsewhere but can be populated here via s script).

---

<div class="post-metadata">

**Author:** ![hogepodge](https://discuss.tvm.apache.org/user_avatar/discuss.tvm.apache.org/hogepodge/32/1843_2.png) [@hogepodge](https://discuss.tvm.apache.org/u/hogepodge)\
**Post date:** [September 15, 2021, 7:50pm UTC](https://discuss.tvm.apache.org/t/the-manual-supports-implementation-recommendations-for-internationalization/11035/6 "2021-09-15T19:50:28Z")

</div>

@tqchen what do you think about linking out to the internationalized documents from the tvm main site for now?

Also, fwiw I’m working up a pull request for the new docs rfc. There will be a lot of moving parts in the coming weeks, so immediate action may not be possible until that dust settles.

> <https://github.com/apache/tvm/issues/8987>
>
> \## This issue is to track progress for \[Formalize TVM Documentation Organization…\](https://github.com/apache/tvm-rfcs/pull/27)
> 
> \### Tree refactor
> \- \[x\] Getting Started
> - \[x\] About TVM
> - \[x\] Install TVM
> - \[x\] Install from Source
> - \[x\] Docker Images
> - \[x\] TLCPack
> - \[x\] Contributor Guide
> - \[x\] Community Guideline
> - \[x\] Performing Code Reviews
> - \[x\] Committer Guide
> - \[x\] Writing Document and Tutorials
> - \[x\] Code Guide and Tips
> - \[x\] Error Handling Guide
> - \[x\] Submitting a Pull Request
> - \[x\] Git Usage Tips
> - \[x\] Apache TVM Release Process
> \- \[x\] User Guide
> - \[x\] Tutorial
> - \[x\] Introduction
> - \[x\] An Overview of TVM and Model Optimization
> - \[x\] Installing TVM
> - \[x\] Compiling and Optimizing a Model with TVMC
> - \[x\] Compiling and Optimizing a Model with the Python Interface (AutoTVM)
> - \[x\] Working with Operators Using Tensor Expression
> - \[x\] Optimizing Operators with Schedule Templates and AutoTVM
> - \[x\] Optimizing Operators with Auto-scheduling
> - \[x\] Cross Compilation and RPC
> - \[x\] Introduction to TOPI
> - \[x\] Quick Start Tutorial for Compiling Deep Learning Models
> - \[x\] How To
> - \[x\] Compile Deep Learning Models
> - \[x\] Deploy Deep Learning Models
> - \[x\] Work With Relay
> - \[x\] Work with Tensor Expression and Schedules
> - \[x\] Optimize Tensor Operators 
> - \[x\] Auto-Tune with Templates and AutoTVM
> - \[x\] Use AutoScheduler for Template-Free Auto Scheduling
> - \[x\] Work With microTVM
> \- \[x\] Topic Guide
> - \[x\] MicroTVM Guide (index to existing docs)
> - \[x\] -\> Work With microTVM
> - \[x\] -\> microTVM Architecture
> - \[x\] VTA (index to existing docs)
> \- \[x\] Developer Guide
> - \[x\] Contributor Tutorial
> - \[x\] Codebase Walkthrough
> - \[x\] How To 
> - \[x\] Write an operator
> - \[x\] Write a pass
> - \[x\] Write a backend
> - \[x\] Write PyTest target paramaterization
> \- \[x\] Architecture Guide
> - \[x\] Architecture Overview
> - \[x\] Research Papers
> - \[x\] Front-end 
> - \[x\] Relay: Graph-level design: IR, pass, lowering
> - \[x\] TensorIR: Operator-level design: IR, schedule, pass, lowering
> - \[x\] TOPI: Pre-defined operators operator coverage
> - \[x\] AutoScheduler / AutoTVM: Performance tuning design
> - \[x\] Runtime & microTVM design
> - \[x\] Customization with vendor libraries BYOC workflow
> - \[x\] RPC system
> - \[x\] Target system
> \- \[x\] API Reference (reference)
> - \[x\] Language Reference
> - \[x\] API Reference
> - \[x\] Generated C++ Docs…
> - \[x\] Generated Python Docs…
> \- \[x\] Index

---

<div class="post-metadata">

**Author:** ![tqchen](https://discuss.tvm.apache.org/user_avatar/discuss.tvm.apache.org/tqchen/32/5_2.png) [@tqchen](https://discuss.tvm.apache.org/u/tqchen)\
**Post date:** [September 15, 2021, 7:52pm UTC](https://discuss.tvm.apache.org/t/the-manual-supports-implementation-recommendations-for-internationalization/11035/7 "2021-09-15T19:52:04Z")

</div>

we can certainly do that as well(as long as we made clear these are good thirdparty community effort for now)

---

<div class="post-metadata">

**Author:** ![oneflyingfish](https://discuss.tvm.apache.org/user_avatar/discuss.tvm.apache.org/oneflyingfish/32/3012_2.png) [@oneflyingfish](https://discuss.tvm.apache.org/u/oneflyingfish)\
**Post date:** [September 18, 2021, 8:56am UTC](https://discuss.tvm.apache.org/t/the-manual-supports-implementation-recommendations-for-internationalization/11035/8 "2021-09-18T08:56:54Z")

</div>

Good news, we have start our work. Welcome to join us.

[Join us and Complete translation of Chinese manual](https://discuss.tvm.apache.org/t/join-us-and-complete-translation-of-chinese-manual/11077)

and the Slack that you mentioned earlier was created, share-link: [https://join.slack.com/t/slack-4xv5706/shared\_invite/zt-vwekxs1y-q8rFdwCPvlCpr7K90X8tRw](https://join.slack.com/t/slack-4xv5706/shared_invite/zt-vwekxs1y-q8rFdwCPvlCpr7K90X8tRw)

---

<div class="post-metadata">

**Author:** ![jkun](https://discuss.tvm.apache.org/letter_avatar_proxy/v4/letter/j/e19b73/32.png) [@jkun](https://discuss.tvm.apache.org/u/jkun)\
**Post date:** [November 9, 2021, 9:46am UTC](https://discuss.tvm.apache.org/t/the-manual-supports-implementation-recommendations-for-internationalization/11035/9 "2021-11-09T09:46:18Z")

</div>

Hey, I want to jion in this group, can you resend the group entry？

---

<div class="post-metadata">

**Author:** ![oneflyingfish](https://discuss.tvm.apache.org/user_avatar/discuss.tvm.apache.org/oneflyingfish/32/3012_2.png) [@oneflyingfish](https://discuss.tvm.apache.org/u/oneflyingfish)\
**Post date:** [November 9, 2021, 10:51am UTC](https://discuss.tvm.apache.org/t/the-manual-supports-implementation-recommendations-for-internationalization/11035/10 "2021-11-09T10:51:14Z")

</div>

Thanks for your joining us.

 ![image](https://discuss.tvm.apache.org/uploads/default/original/2X/5/5a2fc001b94c0022bb8aaae1d7fdc2f8da7223f5.jpeg)
