mirror of
https://github.com/hwchase17/langchain.git
synced 2026-02-21 06:33:41 +00:00
add exception to core
This commit is contained in:
@@ -65,6 +65,14 @@ class OutputParserException(ValueError, LangChainException): # noqa: N818
|
||||
self.send_to_llm = send_to_llm
|
||||
|
||||
|
||||
class ContextOverflowError(LangChainException):
|
||||
"""Exception raised when input exceeds the model's context limit.
|
||||
|
||||
This exception is raised by chat models when the input tokens exceed
|
||||
the maximum context window supported by the model.
|
||||
"""
|
||||
|
||||
|
||||
class ErrorCode(Enum):
|
||||
"""Error codes."""
|
||||
|
||||
|
||||
Reference in New Issue
Block a user