agents.rag.multi_agent_rag.enhanced_state_schemas

Enhanced State Schemas with Configuration Support.

This module provides state schemas that include configuration fields, solving the issue of storing agent-specific configuration in a clean way.

Classes

AdaptiveThresholdRAGState

Adaptive threshold state extending Dynamic RAG state.

ConfigurableRAGState

Base RAG state with configuration support.

DebateRAGState

Debate RAG state with configuration support.

DynamicRAGState

Dynamic RAG state with configuration support.

FLAREState

FLARE state with configuration support.

GradedRAGState

RAG state with grading information and configuration.

StateConfigMixin

Mixin to help MultiAgent classes work with configured states.

Functions

create_configured_state(state_class, agent_name, ...)

Create a state instance with configuration.

Module Contents

class agents.rag.multi_agent_rag.enhanced_state_schemas.AdaptiveThresholdRAGState(/, **data)

Bases: DynamicRAGState

Adaptive threshold state extending Dynamic RAG state.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

Parameters:

data (Any)

class agents.rag.multi_agent_rag.enhanced_state_schemas.ConfigurableRAGState(/, **data)

Bases: haive.core.schema.prebuilt.rag_state.RAGState

Base RAG state with configuration support.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

Parameters:

data (Any)

class agents.rag.multi_agent_rag.enhanced_state_schemas.DebateRAGState(/, **data)

Bases: ConfigurableRAGState

Debate RAG state with configuration support.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

Parameters:

data (Any)

class agents.rag.multi_agent_rag.enhanced_state_schemas.DynamicRAGState(/, **data)

Bases: ConfigurableRAGState

Dynamic RAG state with configuration support.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

Parameters:

data (Any)

class agents.rag.multi_agent_rag.enhanced_state_schemas.FLAREState(/, **data)

Bases: ConfigurableRAGState

FLARE state with configuration support.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

Parameters:

data (Any)

class agents.rag.multi_agent_rag.enhanced_state_schemas.GradedRAGState(/, **data)

Bases: ConfigurableRAGState

RAG state with grading information and configuration.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

Parameters:

data (Any)

class agents.rag.multi_agent_rag.enhanced_state_schemas.StateConfigMixin

Mixin to help MultiAgent classes work with configured states.

get_state_config(state)

Extract configuration from state.

Parameters:

state (ConfigurableRAGState)

Return type:

dict[str, Any]

update_state_config(state, **updates)

Update configuration in state.

Parameters:

state (ConfigurableRAGState)

Return type:

None

agents.rag.multi_agent_rag.enhanced_state_schemas.create_configured_state(state_class, agent_name, workflow_type, **config_kwargs)

Create a state instance with configuration.

Parameters:
Return type:

ConfigurableRAGState