Overview
This notebook expands upon the OpenAI Function calling documentation, focusing on interacting with PDF files. It provides a practical example of using OpenAI's API to process and analyze PDF documents.
Example
API Key: Insert your OpenAI API key at the beginning of the notebook. PDF Processing: The notebook demonstrates how to download a PDF from the arXiv repository, convert the text into embeddings and save the images to a PNG. Data Visualization: There is a corse data extraction for images from the PDF file.
This notebook includes:
- Downloading academic papers from arXiv.
- Reading and extracting information from PDF files.
- Integrating with OpenAI's API for the embeddings model and LLM.
- Displaying images via matplotlib.
- Answering questions based on the PDF
- Enabling the LLM to calling functions for displaying images and formatting equations
Ensure that your OpenAI API key is kept secure and is not shared publicly. The notebook contains placeholders for adding your API key.
This notebook is for educational purposes and serves as a guide to showcase the capabilities of OpenAI's function calling feature in conjunction with PDF processing. It is not intended for any specific production use.