Keys and tokens

Note: Never paste a real key into a lesson page or into git. Use your terminal only.

Key in the environment

Providers give you a secret key. Export it in the same terminal session where you run praisonai or Python.

Security and Install in Agents use the same pattern.

Example

export OPENAI_API_KEY=your_key_here

Input and output tokens

Input tokens are everything you send: instructions, history, and your question.

Output tokens are what the model writes back. Providers bill by token count; smaller models usually cost less.

The Observe course shows totals after real runs; here you only need the vocabulary.

Example

# After a run you might see lines like:
# input tokens: 120
# output tokens: 45

Reference: documentation