> ## 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.

# auto • AI Agents Framework

> Auto-generation module for PraisonAI agents and workflows.

# auto

<Badge color="purple">AI Agents Framework</Badge>

Auto-generation module for PraisonAI agents and workflows.

This module uses FULL LAZY LOADING for all heavy dependencies:

* crewai: Only loaded when framework='crewai' is used
* autogen: Only loaded when framework='autogen' is used
* praisonaiagents: Only loaded when framework='praisonai' is used
* litellm: Only loaded when structured output is needed
* openai: Fallback for structured output when litellm unavailable
* praisonai\_tools: Only loaded when tools are needed

This ensures minimal import-time overhead.

## Import

```python theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
from praisonai import auto
```

## Classes

<CardGroup cols={2}>
  <Card title="BaseAutoGenerator" icon="brackets-curly" href="../classes/BaseAutoGenerator">
    Base class for auto-generators with shared functionality.
  </Card>

  <Card title="TaskDetails" icon="brackets-curly" href="../classes/TaskDetails">
    Details for a single task.
  </Card>

  <Card title="RoleDetails" icon="brackets-curly" href="../classes/RoleDetails">
    Details for a single role/agent.
  </Card>

  <Card title="TeamStructure" icon="brackets-curly" href="../classes/TeamStructure">
    Structure for multi-agent team.
  </Card>

  <Card title="SingleAgentStructure" icon="brackets-curly" href="../classes/SingleAgentStructure">
    Structure for single-agent generation (Anthropic's 'start simple' principle).
  </Card>

  <Card title="PatternRecommendation" icon="brackets-curly" href="../classes/PatternRecommendation">
    LLM-based pattern recommendation with reasoning.
  </Card>

  <Card title="ValidationGate" icon="brackets-curly" href="../classes/ValidationGate">
    Validation gate for prompt chaining workflows.
  </Card>

  <Card title="AutoGenerator" icon="brackets-curly" href="../classes/AutoGenerator">
    Auto-generates agents.yaml files from a topic description.
  </Card>

  <Card title="WorkflowStepDetails" icon="brackets-curly" href="../classes/WorkflowStepDetails">
    Details for a workflow step.
  </Card>

  <Card title="WorkflowRouteDetails" icon="brackets-curly" href="../classes/WorkflowRouteDetails">
    Details for a route step.
  </Card>

  <Card title="WorkflowParallelDetails" icon="brackets-curly" href="../classes/WorkflowParallelDetails">
    Details for a parallel step.
  </Card>

  <Card title="WorkflowAgentDetails" icon="brackets-curly" href="../classes/WorkflowAgentDetails">
    Details for a workflow agent.
  </Card>

  <Card title="WorkflowStructure" icon="brackets-curly" href="../classes/WorkflowStructure">
    Structure for auto-generated workflow.
  </Card>

  <Card title="WorkflowAutoGenerator" icon="brackets-curly" href="../classes/WorkflowAutoGenerator">
    Auto-generates workflow\.yaml files from a topic description.
  </Card>
</CardGroup>

## Functions

<CardGroup cols={2}>
  <Card title="get_all_available_tools()" icon="function" href="../functions/get_all_available_tools">
    Get all available tools organized by category.
  </Card>

  <Card title="get_tools_for_task()" icon="function" href="../functions/get_tools_for_task">
    Analyze a task description and return appropriate tools.
  </Card>

  <Card title="recommend_agent_count()" icon="function" href="../functions/recommend_agent_count">
    Recommend the optimal number of agents based on task complexity.
  </Card>
</CardGroup>

### Constants

| Name                    | Value                                                                                                                                                                                                         |
| ----------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `T`                     | `TypeVar('T', bound=BaseModel)`                                                                                                                                                                               |
| `AVAILABLE_TOOLS`       | `['CodeDocsSearchTool', 'CSVSearchTool', 'DirectorySearchTool', 'DOCXSearchTool', 'DirectoryReadTool', 'FileReadTool', 'TXTSearchTool', 'JSONSearchTool', 'MDXSearchTool', 'PDFSearchTool', 'RagTool', 'S...` |
| `TOOL_CATEGORIES`       | `{'web_search': ['internet_search', 'duckduckgo', 'tavily_search', 'exa_search', 'search_web', 'ydc_search', 'searxng_search'], 'web_scraping': ['scrape_page', 'extract_links', 'crawl', 'extract_text',...` |
| `TASK_KEYWORD_TO_TOOLS` | `{'search': 'web_search', 'find': 'web_search', 'look up': 'web_search', 'google': 'web_search', 'internet': 'web_search', 'online': 'web_search', 'web': 'web_search', 'scrape': 'web_scraping', 'crawl'...` |
