Common Metadata Framework (CMF)
Common Metadata Framework (CMF) is a metadata tracking and versioning system for ML pipelines. It tracks code, data, and pipeline metrics—offering Git-like metadata management across distributed environments.
🚀 Features
- ✅ Track artifacts (datasets, models, metrics) using content-based hashes
- ✅ Automatically logs code versions (Git) and data versions (DVC)
- ✅ Push/pull metadata via CLI across distributed sites
- ✅ REST API for direct server interaction
- ✅ Implicit & explicit tracking of pipeline execution
- ✅ Fine-grained or coarse-grained metric logging
🏛 Quick Start
Get started with CMF in minutes using our example ML pipeline:
📖 Try the Getting Started Example
This example demonstrates:
- Initializing a CMF project
- Tracking an ML pipeline with multiple stages (parse → featurize → train → test)
- Versioning datasets and models
- Pushing artifacts and metadata
- Querying tracked metadata
📦 Installation
Requirements
- Linux/Ubuntu/Debian
- Python: Version 3.9 to 3.11 (3.10 recommended)
- Git (latest)
Virtual Environment
Conda
conda create -n cmf python=3.10
conda activate cmf
Virtualenv
virtualenv --python=3.10 .cmf
source .cmf/bin/activate
Install CMF
Latest from GitHub
pip install git+https://github.com/HewlettPackard/cmf
Stable from PyPI
pip install cmflib
Server Setup
📖 Follow the CMF Server Installation Guide
📘 Documentation
🧠 How It Works
CMF tracks pipeline stages, inputs/outputs, metrics, and code. It supports decentralized execution across datacenters, edge, and cloud.
- Artifacts are versioned using DVC (
.dvcfiles). - Code is tracked with Git.
- Metadata is logged to relational DB (e.g., SQLite, PostgreSQL)
- Sync metadata with
cmf metadata pushandcmf metadata pull.
🏛 Architecture
CMF is composed of:
- cmflib - Metadata library provides API to log/query metadata
- CMF Client – CLI to sync metadata with server, push/pull artifacts to the user-specified repo, push/pull code from Git
- CMF Server – REST API for metadata merge
- Central Repositories – Git (code), DVC (artifacts), CMF (metadata)
🔧 Sample Usage
from cmflib.cmf import Cmf
from ml_metadata.proto import metadata_store_pb2 as mlpb
metawriter = Cmf(filepath="mlmd", pipeline_name="test_pipeline")
context: mlpb.Context = metawriter.create_context(
pipeline_stage="prepare",
custom_properties={"user-metadata1": "metadata_value"}
)
execution: mlpb.Execution = metawriter.create_execution(
execution_type="Prepare",
custom_properties={"split": split, "seed": seed}
)
artifact: mlpb.Artifact = metawriter.log_dataset(
"artifacts/data.xml.gz", "input",
custom_properties={"user-metadata1": "metadata_value"}
)
cmf # CLI to manage metadata and artifacts
cmf init # Initialize artifact repository
cmf init show # Show current CMF config
cmf metadata push # Push metadata to server
cmf metadata pull # Pull metadata from server
➡️ For the complete list of commands, please refer to the Command Reference
✅ Benefits
- Full ML pipeline observability
- Unified metadata, artifact, and code tracking
- Scalable metadata syncing
- Team collaboration on metadata
🎤 Talks & Publications
🌐 Related Projects
🤝 Community
- 💬 Join CMF on Slack
- 📧 Contact: annmary.roy@hpe.com
📄 License
Licensed under the Apache 2.0 License
© Hewlett Packard Enterprise. Built for reproducibility in ML.
Metadata
Release files for cmflib 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| cmflib-0.1.1.tar.gz | 174.9 kB | Without provenance | Details for cmflib-0.1.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| cmflib-0.1.1-py3-none-any.whl | Python 3 | none | any | Details for cmflib-0.1.1-py3-none-any.whl |
Total release size: 408.8 kB
Release files / cmflib-0.1.1.tar.gz
| Download URL | cmflib-0.1.1.tar.gz |
|---|---|
| Size | 174.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
5678caad989e085428630c64382f3d335c4e5ea4b334467714bd122686991180
|
|
BLAKE2b-256 checksum How to use checksums |
fb3348f1871cea55cb8556ab96f60aae3718f20fd88a53a235493f2ff7891ff7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.11.12
|
Release files / cmflib-0.1.1-py3-none-any.whl
| Download URL | cmflib-0.1.1-py3-none-any.whl |
|---|---|
| Size | 233.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
5a0faf2d5d674c05a0aba6daeafb007fce876727086c7bbc99f1296a1c0212ce
|
|
BLAKE2b-256 checksum How to use checksums |
70d9647b7f876653215e1ef09d8db157296696ca3bf216ba07edd5d3866a36aa
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.11.12
|
Security for cmflib 0.1.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.