discourse/plugins/discourse-ai/spec/lib/modules
Rafael dos Santos Silva b81e80a6e2
FIX: Optimize shortcomings from topic truncation from a27e20c (#33983)
On a27e20c we made an emergency perf fix to speedup generating text from
a topic for embeddings generation.

This introduced some issues, like missing separators between posts,
including to line breaks per included post all at the top of the
generated text, and resulted in using a lot less content per topics,
as we count the cooked size before stripping all the HTML tags.

This commit helps alleviate by:

  - removing the "\n\n" * quantity of posts at the top
  - adding a space between posts
  - generating text 3 times longer than the max allowed lenght, since
    it's getting shrinked after it's built by the Nokogiri.text call.
2025-07-30 17:09:05 -03:00
..
ai_bot DEV: Resolve RSpec/NamedSubject lint issues in d-ai (#33810) 2025-07-24 13:50:14 +02:00
ai_helper FEATURE: configure a default LLM model for all features (#33752) 2025-07-28 16:08:00 -03:00
ai_moderation DEV: Fix random typos (#33839) 2025-07-24 22:04:13 +02:00
automation FEATURE: configure a default LLM model for all features (#33752) 2025-07-28 16:08:00 -03:00
embeddings FIX: Optimize shortcomings from topic truncation from a27e20c (#33983) 2025-07-30 17:09:05 -03:00
sentiment DEV: Resolve RSpec/NamedSubject lint issues in d-ai (#33810) 2025-07-24 13:50:14 +02:00
summarization FEATURE: configure a default LLM model for all features (#33752) 2025-07-28 16:08:00 -03:00