Multilanguage
For localization, you can use Babel, or you can simply create the necessary contexts and activate the system setting pageblocks_context_aware
. Then, a select dropdown with all contexts will be added to the block menu.
You can copy all blocks from one context to another. For more details, you can read in the copying section.
ChatGPT
Settings:
System setting | Value | Description |
---|---|---|
pageblocks_translator | ChatGPT | |
pageblocks_chatgpt_apikey | API Key. You can obtain keys here. | |
pageblocks_chatgpt_model | gpt-4-turbo-2024-04-09 | She showed the best result for text translation. |
pageblocks_chatgpt_prompt | translate from [[+from]] to [[+to]]: | The values of "[[+from]]" and "[[+to]]" will be taken from the system setting of the cultureKey context. |
Example:
DeepL
Settings:
System setting | Value | Description |
---|---|---|
pageblocks_translator | DeepL | |
pageblocks_deepl_apikey | API Key. You can obtain keys here. | |
pageblocks_deepl_account | Free | Free or Pro. For more details, click here. |
DeepLGPT
ChatGPT often faces difficulties in accurately translating short sentences due to a lack of context understanding. DeepL manages this better, but ChatGPT is sometimes more suitable for longer texts. Therefore, a combination of both, named DeepLGPT, represents an optimal solution. You will need to set up system settings for both ChatGPT and DeepL, including an extra parameter called pageblocks_deepl_word_count
that determines the maximum number of words. If a text exceeds the word count specified in the pageblocks_deepl_word_count
setting, it will be translated using ChatGPT; if it is less or equal, the text will be translated via DeepL.