A JavaFX desktop application that implements a Retrieval Augmented Generation (RAG) chatbot powered by OpenAI.
- Chat Interface - Interactive chat UI with conversation history
- Knowledge Base Management - Import and manage PDF documents as context
- RAG-powered Responses - Uses document embeddings to provide context-aware answers
- Session Management - Create, edit, and manage multiple chat sessions
- Dark/Light Theme - Toggle between dark and light modes
- Persistent Storage - SQLite database for storing sessions and chat history
- Java 25 with JavaFX 21
- LangChain4j - LLM integration framework
- OpenAI API - GPT models for chat and text-embedding-3-small for embeddings
- Apache PDFBox - PDF document parsing
- SQLite - Local database storage
- Log4j2 - Logging
- Java 25 or higher
- Maven 3.6+
- OpenAI API key
-
Download the repository. This assignment is submitted as a zip file, therefore no git is involved.
-
Create a
.envfile in the project root and add your OpenAI API key:OPENAI_API_KEY=your_api_key_here
mvn clean javafx:runTo build the standalone JAR yourself:
mvn clean packageThis will generate target/rag-1.0-SNAPSHOT.jar which can be run with java -jar.
Refer to the Part A report.
Refer to the Part B report.
This project is for educational purposes.