discourse-ai/db/migrate/20240912052713_add_target_to_rag_document_fragment.rb
Sam 03eccbe392
FEATURE: Make tool support polymorphic (#798)
Polymorphic RAG means that we will be able to access RAG fragments both from AiPersona and AiCustomTool

In turn this gives us support for richer RAG implementations.
2024-09-16 08:17:17 +10:00

10 lines
346 B
Ruby

# frozen_string_literal: true
class AddTargetToRagDocumentFragment < ActiveRecord::Migration[7.1]
def change
add_column :rag_document_fragments, :target_id, :integer, null: true
add_column :rag_document_fragments, :target_type, :string, limit: 800, null: true
add_index :rag_document_fragments, %i[target_type target_id]
end
end