# pipecat-ai/pipecat-examples architecture

> Architecture diagram of the GitHub repository pipecat-ai/pipecat-examples, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-02-10). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/pipecat-ai/pipecat-examples
- Repository: https://github.com/pipecat-ai/pipecat-examples

## Overview

##### Project type and purpose
- This is an open-source “monorepo” of example applications built on the Pipecat framework (voice and multimodal AI). It’s not a single product but a curated collection of standalone demos (each under its own folder) that illustrate different Pipecat use cases: telephony, web clients, real-time APIs, multimodal experiences, translation, deployment, observability, testing, etc.

##### File structure
- Top-level artifacts:
- .github/workflows → CI definitions (build, test, formatting)
- scripts/ → helper scripts (smoke tests, demo runners, linters)
- deployment/ → deployment patterns (Fly.io, Modal, Pipecat Cloud, AWS)
- open-telemetry/ → monitoring & tracing examples
- runner-examples/ → Python runner tutorials
- dozens of example directories (simple-chatbot, twilio-chatbot, p2p-webrtc, storytelling-chatbot, etc.), each self-contained with its own client (web, React, React Native, Android, iOS, TypeScript) and server or bot code (Python, Dockerfiles, env configs, pcc-deploy.toml).

- Common patterns per example:
- client/ subdirectory—static or framework-based UI
- server/ or bot.py—Pipecat bot implementation
- Dockerfile / pyproject.toml / env.example—runtime & dependency config
- pcc-deploy.toml—Pipecat Cloud deployment metadata

##### README insights
- The README categorizes examples by theme (Telephony & Voice Calls, Web & Client Apps, Real-time APIs, Multimodal & Creative, etc.) and highlights prerequisites (Python 3.10+, API keys).
- It positions this repo as intermediate/advanced demos, pointing to the main Pipecat quickstart for basics.

