{"slug":"internal/agents/core-agents","title":"Core Spine Agents","section":"internal","sectionLabel":"Internal","status":"unclassified","type":"document","path":"internal/agents/core-agents.mdx","bytes":21899,"description":null,"updated":null,"source":"integratewise/Integratewise-docs-wiki","content":"\n## The Foundation of the Agent Network\n\n**Core Spine Agents** are the five system-level agents that form the foundation of IntegrateWise. They work together to coordinate all interactions, manage data, discover capabilities, and route work efficiently.\n\n> **Key Insight:** Without these core agents, the Spine Agent Network cannot function. They are always active and provide the essential infrastructure for all other agents.\n\n## The Five Core Agents\n\n### 1. Twin Agent\n\n**Your Digital Representative**\n\nThe Twin is your permanent digital identity within IntegrateWise. It maintains your context, preferences, knowledge, and work patterns across all interactions.\n\n#### Key Responsibilities\n- **Identity Management** - Maintains your digital identity across the system\n- **Context Coordination** - Assembles and manages context for all your work\n- **Agent Orchestration** - Coordinates other agents to complete your requests\n- **Continuity** - Ensures seamless experience across all interactions\n- **Personalization** - Learns and adapts to your unique needs and patterns\n\n#### How Twin Works\n\n```\nUser Request → Twin Analysis → Agent Selection → Context Assembly → Execution → Result Delivery\n```\n\n**Example:** When you ask \"What's the status of the Acme deal?\", Twin:\n1. Understands you're asking about a sales opportunity\n2. Identifies the need for CRM data and previous interactions\n3. Selects appropriate agents (Discovery Agent, CRM connectors)\n4. Assembles context about Acme from Spine Fabric\n5. Coordinates agents to gather and synthesize information\n6. Delivers comprehensive answer with full context\n\n#### User Experience\n\n- **Single Interface** - Talk to Twin, not to individual agents\n- **Consistent Context** - Twin remembers your preferences and work history\n- **Intelligent Delegation** - Twin automatically routes work to the right agents\n- **Proactive Assistance** - Twin suggests relevant actions based on context\n\n---\n\n### 2. Schema Agent\n\n**The Data Architect**\n\nThe Schema Agent is the guardian of IntegrateWise's canonical data model, ensuring all entities, events, and contexts conform to defined schemas.\n\n#### Key Responsibilities\n- **Schema Validation** - Validates all incoming data against canonical schemas\n- **Schema Synthesis** - Automatically generates and evolves schemas from data\n- **Entity Mapping** - Maps between different data models (external → Spine canonical)\n- **Event Extraction** - Extracts structured events from unstructured data\n\n#### Supported Entity Types\n\n| Category | Examples |\n|----------|----------|\n| **Business Entities** | Customer, Account, Opportunity, Contact, Lead |\n| **Work Entities** | Task, Project, Deal, Ticket, Meeting |\n| **Communication** | Email, Message, Call, Chat |\n| **Content** | Document, Note, File, Knowledge Base |\n| **Financial** | Invoice, Payment, Order, Contract |\n| **Events** | Created, Updated, Deleted, Completed |\n\n#### Schema Evolution\n\nThe Schema Agent supports:\n- **Automatic Schema Inference** - Derives schemas from data patterns\n- **Schema Versioning** - Manages schema evolution over time\n- **Conflict Resolution** - Handles schema conflicts and merges\n- **Custom Schemas** - Supports tenant-specific schema extensions\n\n---\n\n### 3. Coworker Agent\n\n**Your Collaboration Partner**\n\nThe Coworker Agent works alongside humans on shared tasks, providing intelligent assistance for collaborative work.\n\n#### Key Responsibilities\n- **Task Collaboration** - Works with humans on shared tasks and projects\n- **Context Sharing** - Maintains shared context for team work\n- **Handoff Management** - Smoothly transitions work between team members\n- **Coordination** - Helps coordinate multi-person workflows\n\n#### Collaboration Patterns\n\n1. **Human + Coworker**\n   ```\n   Human starts task → Coworker assists → Human reviews → Coworker refines → Task complete\n   ```\n\n2. **Multiple Humans + Coworker**\n   ```\n   Team discussion → Coworker captures context → Individual work → Coworker coordinates → Team sync\n   ```\n\n3. **Coworker + Specialized Agents**\n   ```\n   Complex task → Coworker decomposes → Subtasks to agents → Coworker aggregates → Final delivery\n   ```\n\n#### Use Cases\n- **Document Creation** - Collaborate on documents with AI assistance\n- **Project Planning** - Plan projects with intelligent suggestions\n- **Code Review** - Review code with AI-powered analysis\n- **Meeting Preparation** - Prepare for meetings with comprehensive briefings\n\n---\n\n### 4. Discovery Agent\n\n**The Information Finder**\n\nThe Discovery Agent is responsible for finding relevant context, tools, capabilities, and information to support agent operations.\n\n#### Key Responsibilities\n- **Capability Discovery** - Finds agents and tools that can perform needed tasks\n- **Context Discovery** - Identifies relevant information and context for requests\n- **Tool Discovery** - Discovers available tools and their capabilities\n- **Route Optimization** - Determines the most efficient path for work execution\n\n#### Discovery Mechanisms\n\n1. **Capability-Based Discovery**\n   ```\n   Request: \"Analyze this market\"\n   Discovery: Finds agents with \"market_analysis\" capability\n   Result: Returns Market Research Agent\n   ```\n\n2. **Context-Based Discovery**\n   ```\n   Context: Working on Salesforce opportunity\n   Discovery: Finds CRM tools and Sales agents\n   Result: Returns Salesforce connector + Lead Agent\n   ```\n\n3. **Pattern-Based Discovery**\n   ```\n   Pattern: User frequently asks for customer health scores\n   Discovery: Identifies Customer Success agents and metrics\n   Result: Returns Account Health Agent + relevant dashboards\n   ```\n\n#### Discovery Sources\n- **Agent Registry** - Database of all available agents and their capabilities\n- **Tool Registry** - Database of all connected tools and their functions\n- **Context Index** - Index of all context and relationships in Spine Fabric\n- **Usage Patterns** - Historical patterns of user behavior and preferences\n\n---\n\n### 5. Triage Agent\n\n**The Work Router**\n\nThe Triage Agent is responsible for routing requests, tasks, and work to the appropriate agents, systems, or humans based on priority, capability, and context.\n\n#### Key Responsibilities\n- **Request Prioritization** - Determines urgency and importance of incoming requests\n- **Agent Selection** - Routes work to the most appropriate agent\n- **Load Balancing** - Distributes work across available agents\n- **Exception Handling** - Manages edge cases and error conditions\n- **Queue Management** - Maintains work queues and processing order\n\n#### Triage Decision Factors\n\n| Factor | Description | Example |\n|--------|-------------|---------|\n| **Urgency** | Time sensitivity of the request | \"ASAP\" vs \"When convenient\" |\n| **Importance** | Business impact of the request | Customer escalation vs routine task |\n| **Complexity** | How complex the task is | Multi-step workflow vs simple query |\n| **Capabilities** | What capabilities are needed | Requires CRM access + analysis |\n| **Context** | Current user context | Working on specific customer or project |\n| **Availability** | Which agents are available | Agent load and readiness |\n| **Dependencies** | What the task depends on | Waiting for other tasks to complete |\n\n#### Triage Workflow\n\n```\n1. Request Received → Analyze request type and context\n2. Priority Assessment → Determine urgency and importance\n3. Capability Matching → Find agents with required capabilities\n4. Availability Check → Verify agent availability\n5. Route Decision → Select optimal agent or workflow\n6. Handoff → Transfer work with full context\n7. Monitor → Track execution and handle exceptions\n```\n\n## Agent Relationships\n\n### How Core Agents Work Together\n\n```\n┌─────────────────────────────────────────────────────────────┐\n│                    CORE AGENT COLLABORATION                     │\n├─────────────────────────────────────────────────────────────┤\n│                                                                  │\n│  ┌──────────────┐    ┌──────────────┐    ┌──────────────┐   │\n│  │    TWIN      │    │  DISCOVERY   │    │   SCHEMA     │   │\n│  │  (Orchestrator)│   │   (Finder)   │    │   (Architect) │   │\n│  └──────┬───────┘    └──────┬───────┘    └──────┬───────┘   │\n│         │                   │                   │          │\n│         │    ┌──────────────▼──────────────┐    │          │\n│         │    │           WORK REQUEST         │    │          │\n│         │    │    ┌─────────────────────────┐│    │          │\n│         │    │    │  What needs to be done?    ││    │          │\n│         │    │    │  What capabilities needed?││    │          │\n│         │    │    └─────────────────────────┘│    │          │\n│         │    └──────────────┬──────────────┘    │          │\n│         │                   │                   │          │\n│         ▼                   ▼                   ▼          │\n│  ┌──────────────┐    ┌──────────────┐    ┌──────────────┐   │\n│  │  COWORKER    │    │   TRIAGE     │    │   Validates  │   │\n│  │  (Collaborator)│   │   (Router)   │    │   Data &     │   │\n│  └──────────────┘    └──────────────┘    │   Schemas     │   │\n│                                           └──────────────┘   │\n│                                                                  │\n│  ┌─────────────────────────────────────────────────────────┐ │\n│  │                    EXECUTION FLOW                            │ │\n│  │                                                             │ │\n│  │  Twin → Discovery → Triage → Specialized Agent → Execution │ │\n│  │         ↓        ↓              ↓                         │ │\n│  │      Context   Capabilities    Priority                   │ │\n│  └─────────────────────────────────────────────────────────┘ │\n│                                                                  │\n└─────────────────────────────────────────────────────────────┘\n```\n\n### Example: Multi-Agent Collaboration\n\n**User Request:** \"Prepare a comprehensive report on our Q2 sales performance\"\n\n1. **Twin** receives request, understands intent\n2. **Discovery** finds relevant agents (Data Analysis, Report Generation, Sales Context)\n3. **Schema** validates data structures for sales metrics\n4. **Triage** prioritizes and routes to Report Generation Agent\n5. **Coworker** assists with data gathering and formatting\n6. **Specialized Agents** execute their parts (data analysis, chart generation, etc.)\n7. **Twin** aggregates results and delivers final report\n\n## Technical Details\n\n### Agent Architecture\n\nAll Core Agents share a common architecture:\n\n```\n┌─────────────────────────────────────────────────────────────┐\n│                    CORE AGENT STRUCTURE                      │\n├─────────────────────────────────────────────────────────────┤\n│                                                                  │\n│  ┌─────────────────────────────────────────────────────────┐ │\n│  │                    CONTROL LAYER                         │ │\n│  │  ┌─────────────┐  ┌─────────────┐  ┌─────────────┐    │ │\n│  │  │  Intent     │  │  Context    │  │  Governance │    │ │\n│  │  │  Parser     │  │  Manager   │  │  Engine     │    │ │\n│  │  └─────────────┘  └─────────────┘  └─────────────┘    │ │\n│  └─────────────────────────────────────────────────────────┘ │\n│                                                                  │\n│  ┌─────────────────────────────────────────────────────────┐ │\n│  │                    EXECUTION LAYER                        │ │\n│  │  ┌─────────────┐  ┌─────────────┐  ┌─────────────┐    │ │\n│  │  │  Task      │  │  Handoff   │  │  Monitor    │    │ │\n│  │  │  Executor  │  │  Manager   │  │  Engine     │    │ │\n│  │  └─────────────┘  └─────────────┘  └─────────────┘    │ │\n│  └─────────────────────────────────────────────────────────┘ │\n│                                                                  │\n│  ┌─────────────────────────────────────────────────────────┐ │\n│  │                    INTEGRATION LAYER                       │ │\n│  │  ┌─────────────┐  ┌─────────────┐  ┌─────────────┐    │ │\n│  │  │  Spine     │  │  MCP       │  │  Other     │    │ │\n│  │  │  Fabric    │  │  Pool      │  │  Agents    │    │ │\n│  │  └─────────────┘  └─────────────┘  └─────────────┘    │ │\n│  └─────────────────────────────────────────────────────────┘ │\n│                                                                  │\n└─────────────────────────────────────────────────────────────┘\n```\n\n### Capability Matrix\n\n| Capability | Twin | Schema | Coworker | Discovery | Triage |\n|------------|------|--------|---------|-----------|--------|\n| Context Assembly | ✅ | ❌ | ✅ | ✅ | ✅ |\n| Task Execution | ✅ | ❌ | ✅ | ❌ | ✅ |\n| Data Validation | ❌ | ✅ | ❌ | ❌ | ❌ |\n| Capability Discovery | ❌ | ❌ | ❌ | ✅ | ❌ |\n| Work Routing | ✅ | ❌ | ❌ | ✅ | ✅ |\n| Collaboration | ✅ | ❌ | ✅ | ❌ | ❌ |\n| Handoff Management | ✅ | ❌ | ✅ | ❌ | ✅ |\n\n## Configuration\n\n### Core Agent Settings\n\nAll Core Agents are **always active** and cannot be disabled. However, you can configure their behavior:\n\n```yaml\n# Twin Configuration\n  twin:\n    personality: \"professional\"  # professional, friendly, technical\n    learning_rate: 0.8          # How quickly Twin learns from interactions\n    context_retention: 365       # Days of context to retain\n    \n# Schema Agent Configuration\n  schema_agent:\n    auto_evolve: true           # Automatically evolve schemas\n    strict_mode: false           # Strict validation vs lenient\n    \n# Coworker Configuration\n  coworker:\n    collaboration_mode: \"active\"  # active, passive, disabled\n    task_timeout: 3600           # Seconds before task timeout\n    \n# Discovery Configuration\n  discovery:\n    search_depth: 3             # How deep to search for capabilities\n    cache_ttl: 300              # Cache time-to-live in seconds\n    \n# Triage Configuration\n  triage:\n    priority_thresholds:        # Custom priority thresholds\n      urgent: 0.9\n      high: 0.7\n      normal: 0.5\n      low: 0.3\n```\n\n## Monitoring\n\n### Core Agent Metrics\n\n| Agent | Metrics | Description |\n|-------|---------|-------------|\n| **Twin** | Requests Processed | Total user requests handled |\n| | Context Assembled | Context packages created |\n| | Agent Coordinated | Number of agents coordinated |\n| **Schema** | Schemas Validated | Data validation operations |\n| | Schemas Evolved | Automatic schema updates |\n| | Mappings Performed | Entity mapping operations |\n| **Coworker** | Tasks Collaborated | Shared tasks completed |\n| | Handoffs Managed | Work transitions handled |\n| **Discovery** | Capabilities Found | Successful capability discoveries |\n| | Tools Discovered | Tool discovery operations |\n| **Triage** | Requests Routed | Work routing operations |\n| | Priority Decisions | Priority assessments made |\n\n### Health Checks\n\nAll Core Agents include:\n- **Heartbeat** - Regular health signals\n- **Performance Metrics** - Response times and throughput\n- **Error Tracking** - Error rates and types\n- **Resource Usage** - CPU, memory, and network usage\n\n## Troubleshooting\n\n### Common Issues\n\n| Issue | Cause | Solution |\n|-------|-------|----------|\n| Slow response times | High agent load | Check load balancing, scale resources |\n| Context missing | Incomplete data | Verify integrations, check permissions |\n| Wrong agent selected | Discovery misconfiguration | Review capability definitions, retrain discovery |\n| Work not routed | Triage rules incorrect | Update priority thresholds, verify agent availability |\n\n### Debug Mode\n\nEnable debug mode for detailed logging:\n\n```bash\n# Enable debug for specific agent\nintegratewise agent debug twin --level verbose\n\n# View agent logs\nintegratewise agent logs twin --tail 100\n\n# Check agent health\nintegratewise agent health --all\n```\n\n## Best Practices\n\n### For Administrators\n1. **Monitor Core Agents** - Keep an eye on core agent health and performance\n2. **Review Discovery Index** - Regularly update capability and tool registries\n3. **Tune Triage Rules** - Adjust priority thresholds based on your organization's needs\n4. **Backup Schema** - Regularly backup your schema definitions\n\n### For Developers\n1. **Use Discovery API** - Leverage Discovery Agent to find capabilities programmatically\n2. **Register Capabilities** - Ensure all new agents and tools are properly registered\n3. **Follow Schema** - Always validate data against canonical schemas\n4. **Handle Handoffs** - Design agents to properly receive and pass context\n\n### For Users\n1. **Provide Feedback** - Help Twin learn your preferences\n2. **Be Specific** - Clear requests help agents work better\n3. **Review Context** - Check the context Twin assembles for accuracy\n4. **Use Approvals** - Configure approval workflows for sensitive actions\n\n## Roadmap\n\n### Core Agent Enhancements\n- **Twin** - Improved personalization and learning algorithms\n- **Schema** - Enhanced schema inference and conflict resolution\n- **Coworker** - Better multi-human collaboration support\n- **Discovery** - Advanced capability matching and ranking\n- **Triage** - Predictive routing and load optimization\n\n## Support\n\n### Documentation\n- [Spine Agent Network](./spine-agent-network) - Overview of the agent network\n- [Domain Agents](./domain-agents) - Specialized agents by function\n- [Network Effect](./network-effect) - How agents create exponential value\n\n### Community\n- [IntegrateWise Community](https://community.integratewise.com)\n- [GitHub Issues](https://github.com/IntegrateWise/integratewise-live/issues)\n- [Developer Forum](https://forum.integratewise.com)\n\n---\n\n## Quick Reference\n\n### Core Agent Summary\n\n| Agent | Nickname | Primary Role | Always Active |\n|-------|----------|--------------|----------------|\n| Twin | \"The Boss\" | Orchestration | ✅ Yes |\n| Schema | \"The Librarian\" | Data Architecture | ✅ Yes |\n| Coworker | \"The Sidekick\" | Collaboration | ✅ Yes |\n| Discovery | \"The Scout\" | Information Finding | ✅ Yes |\n| Triage | \"The Traffic Cop\" | Work Routing | ✅ Yes |\n\n### Key Concepts\n- **Twin-Centric** - All interactions go through Twin\n- **Context-First** - Context flows with every request\n- **Handoff** - Work transfer between agents with full context\n- **Governed** - All actions have proper permissions and audit\n\n### Next Steps\n1. [Understand the full Agent Network](./spine-agent-network)\n2. [Explore Domain Agents](./domain-agents)\n3. [Learn about Network Effect](./network-effect)\n4. [Try Core Agents in action](https://app.integratewise.ai)\n"}