Skip to content

Latest commit

 

History

History
38 lines (27 loc) · 1.2 KB

File metadata and controls

38 lines (27 loc) · 1.2 KB

Declarative Package (agent-framework-declarative)

YAML/JSON-based declarative agent and workflow definitions.

Main Classes

  • AgentFactory - Creates agents from declarative definitions
  • WorkflowFactory - Creates workflows from declarative definitions
  • WorkflowState - State management for declarative workflows
  • ProviderTypeMapping - Maps provider types to implementations
  • DeclarativeLoaderError / ProviderLookupError - Error types

External Input Handling

  • ExternalInputRequest / ExternalInputResponse - Human-in-the-loop support
  • AgentExternalInputRequest / AgentExternalInputResponse - Agent-level input requests

Usage

from agent_framework.declarative import AgentFactory, WorkflowFactory

# Create agent from YAML file
agent_factory = AgentFactory()
agent = agent_factory.create_agent_from_yaml_path("agent.yaml")

# Create workflow from YAML file
workflow_factory = WorkflowFactory()
workflow = workflow_factory.create_workflow_from_yaml_path("workflow.yaml")

Import Path

from agent_framework.declarative import AgentFactory, WorkflowFactory
# or directly:
from agent_framework_declarative import AgentFactory