TL;DR is a tool designed to read and analyze documents, extracting key information and summarizing content for quick understanding.
- create a file
.envin the root directory of the project with the following content:
OPENAI_API_KEY=add_your_key_here
OPENAI_ORG_ID=org_12345
OPENAI_PROJECT_ID=proj_whateverReplace the placeholders with your actual OpenAI API key, organization ID, and project ID.
- build the project with
./mvnw clean package - run the application with
./mvnw clean spring-boot:run
Optionally, you can also configure the model and reasoning effort by adding the following lines to your .env file:
OPENAI_MODEL=gpt-5-mini
# Applies to gpt-5 only: currently supported values are minimal, low, medium, and high
OPENAI_MODEL_REASONING_EFFORT=minimalInstall tesseract and leptonica if you want to use OCR for image-based PDFs.
$ brew install tesseract
$ brew install leptonicaThe file sample1.pdf is read and processed by the application. The application uses Spring AI to interact with OpenAI's GPT-4 model to analyze the content of the PDF and generate a summary.