Added OpenAI large embedding / improve migration and upgrade handling for containers
This commit is contained in:
@@ -97,3 +97,16 @@ class EmbeddingSmallOpenAI(Embedding):
|
||||
__mapper_args__ = {
|
||||
'polymorphic_identity': 'embedding_small_openai',
|
||||
}
|
||||
|
||||
|
||||
class EmbeddingLargeOpenAI(Embedding):
|
||||
__tablename__ = 'embedding_large_openai'
|
||||
id = db.Column(db.Integer, db.ForeignKey('embeddings.id'), primary_key=True)
|
||||
|
||||
# 3072 is the OpenAI Large Embedding dimension.
|
||||
# If another embedding model is chosen, this dimension may need to be changed.
|
||||
embedding = db.Column(Vector(3072), nullable=False)
|
||||
|
||||
__mapper_args__ = {
|
||||
'polymorphic_identity': 'embedding_large_openai',
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user