> ## Documentation Index
> Fetch the complete documentation index at: https://praison.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Scripted Model Error • AI Agent SDK

> ScriptedModelError: Base class for failures of the double itself.

# ScriptedModelError

> Defined in the [**scripted**](../modules/scripted) module.

<Badge color="blue">AI Agent</Badge>

Base class for failures of the double itself.

Derives from `BaseException` deliberately. The agent's tool loop catches
`Exception` broadly and converts failures into a `None` answer, so an
ordinary exception raised from inside the double would reach the test as a
mysterious `None` -- hiding the very thing the test needs to be told.

## Source

<Card title="View on GitHub" icon="github" href="https://github.com/MervinPraison/PraisonAI/blob/main/src/praisonai-agents/praisonaiagents/model_harness/scripted.py#L68">
  `praisonaiagents/model_harness/scripted.py` at line 68
</Card>
