# generated by datamodel-codegen:
#   filename:  default_factory_nested_model_with_dict.json
#   timestamp: 2019-07-26T00:00:00+00:00

from __future__ import annotations

from pydantic import BaseModel, Field


class Address(BaseModel):
    street: str | None = None
    city: str | None = None


class Contact(BaseModel):
    email: str | None = None
    phone: str | None = None


class Model(BaseModel):
    name: str
    address: Address | None = Field(default_factory=Address)
    metadata: dict[str, str] | Contact | None = Field(default_factory=Contact)
