Connect to OpenAI
Set up your secret key

OPENAI_API_KEY = getpass("Please enter your OpenAI API Key: ")
import openai

openai.api_key = OPENAI_API_KEY

A test call for embeddings
Quickly check how one can get the embedding vectors for a list of input texts:

embedding_model_name = "text-embedding-ada-002"

result = openai.Embedding.create(
    input=[
        "This is a sentence",
        "A second sentence"
    ],
    engine=embedding_model_name,
)

print(f"len(result.data)              = {len(result.data)}")
print(f"result.data[1].embedding      = {str(result.data[1].embedding)[:55]}...")
print(f"len(result.data[1].embedding) = {len(result.data[1].embedding)}")