_aevaluate_strings() — langchain Function Reference
Architecture documentation for the _aevaluate_strings() function in schema.py from the langchain codebase.
Entity Profile
Dependency Diagram
graph TD 18f54728_8c17_5647_a4f6_df52b9f1d794["_aevaluate_strings()"] 3bfa222e_74bd_6c80_db4a_a3d3a09b5e7b["StringEvaluator"] 18f54728_8c17_5647_a4f6_df52b9f1d794 -->|defined in| 3bfa222e_74bd_6c80_db4a_a3d3a09b5e7b 7005c138_072e_7038_918d_35c947f2e4ac["aevaluate_strings()"] 7005c138_072e_7038_918d_35c947f2e4ac -->|calls| 18f54728_8c17_5647_a4f6_df52b9f1d794 style 18f54728_8c17_5647_a4f6_df52b9f1d794 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
libs/langchain/langchain_classic/evaluation/schema.py lines 178–208
async def _aevaluate_strings(
self,
*,
prediction: str | Any,
reference: str | Any | None = None,
input: str | Any | None = None, # noqa: A002
**kwargs: Any,
) -> dict:
"""Asynchronously evaluate Chain or LLM output, based on optional input and label.
Args:
prediction: The LLM or chain prediction to evaluate.
reference: The reference label to evaluate against.
input: The input to consider during evaluation.
**kwargs: Additional keyword arguments, including callbacks, tags, etc.
Returns:
The evaluation results containing the score or value.
It is recommended that the dictionary contain the following keys:
- score: the score of the evaluation, if applicable.
- value: the string value of the evaluation, if applicable.
- reasoning: the reasoning for the evaluation, if applicable.
""" # noqa: E501
return await run_in_executor(
None,
self._evaluate_strings,
prediction=prediction,
reference=reference,
input=input,
**kwargs,
)
Domain
Subdomains
Called By
Source
Frequently Asked Questions
What does _aevaluate_strings() do?
_aevaluate_strings() is a function in the langchain codebase, defined in libs/langchain/langchain_classic/evaluation/schema.py.
Where is _aevaluate_strings() defined?
_aevaluate_strings() is defined in libs/langchain/langchain_classic/evaluation/schema.py at line 178.
What calls _aevaluate_strings()?
_aevaluate_strings() is called by 1 function(s): aevaluate_strings.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free