code: def model_context(sample: Sample) -> frozen_context:
      """Get a context stack of the current model sample (i.e., architecture dict).
  
      This should be used together with :func:`current_model`.
  
      :func:`model_context` is read-only, and should not be used to modify the architecture dict.
      """
      return frozen_context({**sample, "__arch__": True})
  
imports: import copy
  from typing import Optional
  from nni.mutable import frozen_context, Sample
label_desc: Use image node_id 2 for calling a global function with example usage: model_context(sample) and returns: frozen_context