Current location: Homepage > ai > Generative AI Full Course – Gemini Pro, OpenAI, Llama, Langchain, Pinecone, Vector Databases & More - Ep175

Generative AI Full Course – Gemini Pro, OpenAI, Llama, Langchain, Pinecone, Vector Databases & More - Ep175

2025-07-11 11:42:54 [c] Source: ByteGenius
thevector databases now in the next classeasily we can miley cyrus interviewimplement the projectright easily we can implement theproject and we can perform the RGretrieval argument generator so thisVector database we use for the RG onlyfor the retriever agumented generationand is going to play a very importantrole if you are going to create createany sort of a application related to thellms right related to the generative AIwhere you are going to use llm so pleaseguys be take a take it serious and yesin interview they will ask you the samething right I have seen many requirewhatever requirements people are havingright related to the generative to thellm and they are specifically they havementioned chroma DB pine cone rightbecause this is a trend actually rightpeople are able to uh use it people areable to productionize it right peopleare able to achieve whatever they wantright with respect to their use casesand all and yes as a techie you have tosolve this thing you have to take carethis thing so please be serious overhere now uh here guys see we are able toretrieve the document a similar documentby using this particular method rightnow everything you will find out overthe documentation if you want tounderstand a more depth go and checkwith the documentation now let's try tounderstand the next concept so here youcan see we have a doc two now let's doone thing let's make it more interactiveand so for that here I have writtensomething uh so let's make a chain nowwhat I can do I can make a chain andhere guys for that here is one Libraryyou will find out inside the Len CHitself the library is going to beretrieval QA now let me run it and yeswe are able to import this retrieval Qretrieval means you just need toretrieve it retrieve it you just need toget it right retrieve means responseright so here you can see we have thisretrieval QA now what I will do guyshere I'm going to use my llm model soI'm going to call my open API because Iwant to I want to get uh see here if youif you will find out in the response sojust just look into the response here sojust just print this particularresponse um what I can do I can print itnow see the response so they are givingyou the response and they are mentioningeverything over there now how to make itmore interactive and how to work with itlike a question answering right questionanswering so for that you'll find outthis retrieval QA over here now here I'mgoing to use my llm now you will findout the use of the llm over here what isthe use or I will show you onearchitecture so here I shown you thesimple architecture which I created bymyself only here you can see clearly youcan understand everything I will showyou one more architecture and I willshow you what is the role of this llmover here what is the role of the llmover here right now just wait let meshow you that or first of all let me runit uh here I have written couple ofthing so let me show you the llmfirst see we have we are going to callopen API and by default we have the uhby default we have the model GPT modelcut it now what I'm going to do here I'mgoing to create a chain by using this aparticular method so retrieval QA fromchain type so LM open a model and herewe have a retriever object retriever isthere this one okay retriever is thereand here you will find out the documentso return Source document is true so wejust need to pass two thing here thefirst is what up our model and thesecond one is retriever so retriever ishere this one okay this one so we aregoing to collect it from the vector DBthis retriever right so here Vector DBas retriever so this is my Retriever andby using this retriever only we aregetting an information whatever we arepassing as a question and we are usingthis method and this is what this is mydocs so this retriever object also weare passing over here so we have a llmmodel we have a retriever and here twomore parameter right now let me run itand here you can see we are able togenerate or we are able to create aobject and which I'm going to store inqhn right now guys here what I can do Ihave return one more method so let mecopy and paste it over here and one moremethod and after that the thing will bemore clear to all of you so what I'mdoing over here see uh this is the twomethod which I have pasted right two uhtwo code two Cod code is snipp itbasically which I pasted over here sohere see we want to create a retrieverQA so just just check what is themeaning of that just open the Google anduh search it over the Google Now pasteit over here and search about theretrieval Q QA so what is this retrievalQA everything you will find out insidethe Lang CH and guys believe me thislangen chain is very much powerful rightwhether whatever like framework you aregoing to learn in future I don't carellama index and all but please try tolearn this Len CH if you want to buildllm based application so just take aMastery on top of this Len chain it's aimportant one now here you will find outwhat is this retrieval QA this exampleso is question answering over an indexright the following example combining aretrieval with a question answeringchain to do question answering right sohere I just want to make a questionanswering chain and here is a completecode snipp it here is a complete examplewhich they have given to you now what Ican do here I can uh show you that howthat this uh two thing is working nowthis is what this is the from chain typewhich I called create a chain to answerthe question now see process llmresponse so llm response is there rightwhatever L see first of all see

(Editor: php)

Recommended articles
Hot reading