feat: 用户表添加selected_audio_id字段,添加用户音频绑定接口

This commit is contained in:
killua committed 2024-05-23 09:57:53 +08:00
1 parent 773b48471a
commit 387c277c28
5 files changed
+67 -3

No files matched your search

+2
View File
@@ -36,6 +36,7 @@ class User(Base):
avatar_id = Column(String(36), nullable=True)
tags = Column(JSON)
persona = Column(JSON)
selected_audio_id = Column(Integer, nullable=True)
def __repr__(self):
return f"<User(id={self.id}, tags={self.tags})>"
@@ -81,6 +82,7 @@ class Session(Base):
def __repr__(self):
return f"<Session(id={self.id}, user_character_id={self.user_character_id})>"
#音频表定义
class Audio(Base):
__tablename__ = 'audio'
id = Column(Integer, primary_key=True, autoincrement=True)