mirror of
https://github.com/discourse/discourse-ai.git
synced 2025-06-23 16:12:21 +00:00
review feedback
This commit is contained in:
parent
0338dbea23
commit
c885e5697f
@ -1,6 +1,11 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
class CompletionPrompt < ActiveRecord::Base
|
||||
#
|
||||
# DEPRECATED.
|
||||
# TODO(roman): Remove after 06-17-25
|
||||
#
|
||||
|
||||
TRANSLATE = -301
|
||||
GENERATE_TITLES = -307
|
||||
PROOFREAD = -303
|
||||
|
@ -340,32 +340,33 @@ en:
|
||||
name: "Concept Deduplicator"
|
||||
description: "AI Bot specialized in deduplicating concepts"
|
||||
custom_prompt:
|
||||
name: "Custom Prompt"
|
||||
description: "Default persona powering the AI helper's custom prompt feature"
|
||||
name: "Custom prompt"
|
||||
description: "Default persona powering the Helper's custom prompt feature"
|
||||
smart_dates:
|
||||
name: "Smart Dates"
|
||||
description: "Default persona powering the AI helper's smart dates feature"
|
||||
name: "Smart dates"
|
||||
description: "Default persona powering the Helper's smart dates feature"
|
||||
markdown_table_generator:
|
||||
name: "Markdown Table Generator"
|
||||
description: "Default persona powering the AI helper's generate Markdown table feature"
|
||||
name: "Markdown table generator"
|
||||
description: "Default persona powering the Helper's generate Markdown table feature"
|
||||
post_illustrator:
|
||||
name: "Post Illustrator"
|
||||
description: "Generates StableDiffusion prompts to power the AI helper's illustrate post feature"
|
||||
name: "Post illustrator"
|
||||
description: "Generates StableDiffusion prompts to power the Helper's illustrate post feature"
|
||||
proofreader:
|
||||
name: "Proofreader"
|
||||
description: "Default persona powering the AI helper's proofread text feature"
|
||||
description: "Default persona powering the Helper's proofread text feature"
|
||||
titles_generator:
|
||||
name: "Titles Generator"
|
||||
description: "Default persona powering the AI helper's suggest topic titles feature"
|
||||
name: "Titles generator"
|
||||
description: "Default persona powering the Helper's suggest topic titles feature"
|
||||
tutor:
|
||||
name: "Tutor"
|
||||
description: "Default persona powering the AI helper's explain feature"
|
||||
description: "Default persona powering the Helper's explain feature"
|
||||
translator:
|
||||
name: "Translator"
|
||||
description: "Default persona powering the AI helper's translator feature"
|
||||
description: "Default persona powering the Helper's translator feature"
|
||||
image_captioner:
|
||||
name: "Image Captions"
|
||||
description: "Default persona powering the AI helper's image caption feature"
|
||||
name: "Image captions"
|
||||
description: "Default persona powering the Helper's image caption feature"
|
||||
|
||||
topic_not_found: "Summary unavailable, topic not found!"
|
||||
summarizing: "Summarizing topic"
|
||||
searching: "Searching for: '%{query}'"
|
||||
|
@ -166,7 +166,7 @@ discourse_ai:
|
||||
default: "-22"
|
||||
type: enum
|
||||
enum: "DiscourseAi::Configuration::PersonaEnumerator"
|
||||
ai_helper_tittle_suggestions_persona:
|
||||
ai_helper_title_suggestions_persona:
|
||||
default: "-23"
|
||||
type: enum
|
||||
enum: "DiscourseAi::Configuration::PersonaEnumerator"
|
||||
|
@ -307,7 +307,7 @@ module DiscourseAi
|
||||
def personas_prompt_map(include_image_caption: false)
|
||||
map = {
|
||||
SiteSetting.ai_helper_translator_persona.to_i => TRANSLATE,
|
||||
SiteSetting.ai_helper_tittle_suggestions_persona.to_i => GENERATE_TITLES,
|
||||
SiteSetting.ai_helper_title_suggestions_persona.to_i => GENERATE_TITLES,
|
||||
SiteSetting.ai_helper_proofreader_persona.to_i => PROOFREAD,
|
||||
SiteSetting.ai_helper_markdown_tables_persona.to_i => MARKDOWN_TABLE,
|
||||
SiteSetting.ai_helper_custom_prompt_persona.to_i => CUSTOM_PROMPT,
|
||||
@ -325,8 +325,6 @@ module DiscourseAi
|
||||
end
|
||||
|
||||
def all_prompts
|
||||
personas_and_prompts = personas_prompt_map
|
||||
|
||||
AiPersona
|
||||
.where(id: personas_prompt_map.keys)
|
||||
.map do |ai_persona|
|
||||
|
@ -25,7 +25,7 @@ module PageObjects
|
||||
end
|
||||
|
||||
def select_helper_model(mode)
|
||||
find("#{OPTIONS_SELECTOR} .btn[data-value=\"#{mode}\"]").click
|
||||
find("#{OPTIONS_SELECTOR} .btn[data-name=\"#{mode}\"]").click
|
||||
end
|
||||
|
||||
def suggestion_value
|
||||
|
Loading…
x
Reference in New Issue
Block a user