discourse/plugins/discourse-ai
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
..
admin/assets/javascripts/discourse DEV: Replace ArrayProxy with tracked array for ResultSets (#35527) 2025-10-28 16:04:09 -03:00
app PERF: Optimize AI translation stats query and remove caching (#35597) 2025-10-27 14:03:21 -03:00
assets DEV: replace template with component arg in DAutocomplete and add UserAutocompleteResults (#35539) 2025-11-05 10:59:32 +08:00
config Update translations (#35791) 2025-11-04 20:11:21 +01:00
db FIX: Disable AI Problem Checks (#35475) 2025-10-17 14:07:32 -03:00
discourse_automation FIX: allow AI tagging automation to tag posts by bots (#35310) 2025-10-09 18:45:43 -04:00
evals REFACTOR: centralize eval orchestration around feature-driven playground (#35718) 2025-10-30 13:08:38 -03:00
lib FIX: Improve prompt and check returned value conforms to standard (#35763) 2025-11-05 17:41:49 +08:00
public/ai-share
spec FIX: Improve prompt and check returned value conforms to standard (#35763) 2025-11-05 17:41:49 +08:00
svg-icons
test/javascripts FIX: clicking links in discovery search should close quick search (#35660) 2025-10-28 10:10:24 -07:00
.prettierignore
about.json
plugin.rb DEV: Move 'unknown OID' embeddings fix into core (#35519) 2025-10-21 15:23:24 +01:00
README.md

Discourse AI Plugin

Plugin Summary

For more information, please see: https://meta.discourse.org/t/discourse-ai/259214?u=falco

Evals

The directory evals contains AI evals for the Discourse AI plugin. You may create a local config by copying config/eval-llms.yml to config/eval-llms.local.yml and modifying the values.

To run them use:

cd evals ./run --help

Usage: evals/run [options]
    -e, --eval NAME                  Name of the evaluation to run
        --list-models                List models
    -m, --model NAME                 Model to evaluate (will eval all models if not specified)
    -l, --list                       List evals

To run evals you will need to configure API keys in your environment:

OPENAI_API_KEY=your_openai_api_key ANTHROPIC_API_KEY=your_anthropic_api_key GEMINI_API_KEY=your_gemini_api_key