KK
Screenshot
Control plane overview

项目

Voice Agent

Orchestrator

独立项目Prototype
  • Node.js
  • TypeScript
  • Angular
  • Voice AI
  • AI Runtime
  • Voice Streaming
  • Realtime & Pipeline
  • MCP
  • 3CX Call Control
  • RAG
  • SQLite-Vec
  • ONNX Runtime
  • Docker

Voice Agent Orchestrator 是独立的 on-premises 平台,用于在 telephony 上构建、评估与运行 AI voice agent。组织可通过单一 speech-to-speech 模型运行完整对话,或使用 pipeline mode — 可独立配置各阶段的 composable STT → LLM → TTS stack。Knowledge retrieval、MCP tooling 与 built-in evaluation 统一由单一 control plane 管理。

Voice AI 集成往往围绕特定 provider、runtime 和部署假设构建。当组织引入新模型、本地推理、知识系统或混合架构时,业务逻辑与实现细节之间的耦合越来越深。

结果是实验变慢、集成重复,且底层 AI 栈每次变化都会推高维护成本。挑战不在于支持单一 provider 或模型,而在于让对话系统能够演进,而不迫使周边平台随之一起演进。

平台围绕两种可互换的 voice runtime 架构构建,独立于 PBX 部署 — AI 栈可以自主扩展与迭代,而不必绑定通信核心。

Realtime mode 通过单一 speech-to-speech provider 运行完整对话。Pipeline mode 将独立的 STT、LLM、TTS 阶段组合为 cloud、on-premises 或 hybrid 部署 — 无论 provider 是 native streaming 还是 batch API,均使用统一的 runtime 抽象。

Turn-taking、barge-in 与 provider orchestration 在 voice runtime 内部处理,而非 telephony 集成代码中。

平台通过 Call Control API 与 3CX 集成以处理实时通话,并以内置 3CX MCP server 作为主要 tool 执行层。联系人查找、分机发现、呼叫转接与路由等核心 telephony 能力通过 MCP tools 暴露给 agent;电话簿搜索利用 3CX 的 fuzzy linguistic matching,以弥补语音识别误差。

可创建任意架构或部署类型的多个栈,为每个栈配置 agent — 在同一 runtime 中并行运行。

Agent

Agent A
Agent B
Agent C
Agent D

按 agent 配置语音、语言、提示词、工具、知识库访问等。

实时通话的语音处理路径 — 从音频输入到语音输出。

IN

音频输入

3CX Call Control API · 8 kHz mono

getAudioStreamGET 流 · 20 ms 帧
VAD

语音活动检测

STT 前 · 单一 VAD 后端 · barge-in

Silero VAD neural

原始 PCM 上的 neural ONNX。语音起始、静音窗口、Agent 说话时的 barge-in。

Amplitude VAD

峰值振幅阈值,零依赖。不需要 neural VAD 时的轻量替代方案。

Stop-speaking plan

代码强制 · barge-in

Caller 可在 Agent 回复中途打断 — 词数阈值、打断后退避、Agent 说话时更严格的 VAD。

STT

语音识别

云端或本地 · 流式或批处理 · 可选自 8 kHz 上采样

云端

公有云厂商 API。

  • 流式Deepgram · AssemblyAI · Speechmatics
  • 批处理灵活的 OpenAI 兼容端点

本地部署

网络内 sidecar — 无云 egress。

  • 流式本地 WS 流 (sherpa-onnx sidecar)
  • 批处理灵活的 OpenAI 兼容端点
EOT

轮次提交

Patch 重点 · LLM 前单一 authority

STT 仅在 caller 轮次结束后才向 LLM 提交 transcript chunk。由 STT 模型选择路径:流上的 vendor end-of-turn,或 Smart Turn — 在 VAD 暂停后从 caller 语音评分轮次完整度的 neural 编排模块。

Smart Turn neural

编排模块

在语音暂停后评分轮次完整度,然后提交给 LLM。用于 STT 模型无内置 turn detection 时 — 如 Whisper、Nova、本地 batch。

Provider EOT vendor

随 STT 模型提供

  • Deepgram Flux流上 end-of-turn
  • AssemblyAI U3内置 turn detection
  • Speechmatics内置 turn detection
LLM

语言模型

云端或本地 · OpenAI 兼容流式

云端

托管推理与路由 API。

  • 网关OpenAI · OpenRouter · Groq · xAI
  • 模型数千 OpenAI 兼容模型

本地部署

本地或数据中心 GPU — 无云 egress。

  • 开发Ollama · 本地模型与 edge
  • 推理vLLM · SGLang · 生产 GPU
Ollama
ACC

句子流式

编排模块 · LLM delta → TTS 粒度块

Sentence accumulator

