Documentation

Welcome to the Sharyx Voice Agent documentation. Sharyx is a powerful, production-ready SDK designed to help you build AI voice agents in minutes, not months.

Whether you're building a simple customer service bot or a complex real-time conversational system, Sharyx provides the primitives you need for high-quality voice interactions.

Installation

Get started by installing the core package via npm or yarn:

npm install sharyx-voice-agent

Quickstart

Initialize your first agent with just a few lines of code:

import { createAgent } from 'sharyx-voice-agent';

const agent = createAgent({
  llm: 'openai',
  voice: 'natural',
  simulation: true
});

agent.on('message', (reply) => {
  console.log(`🤖 agent: ${reply}`);
});

agent.say('Hello, how can I help?');

Core VoiceAgent

The VoiceAgent class is the heart of the SDK. it handles event orchestration, streaming audio, and state management.

Simulation Mode

Testing voice systems can be slow. Use simulation mode to mock responses and latency instantly.

agent.enableSimulation({ latency: 200, responses: 'mock' })

Full Documentation (Offline)

Download the comprehensive guide in Word format.

Download DOCX