Soniox
Docs

Text capabilities

Explore text capabilities of Omnio.

Omnio is also a powerful AI model for text-to-text applications. Omnio performs on-par with GPT-4o, Mistral Large 2 and Claude 3.5 Sonnet on text-to-text benchmarks. Visit our Omnio blog post for benchmark information.

Example

Make sure you have created a Soniox Account and set the API key. You can find the instructions here.

Terminal
export SONIOX_API_KEY="your_soniox_api_key_here"

Install OpenAI SDK for Python using pip:

Terminal
pip install openai

Create a file called example.py with the following code:

example.py
import os
from openai import OpenAI
 
client = OpenAI(
    api_key=os.environ["SONIOX_API_KEY"],
    base_url="https://stt-rt.soniox.com/v1",
)
 
completion = client.chat.completions.create(
    model="omnio-chat-audio-preview",
    messages=[{"role": "user", "content": "Explain how matrix multiplication works."}],
)
 
print(completion.choices[0].message.content)

Run the code with python example.py and in a few moments you should see the response from the API.

On this page