rigging.error
We try to avoid creating custom exceptions unless they are necessary.
We use the built-in and pydantic exceptions as much as possible.
CompletionExhaustedMaxRoundsError(max_rounds: int, completion: str)
#
Bases: ExhaustedMaxRoundsError
Raised when the maximum number of rounds is exceeded while generating completions.
Source code in .deps/rigging/rigging/error.py
completion = completion
instance-attribute
#
The completion which was being generated when the exception occured.
ExhaustedMaxRoundsError(max_rounds: int)
#
Bases: Exception
Raised when the maximum number of rounds is exceeded while generating.
Source code in .deps/rigging/rigging/error.py
max_rounds = max_rounds
instance-attribute
#
The number of rounds which was exceeded.
InvalidModelSpecifiedError(model: str)
#
MessagesExhaustedMaxRoundsError(max_rounds: int, messages: list[Message])
#
Bases: ExhaustedMaxRoundsError
Raised when the maximum number of rounds is exceeded while generating messages.
Source code in .deps/rigging/rigging/error.py
messages = messages
instance-attribute
#
The messages which were being generated when the exception occured.
MissingModelError(content: str)
#
ProcessingError(content: str)
#
UnknownToolError(tool_name: str)
#
Bases: Exception
Raised when the an api tool call is made for an unknown tool.
Source code in .deps/rigging/rigging/error.py
tool_name = tool_name
instance-attribute
#
The name of the tool which was unknown.
raise_as(error_type: type[Exception], message: str) -> t.Callable[[t.Callable[P, R]], t.Callable[P, R]]
#
When the wrapped function raises an exception, raise ... from
with the new error type.