DEV: Use different feature_names for summarization strategies (#875)
This commit is contained in:
parent
0f0f2a247a
commit
dd404c924a
|
@ -128,10 +128,10 @@ module DiscourseAi
|
|||
)
|
||||
|
||||
if cursor == items.length
|
||||
llm.generate(prompt, user: user, feature_name: "summarize", &on_partial_blk)
|
||||
llm.generate(prompt, user: user, feature_name: strategy.feature, &on_partial_blk)
|
||||
else
|
||||
latest_summary =
|
||||
llm.generate(prompt, user: user, max_tokens: 600, feature_name: "summarize")
|
||||
llm.generate(prompt, user: user, max_tokens: 600, feature_name: strategy.feature)
|
||||
fold(items, latest_summary, cursor, user, &on_partial_blk)
|
||||
end
|
||||
end
|
||||
|
|
|
@ -42,6 +42,11 @@ module DiscourseAi
|
|||
def first_summary_prompt(_input)
|
||||
raise NotImplementedError
|
||||
end
|
||||
|
||||
# We'll pass this as the feature_name when doing LLM calls.
|
||||
def feature
|
||||
"summarize"
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -8,6 +8,10 @@ module DiscourseAi
|
|||
AiSummary.summary_types[:gist]
|
||||
end
|
||||
|
||||
def feature
|
||||
"gists"
|
||||
end
|
||||
|
||||
def targets_data
|
||||
op_post_number = 1
|
||||
|
||||
|
|
Loading…
Reference in New Issue