discourse/plugins/discourse-ai/spec/lib/translation
Natalie Tay 5af43b64ce
FIX: Improve prompt and check returned value conforms to standard (#35763)
This commit improves the prompt, and also matches the return value
against this:
- https://datatracker.ietf.org/doc/html/rfc5646#section-2.2.1
- **Primary Language Subtag**: ... Two-character primary language
subtags were defined in the IANA registry according to the assignments
found in the standard "ISO 639-1:2002 ...
- **Extended Language Subtags**: ... Extended language subtags consist
solely of three-letter subtags.

This commit also moves examples into its own 

Meta:
https://meta.discourse.org/t/locale-detector-return-value-issues/381852
2025-11-05 17:41:49 +08:00
..
base_translator_spec.rb
category_candidates_spec.rb PERF: optimize translation progress dashboard with batch query (#34861) 2025-09-29 13:32:40 +08:00
category_locale_detector_spec.rb FIX: Improve prompt and check returned value conforms to standard (#35763) 2025-11-05 17:41:49 +08:00
category_localizer_spec.rb
content_splitter_spec.rb
entry_point_spec.rb FEATURE: Allow re-localization twice a day if post version has changed (#34023) 2025-08-04 10:58:30 +08:00
language_detector_spec.rb FIX: Improve prompt and check returned value conforms to standard (#35763) 2025-11-05 17:41:49 +08:00
post_candidates_spec.rb FIX: Exclude posts exceeding max length from translation progress (#35723) 2025-10-30 15:09:57 -03:00
post_detection_text_spec.rb
post_locale_detector_spec.rb FIX: Improve prompt and check returned value conforms to standard (#35763) 2025-11-05 17:41:49 +08:00
post_localizer_spec.rb FIX: Continue translation when post-processing fails (#35725) 2025-10-30 16:53:25 -03:00
topic_candidates_spec.rb DEV: Update rubocop-discourse to 3.13 and autofix issues (#35073) 2025-10-06 16:11:01 +02:00
topic_locale_detector_spec.rb FIX: Improve prompt and check returned value conforms to standard (#35763) 2025-11-05 17:41:49 +08:00
topic_localizer_spec.rb