-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
662 lines (570 loc) · 19.8 KB
/
Copy pathindex.html
File metadata and controls
662 lines (570 loc) · 19.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Podcast-Agent</title>
<style>
* {
box-sizing: border-box;
}
body {
margin: 0;
background: #fbfaf7;
color: #111111;
font-family: "Times New Roman", Times, serif;
font-size: 18px;
line-height: 1.65;
}
main {
width: min(900px, calc(100% - 32px));
margin: 0 auto;
padding: 56px 0 72px;
}
header,
section {
border-bottom: 1px solid #e0d8ce;
margin: 0 0 38px;
padding: 0 0 38px;
}
section:last-child {
border-bottom: 0;
margin-bottom: 0;
padding-bottom: 0;
}
h1,
h2 {
line-height: 1.2;
}
header {
text-align: center;
}
h1 {
margin: 0 0 14px;
font-size: clamp(48px, 8vw, 76px);
font-weight: 700;
letter-spacing: 0.01em;
}
h2 {
margin: 0 0 16px;
font-size: 34px;
font-weight: 700;
}
p {
margin: 0 0 16px;
}
ul {
margin: 0 0 16px;
padding-left: 24px;
}
li + li {
margin-top: 8px;
}
pre {
margin: 16px 0 18px;
padding: 16px;
overflow-x: auto;
border: 1px solid #e0d8ce;
background: #fffdf9;
font-family: "Courier New", Courier, monospace;
font-size: 15px;
line-height: 1.5;
}
a {
color: #111111;
}
nav {
display: flex;
flex-wrap: wrap;
justify-content: center;
gap: 0 10px;
margin: 24px auto 0;
max-width: 780px;
color: #4d463f;
font-size: 16px;
line-height: 1.6;
}
nav a {
border-left: 1px solid #b9aa98;
padding-left: 10px;
white-space: nowrap;
}
nav a:first-child {
border-left: 0;
padding-left: 0;
}
.workflow-intro {
max-width: 780px;
}
.workflow-diagram-wrap {
margin-top: 20px;
overflow-x: auto;
border: 1px solid #d8cdbf;
border-radius: 8px;
background: #fffdf9;
box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.75);
}
.workflow-diagram {
display: block;
width: 100%;
min-width: 860px;
height: auto;
font-family: "Times New Roman", Times, serif;
}
.workflow-diagram text {
fill: #17130f;
}
.workflow-diagram .stage {
fill: #fbfaf7;
stroke: #b9aa98;
stroke-width: 1.2;
}
.workflow-diagram .stage-strong {
fill: #efe6da;
stroke: #8f7a63;
}
.workflow-diagram .artifact {
fill: #ffffff;
stroke: #d2c6b8;
stroke-width: 1;
}
.workflow-diagram .arrow {
fill: none;
stroke: #6f6255;
stroke-width: 1.6;
marker-end: url(#workflow-arrow);
}
.workflow-diagram .rail {
fill: none;
stroke: #cdbfad;
stroke-dasharray: 4 5;
stroke-width: 1.1;
}
.workflow-details {
margin-top: 24px;
}
button {
width: 38px;
height: 38px;
border: 1px solid #d2c6b8;
border-radius: 50%;
background: #fffdf9;
color: #3b332b;
cursor: pointer;
font-family: "Times New Roman", Times, serif;
font-size: 22px;
line-height: 1;
box-shadow: 0 5px 14px rgba(40, 28, 16, 0.08);
transition:
background 160ms ease,
border-color 160ms ease,
box-shadow 160ms ease,
transform 160ms ease;
}
button:hover:not(:disabled) {
background: #f4eee6;
border-color: #b9aa98;
box-shadow: 0 8px 20px rgba(40, 28, 16, 0.12);
transform: translateY(-1px);
}
button:disabled {
color: #aaaaaa;
cursor: default;
}
header p {
max-width: 760px;
margin-left: auto;
margin-right: auto;
color: #2f2a25;
}
.pdf-header {
margin-bottom: 12px;
text-align: center;
}
.pdf-meta {
margin: 0;
color: #555555;
font-size: 15px;
}
.pdf-stage {
position: relative;
display: flex;
align-items: center;
justify-content: center;
min-height: 430px;
overflow: hidden;
}
.pdf-cover-link {
display: block;
width: min(100%, 300px);
margin: 0 auto;
text-decoration: none;
z-index: 3;
}
.pdf-cover {
overflow: hidden;
border: 1px solid #d8cdbf;
border-radius: 8px;
background: #fffdf9;
padding: 8px;
box-shadow:
0 16px 34px rgba(40, 28, 16, 0.1),
inset 0 0 0 1px rgba(255, 255, 255, 0.75);
transition:
border-color 160ms ease,
box-shadow 160ms ease,
transform 160ms ease;
}
.pdf-cover-link:hover .pdf-cover {
border-color: #bcae9c;
box-shadow: 0 20px 42px rgba(40, 28, 16, 0.14);
transform: translateY(-2px);
}
.pdf-cover img {
display: block;
width: 100%;
height: auto;
border-radius: 4px;
}
.pdf-open {
margin: 10px 0 0;
color: #6a5e52;
font-size: 14px;
text-align: center;
}
.pdf-side {
position: absolute;
top: 48px;
z-index: 1;
width: 230px;
opacity: 0.42;
filter: saturate(0.78);
pointer-events: none;
transform: scale(0.86);
}
.pdf-side img {
display: block;
width: 100%;
height: auto;
border: 1px solid #d8cdbf;
border-radius: 8px;
background: #fffdf9;
padding: 6px;
box-shadow: 0 12px 28px rgba(40, 28, 16, 0.08);
}
.pdf-side-prev {
left: calc(50% - 330px);
}
.pdf-side-next {
right: calc(50% - 330px);
}
.pdf-arrow {
position: absolute;
top: 50%;
z-index: 4;
transform: translateY(-50%);
}
.pdf-arrow:hover:not(:disabled) {
transform: translateY(calc(-50% - 1px));
}
#pdf-prev {
left: 24px;
}
#pdf-next {
right: 24px;
}
.empty {
display: none;
border: 1px solid #e0d8ce;
padding: 24px;
background: #fffdf9;
}
@media (max-width: 640px) {
main {
width: min(100% - 40px, 900px);
padding-top: 32px;
}
body {
font-size: 17px;
}
h1 {
font-size: 40px;
}
h2 {
font-size: 32px;
}
p,
li {
overflow-wrap: anywhere;
}
.pdf-stage {
min-height: 350px;
}
button {
width: 34px;
height: 34px;
font-size: 20px;
}
.pdf-cover-link {
width: min(100%, 240px);
}
.pdf-side {
width: 170px;
top: 48px;
opacity: 0.32;
}
.pdf-side-prev {
left: calc(50% - 190px);
}
.pdf-side-next {
right: calc(50% - 190px);
}
#pdf-prev {
left: 2px;
}
#pdf-next {
right: 2px;
}
.workflow-diagram {
min-width: 780px;
}
}
</style>
</head>
<body>
<main>
<header>
<h1>Podcast-Agent</h1>
<p>
Podcast-Agent turns YouTube podcasts and long-form videos into
structured reports for faster understanding and analysis.
</p>
<nav aria-label="Page sections">
<a href="#overview">Overview</a>
<a href="#key-features">Key Features</a>
<a href="#agentic-workflow">Agentic Workflow</a>
<a href="#demo-pdfs">Demo PDFs</a>
</nav>
</header>
<section id="overview">
<h2>Overview</h2>
<p>Podcast-Agent is useful when you want to:</p>
<ul>
<li>Quickly understand what a podcast or long-form video is about.</li>
<li>Ask a focused question about a video and collect relevant evidence.</li>
<li>Produce reports in multiple formats, including editable Markdown, PDF, and Xiaohongshu-style image outputs.</li>
<li>Turn video content into viewpoints, summaries, and reports.</li>
<li>Save intermediate artifacts for review, debugging, or downstream analysis.</li>
</ul>
<p>Current input support is centered on YouTube videos.</p>
</section>
<section id="key-features">
<h2>Key Features</h2>
<ul>
<li>Generate a structured report from a podcast or long-form video.</li>
<li>Quickly understand the core content without watching the full episode.</li>
<li>Organize and interpret the key viewpoints discussed in the podcast.</li>
<li>Jump from important report moments directly back to the original video.</li>
</ul>
</section>
<section id="agentic-workflow">
<h2>Agentic Workflow</h2>
<p class="workflow-intro">
Podcast-Agent is designed as an inspectable agentic pipeline rather than a
single opaque prompt. Each stage writes durable artifacts, so a long video
can be reviewed, debugged, resumed, and rendered into multiple report forms.
</p>
<div class="workflow-diagram-wrap">
<svg class="workflow-diagram" viewBox="0 0 980 430" role="img" aria-labelledby="workflow-title workflow-desc">
<title id="workflow-title">Podcast-Agent agentic workflow diagram</title>
<desc id="workflow-desc">
A YouTube URL and user question flow through intent detection, source ingestion,
evidence extraction, outline generation, viewpoint writing, summary creation, and report rendering.
</desc>
<defs>
<marker id="workflow-arrow" markerWidth="8" markerHeight="8" refX="7" refY="4" orient="auto">
<path d="M0,0 L8,4 L0,8 Z" fill="#6f6255"></path>
</marker>
</defs>
<text x="38" y="39" font-size="16" font-weight="700">Input</text>
<rect class="stage stage-strong" x="34" y="54" width="166" height="66" rx="7"></rect>
<text x="117" y="81" font-size="17" text-anchor="middle" font-weight="700">URL + Question</text>
<text x="117" y="103" font-size="13" text-anchor="middle">user intent starts the run</text>
<path class="arrow" d="M200 87 H261"></path>
<text x="276" y="39" font-size="16" font-weight="700">Reasoning stages</text>
<rect class="stage" x="266" y="54" width="142" height="66" rx="7"></rect>
<text x="337" y="81" font-size="17" text-anchor="middle" font-weight="700">Intent</text>
<text x="337" y="103" font-size="13" text-anchor="middle">language and depth</text>
<path class="arrow" d="M408 87 H475"></path>
<rect class="stage" x="482" y="54" width="166" height="66" rx="7"></rect>
<text x="565" y="81" font-size="17" text-anchor="middle" font-weight="700">Ingest</text>
<text x="565" y="103" font-size="13" text-anchor="middle">metadata and transcript</text>
<path class="arrow" d="M565 120 V159"></path>
<rect class="stage" x="482" y="166" width="166" height="66" rx="7"></rect>
<text x="565" y="193" font-size="17" text-anchor="middle" font-weight="700">Evidence</text>
<text x="565" y="215" font-size="13" text-anchor="middle">chapter-aware segments</text>
<path class="arrow" d="M482 199 H415"></path>
<rect class="stage" x="266" y="166" width="142" height="66" rx="7"></rect>
<text x="337" y="193" font-size="17" text-anchor="middle" font-weight="700">Outline</text>
<text x="337" y="215" font-size="13" text-anchor="middle">argument structure</text>
<path class="arrow" d="M337 232 V271"></path>
<rect class="stage" x="266" y="278" width="142" height="66" rx="7"></rect>
<text x="337" y="305" font-size="17" text-anchor="middle" font-weight="700">Viewpoints</text>
<text x="337" y="327" font-size="13" text-anchor="middle">parallel detail passes</text>
<path class="arrow" d="M408 311 H475"></path>
<rect class="stage" x="482" y="278" width="166" height="66" rx="7"></rect>
<text x="565" y="305" font-size="17" text-anchor="middle" font-weight="700">Summary</text>
<text x="565" y="327" font-size="13" text-anchor="middle">conclusions and order</text>
<path class="arrow" d="M648 311 H733"></path>
<text x="750" y="263" font-size="16" font-weight="700">Outputs</text>
<rect class="stage stage-strong" x="738" y="278" width="178" height="66" rx="7"></rect>
<text x="827" y="305" font-size="17" text-anchor="middle" font-weight="700">Reports</text>
<text x="827" y="327" font-size="13" text-anchor="middle">Markdown, HTML, PDF, XHS</text>
<path class="rail" d="M117 133 V381 H827 V354"></path>
<text x="38" y="391" font-size="14" font-weight="700">Artifact trail</text>
<rect class="artifact" x="152" y="364" width="102" height="34" rx="5"></rect>
<text x="203" y="386" font-size="13" text-anchor="middle">input.json</text>
<rect class="artifact" x="272" y="364" width="104" height="34" rx="5"></rect>
<text x="324" y="386" font-size="13" text-anchor="middle">source.json</text>
<rect class="artifact" x="394" y="364" width="104" height="34" rx="5"></rect>
<text x="446" y="386" font-size="13" text-anchor="middle">elements/</text>
<rect class="artifact" x="516" y="364" width="104" height="34" rx="5"></rect>
<text x="568" y="386" font-size="13" text-anchor="middle">insights/</text>
<rect class="artifact" x="638" y="364" width="104" height="34" rx="5"></rect>
<text x="690" y="386" font-size="13" text-anchor="middle">reports/</text>
</svg>
</div>
<ul class="workflow-details">
<li>
The run starts by saving <code>input.json</code>, resolving the YouTube
source into <code>source.json</code>, and detecting report intent from the
question. That intent controls the report language and whether the output
should be brief, default, or detailed.
</li>
<li>
Ingestion uses <code>yt-dlp</code> to fetch normalized metadata and ranked
subtitle tracks. If subtitles are unavailable, the pipeline can download
audio and fall back to an audio transcriber, then writes both
<code>transcript.vtt</code> and <code>transcript.txt</code>.
</li>
<li>
Evidence extraction parses the VTT transcript into timed subtitle segments,
prefers chapter-based chunks when metadata has chapters, otherwise uses
overlapping ten-minute windows, and asks the model to keep the most relevant
evidence for the user's question.
</li>
<li>
The outline stage turns evidence, metadata, source URL, chapters, and the
question into a viewpoint breakdown. Viewpoint generation then selects the
highest-importance viewpoints and writes detailed sub-theses, often in
parallel, while preserving links back to supporting evidence indexes.
</li>
<li>
Summary generation condenses the selected viewpoints into an introduction,
core conclusions, viewpoint order, and takeaway. The same artifact set then
renders to Markdown, HTML, PDF, and Xiaohongshu image output, so every format
shares one analytical core.
</li>
</ul>
</section>
<section id="demo-pdfs">
<h2>Demo PDFs</h2>
<div id="pdf-empty" class="empty">
Put PDF files in <code>demo-pdf/</code>, then add their filenames to
<code>pdfFiles</code> in this page.
</div>
<div id="pdf-viewer">
<div class="pdf-header">
<p id="pdf-count" class="pdf-meta">1 / 5</p>
</div>
<div class="pdf-stage">
<div class="pdf-side pdf-side-prev">
<img id="pdf-prev-cover" src="demo-pdf/demo-1-cover.jpg" alt="">
</div>
<button id="pdf-prev" class="pdf-arrow" type="button" aria-label="Previous PDF"><</button>
<a id="pdf-cover-link" class="pdf-cover-link" href="demo-pdf/demo-4.pdf" target="_blank" rel="noopener">
<div class="pdf-cover">
<img id="pdf-cover" src="demo-pdf/demo-4-cover.jpg" alt="demo-4 PDF cover">
</div>
<p class="pdf-open">Click the cover to preview the PDF.</p>
</a>
<button id="pdf-next" class="pdf-arrow" type="button" aria-label="Next PDF">></button>
<div class="pdf-side pdf-side-next">
<img id="pdf-next-cover" src="demo-pdf/demo-5-cover.jpg" alt="">
</div>
</div>
</div>
</section>
</main>
<script>
const pdfFiles = [
{
title: "demo-4.pdf",
pdf: "demo-4.pdf",
cover: "demo-4-cover.jpg",
alt: "demo-4 PDF cover",
},
{
title: "demo-5.pdf",
pdf: "demo-5.pdf",
cover: "demo-5-cover.jpg",
alt: "demo-5 PDF cover",
},
{
title: "demo-3.pdf",
pdf: "demo-3.pdf",
cover: "demo-3-cover.jpg",
alt: "demo-3 PDF cover",
},
{
title: "demo-2.pdf",
pdf: "demo-2.pdf",
cover: "demo-2-cover.jpg",
alt: "demo-2 PDF cover",
},
{
title: "demo-1.pdf",
pdf: "demo-1.pdf",
cover: "demo-1-cover.jpg",
alt: "demo-1 PDF cover",
},
];
const viewer = document.getElementById("pdf-viewer");
const empty = document.getElementById("pdf-empty");
const coverLink = document.getElementById("pdf-cover-link");
const cover = document.getElementById("pdf-cover");
const prevCover = document.getElementById("pdf-prev-cover");
const nextCover = document.getElementById("pdf-next-cover");
const count = document.getElementById("pdf-count");
const prev = document.getElementById("pdf-prev");
const next = document.getElementById("pdf-next");
let currentPdf = 0;
function fileUrl(filename) {
return `demo-pdf/${filename}`;
}
function showPdf(index) {
currentPdf = (index + pdfFiles.length) % pdfFiles.length;
const item = pdfFiles[currentPdf];
const previous = pdfFiles[(currentPdf - 1 + pdfFiles.length) % pdfFiles.length];
const nextItem = pdfFiles[(currentPdf + 1) % pdfFiles.length];
const pdfUrl = fileUrl(item.pdf);
coverLink.href = pdfUrl;
cover.src = fileUrl(item.cover);
cover.alt = item.alt;
prevCover.src = fileUrl(previous.cover);
nextCover.src = fileUrl(nextItem.cover);
count.textContent = `${currentPdf + 1} / ${pdfFiles.length}`;
prev.disabled = pdfFiles.length <= 1;
next.disabled = pdfFiles.length <= 1;
}
if (pdfFiles.length === 0) {
empty.style.display = "block";
viewer.style.display = "none";
} else {
showPdf(0);
}
prev.addEventListener("click", () => showPdf(currentPdf - 1));
next.addEventListener("click", () => showPdf(currentPdf + 1));
</script>
</body>
</html>