Skip to content

error in line 16 role_playing.py #133

Closed Answered by Benjamin-eecs
Devdevdevdev asked this question in Q&A
Discussion options

You must be logged in to vote

It seems there was a small syntax error. When setting the API key in PowerShell, you need to enclose the key in quotes. Here's the corrected command:

$env:OPENAI_API_KEY = "myapikeynumber"

Replace myapikeynumber with your actual OpenAI API key.

After setting the API key this way, you can confirm that it's set correctly by running:

echo $env:OPENAI_API_KEY

This should display your API key in the console.

Replies: 3 comments 11 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
8 replies
@Devdevdevdev
Comment options

@Devdevdevdev
Comment options

@Benjamin-eecs
Comment options

@Devdevdevdev
Comment options

@Benjamin-eecs
Comment options

Comment options

You must be logged in to vote
3 replies
@Benjamin-eecs
Comment options

Answer selected by Devdevdevdev
@Devdevdevdev
Comment options

@Benjamin-eecs
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants