mirror of
https://github.com/discourse/discourse-ai.git
synced 2025-02-06 03:28:13 +00:00
320ac6e84b
This change makes it easier to add new prompts to our AI helper. We don't have a UI for it yet. You'll have to do it through a console.
16 lines
454 B
Ruby
16 lines
454 B
Ruby
# frozen_string_literal: true
|
|
class CreateCompletionPromptTable < ActiveRecord::Migration[7.0]
|
|
def change
|
|
create_table :completion_prompts do |t|
|
|
t.string :name, null: false
|
|
t.string :translated_name
|
|
t.integer :prompt_type, null: false, default: 0
|
|
t.text :value, null: false
|
|
t.boolean :enabled, null: false, default: true
|
|
t.timestamps
|
|
end
|
|
|
|
add_index :completion_prompts, %i[name], unique: true
|
|
end
|
|
end
|