default_init_validator() — langchain Function Reference
Architecture documentation for the default_init_validator() function in load.py from the langchain codebase.
Entity Profile
Dependency Diagram
graph TD 1910dab6_e109_80ec_5bdc_6188e60ebf46["default_init_validator()"] 05e0e20a_4425_e962_37a4_c6c6f08a700d["load.py"] 1910dab6_e109_80ec_5bdc_6188e60ebf46 -->|defined in| 05e0e20a_4425_e962_37a4_c6c6f08a700d 00eb90c5_a3e3_3bb4_5533_671836ff8211["load()"] 1910dab6_e109_80ec_5bdc_6188e60ebf46 -->|calls| 00eb90c5_a3e3_3bb4_5533_671836ff8211 04c46210_2f06_371b_9374_109532581bd7["loads()"] 1910dab6_e109_80ec_5bdc_6188e60ebf46 -->|calls| 04c46210_2f06_371b_9374_109532581bd7 87ab25e9_a59e_a24e_6a50_7fcddd95becd["_block_jinja2_templates()"] 1910dab6_e109_80ec_5bdc_6188e60ebf46 -->|calls| 87ab25e9_a59e_a24e_6a50_7fcddd95becd style 1910dab6_e109_80ec_5bdc_6188e60ebf46 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
libs/core/langchain_core/load/load.py lines 183–199
def default_init_validator(
class_path: tuple[str, ...],
kwargs: dict[str, Any],
) -> None:
"""Default init validator that blocks jinja2 templates.
This is the default validator used by `load()` and `loads()` when no custom
validator is provided.
Args:
class_path: The class path tuple being deserialized.
kwargs: The kwargs dict for the class constructor.
Raises:
ValueError: If template_format is `'jinja2'`.
"""
_block_jinja2_templates(class_path, kwargs)
Domain
Subdomains
Defined In
Source
Frequently Asked Questions
What does default_init_validator() do?
default_init_validator() is a function in the langchain codebase, defined in libs/core/langchain_core/load/load.py.
Where is default_init_validator() defined?
default_init_validator() is defined in libs/core/langchain_core/load/load.py at line 183.
What does default_init_validator() call?
default_init_validator() calls 3 function(s): _block_jinja2_templates, load, loads.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free