编排模块

将 LLM token 流缓冲为句子,每句完成即 dispatch 给 TTS — caller 在生成继续时即可听到回复。并行 TTS,有序回放至 3CX。

TTS

语音合成

云端或本地 · 可选降采样至 8 kHz 供 3CX

云端

托管语音 API — WebSocket 或 HTTP。

  • 流式ElevenLabs · Cartesia · Deepgram Aura
  • 批处理灵活的 OpenAI 兼容端点

本地部署

本地 sidecar — 无云 egress。

  • 流式本地 WS 流 (Kokoro WS sidecar)
  • 批处理灵活的 OpenAI 兼容端点
OUT

音频输出

3CX Call Control API · barge-in 循环

postAudioStreamPOST 流 · 20 ms PCM

Operations Dashboard

  • 在同一处控制与管理 Realtime / Pipeline agent stack。
  • 在 STT、LLM、TTS 或单一 speech-to-speech runtime 中组合本地、云端与混合阶段。
  • Live Agent Activity — 当前与最近通话、transcript、agent 回复与 tool calls。
  • Outbound Missions & Automations — 跟踪 active、scheduled 与 in-call 工作。
  • Vex、Knowledge Base 与 Ollama embeddings 的 platform services 健康状态。
Operations dashboard
Operations dashboard

Agent Runtime

  • 从 role、caller state、routing、prompt、tools 与 playbooks 组合 agent — 不是单一 system prompt。
  • Per-tool Behavior playbooks 与 Runtime hooks — 在 privileged tools 执行前强制 required state 与 call-routing。
  • Working memory — 跨 turn、tools 与 consult legs 共享的 structured caller state。
  • 按 agent 组合 built-in call-control、MCP 与 webhook tools。
  • 同一 runtime 覆盖 inbound calls 与 outbound missions。
  • Cross-agent handoffs 与 attended transfer 等复杂 telephony 操作。
  • Role presets 作为基线 — 创建后仍可完整编辑。
Agent configuration
Agent configuration

Knowledge Base

  • 通过 Docker 一键部署本地 RAG。
  • 基于 SQLite、sqlite-vec 与 Nomic embeddings。
  • 在所有 provider 与 runtime 模式间共享。
  • 切换模型时无需迁移。
  • 兼容支持 tool calling 的任意模型。
  • 在 dashboard 中直接上传与管理文档。
  • 支持 PDF、Markdown 与纯文本来源。
Knowledge Base
Knowledge base

MCP Integration

  • 内置 3CX MCP server,用于 telephony 操作。
  • 联系人查找、分机发现、routing 与 call transfer。
  • 通过 API 集成支持自定义 MCP server。
  • 在 Realtime 与 Pipeline 架构间共享。
  • 在不修改核心逻辑的情况下扩展 agent 行为。
  • MCP server 连接后,可在 agent 设置中轻松配置每个 agent 的 tool filtering。
MCP Integration
MCP integration

Model Quality Evaluation

  • 适用于 Pipeline 架构。
  • Agent 对 Agent evaluation 框架。
  • 基于 agent 配置动态生成 test scenarios。
  • 自动包含 Knowledge Base、routing 与 tool usage 场景。
  • 在部署配置变更前检测回归。
  • 在相同 agent setup 下比较模型。
Model quality evaluation
Model quality evaluation

Stack Cost Analysis

  • Realtime 与 Pipeline 架构分别追踪成本。
  • Stack 变更后 active sessions 自动归档。
  • 比较历史配置与 provider 组合。
  • 在支持的 provider 上自动同步定价(如 OpenRouter)。
  • 不支持的 provider 支持手动价格 override 与更新追踪。
  • 可选的 self-hosted 组件 infrastructure 成本核算。
Stack Cost Analysis
Stack cost analysis

Performance Monitoring

  • Realtime 响应延迟监控。
  • Pipeline 各 runtime 组件的延迟分解。
  • 对话中的 turn 级性能追踪。
  • 快速定位 active stack 中的瓶颈。
  • 比较不同配置下的性能表现。
  • 内置 diagnostics,用于优化与故障排查。
Performance monitoring
Performance monitoring

Vex

  • 平台管理员 copilot — 与电话上的 voice stack 分离的 text LLM。
  • 通过带 preview 与 confirm 的 guided draft flow 创建与编辑 voice agent。
  • 在 chat 中管理 outbound mission、task board 与 mission lifecycle。
  • 调度 batch outbound automation — 未接来电回拨、每日 dial run 等。
  • 配置 connector 后可在 chat 中使用 PBX 与 custom MCP — call history、phonebook、外部 API。
  • proactive platform alerts 与 on-demand 文档 — 与 operator 会话 tab 分离。
Platform administrator
Platform administrator