Advanced RAG tutorial with Llamaindex & OpenAI GPT: Sentence Window Retrieval vs Basic Chunking

แชร์
ฝัง
  • เผยแพร่เมื่อ 5 ก.ย. 2024

ความคิดเห็น • 32

  • @mikestaub
    @mikestaub 8 หลายเดือนก่อน +3

    This is currently the best RAG tutorial on the internet.

  • @unclecode
    @unclecode 8 หลายเดือนก่อน +2

    Fascinating! Your approach to teaching and presenting is poetic. It is well organized, well explained, and well illustrated. Indeed, kudos to you. If I could, I would subscribe to your channel twice!

  • @sitedev
    @sitedev 8 หลายเดือนก่อน +1

    Great video with an awesome easy to follow explanation of RAG. Reminds of a recent Andrej Karpathy video.

  • @victorfeight9644
    @victorfeight9644 4 หลายเดือนก่อน

    clear effective explanations thank you

  • @ginisksam
    @ginisksam 6 หลายเดือนก่อน

    Llama Index has new version 0.10 - will migrate your codes n learn same time.
    Thanks for introducing Sentence Window Retrieval. Most basic straight-split and retrieve/chat doesnt produce much meanings on our docs.

  • @danielvalentine132
    @danielvalentine132 8 หลายเดือนก่อน

    Great job explaining window and how vector store and doc store relate and where window lives. I’ve been trying to understand this aspect of llamaindex, and you made it very clear!

    • @hubel-labs
      @hubel-labs  8 หลายเดือนก่อน

      Yeah, it took me a while to figure that out too. Glad it helped you!

  • @nazihfattal974
    @nazihfattal974 8 หลายเดือนก่อน

    As always, well prepared, easy to follow video that delivers a lot of information and value. Thank you!

  • @MaliRasko
    @MaliRasko 8 หลายเดือนก่อน +1

    Your explanations and delivery is on point. Thank you for an excellent content and relaxed narration style.

  • @arjoai
    @arjoai 8 หลายเดือนก่อน

    Wow, that’s a wonderful piece of advice from such a talented professional in the field. Thank you 😊

  • @sayanbhattacharyya95
    @sayanbhattacharyya95 7 หลายเดือนก่อน

    Really cool video! Is there an "ideal" or "recommended" value of window_size?

  • @JOHNSMITH-ve3rq
    @JOHNSMITH-ve3rq 8 หลายเดือนก่อน +1

    Wow _ darn useful !!

  • @sivi3883
    @sivi3883 7 หลายเดือนก่อน

    Awesome video explained very clearly! Thanks a ton!
    If I may ask, what tool do you use for those visual flows. Love it!

  • @nunoalexandre6408
    @nunoalexandre6408 8 หลายเดือนก่อน

    Love it!!!!!!!!!!!!!!!!!

  • @mayurmoudhgalya3840
    @mayurmoudhgalya3840 8 หลายเดือนก่อน

    Another great video!

  • @natal10
    @natal10 8 หลายเดือนก่อน

    Great video!! Love it

    • @hubel-labs
      @hubel-labs  8 หลายเดือนก่อน +1

      Thank you!!

  • @goonymiami
    @goonymiami 8 หลายเดือนก่อน

    Seeing your explaination at around 09:30, it seems like we can only use K windows to serve as knowledge base to answer a prompt. What If the prompt asks information that is contained in more than K windows? Like if I have several documents containing each a bio of a person, and if the user asks to sort those 10 people by age... how can it figure it out? I guess we can use a big value for K, if the cosine similarity engine can take it... but I am guessing providing too much context to the LLM will cost a lot of money?

    • @hubel-labs
      @hubel-labs  8 หลายเดือนก่อน

      Yeah, it wouldn’t work very well in that scenario. I wonder if perhaps there is a strategy where the LLM can determine the right K based on what it is trying to do. Or instead of setting K to be a fixed number, to return all chunks where the cosine similarity is above a given threshold.

  • @Work_Pavan-mu9ye
    @Work_Pavan-mu9ye 8 หลายเดือนก่อน

    Excellent video. Liked the workflow you showed in the beginning. What SW are you using to create this workflow?

    • @hubel-labs
      @hubel-labs  8 หลายเดือนก่อน

      Excalidraw

  • @peteredmonds1712
    @peteredmonds1712 8 หลายเดือนก่อน

    Small correction: embedding are not a 1536 digit number but of vector of size 1536

    • @hubel-labs
      @hubel-labs  8 หลายเดือนก่อน +1

      Yes, you are right …. I was thinking of hashes for some reason! I’ll add a correction!

  • @peteredmonds1712
    @peteredmonds1712 8 หลายเดือนก่อน

    I'm a bit confused on the use case for re-ranking. Doesn't that defeat the purpose the top-k search in that we include all chunks, significantly increasing the number of tokens we use? Is the idea to do re-ranking with a smaller & cheaper LLM before sending the resultant top-K chunks to a more robust LLM?

    • @hubel-labs
      @hubel-labs  8 หลายเดือนก่อน +3

      yeah, it took me a while to understand it as well. It does end up using more tokens but I guess that can be, as you said, mitigated with a lower spec LLM. The idea is that embeddings is not a perfect representation of the text - it's a good way to sort through millions of text chunks efficiently but the exact ranking within the top 20, for instance, may not be as good as using the text directly. So if you were to do reranking, you might use the embeddings to return j results (where j is somewhat larger than k) and then rerank those j results using LLM into a final top k that you then pass into your user-facing LLM.

  • @chiggly007
    @chiggly007 8 หลายเดือนก่อน

    Great video? Is the diagram anywhere to refeeence?

    • @hubel-labs
      @hubel-labs  8 หลายเดือนก่อน

      I’ll post it up tomorrow - need to fix an error

    • @grabani
      @grabani 8 หลายเดือนก่อน

      @hubel-labs Any update on the diagram please - thanks? Great vid by the way.

    • @hubel-labs
      @hubel-labs  8 หลายเดือนก่อน +1

      I added it to the description. Here is the link: link.excalidraw.com/readonly/m6DK7oyEFpyQnuw55DVP?darkMode=true

  • @user-jj1ff2gz7u
    @user-jj1ff2gz7u 8 หลายเดือนก่อน

    df

  • @jannessantoso1405
    @jannessantoso1405 7 หลายเดือนก่อน

    it is 1784 in teahistory.txt and 1794 in chinahistory.txt so bit confusing
    but anw great tutorial Thanks