_fake_runnable() — langchain Function Reference
Architecture documentation for the _fake_runnable() function in test_structured.py from the langchain codebase.
Entity Profile
Dependency Diagram
graph TD 9784d7ba_cd2b_433f_04c1_74fedece2596["_fake_runnable()"] 3513030b_4904_ecfd_7a0d_cc92be4dda69["test_structured.py"] 9784d7ba_cd2b_433f_04c1_74fedece2596 -->|defined in| 3513030b_4904_ecfd_7a0d_cc92be4dda69 style 9784d7ba_cd2b_433f_04c1_74fedece2596 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
libs/core/tests/unit_tests/prompts/test_structured.py lines 18–24
def _fake_runnable(
_: Any, *, schema: dict[str, Any] | type[BaseModel], value: Any = 42, **_kwargs: Any
) -> BaseModel | dict[str, Any]:
if isclass(schema) and issubclass(schema, BaseModel):
return schema(name="yo", value=value)
params = cast("dict[str, Any]", schema)["parameters"]
return {k: 1 if k != "value" else value for k, v in params.items()}
Domain
Subdomains
Source
Frequently Asked Questions
What does _fake_runnable() do?
_fake_runnable() is a function in the langchain codebase, defined in libs/core/tests/unit_tests/prompts/test_structured.py.
Where is _fake_runnable() defined?
_fake_runnable() is defined in libs/core/tests/unit_tests/prompts/test_structured.py at line 18.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free