← Home
HeliosAI Studio·Architecture
Open portal →
Three-tier design

Architecture

Three tiers, each shippable independently. POC proves the pipeline. On-premises adds auth, persistence, and observability. Production adds queue-based throughput and owned storage. Each tier is a superset of the previous — no rework, only additions.

Tier 0

Proof of Concept (POC)

Current

Brief in → video URL out.

BrowserClientNext.js / VercelIntegration layerHeyGenVideo Agent API v3Redishelios:briefsOn-Premise Storagepresigned PUTVideo Agent API v3POST /api/generate/api/status · 4s pollvideo_urlhelios:briefs/api/push-video

Arch decisions

Concurrency blockClient-side ref blocks re-submission while a job is in flight — prevents duplicate HeyGen sessions from a double-click or fast re-submit.
60-min timeoutMAX_POLLS ceiling · relies on HeyGen's own failed signal, not a timer.
Failure handlingHeyGen failed: surfaced to UI, user re-submits. 429: Retry-After returned to client with live countdown. Transient errors: 3 retries before error banner.
Cost trackingEach video captures credit cost and render duration from the HeyGen API response, displayed per-video in the portal.
Tier 1

On-Premises

Authentication, job persistence, and direct on-premise delivery.

BrowserClientSSOApp ServerIntegration layerHeyGenVideo Agent API v3CacheRedis · TTLON-PREMISE STORAGEPostgresmetadataBlob Storagevideo filesTTL cacheauto-push2nd hit miss

Arch decisions

Helios IdP (SAML / OIDC)Org-scoped sessions tied to Helios's identity provider; HeyGen API key stays server-side only.
Postgres (self-hosted)orgs · users · briefs · jobs schema; row-level security by org_id; status tracked in DB.
Webhook + auto-pushHeyGen POSTs to /api/webhook on completion; HMAC-SHA256 verified; MP4 written directly to On-Premise Blob.
IdempotencyEvery job gets a deterministic key. Worker checks Postgres before calling HeyGen — prevents duplicate renders on queue retry.
SecurityHeyGen API key: server env var only. Webhook: HMAC-SHA256 verified. Blob: private, pre-signed URLs. All data scoped by org_id (row-level security).
Tier 2

Production

Helios internal product at scale — doc ingestion, async queue, Enablement Tool delivery.

BrowserInternal UISSOApp ServerIntegration layerHeyGenVideo Agent API v3CMSoptionalJob Queueretry · DLQON-PREMISE STORAGEBlob Storagevideo filesPostgresmetadata · jobsEnablement Tooloptionalbrief triggerenqueuedispatch / retryauto-pushpublish

Arch decisions

Job Queue (retry + DLQ)Async dispatch decouples submission from rendering; automatic retry on transient failure; dead letter queue alerts on spike.
Doc ingestionPDF / slide deck parsed into the 6-section brief schema; knowledge base search auto-suggests content from internal docs.
Enablement Tool integrationVideo auto-published to seller's library (Highspot, Seismic, etc.) on webhook completion.

Technology decisions

ConcernTier 0 — POCTier 1 — On-premisesTier 2 — Production
FrameworkNext.js + VercelApp server (self-hosted)--
AI / ScriptHeyGen Video Agent----
AuthNoneSAML / OIDC (Helios IdP)--
Job queueNone (sync poll)None (webhook)Internal queue (retry + DLQ)
Metadata DBRedis (briefs only)Postgres (self-hosted)--
Video storageHeyGen CDN URLOn-Premise Blob← same + CDN
Brief sourceManual formManual formForm + doc upload / internal search
Video deliveryManual downloadAuto-push (webhook)Enablement Tool (auto-publish)
MonitoringVercel AnalyticsOn-prem tools--
Status deliveryREST polling (4s)SSE + webhookSSE + queue events