GPT-4o Model Access and Emotional Audio Voice Generation in Python?

A few hours ago I bought access to GPT-4o
since I wanted to test out emotional audio outputs.

I can’t find an example for this,
but this example was generated for creating emotional text:

from openai import OpenAI

client = OpenAI( api_key = os.getenv('openAiApiKey')  )

models = client.models.list()
print(models)

prompt = "Tell me a story about a brave knight."
emotion = "joyful"  # You can change this to any emotion like 'sad', 'angry', 'excited', etc.

emotional_prompt = f"Respond with a {emotion} tone: {prompt}"

response = client.completions.create(
    model="gpt-4-turbo",  # Use the model you have access to
    prompt=emotional_prompt,
    max_tokens=150,
    temperature=0.7
)

print(response.choices[0].text.strip())

However I am getting the following error:

openai.NotFoundError: Error code: 404 - {'error': {'message': 'The model `gpt-4-turbo` does not exist or you do not have access to it.', 'type': 'invalid_request_error', 'param': None, 'code': 'model_not_found'}}

My billing dashboard states the payment went through. Does the OpenAI API take a few hours or days to process the billing update? Does anyone have a simple example for input text to emotional voice audio outputs?

Thank you.

yeah, I’m interested in emotional audio outputs too.

I’m yet to try the turbo4o engine for this purpose, but I’ve been trying out the tts1 model. It’s good, but it could be better right? :wink: