Various Jupyter Notebooks used for experimentation.
- Click on any
*.ipynb
file. - Click ing on the
Raw
button and thenCtrl+S
to save the file. - Import the notebooks into the IllumiDesk course as a new
Activity
. - Run the cells in the notebook to see the results.
NOTE: When using the IllumiDesk Activity, you need to set the
openai_api_key
variable in the first cell of the notebook as a named parameter to theOpenAI
class. For example:
openai_api_key = "sk-..."
chatgpt_chain = LLMChain(
llm=OpenAI(temperature=0, openai_api_key=openai_api_key),
prompt=prompt,
verbose=True,
memory=ConversationBufferWindowMemory(k=2),
)
The
OPENAI_API_KEY
is already set in theCodespaces
environment variables.
-
Click on the
Code
button and thenOpen with Codespaces
.Python 3.10 and JupyterLab are enabled by default
-
Click on the
Run
button to start the JupyterLab server.
- Clone this repository.
- Create a virtuale environment and install the requirements.
virtualenv -p python3 venv/
source venv/bin/activate
pip install -r requirements.txt
- Export the OPENAI_API_KEY environment variable.
export OPENAI_API_KEY=sk-...
- Start the Jupyter Notebook server.
jupyter lab