Live data from Hacker News

Show HN: Factual AI Q&A – Answers based on Huberman Lab transcripts

huberman.rile.yt

31–40 of 45 posts

Re: Show HN: Factual AI Q&A – Answers based on Huberman Lab transcripts

#31
post #26

This is pretty amazing. Is this approach documented or explained anywhere? I have some ideas of my own that I would love to implement similarly to this and it would help to know how to get started.

I imagine it is something similar to the following.

Preprocessing

1. Transcribe the dataset

2. Chunk the transcription into paragraphs.

3. Store the embedding of each paragraph into a vector database.

Querrying

1. Convert the user's query into an embedding

2. Query the vector database for the top N closest embeddings and fetch the paragraphs that correspond to them. To be robust against queries which you don't have results for you should limit how far away results can be from the user's query.

3. Using those paragraphs craft a propmt that you will give to a LLM.

4. Do any final filtering on the what you got back from the LLM.

Re: Show HN: Factual AI Q&A – Answers based on Huberman Lab transcripts

#33
post #25

This is an amazing piece of work and as others have said, the site and the UI are perfect. On a side note, Huberman Labs bothers me. I was an avid listener to the early episodes. As I have ADHD, some of his explanations of the brain chemistry involved in attention and motivation were fascinating. But in one of the early-ish episodes he said some completely ridiculous about acupuncture (that it worked) that makes me t…

