ai-python-basics

Installation
SKILL.md

ai-python-basics

Requires Python 3.12 or later. Install with uv add ai.

Use import ai.

For gateway-routed model IDs, set AI_GATEWAY_API_KEY.

Core pieces:

  • Model selects the provider and model.
  • Messages are typed Python objects.
  • ai.stream makes one model call and returns one assistant message.
  • ai.Agent wraps ai.stream in a loop that executes Python tools and manages history.

Use gateway model IDs unless you need a direct provider:

Installs
9
GitHub Stars
148
First Seen
12 days ago
ai-python-basics — vercel-labs/ai-python