phidatahq / ai-cookbook

Mozilla Public License 2.0
60 stars 12 forks source link

AI Cookbook

This repo contains a collection of AI recipes/patterns built using phidata

Live Demos

The AI cookbook apps are live and can be accessed at:

Setup

  1. Clone the git repo

from the ai-cookbook dir:

  1. Create + activate a virtual env:
python3 -m venv aienv
source aienv/bin/activate
  1. Install phidata:
pip install phidata
  1. Setup workspace:
phi ws setup
  1. Copy workspace/example_secrets to workspace/secrets:
cp -r workspace/example_secrets workspace/secrets
  1. Copy .env file:
cp example.env .env
  1. Update .env file:
HACKERNEWS_AI=True
# OPENAI_API_KEY=sk-***
export OPENAI_API_KEY=sk-***

Run AI Cookbook locally

  1. Install docker desktop

  2. Start the workspace using:

phi ws up
  1. Stop the workspace using:
phi ws down