Context

Magik AI is a web and mobile application for interactive media generation that I built as part of my freelance and personal projects (2020 – 2025). It runs on open-source AI models deployed on a RunPod GPU cluster for distributed inference. Around the models sit GenAI pipelines (RAG, fine-tuning, ComfyUI), automatic upscaling, AI agents and n8n workflows that automate media production.

Problem

Generating media with AI models is compute-heavy and bursty. A product built on it has to decide which models to use, where to run them and how to turn raw model output into something finished, without the cost and rigidity of a fixed GPU fleet or a single hosted API. Media generation is also multi-step: a raw generation usually needs upscaling and further processing before it is usable, so the platform has to orchestrate a chain of steps rather than a single model call.

Architecture decisions

Open-source models instead of a hosted API

The platform is built on open-source AI models, which can be fine-tuned and run on infrastructure the team controls.

Trade-off: running your own models means owning deployment, scaling and upgrades. In exchange you control the model, its tuning and its cost profile.

A RunPod GPU cluster for distributed inference

Inference is distributed across a RunPod GPU cluster, so generation work can be spread over several GPUs instead of queuing on one.

Trade-off: distributed inference adds scheduling and failure handling. It lets throughput scale with the number of GPUs.

GenAI pipelines: RAG, fine-tuning and ComfyUI

The GenAI pipelines combine RAG, fine-tuning and ComfyUI, with automatic upscaling as a step that improves the finished output.

Trade-off: node-based pipelines such as ComfyUI make workflows composable and repeatable, but they add a layer to learn and to version.

Automation with AI agents and n8n workflows

AI agents and n8n workflows automate media production, chaining generation, upscaling and the surrounding steps so that finished media does not depend on manual hand-offs.

Trade-off: automation reduces manual work but needs monitoring, because an unattended workflow can fail silently.

Outcome

Magik AI is a working web and mobile platform where interactive media is generated on open-source models, served by distributed GPU inference and produced through automated pipelines.

Stack

  • RunPod
  • Open-source models
  • RAG
  • Fine-tuning
  • ComfyUI
  • n8n
  • AI agents