Getting Started

We have created a repository for this workshop. It contains the starter code and resources you need.

A blank Neo4j Sandbox instance has also been created for you to use during this course.

You can open a Neo4j Browser window throughout this course by clicking the Toggle Sandbox button in the bottom right-hand corner of the screen.

Get the code

You can use Gitpod as an online IDE and workspace for this workshop. It will automatically clone the workshop repository and set up your environment.

Open Gitpod workspace

You will need to login with a Github account.

Alternatively, you can clone the repository and set up the environment yourself.

Develop on your local machine

You will need Python installed and the ability to install packages using pip.

You may want to set up a virtual environment using venv or virtualenv to keep your dependencies separate from other projects.

Clone the github.com/willtai/genai-workshop repository:

bash
git clone https://github.com/neo4j-graphacademy/genai-workshop-graphrag

Install the required packages using pip:

bash
cd genai-workshop
pip install -r requirements.txt

Setup the environment

Create a copy of the .env.example file and name it .env. Fill in the required values.

Create a .env file
OPENAI_API_KEY="sk-..."
NEO4J_URI="bolt://"
NEO4J_USERNAME="neo4j"
NEO4J_PASSWORD="password"
TOKENIZERS_PARALLELISM="true"

Add your Open AI API key (OPENAI_API_KEY), which you can get from platform.openai.com.

Update the Neo4j sandbox connection details:

NEO4J_URI

bolt://{sandbox-ip}:{sandbox-boltPort}

NEO4J_USERNAME

{sandbox-username}

NEO4J_PASSWORD

{sandbox-password}

Test your setup

You can test your setup by running test_environment.py - this will attempt to connect to the Neo4j sandbox and the OpenAI API.

You will see an OK message if you have set up your environment correctly. If any tests fail, check the contents of the .env file.

Continue

When you are ready, you can move on to the next task.

Summary

You have setup your environment and are ready to start the workshop.