How biopb fits together¶
Biopb is built around a simple idea: Give the AI agent resources and tools, then ask the agent to write an image analysis program specifically tailored to your data.
The pieces¶
Your AI agent¶
The agent is who you talk to. Instead of clicking through menus, you describe what you want, and the agent writes and runs the analysis code. Crucially, the agent isn't limited to a fixed menu of buttons. It works in a real Python environment with your data and algorithms pre-wired in, and is a capable assistant knowledgeable about all kinds of image analysis pipelines.
See working with agents for details.
Napari + Data Browser¶
Napari is the image viewer. It comes preloaded with a Data Browser plugin letting you and your agent browse and open data together. You can add a label by hand, and the agent can read it back — it's a shared canvas.
See working with napari for details.
The control plane¶
The control plane is the durable root of a biopb install, and the piece you actually visit in a browser. It does two jobs:
- It owns the data plane. It starts the tensor server, watches it, and restarts it if it crashes. Nothing else is allowed to start one — that's why you no longer start a server by hand before using biopb.
- It's the single web origin. Everything you open lives behind one address,
http://127.0.0.1:8813: the dashboard at
/, the image viewer at/viewer, the server admin page at/admin, the data-plane logs at/logs, and each agent session's observe view at/session/<id>/observe.
The dashboard is the one thing worth bookmarking. From it you can see which agent sessions are running and open their observe views, check and restart the data plane, browse your data, and register biopb with your agent. See Working with the dashboard.
The data plane¶
The tensor server owns "where the pixels live and how they move." It reads whatever microscopy format you have and serves it as uniform, lazy, chunked arrays over Apache Arrow Flight. "Lazy" means pixels are fetched only as needed, so your agent can work with images far larger than your computer's RAM.
The default install runs a tensor server locally for you. See Data (tensor) servers to connect to or deploy your own.
Note
Under the hood biopb uses dask.array to represent all image data, and spins up a local
dask cluster for the agent to use. This is why your agent can run some serious
computation, instead of being just a cute demo toy. You can even hook up a
distributed dask cluster, if your institute has one, to really run some intensive
computations.
The compute plane¶
Algorithm servers own "what algorithm runs." Each one wraps a specialized algorithm, often a trained deep learning model, e.g., Cellpose for pixel-perfect cell segmentation, behind a standard protocol. Biopb ships these as containers, so they can be run on dedicated machines, e.g., one with a GPU. Because data and compute are separate, an algorithm server can pull its input pixels straight from the data plane and write results back, so even big-image analyses never have to round-trip through your laptop.
See Algorithm servers to run one.