Skip to main content

OpenMolt

OpenMolt is a programmatic AI Agent System for Node.js. Define agents, wire them to LLMs and external tools, and run autonomous multi-step workflows — all in TypeScript.

npm install openmolt

What is an agent?

An agent is an autonomous loop. It receives a task, reasons about it with an LLM, calls tools, and repeats until it has a final answer. OpenMolt's loop is called the Maestro loop.

┌─────────────────────────────────────────┐
│ Maestro Loop │
│ │
│ Input ──► LLM ──► Commands │
│ ▲ │ │
│ │ ▼ │
│ History ◄── Execute │
│ (tools, waits...) │
│ │ │
│ finish ──► Output │
└─────────────────────────────────────────┘

Key features

FeatureDescription
Multi-provider LLMsOpenAI (GPT-4o, o1, o3), Anthropic (Claude), Google (Gemini)
30+ built-in integrationsGmail, Slack, Telegram, GitHub, Stripe, Airtable, fal.ai, S3 …
Structured outputValidate agent output against a Zod schema
MemoryLong-term and short-term memory stores with persistence callbacks
SchedulingInterval and daily cron-style schedules
Custom integrationsRegister your own HTTP or SDK-based tools
TypeScript-firstFull type inference on configs, schemas, and events

Quick look

import OpenMolt from 'openmolt';
import { z } from 'zod';

const om = new OpenMolt({
llmProviders: { openai: { apiKey: process.env.OPENAI_API_KEY } },
});

const agent = om.createAgent({
name: 'Researcher',
model: 'openai:gpt-4o',
instructions: 'You are a helpful research assistant.',
integrations: [
{
integration: 'httpRequest',
credential: { type: 'custom', config: {} },
scopes: 'all',
},
],
outputSchema: z.object({ summary: z.string(), sources: z.array(z.string()) }),
});

const result = await agent.run('Summarise the main use cases for WebAssembly.');
console.log(result.summary);

Next steps