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

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

2025-07-11 11:45:11 [go] Source: ByteGenius
caseyou can future careers in techcompress it if we are going toupload it inside your neural lab so hereI'm writing about PDF uhcompressor uh so here you can compressthe PDF with any free compressor nowhere I'm using this particular uhwebsite I'm opening my PDF and here itis giving the recommended compressionnow if I will click on the compressPDF so it got converted into a 137 MBfrom 2.11 MB now it is saying to me youcan download it so I'm downloading thisparticular PDF and here Transformercompressor right so I got my compressedPDF it is very simple step you can openthe Google and you can search about thePDF compressor if your PDF is too hugelet's say see here we are using a PDFnow for getting a data for collecting adata right real time data so for thatonly uh like I use this PDF compressorbecause this neural lab is notallying okay a file basically which ishaving the size around 2 MB 2.11 MB nowlet's see we are able to upload it ornot so what I will do here I will usethis Transformer compressed and if I'mgoing to upload it or still it is sayingthat request entity to larger okay justwait uh let me compress it again uhselect PDF and here is a compress PDFbecause I want to make it a small onlynow extreme compressor okay this oneonly let's see what will be the size ofitno just asecond select PDF and here compressPDF extremelycomparison uh the size is going to be1.3 MB I don't think this lab will allowto me just asecond otherwise I will have to use anyother file um this just a second let mecheck so it is saying request entity toolarge no issue no worry uh see what Idid actually let me show you my downloadsection so here before the class itselfI have uh I was exploring it and Idownloaded couple of PDF so this was thePDF actually this was this is a YOLOresearch paper so let me show you thisparticular PDF this one see this is theYOLO research paper YOLO V7 okay YOLO V7as of now I was trying to show youwith attention all your need paper butit is not allowing because uh the sizeis a little huge see the size of thiscompressed file 540 KB only now here thesize of this Transformer compress around1,339 so actually it is not allowing tome to upload this particular PDF so inthat case what you can do so here uh youcan uh we can use this YOLO V7 paper nowwhat I'm going to do let me first of allrename this particular paper okay uh Iwill have to close it from here just asecond now let me rename this paper sohere I'm going to write it down YOLO V7so this is what this is my YOLO V7 paperand now let me upload it over therebecause I want a data and I'm going toread the PDF and from there itself I amgoing to collect my data for convertinginto a embeding so now see it we haveuploaded this particular PDF so if yourPDF is uh exceeding exceeding the sizethe size is around 1 MB so it won'tallow to you you cannot upload the PDFin our neural lab so don't worry it willbe solved in our near a future sessionsso our team is working on that and it isU we are like uh making it more powerfulas well so don't worry many morefunctionality will find out over hereitself inside the lab now we got thisYOLO V7 now what I will do guys so hereI'm going to read this PDF so for thatalready I'm uh for that basicallyalready I have imported this particularclass so here I'm uh like passing it I'mcopying and pasting over here and thenhere I'm writing PDFs right so once Iwill write on the PDFs so see it isgiving me that PDFs is not defined uhPDFs where is aPDF okay so actually I will have to passin a double code just wait let me takein a double code yes so I I'm able toload this PDF actually whatever we haveinside this PDF folder now what I willdo guys here I'm going to write down theloader so this is what this is my loaderand now what I will do guys so here Iwill call loader loader. load right soby using this particular code I will beable to read my PDF see this is whatthis is my PDF now here I can collectthis data so this is what this is mydata which I'm going to be convert intoa vectors with that I'm going to makinga like embeddings and all and thatembedding I'm going to store inside mydat database inside my Vector databasewhich is a pine gon right so now let meshow you this data so here is what guyshere is my data which you can see overhere and it is in a list format listform so here just press zero so you willfind out all the data entire databasically uh whatever we have inside thePDF this is what this is my data rightnow here we are able to load the PDF nowguys let me give you this particularcode so at least you all can run insideyour system so just a seconduh here is a code guys this one forloading the PDF and here we have onemore function that's going to be a datado load so loader do load actually justa second let me copy and paste over herethis one so loader and here basically wehave a PDF and we are able to load thedata now uh yes we are able to get adata now what I will do guys so here Iwill perform the uh like a tokenizationright right so here the next step isgoing to be a tokenization one let meshow you uh The Next Step so what I'mgoing to do let me do one thing let mecopy and paste and here is what here ismy next step basically so just look intothe step what I'm doing here I'm callingthis recursive character text splitterright and here my chunk size

(Editor: java)

Recommended articles
Hot reading