name: gnn-model-registry description: GNN model versioning and registry management. Use when registering parsed models, tracking model versions, querying model metadata (author, license, version), or managing the model catalog.
GNN Model Registry (Step 4)
Purpose
Manages a registry of parsed GNN models with versioning, metadata extraction, and catalog management. Tracks model lineage including author, license, and version information.
Key Commands
# Run model registry step
python src/4_model_registry.py --target-dir input/gnn_files --output-dir output --verbose
# As part of pipeline
python src/main.py --only-steps 4 --verbose
API
from model_registry import ModelRegistry, process_model_registry
# Use the registry class
registry = ModelRegistry()
# Process model registry step (used by pipeline)
result = process_model_registry(target_dir, output_dir, verbose=True)
Key Exports
ModelRegistry— class managing model catalog, versioning, and metadataprocess_model_registry— main processing function for pipeline integration
Metadata Extraction
The registry automatically extracts:
- Author and license from file headers
- Version information from model definitions
- Dimensions and types from StateSpaceBlock
- Framework compatibility from annotations
Output
- Model catalog in
output/4_model_registry_output/ - JSON registry index
- Version history tracking
MCP Tools
This module registers tools with the GNN MCP server (see mcp.py):
model_registry.get_modelmodel_registry.list_modelsmodel_registry.register_modelmodel_registry.search_models