Lewati ke konten utama

Agents

In Perfect10, an Agent is a modular AI entity that serves as the brain of a conversational system. Each Agent has a unique configuration that determines how it responds, thinks, retrieves information, and executes actions.

Agents can be used for various purposes, such as:

  • Customer service chatbots
  • Internal company assistants
  • Business process automation
  • Interface to a knowledge base

Agent Structure

Each agent in Perfect10 consists of the following components:

1. Model

The LLM model used as the reasoning foundation. Examples: Gemini, GPT-4, GPT-3.5.

2. Prompt Template

The base instructions (system prompt) that define the agent’s style, role, and constraints. Example:

You are a helpful AI assistant specialized in logistics management.

3. Tools (Optional)

External functions that the agent can call, such as:

  • Calculator Tools: Mathematical calculations, financial analysis, statistical computations
  • Web Search: Fetching real-time information from the internet
  • URL Access: Retrieving content from web pages
  • API Integration: Accessing internal company APIs and external services
  • File Processing: Handling document uploads and processing

4. Memory (Optional)

  • Short-Term Memory: Retains the context of the current conversation.
  • Long-Term Memory: Stores significant episodes for long-term learning.

5. Knowledge Sources

Documents or knowledge bases used in the RAG process:

  • Files (PDF, Word, CSV)
  • URLs/web scraping
  • Internal document systems

Agent Types

Agent TypeDescription
ChatbotAnswers questions based on natural text input
RAG AssistantCombines conversation with external document retrieval
Action AgentCan execute actions (function calling), such as accessing APIs
Multi-AgentA collaborative system of multiple agents with specific tasks

Agent Workflow

Example Agent Configuration

{
"name": "HelpdeskBot",
"model": "gemini-pro",
"prompt": "You are a friendly and concise helpdesk assistant.",
"tools": ["getTicketStatus", "createSupportTicket"],
"memory": true,
"knowledge_sources": ["faq.pdf", "support-guidelines.md"]
}

Tips for Designing Agents

  • Assign a single primary role for each agent.
  • Use clear and instructive prompts.
  • Enable tool calling if the agent needs to take actions, not just respond.
  • Add knowledge sources when answers require strong references.

Calculator Tools Integration

Perfect10 agents come equipped with powerful Calculator Tools that enable them to perform accurate mathematical calculations. This feature is automatically available to all agents and enhances their capabilities in various domains:

Mathematical Capabilities

  • Financial Calculations: Compound interest, discounts, tax calculations
  • Statistical Analysis: Averages, sums, aggregations, percentage changes
  • Scientific Computing: Trigonometric functions, logarithms, exponentials
  • Data Processing: Mathematical transformations and formula evaluations

Example Usage

User: "Calculate the compound interest for $10,000 at 8% for 5 years"
Agent: Uses calculator tool → Result: $14,693.28

User: "What's the average of scores: 85, 92, 78, 88?"
Agent: Uses calculator tool → Result: 85.75

Security Features

  • Safe Evaluation: All mathematical expressions are validated for security
  • Error Handling: Comprehensive error messages for invalid expressions
  • High Precision: Accurate calculations with up to 10 significant digits

For detailed information about Calculator Tools, see the Calculator Tools Guide.

Integration

Agents can be used on various platforms:

  • Web Widget
  • Mobile App
  • Internal Dashboard
  • WhatsApp, Telegram, etc.
  • API Endpoint for automation