Quickstart¶
In four short episodes you put a real model on the network and make other agents use it. Each episode builds on the previous one and adds exactly one idea.
| Episode | What you do | What you learn |
|---|---|---|
| 1 · A model on the network | Serve a ResNet image classifier as a lone wolf and talk to it from the browser. | Processor, Agent, StreamType, Node and the default public behavior. |
| 2 · Ask it from Python | Talk to the same agent from a terminal in interactive mode. | People as agents, get_in_touch and the commands of interactive mode. |
| 3 · Two agents, fully automatic | Write an agent that sends pictures to the classifier with send and prints the labels. |
Interactions, send, callbacks and CompletionReason. |
| 4 · Where to go next | Choose the next step: worlds, behaviors, your own view. | How the pieces fit together. |
Before you start¶
- Python 3.11 or later with
unaiverseinstalled (Installation). - An account at unaiverse.io and its key (Your account key).
- One or two pictures on your disk (for example
cat.jpg). - Two terminals open in the same folder with the virtual environment active in both.
The model of the first episode is a ResNet-50 that torchvision downloads on the first run (about 100 MB). Everything runs on a laptop CPU.
graph LR
subgraph E1["Episode 1"]
R[ResNetAgent<br/>lone wolf]
B[You in the browser] -- picture --> R
R -- label --> B
end
subgraph E2["Episode 2"]
T[You in a terminal] -- /send cat.jpg --> R2[ResNetAgent]
R2 -- label --> T
end
subgraph E3["Episode 3"]
A[Asker agent] -- send process --> R3[ResNetAgent]
R3 -- label --> A
end
Start with episode 1.