#python3 pyopen.py > output.mdx import os from dotenv import load_dotenv from openai import OpenAI # pip install openai==1.30.5 # Load environment variables from the .env file load_dotenv() # Get the OpenAI API key from the environment variables api_key = os.getenv("OPENAI_API_KEY") # Initialize the OpenAI client client = OpenAI( api_key=api_key, ) chat_completion = client.chat.completions.create( messages=[ { "role": "system", "content": """You are an expert developer in SliDev - the framework to create PPTs """, }, {"role": "user", "content": "Who are you and what can you do?"} ], model="gpt-4o-mini", temperature=0.3, ) # print(chat_completion) # Extract and print the content of the completed message completed_message = chat_completion.choices[0].message.content print(completed_message)