mirror of
https://github.com/R0m1k3/Socialflow.git
synced 2026-10-15 19:29:03 +02:00
feat: add Minimax Speech as alternative TTS provider for Reels
- Add minimax_config table (migration + schema + storage CRUD) - Add GET/POST /api/minimax/config routes - Pass tts_provider + minimax_api_key through ffmpeg service - Add generate_tts_minimax() in Python using Minimax T2A v2 API - Fall back to ffsubsync for subtitle sync (no WordBoundary events) - Add Minimax config card in Settings page - Add provider toggle (Edge TTS / Minimax) + French voices in new-reel
This commit is contained in:
1 parent
9932561050
commit
b7ef4940f7
9 files changed
+364
-29
No files matched your search
@@ -142,6 +142,14 @@ export const freesoundConfig = pgTable("freesound_config", {
|
||||
updatedAt: timestamp("updated_at").defaultNow(),
|
||||
});
|
||||
|
||||
export const minimaxConfig = pgTable("minimax_config", {
|
||||
id: varchar("id").primaryKey().default(sql`gen_random_uuid()`),
|
||||
userId: varchar("user_id").notNull().unique().references(() => users.id, { onDelete: "cascade" }),
|
||||
apiKey: text("api_key").notNull(),
|
||||
createdAt: timestamp("created_at").defaultNow(),
|
||||
updatedAt: timestamp("updated_at").defaultNow(),
|
||||
});
|
||||
|
||||
export const media = pgTable("media", {
|
||||
id: varchar("id").primaryKey().default(sql`gen_random_uuid()`),
|
||||
userId: varchar("user_id").notNull().references(() => users.id, { onDelete: "cascade" }),
|
||||
@@ -489,4 +497,20 @@ export type AppConfig = typeof appConfig.$inferSelect;
|
||||
export type InsertFreesoundConfig = z.infer<typeof insertFreesoundConfigSchema>;
|
||||
export type UpdateFreesoundConfig = z.infer<typeof updateFreesoundConfigSchema>;
|
||||
|
||||
export const insertMinimaxConfigSchema = createInsertSchema(minimaxConfig).omit({
|
||||
id: true,
|
||||
createdAt: true,
|
||||
updatedAt: true,
|
||||
});
|
||||
|
||||
export const updateMinimaxConfigSchema = insertMinimaxConfigSchema.omit({
|
||||
userId: true
|
||||
}).partial({
|
||||
apiKey: true,
|
||||
});
|
||||
|
||||
export type MinimaxConfig = typeof minimaxConfig.$inferSelect;
|
||||
export type InsertMinimaxConfig = z.infer<typeof insertMinimaxConfigSchema>;
|
||||
export type UpdateMinimaxConfig = z.infer<typeof updateMinimaxConfigSchema>;
|
||||
|
||||
|
||||
Reference in new issue
Block a user