Agent-TS Overview
Agent-TS is the TypeScript implementation of the OLIVE conversational agent, powered by OpenAI’s Assistant API with function calling capabilities.Purpose
The agent provides an automated conversational interface for OLIVE mobile-money users, enabling self-service operations through natural language:WhatsApp Integration
Handles user messages from WhatsApp Business API and external clients
Wallet Operations
Check balance, send money, view transactions, manage linked cards
KYC Processing
Upload and validate identity documents with OCR and fraud detection
Natural Language
OpenAI-powered intent recognition and response generation
Key Features
OpenAI Function Calling
The agent leverages OpenAI’s function calling to execute wallet operations:Available Operations
KYC Fraud Detection
Multi-layer validation for Sierra Leone National ID cards:- OpenAI Vision API - Document authenticity validation
- Tesseract OCR - Text extraction and tampering detection
- Cross-Validation - Data consistency between front and back images
Architecture
User Flow
Quick Start
Prerequisites
- Node.js 18+
- OpenAI API key
- Gateway API key
- AWS credentials (for KYC document storage)
Installation
Docker
Project Structure
Next Steps
Configuration
Environment variables and setup
Tools Reference
Complete tool documentation
KYC Validation
OCR and fraud detection details
Webhooks
WhatsApp integration setup