https://github.com/esgf/esgf-vocab
CLI + library to deal with WCRP CVs
https://github.com/esgf/esgf-vocab
Last synced: 7 days ago
JSON representation
CLI + library to deal with WCRP CVs
- Host: GitHub
- URL: https://github.com/esgf/esgf-vocab
- Owner: ESGF
- License: other
- Created: 2024-11-12T11:00:50.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2026-05-28T10:06:55.000Z (11 days ago)
- Last Synced: 2026-05-28T11:22:52.116Z (11 days ago)
- Language: Python
- Homepage: https://esgf.github.io/esgf-vocab/
- Size: 9.86 MB
- Stars: 6
- Watchers: 6
- Forks: 8
- Open Issues: 12
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# ESGVOC Library
ESGVOC is a Python library designed to simplify interaction with controlled vocabularies (CVs) used in WCRP climate data projects. It supports querying, caching, and validating terms across various CV repositories like the [universe](https://github.com/WCRP-CMIP/WCRP-universe/tree/esgvoc) and project-specific repositories (e.g., [CMIP6Plus](https://github.com/WCRP-CMIP/CMIP6Plus_CVs/tree/esgvoc), [CMIP6](https://github.com/WCRP-CMIP/CMIP6_CVs/tree/esgvoc), etc.).
Full documentation is available at [https://esgf.github.io/esgf-vocab/](https://esgf.github.io/esgf-vocab/).
---
## Features
- **Query controlled vocabularies**:
- Retrieve terms, collections, or descriptors.
- Perform cross-validation and search operations.
- Supports case-sensitive, wildcard, and approximate matching.
- **Caching**:
- Download CVs to a local database for offline use.
- Keep the local cache up-to-date.
- Note: at present, this is a design choice.
You can't use esgvoc without this cache,
it always downloads the CVs to a local database first
- **Validation**:
- Validate strings against CV terms and templates.
- **Apps**:
- Ease some treatment using the CV.
## Installation
ESGVOC is available on PyPI. Install it with pip:
```bash
pip install esgvoc
```
After installing ESGVOC,
use this command to install the latest CVs
(or update them if you have already installed ESGVOC).
```bash
esgvoc install
```
### For developers
* with pip
```bash
pip install -e .
pip install pre-commit
pre-commit install
```
* with uv
```bash
uv sync
uv run pre-commit install
```