An R Toolkit for the Micheli Guide to Fungal Conservation Policy Gap Assessment
Overview
MicheliR is a Shiny‑based R package that automates the keyword‑search and evaluation workflow of the Micheli Guide to Fungal Conservation (CBD Evaluation Form).
It performs deterministic keyword counting (Fungi, Animals, Plants) with full audit logs, and optionally uses the DeepSeek API to:
- Filter out false positives (e.g., “fung” in “fungicide”, industrial “plant”)
- Answer the 5 key questions of the Micheli Guide with justifications
- Compute a score (0–5) and rating (Adequate → Totally Deficient)
The tool is designed to assist researchers, policy makers, and conservation practitioners in assessing National Biodiversity Strategy and Action Plans (NBSAPs) and CBD National Reports for fungal conservation policy gaps.
Features
- Language support – English or French keyword lists (root‑based matching, singular+plural).
-
Flexible document input – upload
.txt,.pdf,.docx, or paste plain text. - On‑demand keyword searches – buttons for Fungi, Animals, Plants, or Run All.
- Live summary statistics – total counts and percentages for each kingdom.
- Detailed audit logs – each match includes: keyword group, matched text, location (page/line/paragraph), and 80‑character context with yellow highlighting.
- Industrial‑plant exclusion – automatically excludes “plant” when used in a factory/sewage/industrial context.
- AI evaluation (DeepSeek) – filters false positives and applies the full Micheli Guide assessment.
- Export results – download a ZIP archive with CSV files for frequency tables and audit logs.
- No AI hallucination in counting – keyword search is 100% deterministic and reproducible.
Installation
You can install the development version from GitHub:
# Install remotes if you don't have it
install.packages("remotes")
# Install MicheliR
remotes::install_github("DATAVERSE01/MicheliR")Required Dependencies
All required packages will be installed automatically when you install MicheliR. For reference:
| Package | Use |
|---|---|
shiny |
Interactive web application framework |
shinythemes |
Professional theming for the app |
stringr |
String manipulation and pattern matching |
pdftools |
PDF text extraction |
readtext |
DOCX and other text file reading |
dplyr, tidyr
|
Data wrangling and manipulation |
DT |
Interactive, searchable data tables |
plotly |
Pie chart visualisation |
httr, jsonlite
|
DeepSeek API calls (JSON handling) |
magrittr |
Pipe operator %>%
|
Workflow
1. Load a Document
- Upload a
.txt,.pdf, or.docxfile using the “Choose a file” button, or - Paste the document content directly into the text area.
2. Enter Metadata
- Document Title – e.g., National Biodiversity Strategy and Action Plan
- Country – e.g., Benin
- Document Date – the publication or submission date
- Language – select English or French (this determines which keyword patterns are used)
3. Run Keyword Searches
- Click 🔍 Fungi, 🔍 Animals, or 🔍 Plants to search individually.
- Click ▶ Run All to search all three kingdoms at once.
After each search, you’ll see: - Pie chart – visual breakdown of word frequencies by kingdom. - Frequency table – counts per keyword group (e.g., fung, lichen, mushroom, etc.). - Audit log – each match with: - Group (keyword category) - Matched word (exact text found) - Location (page, line, or paragraph number) - Highlighted context – the matched word is shown in yellow for easy scanning.
4. AI Evaluation (Optional)
- Enter your DeepSeek API key in the sidebar (or set the
DEEPSEEK_API_KEYenvironment variable). - Click 🧠 Run AI Evaluation.
- The AI will:
- Filter out false positives from the audit logs.
- Answer the 5 key questions of the Micheli Guide with justifications.
- Compute a score (0–5) and rating (Adequate → Totally Deficient).
- Results appear in the “AI Evaluation” tab, along with filtered audit logs (only the relevant, non‑false‑positive matches).
5. Save Results
- Click 💾 Save Results to download a ZIP file containing:
-
Fungus_freq.csv,Animal_freq.csv,Plant_freq.csv– frequency tables -
Fungus_audit.csv,Animal_audit.csv,Plant_audit.csv– audit logs (raw context) -
Summary.csv– overall counts and percentages -
Metadata.csv– document title, country, date, language, evaluation date
-
API Key for AI Evaluation
If you want to use the AI evaluation feature, you need a DeepSeek API key:
- Sign up at platform.deepseek.com
- Generate an API key
- Enter the key in the app’s sidebar when prompted
The AI evaluation is optional – you can still perform deterministic keyword searches without an API key.
Example
# Install and load
library(MicheliR)
# Launch the app
run_app()
# The app will open in your browser.
# Upload a document, run searches, and optionally run AI evaluation.Authors
- Apollon D.M.T. HEGBE – Creator & Maintainer – [Laboratory of Tropical Mycology and Plant‑Fungus‑Soil Interaction / International Society for Fungal Conservation]
- Nourou S. Yorou – Contributor – [Laboratory of Tropical Mycology and Plant‑Fungus‑Soil Interaction]
- David W. Minter – Contributor – [International Society for Fungal Conservation]
Citation
If you use MicheliR in your research, please cite:
@Manual{MicheliR,
title = {MicheliR: An R Toolkit for the Micheli Guide to Fungal Conservation Policy Gap Assessment},
author = {Apollon D.M.T. HEGBE and Nourou S. Yorou and David W. Minter},
year = {2026},
note = {R package version 1.0.0},
url = {https://github.com/DATAVERSE01/MicheliR}
}Acknowledgements
This tool was developed to support the evaluation of National Biodiversity Strategy and Action Plans (NBSAPs) and CBD National Reports under the Micheli Guide framework. We thank the International Society for Fungal Conservation for their support.
Feedback and Contributions
Issues, feature requests, and contributions are welcome!
- Bug reports / feature requests: Please use the GitHub issue tracker
- Contributions: Fork the repository, make your changes, and submit a pull request.
- Questions: Open an issue or contact the maintainer directly.
How to Contribute
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
We welcome contributions of all kinds – code, documentation, bug reports, and feature suggestions.
References
The Micheli Guide to Fungal Conservation. Available at: http://www.fungal-conservation.org/
Abdel-Azeem, A., & Minter, D. W. (2011). The Rio Convention and Fungi: A review of recent national biodiversity action plans and reports. Fungal Conservation, (1), 29–32. Available at: fungal-conservation.org
Minter, D. W. (2013a). A Future for Fungi: The Orphans of Rio. International Society for Fungal Conservation, UK. Available at: http://www.fungal-conservation.org/blogs/orphans-of-rio.pdf
Minter, D. W. (2013b). Fungal Conservation and Sustainability in Europe. In M. Letizia Gargano, G. I. Zervakis, & G. Venturella (Eds.), Pleurotus nebrodensis: A Very Special Mushroom (pp. 3–30). BENTHAM SCIENCE PUBLISHERS. https://doi.org/10.2174/9781608058006113010004
Minter, D. W. (2014). Fungal conservation and the CBD: focus on Belgium. A Micheli Guide Review. Fungal Conservation, (4). Available at: https://www.academia.edu/download/68114039/Fungi_and_the_Action_Plan_for_the_Conser20210715-11887-1x5p8ga.pdf#page=59