[groq] Research: NotebookLM — create audio overview of SOUL.md as podcast (#293) (#357)
Some checks failed
Deploy Nexus / deploy (push) Failing after 9s

This commit was merged in pull request #357.
This commit is contained in:
2026-03-24 12:39:47 +00:00
parent 0073f818b2
commit 0a217401fb
2 changed files with 31 additions and 0 deletions

18
app.js
View File

@@ -2719,6 +2719,24 @@ document.getElementById('audio-toggle').addEventListener('click', () => {
}
});
// Podcast toggle
document.getElementById('podcast-toggle').addEventListener('click', async () => {
try {
const response = await fetch('SOUL.md');
if (!response.ok) throw new Error('Failed to load SOUL.md');
const text = await response.text();
const utterance = new SpeechSynthesisUtterance(text);
utterance.lang = 'en-US';
utterance.rate = 0.9;
utterance.pitch = 0.9;
utterance.volume = 1.0;
speechSynthesis.speak(utterance);
} catch (err) {
console.error('Failed to load or play SOUL.md:', err);
alert('Could not load SOUL.md for audio playback.');
}
});
// === DEBUG MODE ===
let debugMode = false;

View File

@@ -81,6 +81,19 @@ canvas {
transition: background-color 0.2s ease;
}
#podcast-toggle {
margin-left: 8px;
background-color: var(--color-accent);
color: var(--color-bg);
padding: 4px 8px;
border: none;
border-radius: 4px;
font-size: 12px;
cursor: pointer;
font-family: var(--font-body);
transition: background-color 0.2s ease;
}
#export-session:hover {
background-color: var(--color-primary);
color: var(--color-bg);