FIX: Include OP when building title suggestion prompt. (#248)
When the OP is the only post in the topic, we'll send a prompt without user content to the LLM, and the suggested title will make no sense.
This commit is contained in:
parent
99ee949b33
commit
919a87f8d7
|
@ -298,7 +298,7 @@ module DiscourseAi
|
|||
You will never respond with anything but a topic title.
|
||||
Suggest a 7 word title for the following topic without quoting any of it:
|
||||
|
||||
#{post.topic.posts[1..-1].map(&:raw).join("\n\n")[0..prompt_limit]}
|
||||
#{post.topic.posts.map(&:raw).join("\n\n")[0..prompt_limit]}
|
||||
TEXT
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue