Skip to main content
Version: 2.0

aixplain.v2.inspector

Inspector module for v2 API - Team agent inspection and validation.

This module provides inspector functionality for validating team agent operations at different stages (input, steps, output) with custom policies.

InspectorTarget Objects

class InspectorTarget(str, Enum)

[view_source]

Target stages for inspector validation in the team agent pipeline.

__str__

def __str__() -> str

[view_source]

Return the string value of the enum.

InspectorAction Objects

class InspectorAction(str, Enum)

[view_source]

Actions an inspector can take when evaluating content.

InspectorOnExhaust Objects

class InspectorOnExhaust(str, Enum)

[view_source]

Action to take when max retries are exhausted.

InspectorSeverity Objects

class InspectorSeverity(str, Enum)

[view_source]

Severity level for inspector findings.

EvaluatorType Objects

class EvaluatorType(str, Enum)

[view_source]

Type of evaluator or editor.

InspectorActionConfig Objects

@dataclass
class InspectorActionConfig()

[view_source]

Inspector action configuration.

__post_init__

def __post_init__() -> None

[view_source]

Validate that max_retries and on_exhaust are only used with RERUN.

to_dict

def to_dict() -> Dict[str, Any]

[view_source]

Convert the action config to a dictionary for API serialization.

from_dict

@classmethod
def from_dict(cls, data: Dict[str, Any]) -> "InspectorActionConfig"

[view_source]

Create an InspectorActionConfig from a dictionary.

EvaluatorConfig Objects

@dataclass
class EvaluatorConfig()

[view_source]

Evaluator configuration for an inspector.

__post_init__

def __post_init__() -> None

[view_source]

Validate and convert callable functions to source strings.

to_dict

def to_dict() -> Dict[str, Any]

[view_source]

Convert to a dictionary for API serialization.

from_dict

@classmethod
def from_dict(cls, data: Dict[str, Any]) -> "EvaluatorConfig"

[view_source]

Create an EvaluatorConfig from a dictionary.

EditorConfig Objects

@dataclass
class EditorConfig()

[view_source]

Editor configuration for an inspector.

__post_init__

def __post_init__() -> None

[view_source]

Validate and convert callable functions to source strings.

to_dict

def to_dict() -> Dict[str, Any]

[view_source]

Convert to a dictionary for API serialization.

from_dict

@classmethod
def from_dict(cls, data: Dict[str, Any]) -> "EditorConfig"

[view_source]

Create an EditorConfig from a dictionary.

Inspector Objects

@dataclass
class Inspector()

[view_source]

Inspector v2 configuration object.

__post_init__

def __post_init__() -> None

[view_source]

Validate inspector configuration after initialization.

to_dict

def to_dict() -> Dict[str, Any]

[view_source]

Convert the inspector to a dictionary for API serialization.

from_dict

@classmethod
def from_dict(cls, data: Dict[str, Any]) -> "Inspector"

[view_source]

Create an Inspector from a dictionary.