I’m encountering some bugs while using Discourse AI. Here’s the situation:
First, let’s look at a correct post to demonstrate that my configuration is not the issue and everything is working as I intended.
My site’s base language is Simplified Chinese, and there are 9 other languages available.
This “New post test 0 translation” post is normal.
However, some individual posts are experiencing issues. For example:
This “About ‘Image Library’ category” post. The original post was published in Simplified Chinese (it was automatically published when the category was created).
But in the translation results, the original Simplified Chinese has been translated into “zh_CN” again, instead of being translated into English.
In the dropdown list, I am unable to add a separate translation for English.
However, in my global settings, English (US) has already been added correctly.
I have disabled the CDN cache and repeatedly cleared the local browser cache.
This rules out caching as the problem.
My basic configuration can also be ruled out, as the first image shows the correct behavior.
I don’t understand why this problem is happening. How can I fix it?
My Discourse version is 3.6.0.beta1-dev(b8e86ceb23)
The server OS is Debian 12.12
I have tested this locally using the latest versions of both Chrome and Opera browsers.
URL for the correct case: https://openttc.com/t/topic/61
URL for the incorrect case: https://openttc.com/t/topic/58
Dit is geen bug. Omdat de standaardtaal voor alle categoriebeschrijvingen (systeemschepping) En is. Wat je ook invoert, het is standaard een En-post. Daarom wordt de vertaling niet geactiveerd.
If you have a post originally written in “Chinese”, by right, the LLM should detect it to be “zh_CN”. You can view the detected language in the regular composer (not the translation composer) next to the .
The detected language is important so that the translator does not unnecessarily translate it to the detected language itself, and translates the post to every other language.
I suspect what is happening with https://openttc.com/t/topic/58 is that the detected language is incorrect, can you check?
Ja. Het werd ten onrechte gedetecteerd als en in plaats van zh_CN. Ik heb gecontroleerd en ontdekt dat alle door het systeem gemaakte categoriebeschrijvingsberichten als en werden gedetecteerd. Zelfs als ze in het Chinees zijn geschreven.
Nieuw probleem: Ondersteunt de FAQ-pagina meerdere talen? Waar moeten vertalingen worden toegevoegd?
Het kan ook met de tijd te maken hebben. Als de categorieën zijn aangemaakt voordat de sitetaal werd gewijzigd, kunnen de talen van de categorieonderwerpen allemaal Engels zijn.
In dat geval kunt u naar het eerste bericht van de onderwerpen gaan, de composer openen en deze naar het Chinees schakelen.
-- [params]
-- integer :topic_id = 66
SELECT
a.id,
a.created_at,
a.response_tokens,
(REGEXP_MATCH(a.raw_response_payload, '"text": "([^"\\]+)"'))[1] AS llm_detected_locale,
a.raw_response_payload
FROM ai_api_audit_logs a
JOIN posts p ON p.id = a.post_id AND p.deleted_at IS NULL
LEFT JOIN topics t ON t.id = a.topic_id AND t.deleted_at IS NULL
WHERE t.id = :topic_id
AND p.post_number = 1
AND a.feature_name = 'translation'
AND a.response_tokens < 5
This should tell us what the LLM is actually returning.
If we’re seeing an “en” in the llm_detected_locale column, I suspect your site’s prompts for locale detection may need a change, or you can use a more suitable LLM (maybe qwen?)