Using Biomni Tools in BioCortex
BioCortex uses Biomni’s 200+ domain tools (genomics, single-cell, pharmacology, etc.) so the model (Planner + Executor) can call Biomni functions inside the analysis sandbox. Two ways: embedded (install and use) or custom path.Default: embedded tools (Plan A)
If Biomni is present atvendor/Biomni/biomni (e.g. added as a git submodule), BioCortex loads it automatically. No configuration needed.
- After cloning BioCortex, run:
git submodule update --init --recursiveto fetch the embedded Biomni tools. - See
vendor/README.mdin the repo for how to add the Biomni submodule.
Optional: custom Biomni path
To use a different Biomni clone (e.g. your own fork or another path on the server):- Open Settings → Biomni path.
- Enter the absolute or relative path to the Biomni
biomnidirectory (e.g./path/to/Biomni/biomni). - Save. This overrides the embedded path and is sent with every new analysis.
vendor/Biomni/biomni exists, the embedded path is used. If neither exists, analysis runs with BioCortex built-in domains only (ecology, neuroscience, plant, marine, browser, etc.).
How it works
- Tool descriptions — Biomni’s
tool_description/*.pyare imported into BioCortex’s tool registry and used by the hybrid retriever (vector + KG + LLM) so the Planner picks the right tools. - Tool bridge — Biomni’s actual
tool/*.pyfunctions are exposed to the Executor via a preamble and docs. The Executor generates code that imports and calls them, e.g.from biomni.tool.cell_biology import annotate_celltype_scRNA. - Know-how — Biomni’s
know_how/*.mdbest-practice docs are loaded and injected into the Planner context.
Run analysis
In Chat, describe your task in natural language (e.g. “Analyze single-cell RNA-seq data from pbmc.h5ad with clustering and cell type annotation”). The Planner will select Biomni tools (and other BioCortex tools) via the hybrid retriever; the Executor will generate and run code that calls Biomni functions. No change to prompts is required.Verify Biomni is loaded
- Status API:
GET /api/v1/status— when an agent with Biomni is loaded, the response can includebiomni_bridge(e.g. number of public functions, domains). - Resources page: Biomni tools appear in the tools list with domain labels (e.g. genomics, cell_biology).
Summary
| Case | Action |
|---|---|
| Embedded | Ensure vendor/Biomni/biomni exists (git submodule update --init --recursive). No Settings needed. |
| Custom path | Set Biomni path in Settings (or in analysis config when using the API). |
| No Biomni | Leave path empty and do not init the submodule; analysis uses built-in domains only. |