Do you claim that acupuncture, a practice with significant use for thousands of years and supporting scientific studies, is invalid because it goes counter to your belief? [1][2] Prof Huberman is an expert and he reads up on relevant studies before talking about something. Even though he may occasionally make mistakes (who doesn't?), your evidence to the contrary, if any, should be at least as strong as his. Moreover…

You are right and everyone makes mistakes and I'm sure much of the Huberman Lab content is great. I don't claim that acupuncture is invalid because it goes against my belief. I claim that it does not work because there are no credible studies that show that it does. The links you have provided are not to studies, they are to organisations that promote/sell acupuncture. [Edited to correct a typo]

Re: Show HN: Factual AI Q&A – Answers based on Huberman Lab transcripts

#34
post #25

This is an amazing piece of work and as others have said, the site and the UI are perfect. On a side note, Huberman Labs bothers me. I was an avid listener to the early episodes. As I have ADHD, some of his explanations of the brain chemistry involved in attention and motivation were fascinating. But in one of the early-ish episodes he said some completely ridiculous about acupuncture (that it worked) that makes me t…

+1 to this. Huberman has the bad habit of constructing grand narratives that match his beliefs about health and reality, and packaging them as podcast episodes based on science. The only problem is that "based on science" might mean a single low-powered study, which Huberman cites and over-generalizes as if it was rock-solid fact. See this[0] discussion on Huberman's subreddit for more context. Another example is his…

+1

Re: Show HN: Factual AI Q&A – Answers based on Huberman Lab transcripts

#35
post #26

This is pretty amazing. Is this approach documented or explained anywhere? I have some ideas of my own that I would love to implement similarly to this and it would help to know how to get started.

I built something similar using a variety of YouTube channels focused on NLP, AI, etc. The app is here https://huggingface.co/spaces/jamescalam/ask-youtube - you can ask things like "what is a transformer model?" or "what is semantic search?"

The way I built it is documented here: https://www.pinecone.io/learn/openai-whisper/

Afaik it's the same approach as Riley, that is:

- Scrape audio of YouTube videos

- Transcribe to text with OpenAI's Whisper

- Use sentence transformer to create embeddings of text

- Index embeddings (with transcribed text, timestamps, and video URL attached) in Pinecone's vector database

- Wrap up the querying functionality in a nice UI

(this is for the search functionality)

If wanting to replicate the Q&A part, I also built something similar and wrote about it (https://youtu.be/coaaSxys5so) - it's essentially the same process but we return text snippets to GPT-3 along with the original question and it generates an answer

Re: Show HN: Factual AI Q&A – Answers based on Huberman Lab transcripts

#36

Can one generate the answers using text-embedding-ada-002 as well?

you can return the chunks of text containing the answers, but not generate answers as that isn't what text-embedding-ada-002 is for. For that you need generation model (davinci in this case)

Re: Show HN: Factual AI Q&A – Answers based on Huberman Lab transcripts

#37
post #33

Earlier quoted context omitted.

Do you claim that acupuncture, a practice with significant use for thousands of years and supporting scientific studies, is invalid because it goes counter to your belief? [1][2] Prof Huberman is an expert and he reads up on relevant studies before talking about something. Even though he may occasionally make mistakes (who doesn't?), your evidence to the contrary, if any, should be at least as strong as his. Moreover…

You are right and everyone makes mistakes and I'm sure much of the Huberman Lab content is great. I don't claim that acupuncture is invalid because it goes against my belief. I claim that it does not work because there are no credible studies that show that it does. The links you have provided are not to studies, they are to organisations that promote/sell acupuncture. [Edited to correct a typo]

Thanks for your explanation of the rationale.

The links I provided are to trustworthy organizations in healthcare who usually practice evidence-based medicine.

There are many studies referenced here: https://www.evidencebasedacupuncture.org/acupuncture-scienti...

This one is published in Cell: https://www.cell.com/neuron/fulltext/S0896-6273(20)30532-8

But of course, one can always find faults in most single studies. It's the accumulative amount of evidence that supports the claim that acupuncture often work for certain types of syndromes. Note that in medicine, few things have irrefutable proof as in math or even engineering.

Re: Show HN: Factual AI Q&A – Answers based on Huberman Lab transcripts

#38
post #26

This is pretty amazing. Is this approach documented or explained anywhere? I have some ideas of my own that I would love to implement similarly to this and it would help to know how to get started.

I built something similar using a variety of YouTube channels focused on NLP, AI, etc. The app is here https://huggingface.co/spaces/jamescalam/ask-youtube - you can ask things like "what is a transformer model?" or "what is semantic search?" The way I built it is documented here: https://www.pinecone.io/learn/openai-whisper/ Afaik it's the same approach as Riley, that is: - Scrape audio of YouTube videos - Transcrib…

I should add, Riley used the ada embedding model (rather than sentence transformers). Performance wise they should be similar (in ability to encode meaning accurately) but the ada model can encode a much larger chunk of text. I don't know exact numbers but something like 1-2 pages of text in a typical corporate PDF. Whereas sentence transformers are typically limited to around a paragraph of text.

Typically you'd split the text in paragraph sized chunks to handle this requirement of sentence transformers, with GPT-3 embeddings you naturally have more flexibility there

Re: Show HN: Factual AI Q&A – Answers based on Huberman Lab transcripts

#39
post #24
post #7

Earlier quoted context omitted.

It uses Whisper for transcripts, which I believe are better than the YouTube generated ones. My guess is that there are more relevant results from the semantic search than I'm including in the context (to reduce costs) and that exact snippet isn't being given to the answering model as context.

As I wrote here: https://news.ycombinator.com/item?id=34035123 , I also wrote a tool to access them. I'm pretty sure there are English transcripts which are manually generated, not just the YouTube generated ones. I've always found them to be high quality, enough to make a book out of.

For Huberman Podcast I imagine he pays someone to do the annotations manually, so they're accurate. But on most videos I've found Whisper's annotations to be more accurate than YouTube's default annotations - not to bash YouTube's, they're still great but occasionally you get some weird annotations

Re: Show HN: Factual AI Q&A – Answers based on Huberman Lab transcripts

#40
post #26

This is pretty amazing. Is this approach documented or explained anywhere? I have some ideas of my own that I would love to implement similarly to this and it would help to know how to get started.

I built something similar using a variety of YouTube channels focused on NLP, AI, etc. The app is here https://huggingface.co/spaces/jamescalam/ask-youtube - you can ask things like "what is a transformer model?" or "what is semantic search?" The way I built it is documented here: https://www.pinecone.io/learn/openai-whisper/ Afaik it's the same approach as Riley, that is: - Scrape audio of YouTube videos - Transcrib…

Thank you :)
Post reply on HN