# Build a chatbot that answers from podcast transcripts

> Build an assistant that answers questions from a podcast’s back catalogue, quoting the speaker and linking to the exact moment in the episode.

Source: https://www.podcastlookup.com/use-cases/podcast-chatbot

**Let fans ask the show anything.** Years of episodes hold answers nobody can find. Load a show’s transcripts, retrieve the right moments, and let Claude answer with the speaker, the episode and a link to the second it was said.

Uses: API. For: Podcast networks, Creators, Course platforms, Developer tools.

## What you get

- **Answers with sources.** Each answer cites the episode, the speaker and the timestamp, so fans can check it, and keep listening.
- **Knows who said it.** Speaker names are part of every line: ask what one guest thinks, or how the host’s view changed over the years.
- **Your stack, your data.** Store transcripts in your own database or vector store. Answering questions costs no credits.

## How it works

### 1. Load the back catalogue

List every episode, 100 per call, and fetch the transcripts that exist. Request the missing ones once.

`load.ts`:

```ts
const API_BASE = "https://www.podcastlookup.com/api/v1"
const lookup = (path: string, init?: RequestInit) =>
  fetch(API_BASE + path, {
    ...init,
    headers: { Authorization: `Bearer ${process.env.PODCAST_LOOKUP_API_KEY}` },
  }).then((res) => res.json())

const podcastId = 4458228
const transcripts = []
for (let page = 1; ; page++) {
  const body = await lookup(`/podcasts/${podcastId}/episodes?page=${page}&page_size=100`)
  for (const ep of body.episodes) {
    if (ep.transcript) transcripts.push(await lookup(`/podcasts/${podcastId}/episodes/${ep.id}/transcript`))
  }
  if (page * body.page_size >= body.total) break
}
```

### 2. Cut it into moments

Group consecutive lines into chunks of a minute or two. Keep the speaker, the start time and the episode link on each chunk.

`chunk.ts`:

```ts
const chunks = transcripts.flatMap((t) => {
  const out = []
  for (let i = 0; i < t.segments.length; i += 8) {
    const lines = t.segments.slice(i, i + 8)
    out.push({
      url: `${t.url}#t=${Math.floor(lines[0].start_seconds)}`,
      text: lines.map((s) => `${s.speaker}: ${s.text}`).join("\n"),
    })
  }
  return out
})
// Embed and store chunks in pgvector, Turbopuffer, Pinecone…
```

### 3. Answer with Claude

Retrieve the closest chunks for each question and ask Claude to answer only from them, citing the links.

`answer.ts`:

```ts
import Anthropic from "@anthropic-ai/sdk"

const context = (await search(question, 8)) // your vector search
  .map((c) => `<moment url="${c.url}">\n${c.text}\n</moment>`)
  .join("\n")

const message = await new Anthropic().messages.create({
  model: "claude-opus-5-5",
  max_tokens: 16000,
  system: "Answer only from the moments given. Name the speaker and cite the url.",
  messages: [{ role: "user", content: `${context}\n\nQuestion: ${question}` }],
})
```

## What it costs

|  | Credits |
| --- | --- |
| List episodes, per 100 | 1 |
| One transcript | 1 |
| A 200-episode show, loaded once | ≈ 202 |
| Answering questions | 0 |

Loading is a one-off; after that, only new episodes cost a credit each. Pro: 10,000 credits for $100 a month. Business: 100,000 for $499 a month. Free accounts get 50 credits a month to try it. Details: https://www.podcastlookup.com/pricing.md

## Questions & answers

### Can I build this for a show I don’t own?

For your own research, yes. To publish a public chatbot about someone else’s show, ask the publisher first: the transcripts describe their work.

### Why not just paste the transcripts into the prompt?

For one episode, do. Claude reads a whole transcript at once. Retrieval only matters once you have dozens of episodes.

### Are timestamps precise enough to link?

Each line has start and end times to the hundredth of a second, so links land on the sentence, not the minute.

### Can it use the MCP server instead?

Yes: an agent connected to the MCP server can fetch transcripts on demand. Retrieval over your own store is faster and cheaper for a fixed catalogue.

## Go further

- [Get a transcript](https://www.podcastlookup.com/documentation/rest-api/get-transcript.md)
- [Startup ideas newsletter](https://www.podcastlookup.com/use-cases/startup-ideas-newsletter.md): Mine founder podcasts for ideas, every week
- [Podcast to newsletter](https://www.podcastlookup.com/use-cases/podcast-to-newsletter.md): Every new episode, written up and sent
- [Podcasts in Claude](https://www.podcastlookup.com/use-cases/podcast-research-in-claude.md): Research any show from Claude, Cursor or VS Code
- [Brand mentions](https://www.podcastlookup.com/use-cases/brand-mentions.md): Know when your company is said out loud
- [Guest outreach](https://www.podcastlookup.com/use-cases/podcast-guest-outreach.md): Find the right shows to pitch, and who hosts them
