Tokens and cost

Note: Costs depend on the model name PraisonAI sees for each call. Unknown models show as unknown, not a guessed price.

Short answer, fewer tokens

Session totals come from the CLI. Here you practise a token-conscious instruction before you run with –session locally.

Example

from praisonai import Agent

agent = Agent(instructions="Answer in at most fifteen words.")
print(agent.start("Summarise agents in one line."))

Try it Yourself

What you are paying for

Each model call sends input tokens (your prompt and context) and returns output tokens (the reply). Cached tokens, when the provider reports them, can lower the input side.

After a praisonai run with a session, the CLI can print a short footer with token counts and an estimated cost.

Example

praisonai run "Summarise this in one line: agents use tools" --session observe-demo

Example explained

  • input tokens — What you sent to the model.
  • output tokens — What the model wrote back.
  • –session — Names the run so totals can accumulate if you continue later.

See totals across sessions

Session list shows stored token and cost columns when runs used a session id.

Usage rolls up many sessions when you want a weekly view.

Example

praisonai session list
praisonai usage --days 7

In the web console

The Usage page in the dashboard shows the same kind of rollups when your runs went through Chat or Jobs.

An active chat session may show a short cost or token summary on the session—use Usage when you need a wider date range.

Reference: documentation