test_loads_llmchain_with_non_serializable_arg() — langchain Function Reference
Architecture documentation for the test_loads_llmchain_with_non_serializable_arg() function in test_load.py from the langchain codebase.
Entity Profile
Dependency Diagram
graph TD 3cfd827f_8812_0e35_1454_0d98bceab055["test_loads_llmchain_with_non_serializable_arg()"] 0b08876e_5a62_23f2_8ed5_ec59f46366a7["test_load.py"] 3cfd827f_8812_0e35_1454_0d98bceab055 -->|defined in| 0b08876e_5a62_23f2_8ed5_ec59f46366a7 style 3cfd827f_8812_0e35_1454_0d98bceab055 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
libs/langchain/tests/unit_tests/load/test_load.py lines 90–101
def test_loads_llmchain_with_non_serializable_arg() -> None:
llm = CommunityOpenAI(
model="davinci",
temperature=0.5,
openai_api_key="hello",
model_kwargs={"a": NotSerializable},
)
prompt = PromptTemplate.from_template("hello {name}!")
chain = LLMChain(llm=llm, prompt=prompt)
chain_string = dumps(chain, pretty=True)
with pytest.raises(NotImplementedError):
loads(chain_string, secrets_map={"OPENAI_API_KEY": "hello"})
Domain
Subdomains
Source
Frequently Asked Questions
What does test_loads_llmchain_with_non_serializable_arg() do?
test_loads_llmchain_with_non_serializable_arg() is a function in the langchain codebase, defined in libs/langchain/tests/unit_tests/load/test_load.py.
Where is test_loads_llmchain_with_non_serializable_arg() defined?
test_loads_llmchain_with_non_serializable_arg() is defined in libs/langchain/tests/unit_tests/load/test_load.py at line 90.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free