Skip to content

The agent engineering platform.

docs: fix typos in libs/langchain/langchain_classic/chains/summarize/chain.py (#33877)

Lê Nam Khánhc2324b8f3e53
diff --git a/libs/langchain/langchain_classic/chains/summarize/chain.py b/libs/langchain/langchain_classic/chains/summarize/chain.py
index 163cc8eb1e..08f82329be 100644
--- a/libs/langchain/langchain_classic/chains/summarize/chain.py
+++ b/libs/langchain/langchain_classic/chains/summarize/chain.py
@@ -103,7 +103,7 @@ def _load_map_reduce_chain(
Args:
llm: Language Model to use for map and reduce steps.
- map_prompt: Prompt used to summarize each documnet in the map step.
+ map_prompt: Prompt used to summarize each document in the map step.
combine_prompt: Prompt used to combine summaries in the reduce step.
combine_document_variable_name: Variable name in the `combine_prompt` where
the mapped summaries are inserted.
@@ -115,7 +115,7 @@ def _load_map_reduce_chain(
which uses the same model as the map step.
collapse_llm: Optional separate LLM for the collapse step.
which uses the same model as the map step.
- verbose: Whether to log progess and intermediate steps.
+ verbose: Whether to log progress and intermediate steps.
token_max: Token threshold that triggers the collapse step during reduction.
callbacks: Optional callbacks for logging and tracing.
collapse_max_retries: Maximum retries for the collapse step if it fails.