generative-ai-for-beginners icon indicating copy to clipboard operation
generative-ai-for-beginners copied to clipboard

different handling environment (missing dotenv.load_dotenv() in sample 08)

Open bmerkle opened this issue 6 months ago • 1 comments

Describe the bug most python samples use

# import dotenv
dotenv.load_dotenv()

However in sample08 the environment variables are only used, (so .env files are ignored) e.g. transcript_enrich_summaries.py

# no usage of dotenv
API_KEY = os.environ["AZURE_OPENAI_API_KEY"]

I could contribute a patch/merge request for this.

To Reproduce all python programs transcript*.py in C:\work\microsoft\generative-ai-for-beginners\08-building-search-applications\scripts are missing dotenv and are using the environment variables only.

Expected behavior dotenv should be used in all examples

bmerkle avatar Jul 29 '24 09:07 bmerkle