def model_registry() -> Generator[type[ModelRegistry], None, None]:
    """Create a model registry.

    Yields:
        A fresh model registry.
    """
    yield ModelRegistry
    ModelRegistry._metadata = None
Create a model registry.

    Yields:
        A fresh model registry.
    
tests/units/conftest.py