fix: use original page content for title generation instead of processed TTS content

This commit is contained in:
Russell Ballestrini 2025-07-03 22:39:55 -04:00
parent 7bb43c7613
commit b178e039b2

View file

@ -42,8 +42,9 @@ export async function readPageWithHermes() {
downloadButton.onclick = async () => {
try {
const { generateTitleForTTS } = await import("./tts.js");
console.log("Generating title for Read Page content:", processedContent.substring(0, 200) + "...");
const filename = await generateTitleForTTS(processedContent);
// Use original content for title generation, not the processed TTS content
console.log("Generating title for Read Page using original content:", content.substring(0, 200) + "...");
const filename = await generateTitleForTTS(content);
console.log("Generated filename:", filename);
const a = document.createElement("a");
a.href = URL.createObjectURL(blob);