Welcome to the intersection of structured data and cutting-edge AI! This Jupyter notebook aims to explore the synergy between RDF cubes, SPARQL queries, and Language Model (LM) capabilities. Using OpenAI's API through LangChain, we will dive into the process of constructing intuitive SPARQL queries to interact with RDF cubes, enhancing our data retrieval and analysis processes
This Proof of Concept (PoC) taps into the powerful combination of structured semantic web data (RDF cubes) and natural language processing.
The fastest way to try this is to click on the "launch binder" icon above. This will start a web-based container where you can directly try the notebook. The only thing you need to adjust is the OpenAI API key, which you can generate using the trial offer from OpenAI (requires credit card now apparently...).
If you wish to run the project locally, please follow the installation guide below.
Ensure you have Python 3.10 installed to align with our dependencies.
pip install poetry
- Clone the repository and navigate to the project directory.
git clone https://github.com/ktk/cube-sparql-llm.git
cd cube-sparql-llm
- Create a virtual environment within the project directory.
python -m venv .venv
- Activate your virtual environment
source .venv/bin/activate
- Install dependencies using poetry in virtual environment
poetry install --no-root
- Run it within Visual Studio Code
The optimal experience is through Visual Studio Code equipped with the Jupyter extension . This setup allows seamless interaction with the playground/full_pipeline.ipynb
notebook, our playground for our hands-on adventure.
We welcome contributions from the community! If you have suggestions for improvements or want to contribute to the code, please feel free to fork the repository, make your changes, and submit a pull request.
This project is licensed under the MIT License - see the LICENSE file for details.
Copyright 2023 Zazuko GmbH