const { PrismaClient } = require('@prisma/client'); const p = new PrismaClient(); (async () => { const b = await p.book.findUnique({ where: { id: 82 }, include: { chapters: true } }); console.log(`book 82 lang=${b.targetLanguage} stage=${b.genStage} chapters=${b.chapters.length}`); for (const c of b.chapters) { const sample = (c.content || '').substring(0, 400).replace(/\n/g, ' / '); const hasCN = /[一-鿿]/.test(c.content || ''); console.log(` ch#${c.id} [${c.genStage}] audio=${c.audioUrl ? 'yes' : 'NO'}`); console.log(` ${sample}`); console.log(` hasChinese: ${hasCN ? '❌ 是(有中文!)' : '✅ 否(纯英文)'}`); } // 同时查 TtsTask const tasks = await p.ttsTask.findMany({ where: { chapterId: { in: b.chapters.map(c => c.id) } }, select: { id: true, chapterId: true, status: true, voiceId: true, targetLanguage: true, preferredVendor: true, preferredModel: true } }); console.log(`\n TtsTask count: ${tasks.length}`); for (const t of tasks) { console.log(` ttsTask#${t.id} ch=${t.chapterId} status=${t.status} voice=${t.voiceId} lang=${t.targetLanguage} vendor=${t.preferredVendor} model=${t.preferredModel}`); } await p.$disconnect(); })();