a. Main components (grouped)
- Monorepo Root: CI, scripts, shared tooling
- Example Categories:
- Telephony & Voice: phone-chatbot, twilio-chatbot, plivo-chatbot, exotel-chatbot, ivr-navigation
- Web & Client: simple-chatbot, push-to-talk, websocket, instant-voice, p2p-webrtc
- Real-time APIs: word-wrangler-gemini-live, aws-strands
- Multimodal & Creative: storytelling-chatbot
- Translation & Localization: daily-multi-translation
- Support/Educational: studypal
- Advanced Features: local-smart-turn, daily-custom-tracks, local-input-select-stt, bot-ready-signalling
- Deployment Patterns: deployment/*
- Monitoring & Analytics: open-telemetry/*
- Testing & Development: freeze-test, runner-examples

b. Relationships & interactions
- Within each example:
[Client] ←HTTP/WebSocket/API→ [Server/Bot (Python + Pipecat core)]
[Server/Bot] →External AI services (OpenAI, Deepgram, AWS Strands, Gemini Live)
Docker or pcc-deploy defines containerization or cloud deployment.
- Shared cross-cutting: CI pipelines test/fmt all examples; scripts orchestrate demos across examples.

c. Architectural patterns & principles
- Each example follows a micro-application pattern (self-contained client + server)
- Uniform configuration (pyproject.toml + env.example) for consistency
- Separation of concerns: frontends in JavaScript/TypeScript or native (Android/iOS/React Native) and backends in Python bots
- Transport-layer abstraction (HTTP, WebSocket, WebRTC, PSTN, SIP)

d. Key technologies & frameworks
- Pipecat framework (core)
- Python 3.10+, FastAPI or built-in HTTP servers
- Frontend stacks: React, Next.js, Vite+TS, React Native, Android (Kotlin), iOS (SwiftUI)
- Docker for local containerization
- Cloud deployment via Pipecat Cloud (pcc), Fly.io, Modal, AWS
- Observability: Langfuse, Jaeger

## Diagram (Mermaid)

```mermaid
flowchart TD
    %% Infrastructure Layer
    subgraph "Monorepo Infrastructure"
        CI["CI Pipelines"]:::infra
        Scripts["Shared Scripts & Tooling"]:::infra
        Deployment["Deployment Patterns"]:::infra
        Observability["Observability & Monitoring"]:::infra
        Runner["Runner Tutorials"]:::infra
        Testing["Testing & Freeze Tests"]:::infra
    end

    %% Telephony & Voice Demos
    subgraph "Telephony & Voice Demos"
        phone["phone-chatbot"]:::telephony
        twilio["twilio-chatbot"]:::telephony
        plivo["plivo-chatbot"]:::telephony
        exotel["exotel-chatbot"]:::telephony
        ivr["ivr-navigation"]:::telephony
    end

    %% Web & Client Demos
    subgraph "Web & Client Demos"
        simple["simple-chatbot"]:::web
        ptt["push-to-talk"]:::web
        websocket["websocket"]:::web
        instant["instant-voice"]:::web
        p2p["p2p-webrtc"]:::web
    end

    %% Real-time API Demos
    subgraph "Real-time API Demos"
        word["word-wrangler-gemini-live"]:::realtime
        aws["aws-strands"]:::realtime
    end

    %% Multimodal & Creative Demos
    subgraph "Multimodal & Creative Demos"
        storytelling["storytelling-chatbot"]:::creative
    end

    %% Translation & Localization Demo
    subgraph "Translation & Localization Demo"
        multi["daily-multi-translation"]:::creative
    end

    %% Educational & Support Demo
    subgraph "Educational & Support Demo"
        studypal["studypal"]:::creative
    end

    %% Advanced Feature Demos
    subgraph "Advanced Feature Demos"
        signalling["bot-ready-signalling"]:::creative
        tracks["daily-custom-tracks"]:::creative
        localstt["local-input-select-stt"]:::creative
    end

    %% External Services
    subgraph "External AI & Telephony Providers"
        AI["AI Services (OpenAI, Deepgram, Gemini, AWS)"]:::gray
        TP["Telephony Providers (Twilio, Plivo, Exotel)"]:::gray
    end

    %% CI & Scripts Span All Examples
    CI -.-> phone
    CI -.-> simple
    CI -.-> word
    CI -.-> storytelling
    CI -.-> multi
    CI -.-> studypal
    CI -.-> signalling

    Scripts -.-> phone
    Scripts -.-> simple
    Scripts -.-> word
    Scripts -.-> storytelling
    Scripts -.-> multi
    Scripts -.-> studypal
    Scripts -.-> signalling

    %% Telephony integrations
    phone -->|"PSTN/SIP"| TP
    twilio -->|"API"| TP
    plivo -->|"API"| TP
    exotel -->|"API"| TP
    ivr -->|"IVR Flow"| TP

    %% Web & Client interactions
    simple -->|"HTTP/WebSocket"| AI
    ptt -->|"WebSocket"| AI
    websocket -->|"WebSocket"| AI
    instant -->|"HTTP"| AI
    p2p -->|"WebRTC"| AI

    %% Real-time APIs
    word -->|"API Calls"| AI
    aws -->|"API Calls"| AI

    %% Multimodal & Creative
    storytelling -->|"Media Processing"| AI

    %% Translation & Localization
    multi -->|"Translation API"| AI

    %% Educational & Support
    studypal -->|"Query Fulfillment"| AI

    %% Advanced Features
    signalling -->|"Signaling API"| AI
    tracks -->|"Audio Generation"| AI
    localstt -->|"Local STT"| AI

    %% Click Events
    click CI "https://github.com/pipecat-ai/pipecat-examples/tree/main/.github/workflows/"
    click Scripts "https://github.com/pipecat-ai/pipecat-examples/tree/main/scripts/"
    click Deployment "https://github.com/pipecat-ai/pipecat-examples/tree/main/deployment/"
    click Observability "https://github.com/pipecat-ai/pipecat-examples/tree/main/open-telemetry/"
    click Runner "https://github.com/pipecat-ai/pipecat-examples/tree/main/runner-examples/"
    click Testing "https://github.com/pipecat-ai/pipecat-examples/tree/main/freeze-test/"
    click phone "https://github.com/pipecat-ai/pipecat-examples/tree/main/phone-chatbot/"
    click twilio "https://github.com/pipecat-ai/pipecat-examples/tree/main/twilio-chatbot/"
    click plivo "https://github.com/pipecat-ai/pipecat-examples/tree/main/plivo-chatbot/"
    click exotel "https://github.com/pipecat-ai/pipecat-examples/tree/main/exotel-chatbot/"
    click ivr "https://github.com/pipecat-ai/pipecat-examples/tree/main/ivr-navigation/"
    click simple "https://github.com/pipecat-ai/pipecat-examples/tree/main/simple-chatbot/"
    click ptt "https://github.com/pipecat-ai/pipecat-examples/tree/main/push-to-talk/"
    click websocket "https://github.com/pipecat-ai/pipecat-examples/tree/main/websocket/"
    click instant "https://github.com/pipecat-ai/pipecat-examples/tree/main/instant-voice/"
    click p2p "https://github.com/pipecat-ai/pipecat-examples/tree/main/p2p-webrtc/"
    click word "https://github.com/pipecat-ai/pipecat-examples/tree/main/word-wrangler-gemini-live/"
    click aws "https://github.com/pipecat-ai/pipecat-examples/tree/main/aws-strands/"
    click storytelling "https://github.com/pipecat-ai/pipecat-examples/tree/main/storytelling-chatbot/"
    click multi "https://github.com/pipecat-ai/pipecat-examples/tree/main/daily-multi-translation/"
    click studypal "https://github.com/pipecat-ai/pipecat-examples/tree/main/studypal/"
    click signalling "https://github.com/pipecat-ai/pipecat-examples/tree/main/bot-ready-signalling/"
    click tracks "https://github.com/pipecat-ai/pipecat-examples/tree/main/daily-custom-tracks/"
    click localstt "https://github.com/pipecat-ai/pipecat-examples/tree/main/local-input-select-stt/"

    %% Styles
    classDef infra fill:#D8B4FE,stroke:#9D7FEA,color:#000
    classDef telephony fill:#BFDBFE,stroke:#60A5FA,color:#000
    classDef web fill:#BBF7D0,stroke:#34D399,color:#000
    classDef realtime fill:#FED7AA,stroke:#FB923C,color:#000
    classDef creative fill:#A7F3D0,stroke:#5EEAD4,color:#000
    classDef gray fill:#E5E7EB,stroke:#9CA3AF,color:#000
```
