Classification in the Discourse Sentiment Dashboard

Hi everyone,

I’m exploring the sentiment analysis feature available in the Discourse admin dashboard (Admin > Dashboard > Sentiment) and I have questions about how it works:

  1. How is sentiment assigned to posts? Is it based on a machine learning model, keyword matching, or a combination of both?
  2. Are there specific keywords or phrases that trigger a particular sentiment? If so, is there a way to view, edit or export the full list?

Thanks in advance.
Laura

Sentiment is part of the ai plugin. You can read more about it here:

Thank you. Is there a way to adjust this?

We’ve noticed that sentiment is only assigned to a small number of posts. Since we find this feature very helpful, we were wondering whether there is a way to expand or configure the sentiment classification so that it applies to more posts.

Alternatively, is it possible to have sentiment determined by users (for example, members of our community) rather than by AI? If that’s not currently supported, would there be a way for us to manually assign or manage sentiment classifications ourselves?

Backfill for older postsare controlled by this setting:

As for customizing this… the agent used for Sentiment can be found in the AI > Agents tab, under the name ‘Sentiment classifier’.

You can also edit Sentiment-related settings at /admin/plugins/discourse-ai/settings?filter=sentiment.

Thank you for pointing me in the right direction! I was able to find the Sentiment classifier agent. However, I’m unable to edit its prompt, even though I have admin access. The fields appear to be locked or read-only.

Is there a specific permission or configuration that needs to be enabled to allow editing of this built-in agent? Or would the recommended approach be to create a custom agent to replace or supplement the default Sentiment classifier?

Any guidance on this would be greatly appreciated!

Hmm… if I am not wrong, you can’t edit them (yet?). You could self-host a custom LLM if you’re very eager to tweak it though.

Yes, I’d like to customize it. What do you mean by LLM? Do you mean creating my own agent?

I’m not as familiar with this, but you can check this out:

Though I am not too sure to what extent you can customize the prompts. It’s fixed a for a reason, as they are quite fine-tuned for better accuracy, if I am not mistaken.