Skip to content

Commit

Permalink
Merge pull request #15 from luo-anthony/patch-1
Browse files Browse the repository at this point in the history
Add API Key Setup to README
  • Loading branch information
Bam4d authored Dec 17, 2023
2 parents 60d37a0 + 08df8e7 commit 91854c5
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,20 @@ poetry install

## Run examples

You can run the examples in the `examples/` directory using `poetry run` or by entering the virtual environment using `poetry shell`. You should have a `MISTRAL_API_KEY` environment variable defined containing your API key to run those examples.
You can run the examples in the `examples/` directory using `poetry run` or by entering the virtual environment using `poetry shell`.

### API Key Setup
Running the examples requires a Mistral AI API key.

1. Get your own Mistral API Key: https://docs.mistral.ai/#api-access
2. Set your Mistral API Key as an environment variable. You only need to do this once.
```bash
# set Mistral API Key (using zsh for example)
$ echo 'export MISTRAL_API_KEY=[your_key_here]' >> ~/.zshenv

# reload the environment (or just quit and open a new terminal)
$ source ~/.zshenv
```

### Using poetry run

Expand Down

0 comments on commit 91854c5

Please sign in to comment.