penzai.core.context.enable_interactive_context() None[source]#

Enables the global interactive context stack.

By default, ContextualValues can only be changed in a scoped with block. This function turns on interactive mode, enabling those contexts to be set persistently in an interactive setting. To turn it back off, see disable_interactive_context.

Interactive mode is itself a thin wrapper around a contextlib ExitStack.