Skip to content

Georgian GenAI 2023 Bootcamps Codebase - changes by Allure Security

Notifications You must be signed in to change notification settings

Allure-Security/genai

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

204 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Georgian

Georgian GenAI Boot Camp

Welcome to the Georgian GenAI boot camp repository. This repository contains all the demos we used during our bootcamps. Content for the latest boot camp can be found under the notebooks directory. A copy of the content from previous boot camps can be found in the archive.

Table of Contents


Goals

Our bootcamps usually consist of a few days of tutorials followed by a hackathon. At the end of the hackathon our goal was for participants to have:

  • A deeper understanding of the opportunities GenAI unlocks.
  • A theoretical understanding of the latest GenAI technologies.
  • A practical understanding of the latest GenAI technologies.
  • Implemented at least one end-to-end application using GenAI.

[Back to top]

Setup & Installation

  1. This repository requires you to have installed poetry as a dependency manager. Please follow the instructions to install poetry from here.

  2. Clone this repository and cd genai-bootcamp

  3. Environment management options

    a) Poetry: poetry shell

    b) Conda: create and activate a conda env for this project:

conda create -n genai-bootcamp python=3.10
conda activate genai-bootcamp
  1. Install package
poetry install
  1. Setup private environment files

Paste the .env file and google-api.json file provided to you into root directory of this repository.

Note: DO NOT COMMIT THIS FILE OR SHARE IT ANYWHERE!

Note: If you have trouble setting up Poetry, you should be able to skip it and just run pip install -r requirements.txt instead. Please reach out to us or create an issue if this does not work.

Note: Some operating systems might rename .env to env. The period at the front is important as all the notebooks expect this. Please rename the file if you run into this issue.

[Back to top]


Agenda

Below you can see the agenda we followed for our boot camp in October 2023.

Day 1:

Introduction to LLMs & Prompt Engineering (Georgian & Vector Institute)

Prompt Engineering & Evaluation (Georgian)

[Guest Speakers] Google & Microsoft

Day 2:

LLM Fine-Tuning & Alignment (Georgian)

Tools, Platforms, & Deployment (Georgian)

Privacy, Trust & Responsible AI (Georgian & PrivateAI)

Day 3:

[Guest Speakers] Meta & Qdrant

Day 4:

[Guest Speaker] LLM Observability with Arize AI

[Back to top]


API Access

Bootcamp Participants:

To be able to run the notebooks here, you'll need access to API keys for all the different services. Fear not, we've provided you with all the API keys you need. Just download the files we've sent to you and place them in the root of this directory.

Non-Bootcamp Participants:

To be able to run the notebooks here, you'll need access to API keys for all these services. Read on for instructions on how to set up each of the APIs that you need. Many of these APIs (such as OpenAI) will charge you based on usage, so you will need to set up billing.

Note that to run the examples, you only need to have one LLM set up. So if you already have access to an OpenAI key, you could run all the notebooks with it (excluding the Google/HuggingFace examples). The PrivateAI API key is used only for the PrivateAI demo (notebooks/extra_resources/PrivateAI Demo.ipynb). We use AnyScale to set up LLaMa 2 access.

  1. Create a .env file. In the root directory of this repo (I.E., the same directory this readme is in), create a .env file. Ensure that the period is present at the start of the filename. Within this file, place the following text:
OPENAI_API_KEY=""
GOOGLE_APPLICATION_CREDENTIALS="../../google-api.json"
ANYSCALE_API_BASE="https://api.endpoints.anyscale.com/v1"
ANYSCALE_API_KEY = ""
PRIVATE_AI_API_KEY = ""
AWS_ACCESS_KEY_ID=""
AWS_SECRET_ACCESS_KEY=""
AWS_DEFAULT_REGION="us-east-1"
  1. OpenAI: Create an OpenAI account (or login) and visit the API Keys page. Generate an API key here and place it in the .env file you created above. These examples were designed with GPT-4. If you do not have access to it, please request access through the waitlist. Or alternatively, you can use gpt-3.5-turbo instead.
  2. Google: Follow steps 1 through 4 detailed in this link. Once you have downloaded the service account key from step 4, place it in the root directory of this repository and rename it to google-api.json.
  3. AnyScale: Once you have billing setup, you can get your API keys from the credentials page.
  4. PrivateAI: Request an API key through this form. Add it to the .env file above.
  5. AWS Bedrock (for Claude): Follow the instructions on this page to obtain your AWS keys. Alternatively, you can authenticate via boto3 if you have AWS Bedrock access within your organization.
  6. You should now have all fields in the .env file setup and ready to go! You can now proceed with the installation steps below.

[Back to top]


Repository Info

Poetry

We use poetry as our dependency manager. The link above has great documentation but there is a TL;DR.

  • Install the package: poetry install
  • Add a dependency: poetry add <python-lib>
  • Where are dependencies specified? pyproject.toml include the high level requirements. The latests exact versions installed are in poetry.lock.

Debugging

  • If for some reason poetry install fails to install a library try to pip install <lib> and then run poetry install again. This solves 95% of these errors.

[Back to top]

Resources

[Back to top]

About

Georgian GenAI 2023 Bootcamps Codebase - changes by Allure Security

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Jupyter Notebook 98.2%
  • Python 1.7%
  • Shell 0.1%