Skip to content
Mihail Leybuk-Galin — home

NeuroFlows

Architecting Autonomous Business Workflows

NeuroFlows is a multi-tenant SaaS platform designed to orchestrate complex, agentic AI workflows. We built a scalable foundation capable of handling real-time speech-to-text, sophisticated RAG pipelines, and deterministic business logic for diverse enterprise clients.

Project website (opens in a new tab)
Domain
AI / SaaS
Role
Lead Architect

The Engineering Context

The core challenge of NeuroFlows was not just integrating LLMs, but orchestrating them within a rigid, deterministic business environment. Clients needed the flexibility of generative AI combined with the reliability of traditional state machines.

We approached this by decoupling the "intelligence" from the "execution." LLMs were treated as unreliable co-processors within a robust orchestration engine, requiring extensive fallback mechanisms, prompt versioning, and rigorous output validation schemas.

Technology Stack

Infrastructure
AWS / EKS
Backend
Go / Python
Databases
PostgreSQL / Pinecone
AI/ML
LangChain / Whisper
Message Broker
Apache Kafka

Architectural Imperatives

Key Decisions

  • Event-Driven Orchestration

    Moved away from synchronous API calls to an asynchronous, Kafka-backed event architecture. This prevented long-running LLM inferences from blocking critical UI threads and allowed for robust retry mechanisms on failure.

  • Multi-Tenant RAG Isolation

    Implemented strict logical separation within the vector database. Each tenant's embeddings were namespace-isolated, with application-level middleware enforcing role-based access control before any similarity search execution.

  • Agentic State Management

    Designed a custom state machine to track multi-step agent interactions. This provided auditability, allowed human-in-the-loop interventions, and ensured non-deterministic LLM paths always converged on valid business states.

Business Impact

The architecture enabled rapid onboarding of enterprise clients, handling significant throughput while maintaining strict latency SLAs for real-time transcription and generative responses.

System Uptime
99.9%
P95 Inference Latency
<200ms
Reduction in Ops Costs
40%
Workflows Executed / Mo
1.2m