feat: Add emotion handling to audiobook segments with emo_text and emo_alpha attributes

This commit is contained in:
2026-03-12 14:34:20 +08:00
parent 1757f39322
commit bbcfc0e8d3
8 changed files with 37 additions and 5 deletions

View File

@@ -40,3 +40,12 @@ def init_db():
conn.commit()
except Exception:
pass
for col_def in [
"ALTER TABLE audiobook_segments ADD COLUMN emo_text VARCHAR(20)",
"ALTER TABLE audiobook_segments ADD COLUMN emo_alpha REAL",
]:
try:
conn.execute(__import__("sqlalchemy").text(col_def))
conn.commit()
except Exception:
pass