This repository contains Jupyter notebooks for the workshop Generative AI - A whirlwind tour
by Mario Zechner.
For remote or in-person workshop bookings, please reach out at [email protected].
Workshop Duration: Minimum 4 hours, maximum 10 hours.
Languages: English or German (Course materials in English only).
Target Audience: This workshop is ideal for organizations interested in:
Prerequisites: Basic familiarity with any programming language is beneficial but not required. The workshop is designed to be accessible, with technical concepts explained in a way that everyone can understand.
Content Overview:
Key Takeaways:
Pricing is tailored to meet individual or organizational needs.
"Mario hat uns in nur wenigen Stunden einen fundierten Einblick gegeben, wie GenAI funktioniert und wo heute die Möglichkeiten und Grenzen liegen. Der Workshop zielt auf Leute mit Basis SW Entwicklungs-Know How ab und hilft unserem Unternehmen, die AI Strategie besser zu definieren."
- Bernhard Reichel, CEO ETM professional control
"Demystified the "magic" notion of AI and brought it down to earth for us in order to get a more correct idea what it can be useful for."
- Course participant, ETM professional control
"Sehr kompetenter Trainer und schonungsloses Aufzeigen von Vor-/Nachteilen der LLMs (=keine Marketingveranstaltung "pro AI")"
- Course participant, ETM professional control
The contents of this repository are licensed under the CC BY-NC 4.0 DEED license. You are free to share and adapt the contents of your repository under the following terms:
See the full license text for more information.
You can run the notebooks via Google Colab, or locally via Jupyter.
Some of the notebooks require you to get an OpenAI API key, as well as a Hugging Face API token.
Sign up for Hugging Face (free)
Click the links below to open each section in Google Colab in your browser.
This repository also contains more elaborate projects, that are closer to real-world use cases.
The "product adviser" uses a simple "grounding" technique as described in the Prompt Engineering notebook.
Its task is it, to answer customer questions for a specific product the customer is currently viewing in the webshop of Blue Tomato.
The product advisor is implemented as 2 components:
content.js
. When a page is loaded, the extension checks if the viewed URL is that of a product on blue-tomato.com. If so, it issues a request to the server component (/create
), which returns an id for the current chat, as well as 5 questions, a user may ask about the product, which are displayed as suggestions. When the user selects a suggested question, or enters their own question, a call to the /turn
endpoint is issued, sending the server component the chat id and the message the user selected/entered. It then receives the response from the server, which itself gets the answer from OpenAI's API. The returned answer is then rendered in the chat UI./create
: called by the Google Chrome extension when a product page on blue-tomato.com is viewed. It receives the URL of the viewed page, extracts its plain text, and creates an in-memory object that keeps track of the chat history for this specific session. The system prompt contains the extracted product page contents, and instructions to answer any question based on that extracted text./turn
: called by the Google Chrome extension when the user entered a new message/question. Receives the chat id and the new message. The new message is appeneded to the chat history for that chat id. Then the full chat history plus the system prompt including the product page text and instructions are send to OpenAI's APIs to receive a corresponding answer. The answer is stored in the chat history and returned to the Google Chrome extension.To run this demo:
cd examples/product-advisor && ./setup.sh && source venv/bin/activate
to create a Python virtual environment, install the dependencies, and activate the virtual environment for the current terminal session. Then run python sever.py
to start the server.chrome://extensions
in Google Chrome. Click on "Load unpacked" and select the directory examples/product-advisor/extension
.