Skip to main content
An agent is an autonomous AI system that can invoke tools, remember context, and collaborate with other agents. Unlike MCP gateways (which just expose tools), agents actively think, plan, and execute.

Agent vs Gateway

MCP Gateway

  • Passive: exposes tools, waits for external client
  • Stateless: no memory between requests
  • Controlled: operates on external client’s schedule
  • Use for: providing tools to external AI systems

Agent

  • Active: reasons about tasks, calls tools proactively
  • Stateful: maintains working memory and conversation history
  • Autonomous: operates on schedule or on-demand
  • Use for: autonomous execution, persistent assistants
When to use:
  • Use Gateway: “I want to expose tools to Claude or other AI”
  • Use Agent: “I want my own AI system that acts autonomously”

Agent Architecture

Agent Specifications

When you create an agent, you define its specifications:
{
  "name": "Research Assistant",
  "description": "Autonomous research agent that gathers and analyzes information",
  "routing_strategy": {
    "strategy": "smart",
    "tier": "standard",
    "provider": "anthropic",
    "use_case": "reasoning"
  },
  "capabilities": [
    "Files",
    "WebSearch",
    "CodeRunner",
    "KnowledgeRetrieval"
  ],
  "instructions": "You are a research agent. Search for information, analyze it, and provide insights.",
  "memory_config": {
    "working_memory_size": 20,
    "enable_summarization": true,
    "archive_threshold": 100
  }
}

Key Components

Name & Description
  • Human-readable identifier and purpose
  • Used for logging, displays, agent discovery
Routing Strategy How the agent selects models:

Smart Routing

Platform automatically chooses the best model based on task requirements.
{
  "strategy": "smart",
  "tier": "standard",              // fast, standard, advanced
  "provider": "anthropic",         // optional: anthropic, openai, any
  "use_case": "reasoning"          // fast, code, reasoning, creative
}
Tier options:
  • fast: GPT-4o Mini, Claude Haiku (cheap, quick)
  • standard: GPT-4, Claude Opus (balanced)
  • advanced: GPT-5, Claude Opus 4 (powerful, expensive)

Specific Routing

Agent always uses one specific model (or a budget model for cost optimization).
{
  "strategy": "specific",
  "model_name": "claude-opus-4-5-20250929",
  "settings": {
    "temperature": 0.7,
    "max_tokens": 2048
  },
  "budget_model": "claude-haiku-4-5",          // optional cheaper fallback
  "budget_model_settings": {
    "temperature": 0.5
  },
  "fallback": true                             // allow fallback if model unavailable
}
Capabilities Which tools the agent can access:
  • Built-in (Files, Web Search, etc.)
  • Plugins (your custom tools)
  • Connectors (external APIs)
Instructions System prompt that guides agent behavior. Examples:
You are a helpful research assistant. Your goal is to find accurate information
and present it clearly. Always cite sources. Ask clarifying questions if needed.
Be concise but thorough.
You are a data analyst. Your task is to process data, find patterns, and explain
findings. Use Code Runner to execute analysis. Always validate results.
Memory Configuration Control how the agent remembers:
  • working_memory_size: Recent messages to keep in fast access (Redis)
  • enable_summarization: Compress old messages via LLM
  • archive_threshold: How many messages before summarizing

Agent Lifecycle

Agent Execution Modes

On-Demand

Agent processes single request and returns result.
curl -X POST https://api.noorle.com/agents/{agent_id}/execute \
  -d '{"message": "Search for AI trends"}'

Response: {"result": "...", "memory_used": 3}
Use for: Interactive chat, webhooks, API calls

Scheduled

Agent runs on a schedule (daily, hourly, etc.).
{
  "schedule": "0 9 * * *",        // 9 AM daily
  "task": "Analyze yesterday's logs and generate report"
}
Use for: Daily reports, periodic cleanup, monitoring

Streaming

Agent output streams in real-time.
curl -X POST https://api.noorle.com/agents/{agent_id}/stream \
  -d '{"message": "Write a detailed analysis"}'

Response:
---
data: {"chunk": "I'll analyze...", "tokens": 5}
data: {"chunk": " the provided", "tokens": 2}
data: {"chunk": " data carefully.", "tokens": 2}
---
Use for: Long-running tasks, interactive chat, feedback

Multi-Agent Workflows

Agents can collaborate through A2A protocol: How it works:
  1. Coordinator receives user request
  2. Coordinator determines subtasks
  3. Coordinator sends tasks to specialized agents via A2A
  4. Agents execute tasks, return results
  5. Coordinator aggregates, sends final response
Advantages:
  • Divide complex tasks into subtasks
  • Parallelize execution
  • Specialize agents for different tasks
  • Resilient to individual agent failures

Agent vs Agent Gateway

Agent (Standalone)

  • Created in Console or via API
  • Manages its own state, memory, execution
  • Can be triggered on-demand or scheduled
  • Has its own agent-.noorle.com endpoint

Agent Gateway (Wrapper)

When you want external clients to invoke an agent:
  • Wraps an agent in MCP protocol
  • Exposes agent’s tools and memory
  • Allows clients to interact with agent
  • Creates agent-.noorle.com endpoint

Common Patterns

Pattern: Customer Support Agent

Instructions:
  "You are a helpful support agent. Answer customer questions about
   our products. Use the knowledge base. If you can't help, escalate
   to a human. Always be friendly and professional."

Capabilities:
  • KnowledgeRetrieval (product docs)
  • Files (FAQ, policies)
  • HttpClient (check order status via API)
  • WebSearch (find public information)

Memory:
  • Keep customer context for 20 messages
  • Summarize old conversations for efficiency

Pattern: Data Processing Agent

Instructions:
  "Process uploaded data files. Clean, analyze, and generate insights.
   Use Code Runner for data processing. Store results in Files.
   Alert if data quality issues found."

Capabilities:
  • Files (read/write data)
  • CodeRunner (Python for analysis)
  • HttpClient (send notifications)

Memory:
  • Keep recent processing steps
  • Archive completed analyses

Pattern: Monitoring Agent

Instructions:
  "Monitor system health. Check metrics hourly. Alert if thresholds
   exceeded. Investigate failures automatically using available tools."

Capabilities:
  • HttpClient (query monitoring APIs)
  • CodeRunner (analyze metrics)
  • KnowledgeRetrieval (runbooks)

Schedule:
  • Run every hour
  • On failures, escalate immediately

Configuration Best Practices

Start with Smart Routing

Let Noorle pick the model. Switch to Specific when you know your needs.

Clear Instructions

Write detailed system prompts. Include examples. Specify output format.

Memory for Long Tasks

Enable summarization for long conversations. Archive old messages.

Monitor Usage

Track token usage, costs, errors. Adjust tiers based on metrics.

Next: Learn about Connectors for external service integration.