Drop the notebooks/ directory and the notebooks pyproject extra from metpo.
Why
The notebooks pyproject extra pulls in jupyter, notebook, jupyterlab, matplotlib, numpy, python-levenshtein, chromadb, and openai. This is the main source of Dependabot churn. The 2026-05-18 batch alone was 13 high and 7 medium alerts, all from this dependency tree.
No code under metpo/ imports any Jupyter or IPython modules. Nothing outside the notebooks themselves needs the Jupyter stack.
What is in notebooks/
Two notebooks, plus an .ipynb_checkpoints/ autosave folder and an outdated README.md. The README lists four notebooks; two of those (ols_search_example.ipynb and explore_embeddings.ipynb) have already been deleted, so the README is wrong.
query_chromadb.ipynb (12 cells, ChromaDB-dependent)
Demonstration of semantic similarity search using ChromaDB. It opens the local ChromaDB at data/chromadb/chroma_ols20_nonols4/, embeds a user query using OpenAI's embedding API, and returns the nearest-neighbor ontology terms. The stored collection covers roughly 20 OLS ontologies plus the 4 BioPortal-only ones (D3O, OMP, MPO, n4l_merged). Purely a demo of the pipeline that #364 is in the process of replacing.
assess_ontology_by_api_search.ipynb (49 cells, not ChromaDB-dependent)
Baseline ontology-popularity analysis. It reads 50 METPO term labels (a 20% sample) from data/metpo_terms/metpo_sample_labels.tsv, calls BioPortal's REST search API for each label, and tallies which external ontologies return hits. The result answers "which ontologies most often match METPO labels?" and is useful input for #364. Does not use ChromaDB or any Jupyter-specific machinery beyond the notebook wrapper.
Proposed steps
- Delete
query_chromadb.ipynb. Recoverable from git history if ever needed.
- Convert
assess_ontology_by_api_search.ipynb into a Click command-line script under metpo/scripts/, per the metpo CLAUDE.md script standards. The logic is straightforward: read a TSV of labels, loop over them, call the BioPortal search API, aggregate hits per ontology, write output TSV.
- Delete the
notebooks/ directory and the .ipynb_checkpoints/ autosave folder.
- Remove the
notebooks extra from pyproject.toml; re-run uv lock to drop the Jupyter, Notebook, and JupyterLab dependency tree.
- Remove the
install-notebooks target from the Makefile.
ChromaDB direction (context for #364)
The broader goal is to remove ChromaDB as a metpo dependency. The replacement plan tracked in #364 is a hybrid: OLS4's /api/v2/classes/llm_search endpoint for the roughly 270 OLS-hosted ontologies, and linkml-store with the LLMIndexer for the 4 BioPortal-only ontologies (D3O, OMP, MPO, n4l_merged). Any ChromaDB usage that survives the #364 cleanup must be clearly scoped to only the highest-value BioPortal-only ontologies. Broad ChromaDB indexing is not the long-term path.
Impact
Related
🤖 Generated with Claude Code
Drop the
notebooks/directory and thenotebookspyproject extra from metpo.Why
The
notebookspyproject extra pulls injupyter,notebook,jupyterlab,matplotlib,numpy,python-levenshtein,chromadb, andopenai. This is the main source of Dependabot churn. The 2026-05-18 batch alone was 13 high and 7 medium alerts, all from this dependency tree.No code under
metpo/imports any Jupyter or IPython modules. Nothing outside the notebooks themselves needs the Jupyter stack.What is in
notebooks/Two notebooks, plus an
.ipynb_checkpoints/autosave folder and an outdatedREADME.md. The README lists four notebooks; two of those (ols_search_example.ipynbandexplore_embeddings.ipynb) have already been deleted, so the README is wrong.query_chromadb.ipynb(12 cells, ChromaDB-dependent)Demonstration of semantic similarity search using ChromaDB. It opens the local ChromaDB at
data/chromadb/chroma_ols20_nonols4/, embeds a user query using OpenAI's embedding API, and returns the nearest-neighbor ontology terms. The stored collection covers roughly 20 OLS ontologies plus the 4 BioPortal-only ones (D3O, OMP, MPO, n4l_merged). Purely a demo of the pipeline that #364 is in the process of replacing.assess_ontology_by_api_search.ipynb(49 cells, not ChromaDB-dependent)Baseline ontology-popularity analysis. It reads 50 METPO term labels (a 20% sample) from
data/metpo_terms/metpo_sample_labels.tsv, calls BioPortal's REST search API for each label, and tallies which external ontologies return hits. The result answers "which ontologies most often match METPO labels?" and is useful input for #364. Does not use ChromaDB or any Jupyter-specific machinery beyond the notebook wrapper.Proposed steps
query_chromadb.ipynb. Recoverable from git history if ever needed.assess_ontology_by_api_search.ipynbinto a Click command-line script undermetpo/scripts/, per the metpo CLAUDE.md script standards. The logic is straightforward: read a TSV of labels, loop over them, call the BioPortal search API, aggregate hits per ontology, write output TSV.notebooks/directory and the.ipynb_checkpoints/autosave folder.notebooksextra frompyproject.toml; re-runuv lockto drop the Jupyter, Notebook, and JupyterLab dependency tree.install-notebookstarget from theMakefile.ChromaDB direction (context for #364)
The broader goal is to remove ChromaDB as a metpo dependency. The replacement plan tracked in #364 is a hybrid: OLS4's
/api/v2/classes/llm_searchendpoint for the roughly 270 OLS-hosted ontologies, andlinkml-storewith the LLMIndexer for the 4 BioPortal-only ontologies (D3O, OMP, MPO, n4l_merged). Any ChromaDB usage that survives the #364 cleanup must be clearly scoped to only the highest-value BioPortal-only ontologies. Broad ChromaDB indexing is not the long-term path.Impact
uv.lock. Most of the current Dependabot batch becomes impossible in future cycles.openaiandchromadbwould also become droppable from theliteraturepyproject extra. That follow-up work is downstream of this issue.Related
query_chromadb.ipynbdeletion aligns with that direction and can also proceed independently.🤖 Generated with Claude Code