Chapter 2 — Architecture
Installation Environment
The network and communication environment of the framework, its interconnections to the PBX and VoiceBot solution, multi-tenancy principles and storage sizing.

Figure 3 — Installation environment.
Components and endpoints
SIP Trunk
Connects the framework to a SIP trunk provider using trunk username and password authentication, enabling VoIP telephony features such as receiving calls.
Software-based PBX 4573/TCP
The Private Branch Exchange software component managing internal and external phone calls.
AGI — Asterisk Gateway Interface 4537/TCP
Protocol for interfacing the telephony system with external software modules. It connects the PBX to the VoiceBot logic, enabling dynamic call handling, rerouting and hand-over.
SIP Connector HTTP
Bridges SIP-based telephony and HTTP-based services, allowing the assistant to process SIP messages via OpenBrain services.
AMQP 5672/TCP
Asynchronous message passing between framework components, ensuring reliable communication between microservices such as routing queries to AI modules.
OpenBrain Integration API https://
Secured HTTPS endpoint for receiving messages. The primary interface used to send chat or control messages to the assistant.
BlockFlow Integration API https://
Chatbot endpoint for exchanging messages between the framework and the chatbot solution. It receives user commands in textual format and sends replies through the OpenBrain Integration API.
AI modules AMQP
Speech-to-Text, Text-to-Speech, speech segmentation, and noise removal and silence detection. They process user speech and synthesise responses, interacting with other components over AMQP.
Multi-tenancy and environments
The framework supports multiple organisations and project instances on the same infrastructure.
- Shared infrastructure — all tenants use a shared PostgreSQL database and DMS. PostgreSQL holds structured metadata: user accounts, access logs, call metadata (timestamp, duration, participants), transcription results, call logs, indexing information and audit trails. The DMS holds unstructured and binary data: audio recordings, waveform files and uploaded documents associated with a session.
- Per-tenant SIP configuration — each tenant is assigned a dedicated SIP trunk configuration used for both inbound and outbound calls, isolating telephony resources per tenant.
- Environment isolation within a tenant — multiple projects can exist under one tenant, sharing the SIP configuration but logically separated in project logic, call flows, logging and monitoring.
Database and DMS storage requirements
PostgreSQL stores only metadata about conversations, recordings and transcriptions — file names and paths, timestamps, conversation identifiers, audio duration, and transcription status and text (plain text or JSON). Because no raw audio is stored in the database, the footprint stays minimal: even high-volume systems typically require only a few gigabytes over extended operation.
The DMS stores WAV recordings. The estimate below covers one concurrent user over one month of continuous recording.
Sampling rate 8,000 samples/second
Bit depth 16-bit (2 bytes/sample)
Channels mono (1 channel)
Duration/month 60 min × 24 h × 30 d = 43,200 min = 2,592,000 s
8,000 × 2 × 2,592,000 ≈ 41 GB per user per month per continuously active channel