Skip to Content
Loopstack AI Logo

The AI framework.

A complete TypeScript framework built on NestJS + React. Combine agentic loops and deterministic workflows in one state machine powered system, integrate anywhere, with built-in user interface, pause for human input, and resume from where you left off.

Free & open source under BSL license

Composable Building Blocks

Code the logic - Configure the UI

chat.workflow.ts
@Workflow({ uiConfig: __dirname + '/chat.ui.yaml' })
export class ChatWorkflow extends BaseWorkflow {

  @InjectTool() claudeGenerateText: ClaudeGenerateText;

  @Initial({ to: 'waiting_for_user' })
  async setup() {}

  @Transition({ from: 'waiting_for_user', to: 'ready', wait: true })
  async userMessage(payload: string) {
    await this.repository.save(MessageDocument, { role: 'user', content: payload });
  }

  @Transition({ from: 'ready', to: 'waiting_for_user' })
  async llmTurn() {
    const result = await this.claudeGenerateText.call({ ... });
    await this.repository.save(MessageDocument, result.data!);
  }
}

Workflows

Workflows are TypeScript state machines with explicit states and transitions. Mix agentic LLM calls with deterministic steps in the same flow. Pause for human input with wait: true, and state is checkpointed after every step. If something fails, resume from exactly where you left off.

Learn more

Key Benefits

Agentic Meets Deterministic

Drop an LLM call into any point in a deterministic workflow, or nest agents inside structured pipelines. One system, not two bolted together.

State Machine Workflows

Explicit states and transitions, not arbitrary graphs. Formal guarantees about valid paths make workflows easy to reason about, debug, and visualize.

Persistent State

Every step is checkpointed to the database. If a process fails, resume from the last successful state. Works the same for workflow steps and agentic loops.

Built-in Human Interaction

Approvals, forms, confirmations, and clarifications ship as framework primitives. Pause for human input for hours or days and resume cleanly.

Full-Stack on NestJS + React

Dependency injection, modules, guards, and a massive ecosystem out of the box. The React frontend ships end-user applications, not just backend pipelines.

Full Traceability

Every state transition, tool call, and LLM decision is recorded. Replay any execution step by step, audit what happened, and pinpoint exactly where things went wrong.

Ready-Made Registry

Install production-grade tools and workflow templates with a single command. AI providers, OAuth flows, sandboxed code execution, and more - ready to use or customize.

Nested Sub-Workflows

Break complex processes into composable sub-workflows that run independently and report back. Nest them arbitrarily deep - each with its own state, tools, and lifecycle.

Framework, Not a Platform

Extend it like any NestJS app. No vendor lock-in, no external execution engine. Free and open source under the BSL license.

Run and Interact in the browser

Use the built-in ReactJS frontend for running, debugging and organizing automations.

Loopstack Studio workflow example 1

Community Registry

Ready made templates, tools and integrations. Install with a single command.

Terminal
$ loopstack add <package-name>

Supported by:

IFB IS LogoMS Startups Logo