test_finish() — langchain Function Reference
Architecture documentation for the test_finish() function in test_self_ask.py from the langchain codebase.
Entity Profile
Dependency Diagram
graph TD c450b408_23e7_d8fe_13bc_caa9886f8273["test_finish()"] fd5e49f7_25e9_e2c1_8142_fdd27d067ba1["test_self_ask.py"] c450b408_23e7_d8fe_13bc_caa9886f8273 -->|defined in| fd5e49f7_25e9_e2c1_8142_fdd27d067ba1 style c450b408_23e7_d8fe_13bc_caa9886f8273 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
libs/langchain/tests/unit_tests/agents/output_parsers/test_self_ask.py lines 41–47
def test_finish() -> None:
"""Test standard finish."""
parser = SelfAskOutputParser()
_input = "So the final answer is: 4"
output = parser.invoke(_input)
expected_output = AgentFinish(return_values={"output": "4"}, log=_input)
assert output == expected_output
Domain
Subdomains
Source
Frequently Asked Questions
What does test_finish() do?
test_finish() is a function in the langchain codebase, defined in libs/langchain/tests/unit_tests/agents/output_parsers/test_self_ask.py.
Where is test_finish() defined?
test_finish() is defined in libs/langchain/tests/unit_tests/agents/output_parsers/test_self_ask.py at line 41.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free