⚡

Content Automation Platform

Architecture & Technical Verification Portfolio
Evidence-Driven Architecture Portfolio

Engineered for High-Throughput Media Assembly & Autonomous Social Distribution

Explore the verified systems architecture of the Content Automation Platform: an autonomous, multi-tenant media production suite powered by 16 decoupled n8n workflow engines, multi-provider AI failover (Groq & Gemini), Windows SAPI / FFmpeg media synthesis, and idempotent fail-closed publishing to YouTube and Meta.

Workflow Orchestration
16 Engines
Decoupled n8n state machines with rights verification & auto-recovery
PostgreSQL State Model
35 Tables
Sequential migrations (001–008) with pessimistic lease locks
Dynamic AI Failover
< 1.2s Latency
Groq Llama 3.3 primary with automated Gemini 2.5 Pro circuit breaker
Social Ingress & Publishing
100% Idempotent
Token-locked resumable upload preventing duplicate social dispatch
Master System Architecture
Complete runtime component topology, trust boundaries, and network flows

System Overview & Ingress Perimeter

The Content Automation Platform organizes content production across three operational tiers: an operator-facing CoreUI dashboard served by an Express BFF API (port 3000), 16 decoupled n8n workflow engines (port 5678) acting as distributed state machines, and a specialized background worker tier coordinating video assembly (FFmpeg), audio synthesis, and visual quality assurance.

Archify Type architecture
Delivery Receipt d633dad7-dd0b
Quality Profile showcase
Validation Status PASSED (9/9)
Architectural Pillars & Source Evidence

01. Decoupled State Machine Orchestration

Instead of a monolithic backend worker, business processes are partitioned into 16 discrete n8n workflow definitions. Each workflow maintains an independent error-handling boundary, executes idempotent state mutations, and delegates heavy media compute to isolated Node.js child processes.

  • Reviewed
    workflows/01_master_orchestrator.json
    Coordinates cron triggers and dispatches trend research jobs
  • Reviewed
    workflows/12_supervisor_sentinel.json
    Deadlock detector and lease reaper for abandoned worker jobs
  • Reviewed
    workflows/13_global_error_handler.json
    Centralized classification of network, quota, and schema failures

02. Pessimistic Lease Locking & Concurrency

High-throughput distributed media generation requires strict concurrency control. The PostgreSQL database uses sequential migrations to define a resilient job queue with row-level locks (SELECT FOR UPDATE SKIP LOCKED) and 30-second worker heartbeats to guarantee at-most-once execution.

  • Test Verified
    database/schema.sql (lines 45–120)
    Defines jobs_queue, content_items, and worker_heartbeats tables
  • Reviewed
    database/migrations/001_initial_schema.sql
    Foreign key constraints and immutable audit history triggers
  • Test Verified
    tests/database.test.js
    Asserts lease expiration, renewal, and deadlock protection

03. AI Provider Resiliency & Quota Circuit Breaker

Procedural script generation leverages Groq's high-speed Llama 3.3 70B model for primary synthesis. When rate limits (HTTP 429) or service outages (503) occur, requests automatically fail over to Google Gemini 2.5 Pro. If all providers exhaust quotas, the circuit breaker opens into a 60-second cooldown.

  • Reviewed
    workers/original_generator.js (lines 55–130)
    Multi-provider adapter implementing exponential backoff
  • Reviewed
    workflows/16_original_generation.json
    Dynamic provider routing node with quota validation fallback
  • Reviewed
    database/migrations/005_quotas.sql
    Provider quota ledger tracking rolling token expenditure

04. Fail-Closed Rights & Human-in-the-Loop Review

Copyright risk and platform policy compliance are enforced before synthesis begins. Unlicensed source content is rejected at Workflow 04. Rendered video drafts undergo automated black-frame and audio QA (port 9100) before presenting in the CoreUI approval modal for explicit human sign-off.

  • Reviewed
    workflows/04_rights_verification.json
    Automated Creative Commons and license attribution check
  • Reviewed
    workers/qa_worker.js (port 9100)
    FFmpeg freeze-frame detector and silence threshold analyzer
  • Reviewed
    server/index.js (/api/approvals)
    Idempotent approval gateway generating signed publishing tokens
Implementation Truth Matrix & Verification Status
Subsystem Source Location Evidence Artifact Truth Classification Architectural Role
Orchestration workflows/01-16_*.json 16 n8n workflow definitions Code Reviewed Distributed state machines for trend discovery, synthesis, QA & distribution
State Engine database/schema.sql 35 SQL table schemas + 8 migrations Test Verified Pessimistic lease locking, audit logging, and quota ledger
BFF REST API server/index.js Express server on port 3000 Code Reviewed Operator authentication, approval endpoints, and telemetry aggregation
Video Synthesis workers/original_generator.js Node worker + Windows SAPI & FFmpeg Code Reviewed Procedural script generation, TTS audio rendering, and subtitle burn-in
Technical QA workers/qa_worker.js FastAPI / Express worker on port 9100 Code Reviewed Automated detection of frozen frames, audio clipping, and black screen
Social Publisher workers/youtube_publisher.js Google API Client v3 resumable upload Code Reviewed Fail-closed YouTube and Meta distribution with token idempotency
Operator UI frontend/src/ CoreUI React 18 + TypeScript Code Reviewed Pipeline control dashboard, job monitoring, and approval review modal
Automated Tests tests/ 7 test suites (database, api, workers) Test Verified Regression suites verifying lease lifecycle, schema integrity & error traps
Operational Boundaries & Production Disclosures

⚠️ Honest Engineering Disclosures & Environment Assumptions

To ensure complete integrity in technical recruitment and architectural evaluations, the following boundaries must be explicitly noted: