code: def output_defaults(dest: Path, defaults: dict[str, Any]) -> None:
      os.makedirs(dest.parent, exist_ok=True)
  
      output = json5.dumps(defaults, sort_keys=False, indent=2)
      with open(dest, "w", encoding="utf-8") as f:
          f.write(output)
          f.write("\n")
  
      print(f"Wrote {dest} with {len(defaults)} models")
  
file_path: bokeh/tests/support/defaults.py
imports: from __future__ import annotations
  import logging
  import os
  import warnings
  from pathlib import Path
  from typing import Any
  import json5
  from bokeh.core.has_props import HasProps
  from bokeh.core.property.descriptors import PropertyDescriptor
  from bokeh.core.property.singletons import Undefined
  from bokeh.core.serialization import AnyRep, ObjectRep, Serializer, SymbolRep
  from bokeh.model import Model
  from bokeh.util.warnings import BokehDeprecationWarning
label_desc: Use image node_id 2 for calling a global function with example usage: output_defaults(dest, defaults) without return types