Exercise#2 Few Shot : Code

Objective

Understanding how examples are used with models is important. In the last exercise you used Cohere playground to try out the zero/few shots prompt. In this exercise you will go through a notebook that demonstrates the use of zero/few shots prompts for tasks as well as the limitations.

Notebook

There are two notebooks. One for the Hugging Face models and another for Cohere models. You may pick one or try both in local Jupyter Lab setup or on Google colab.

Local Jupyter Lab setup

few-shots-code-notebooks

Google Colab

Hugging Face Open In Colab

Cohere

Open In Colab