Big News: Socket raises $60M Series C at a $1B valuation to secure software supply chains for AI-driven development.Announcement
Sign In

condukt

Package Overview
Dependencies
Maintainers
1
Versions
30
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

condukt

Composable AI agent workflow framework — execution, state, orchestration, runtimes, UI

latest
Source
npmnpm
Version
0.6.19
Version published
Weekly downloads
73
121.21%
Maintainers
1
Weekly downloads
 
Created
Source

condukt

Composable AI agent workflow framework. Define pipelines as directed graphs, execute them with fan-out parallelism and bounded loops, persist state through event sourcing, and visualize everything with a dark-themed React UI.

npm tests license

npm install condukt

Why condukt

  • Graph-based execution — DAG scheduler with topological ordering, fan-out/fan-in, and bounded loop-back
  • Four node typesagent (LLM), deterministic (pure function), gate (human approval), verify (iterative validation)
  • Event-sourced state — every execution event is persisted; projections are recomputed from the log
  • Runtime-agnostic — plug in any LLM backend via the AgentRuntime interface
  • Modular imports — 12 sub-path exports; consumers install only what they use
  • Full React UI — interactive flow graph, node panels, tool display, status bar — all dark-themed with warm charcoal tokens

Quick start

Define a pipeline

import { agent, deterministic, gate } from 'condukt';
import type { FlowGraph } from 'condukt';

const pipeline: FlowGraph = {
  nodes: [
    agent('research', { prompt: 'Research the topic...' }),
    deterministic('transform', async (input) => {
      return { summary: extract(input), confidence: 0.94 };
    }),
    gate('review', { allowedResolutions: ['approved', 'rejected'] }),
  ],
  edges: [
    { source: 'research', target: 'transform', action: 'default' },
    { source: 'transform', target: 'review', action: 'default' },
  ],
};

Execute it

import { run, validateGraph } from 'condukt';
import { StateRuntime } from 'condukt/state';
import { FileStorage } from 'condukt/state/server';
import { createBridge } from 'condukt/bridge';

validateGraph(pipeline);

const storage = new FileStorage('.flow-data');
const state = new StateRuntime(storage);
const bridge = createBridge(state, runtime);

const execution = await bridge.launch(pipeline, { scenario: 'my-workflow' });

Add the UI

import { FlowGraph } from 'condukt/ui/graph';
import { NodeDetailPanel } from 'condukt/ui/core';
import { useFlowExecution } from 'condukt/ui';
import 'condukt/ui/style.css';

Architecture

┌─────────────────────────────────────────────────────────┐
│  Your code                                              │
│  FlowGraph { nodes, edges }                             │
│  agent() · deterministic() · gate() · verify()          │
└────────────────────────┬────────────────────────────────┘
                         │
┌────────────────────────▼────────────────────────────────┐
│  Execution         src/                                 │
│  DAG scheduler · fan-out · fan-in · bounded loop-back   │
│  Emits 16 event types as a stream                       │
└────────────────────────┬────────────────────────────────┘
                         │
┌────────────────────────▼────────────────────────────────┐
│  State             state/                               │
│  Pure reducer · JSONL persistence · crash recovery      │
└────────────────────────┬────────────────────────────────┘
                         │
┌────────────────────────▼────────────────────────────────┐
│  Bridge            bridge/                              │
│  launch · stop · resume · retry · skip · approve        │
└────────────────────────┬────────────────────────────────┘
                         │
┌────────────────────────▼────────────────────────────────┐
│  Runtimes          runtimes/                            │
│  AgentRuntime interface → any LLM backend               │
│  Built-in: CopilotBackend · SdkBackend · MockRuntime    │
└────────────────────────┬────────────────────────────────┘
                         │
┌────────────────────────▼────────────────────────────────┐
│  UI                ui/                                  │
│  FlowGraph · MiniPipeline · NodePanel · FlowStatusBar   │
│  ResponsePartRenderer · 50+ tool formatters             │
│  Warm charcoal dark theme · React 19 + React Flow       │
└─────────────────────────────────────────────────────────┘

Imports

condukt is split into sub-path exports so you only pull in what you need.

ImportWhat you get
conduktCore engine — run, validateGraph, node factories, types, events
condukt/stateStateRuntime, MemoryStorage, reducer
condukt/state/serverFileStorage (JSONL persistence, Node.js only)
condukt/bridgecreateBridgeBridgeApi
condukt/runtimes/copilotSubprocessBackend, SdkBackend, adaptCopilotBackend
condukt/runtimes/mockMockRuntime for deterministic tests
condukt/uiFull UI — hooks, components, graph (requires react, @xyflow/react)
condukt/ui/coreDesign-system primitives — no xyflow dependency
condukt/ui/graphFlowGraph, FlowEdge (requires @xyflow/react)
condukt/ui/tool-displayResponsePartRenderer, SubagentSection, tool formatters
condukt/themeTailwind preset, STATUS_COLORS, design tokens
condukt/utilsShared utilities

Node types

FactoryPurposeExample
agent(id, config)LLM call with crash recovery, setup/teardown hooksResearch, analysis, code generation
deterministic(id, fn)Pure async function, no LLMParsing, validation, API calls
gate(id, options)Pauses execution until a human resolves itApproval workflows, review checkpoints
verify(id, config)Iterative agent + property checks, retries until passingOutput validation, quality gates

Graph features

  • Fan-out — one node fans out to multiple parallel branches
  • Fan-in — multiple branches converge into a single node (waits for all)
  • Loop-back — edges that point backward with maxIterations bounds and loopFallback strategy
  • Per-node timeout — individual deadline per node
  • Abort / Resume — stop mid-execution and pick up where you left off

UI components

The UI layer is a complete React component library with a warm charcoal dark theme.

Graph visualizationFlowGraph renders the full interactive DAG via React Flow. MiniPipeline provides a compact thumbnail in three modes: graph (≤20 nodes), bar (21–50), and summary (>50).

Node detailNodeDetailPanel is a zero-config convenience wrapper. For full control, use the compound NodePanel.* components: Header, Info, ErrorBar, Gate, Controls, Output.

Tool displayResponsePartRenderer handles tool calls, thinking blocks, text, and sub-agent grouping. Ships with 50+ built-in tool formatters and a renderToolExpanded callback for custom rendering.

HooksuseFlowExecution (SSE + REST), useNodeOutput (streaming per-node), useAutoSelectNode, useNodeNavigation.

Tailwind preset

// tailwind.config.js
const { flowFrameworkPreset } = require('condukt/theme');

module.exports = {
  presets: [flowFrameworkPreset],
  content: ['./src/**/*.{ts,tsx}', './node_modules/condukt/dist/**/*.js'],
};

Testing

npm test              # 659 tests across 50 suites
npm run typecheck     # tsc --noEmit
npm run build         # TypeScript → dist/

License

MIT

Keywords

pipeline

FAQs

Package last updated on 31 Mar 2026

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts