class_docstr: Provides domain during training and inference time.
docstr: Persists domain to model storage.
docstr_tok: ["Persists","domain","to","model","storage","."]
code: def _persist(self, domain: Domain) -> None:
      """Persists domain to model storage."""
      with self._model_storage.write_to(
          self._resource
      ) as resource_directory:
          domain.persist(resource_directory / "domain.yml")
  
file_path: rasa/rasa/graph_components/providers/domain_provider.py
imports: from __future__ import annotations
  from typing import Dict, Text, Any, Optional
  from rasa.engine.graph import GraphComponent, ExecutionContext
  from rasa.engine.storage.resource import Resource
  from rasa.engine.storage.storage import ModelStorage
  from rasa.shared.core.domain import Domain
  from rasa.shared.exceptions import InvalidConfigException
  from rasa.shared.importers.importer import TrainingDataImporter
label_desc: Use image node_id 4 for calling the DomainProvider obj's underlying member method code with example usage: obj._persist(domain) without return types