Skip to main content

v3.6.6

Released: March 11, 2026

✨ New Features

Added lua logs --type agent_error to filter logs for execution errors in tools, webhooks, and jobs.

🐛 Bug Fixes

Fixed timezone handling for cron schedules and improved error logging for failed cron jobs.

v3.6.5

Released: March 10, 2026

🔧 Improvements

Extended base URLs for internal service discovery.

v3.6.1

Released: March 2, 2026

🐛 Bug Fixes

interval and once job schedules now compile and push correctly. Previously, the seconds field (interval) and executeAt field (once) were silently dropped during compilation, causing lua push job to fail with:
Push Error: Interval seconds must be at least 60
All three schedule types now work as documented:
// Interval — seconds now correctly sent to server
schedule: { type: 'interval', seconds: 300 }

// Once — executeAt now correctly sent to server
schedule: { type: 'once', executeAt: new Date(Date.now() + 3600000) }

// Cron — was already working
schedule: { type: 'cron', expression: '0 9 * * *' }
Agents that reference imported primitives using instantiation patterns in their config arrays (e.g. jobs: [new MyJob()]) now correctly resolve and compile.
The CLI now exits immediately after completing a command. Previously, a background timer kept the process alive for up to ~1s after all work was done.

v3.6.0

Released: February 27, 2026

✨ New Features

LuaAgent now supports a model property to control which AI model your agent uses. Specify a static model string or a dynamic resolver function.
import { LuaAgent } from 'lua-cli';

// Static model
export const agent = new LuaAgent({
  name: 'my-agent',
  persona: 'You are a helpful assistant.',
  model: 'openai/gpt-4o',
});

// Dynamic model based on channel
export const agent = new LuaAgent({
  name: 'my-agent',
  persona: 'You are a helpful assistant.',
  model: async (request) => {
    if (request.channel === 'whatsapp') return 'openai/gpt-4o-mini';
    return 'openai/gpt-4o';
  },
});
Supported providers: google/*, openai/*, anthropic/*. Default: google/gemini-2.5-flash.
lua-cli now collects usage data to help improve the developer experience. A new lua telemetry command lets you control data collection:
lua telemetry          # Show current status
lua telemetry on       # Enable telemetry
lua telemetry off      # Disable telemetry
Or set LUA_TELEMETRY=false in your environment. See Telemetry for details.

🔧 Improvements

keytar (OS keychain access) is now optional. Fixes installation on CI/CD systems without native build tools. Falls back to environment variables or .env file.

v3.5.0

Released: February 20, 2026

✨ New Features

The User.get() method now supports looking up users by email address or phone number, in addition to userId.
import { User } from 'lua-cli';

// Look up by email
const user = await User.get({ email: '[email protected]' });

// Look up by phone (both formats work)
const user = await User.get({ phone: '+1234567890' });

// Handle not found (returns null, doesn't throw)
if (!user) {
  return { error: 'User not found' };
}
Useful for webhooks receiving contact info from external systems.
Connect your agent to 250+ third-party services via Unified.to. When you connect an account, an MCP server is automatically created to expose tools to your agent.
lua integrations              # Interactive mode
lua integrations connect      # Connect (OAuth or API token)
lua integrations list         # List connected accounts
lua integrations webhooks     # Manage webhook triggers
lua integrations mcp          # Manage MCP servers
Key Features:
  • OAuth and API token authentication
  • Automatic MCP server creation and activation per connection
  • Event-driven webhook triggers that wake up your agent
  • Server-side finalization for reliable connection setup
See the Integrations Command documentation.
Event-driven triggers that wake up your agent when events occur in connected services.
# Connect with triggers (all selected by default in interactive mode)
lua integrations connect --integration linear --auth-method oauth --scopes all \
  --triggers task_task.created,task_task.updated

# Use custom webhook URL instead of agent trigger
lua integrations connect --integration linear --auth-method oauth --scopes all \
  --triggers task_task.created --custom-webhook --hook-url https://my-server.com/webhook
  • Triggers pre-selected by default in interactive mode
  • Choose between “Agent wake-up” mode or custom webhook URLs
  • Friendly labels for OAuth scopes and webhook events
  • JSON output: lua integrations webhooks list --json
Back up your project source files to cloud storage and restore them on any machine.
# Backup project sources
lua push backup

# Restore on new machine
lua init --agent-id abc123 --restore-sources
Key Features:
  • Content-addressed storage with automatic deduplication
  • S3 direct upload — no file size limits
  • Efficient incremental backups (only changed files uploaded)
  • Full project recovery on new machines
See the Skill Management documentation.
New global --ci flag makes the CLI fail loudly on missing required arguments instead of silently hanging in non-TTY environments.
# In CI/CD pipelines
lua --ci push skill --name mySkill --set-version ${{ github.sha }} --force

# In local development (interactive prompts work normally)
lua push skill
See the Non-Interactive Mode documentation.
New lua update command for self-updating from npm, plus a background outdated version warning on every command.
lua update   # Force-fetch latest version and install
  • Background version check with 24h file cache (zero latency impact)
  • Alpha users stay on alpha channel, stable users stay on latest
  • Boxed warning to stderr when outdated
New lua agents command lists all organizations and agents you have access to.
lua agents            # Formatted output
lua agents --json     # JSON output for scripting
See the Utility Commands documentation.
You can now define primitive properties using variables and imports — not just inline literals.
const MY_SCHEDULE = { type: 'cron', expression: '0 9 * * *' };
const MY_TOOLS = [calculatorTool, weatherTool];
import { RETRY_CONFIG } from './config';

export const myJob = defineJob({
  schedule: MY_SCHEDULE,        // ✅ variable reference
  retry: RETRY_CONFIG,          // ✅ imported constant
  execute: async () => { ... }
});
Supported for: job schedule/retry, skill tools arrays, MCP server resolver functions, and all agent config arrays.
lua push all now pushes everything including persona and backup:
lua push all --force                # All primitives + persona + backup
lua push all --force --auto-deploy  # Also deploys persona to production
Persona and backup failures are non-fatal — the rest of the push completes normally.
The CLI now automatically adds dist-v2/ to your .gitignore:
  • New projects: Included in lua init template
  • Existing projects: Added after first successful compilation
  • Idempotent and safe to run multiple times
lua logs --type mcp      # View MCP tool execution logs
lua logs --type mastra   # View Mastra AI runtime logs
lua logs --user-id user_123456  # Filter by user ID
lua configure --api-key YOUR_API_KEY              # Direct setup
lua configure --email [email protected]            # Request OTP
lua configure --email [email protected] --otp 123  # Verify OTP
lua persona sandbox view    # Print persona and exit
lua skills sandbox view     # List local skills and exit

🔧 Breaking Changes

These changes may affect existing scripts and workflows. Please update accordingly.
# Old (no longer works)
lua push skill --name mySkill --version 1.0.5

# New (correct)
lua push skill --name mySkill --set-version 1.0.5
Reason: Avoids confusion with the global --version flag that shows CLI version.
# Old behavior (sync ran by default)
lua compile             # Checked for drift

# New behavior (sync is opt-in)
lua compile             # No drift check (fast)
lua compile --sync      # Enable drift check
New flag: --verbose for detailed compilation output.

🚀 Improvements

lua push --force now automatically checks the server for the highest existing version.Benefit: Prevents “Version already exists” errors during automated deployments.
lua sync now runs compilation first for more accurate drift detection.
Chat now displays preprocessor block response text instead of showing empty responses.
All errors now go through standardized formatting for clearer, more actionable messages.

⚡ Performance

  • Before: 6 sequential HTTP calls (~3-6s)
  • After: All fetched in parallel (~1s)
One HTTP call per primitive type instead of one per entity.
No upfront validation call. The first API call validates the key.

🐛 Bug Fixes

  • Job Creation: Fixed __exports naming collision when primitives called Jobs.create() at runtime
  • Backup Size Limit: S3 presigned uploads fix “request entity too large” for large projects
  • MCP Server Duplicates: Intelligent URL merging handles concurrent MCP creation flows
  • Email Channels: Aligned with updated API schema (mode selection, displayName, response types)
  • Agent Config Arrays: Defining jobs: MY_JOBS via variables no longer silently empties the agent
  • Webhook headerSchema: Header validation schemas now correctly pushed to server
  • Tool Conditions: Tools without condition() no longer fail at runtime
  • MCP Server Push: Fixed detection, manifest metadata, and push pipeline (3 bugs)
  • Auth Errors: AuthenticationError properly propagated; 403 Forbidden handling added
  • Compile Sync: Handlers no longer overwrite each other’s IDs
  • Marketplace: Only shows skills with published and approved versions
  • Test Command: Fixed preprocessor test handling for object format

📝 Interface Updates

  • Added UserLookupOptions for email/phone lookup
  • Added EmailChannelMode, CreateGeneratedEmailChannelResponse, CreateExistingEmailChannelResponse
  • Added MCPServerSource enum for tracking MCP server origin
  • Updated User.get() return type to UserDataInstance | null
  • Added 'mcp' and 'mastra' to log type enums

v3.4.0

Released: January 22, 2026

✨ New Features

The lua compile command now uses a safer, non-destructive sync pattern. Instead of automatically deleting primitives on the server that aren’t in your local code, it now:
  • Warns about orphaned primitives (skills, webhooks, jobs, MCP servers)
  • Suggests using explicit delete commands
  • Filters warnings to CLI-sourced skills only (ignores marketplace and manual skills)
This prevents accidental data loss and gives you full control over what gets removed.
Explicit delete commands for managing primitives no longer in your local code:
# Delete a skill from the server
lua skills delete --skill-name my-old-skill

# Delete a webhook
lua webhooks delete --webhook-name old-webhook

# Delete a job
lua jobs delete --job-name deprecated-job
Features:
  • Server lookup for orphaned items not in local YAML
  • Interactive mode with confirmation prompts
  • --force flag for non-interactive deletion
Added support for the modern Streamable HTTP transport (MCP spec 2025-03-26):
const server = new LuaMCPServer({
  name: 'my-api',
  transport: 'streamable-http',  // New transport type
  url: 'https://mcp.example.com/mcp',
  headers: () => ({
    'Authorization': `Bearer ${env("API_KEY")}`
  })
});
Supported transports:
  • 'streamable-http' - Modern MCP standard (recommended)
  • 'sse' - Legacy Server-Sent Events transport
stdio transport removed: Local MCP servers using stdio transport are not supported yet. Use remote servers with streamable-http or sse instead.

🐛 Bug Fixes

  • Push: Fixed crash when pushing primitives without a version field. First push now defaults to version 0.0.1 and shows “(none - first push)” in prompts.

📝 Interface Updates

  • Added MCPStreamableHttpServerConfig interface for streamable-http transport
  • Updated MCPTransport type to 'sse' | 'streamable-http'
  • Added SkillSource type: 'cli' | 'marketplace' | 'manual'
  • Removed MCPStdioServerConfig (stdio not supported yet)

v3.3.0

Released: January 20, 2026

✨ New Features

All CLI commands now support full non-interactive operation, enabling seamless automation for AI IDEs, CI/CD pipelines, and shell scripting.Design Patterns:
  • Consistent option naming: --<entity>-name and --<entity>-version
  • --force flag for skipping confirmation prompts
  • --json flag for machine-readable output
  • Action arguments for entity management (view, versions, deploy, activate, deactivate)
# Entity management
lua skills view
lua skills versions --skill-name mySkill
lua skills deploy --skill-name mySkill --skill-version 1.0.3

# Init command
lua init --agent-id abc123
lua init --agent-name "My Bot" --org-id org1

# Sync command
lua sync --check    # CI drift detection
lua sync --accept   # Auto-sync from server

# Test command
lua test skill --name get_weather --input '{"city": "London"}'

# Logs command
lua logs --type skill --name mySkill --limit 10 --json
See the Non-Interactive Mode Guide for complete documentation.
The logs command now supports filtering by user messages and agent responses:
lua logs --type user_message --limit 20
lua logs --type agent_response --limit 20
  • 💬 User Messages: View incoming user messages with channel and userId info
  • 🤖 Agent Responses: View AI-generated responses with distinct coloring
MCP server configurations now support dynamic environment variable resolution using the env() API:
const mcpServer = new LuaMCPServer({
  name: 'mongo-mcp',
  transport: 'stdio',
  command: 'npx',
  args: ['-y', '@mongodb/mcp-server'],
  env: () => ({
    MDB_CONNECTION_STRING: env("MDB_CONNECTION_STRING")
  })
});
Also supported for SSE transport with url and headers resolver functions.
Added filter support to Products.get() with backward compatibility:
// Backward compatible
const products = await Products.get(1, 10);

// New approach with filters
const products = await Products.get({
  page: 1,
  limit: 10,
  filter: {
    category: 'electronics',
    inStock: true
  }
});

🐛 Bug Fixes

  • Chat: Allow lua chat to work without mandatory skills - agents can now have only webhooks, jobs, or processors
  • Commands: Normalized action handling for case-insensitive action comparisons

🔧 Improvements

  • Chat Command: Informational message when defaulting to sandbox environment
  • Chat Command: Improved visual separation between compile logs and chat response
  • Env Command: Proper error handling for save/delete operations
  • Push Command: Shared helper functions reduce code duplication

v3.2.0

Released: January 13, 2026

✨ New Features

New lua sync command to detect drift between server and local code:
lua sync
Features:
  • Compare agent name and persona between server state and local code
  • Fetch latest published persona version (excludes drafts and rollbacks)
  • Show colored line-by-line diff for easy comparison
  • Interactive resolution: update local from server or continue with local
  • Integrated into compile flow with --no-sync and --force-sync flags
New lua chat clear command to clear conversation history:
# Clear all conversation history
lua chat clear

# Clear history for a specific user
lua chat clear --user [email protected]
Accepts userId, email, or mobile number as the identifier.
New Lua namespace for runtime access:
import { Lua } from 'lua-cli';

// Access channel information
const channel = Lua.request.channel; // 'dev', 'webchat', 'whatsapp', etc.
Channel is typed as a union type: 'dev' | 'webchat' | 'whatsapp' | 'messenger' | 'voice' | 'api' | 'email'
Access raw webhook payloads in tool execute functions:
import { Lua } from 'lua-cli';

// Access raw webhook payload when triggered by webhook
const webhookPayload = Lua.request.webhook;
Browse marketplace skills now supports pagination:
  • Navigate through pages with Previous/Next options
  • Shows page info (Page X/Y) and total count
  • Configurable page size (default: 10 items)

🔧 Improvements

  • Simplified Agent Creation: Streamlined lua init flow with cleaner prompts
  • Better TypeScript Support: Improved handling of path aliases and variable references in your code

🐛 Bug Fixes

  • Fixed sync command occasionally showing false drift detection
  • Fixed skill publishing issues
  • Fixed compilation when skills are defined inline vs imported from separate files

v3.1.0

Released: December 7, 2025

✨ New Features

New LuaMCPServer class for integrating Model Context Protocol servers with your agent:
import { LuaMCPServer, LuaAgent } from 'lua-cli';

const docsServer = new LuaMCPServer({
  name: 'lua-docs',
  transport: 'sse',
  url: 'https://docs.heylua.ai/mcp/sse'
});

export const agent = new LuaAgent({
  mcpServers: [docsServer]
});
CLI commands:
  • lua mcp - List, activate, deactivate, or delete MCP servers
  • lua push mcp - Push individual MCP servers
  • MCP servers included in lua push all --force
Tools can now have a condition function that determines if the tool is available:
const adminTool = new LuaTool({
  name: 'admin-tool',
  condition: async () => {
    const user = await User.get();
    return user.data?.isAdmin === true;
  },
  execute: async (input) => { return 'admin action completed'; }
});
Use conditions to dynamically enable/disable tools based on user subscription, verification status, feature flags, or region.
New CDN namespace for uploading and retrieving files:
import { CDN } from 'lua-cli';

// Upload a file
const file = new File([buffer], 'image.png', { type: 'image/png' });
const fileId = await CDN.upload(file);

// Get file
const file = await CDN.get(fileId);
New methods for job management:
// Get all jobs
const jobs = await Jobs.getAll();

// Activate/deactivate job scheduling
await job.activate();
await job.deactivate();

// Manually trigger execution
await job.trigger();
New lua evals command opens the Evaluations Dashboard with your agent pre-configured.
lua evals
New Templates namespace for WhatsApp template messaging:
import { Templates } from 'lua-cli';

// List templates
const result = await Templates.whatsapp.list(channelId);

// Send template message
await Templates.whatsapp.send(channelId, templateId, {
  phoneNumbers: ['+447551166594'],
  values: { body: { name: 'John' } }
});
New lua marketplace command for discovering, installing, and publishing skills:For Creators:
  • Publish skills to the global marketplace
  • Version management with semantic versioning
  • Environment variable configuration per version
For Installers:
  • Browse and search for verified skills
  • Smart installation with dependency checks
  • Interactive environment variable configuration
The lua logs command now features:
  • Interactive filtering by primitive type (Skills, Jobs, Webhooks, etc.)
  • Live data from API including dynamically created jobs
  • Context-aware log display with detailed metadata
New user._luaProfile property for read-only core user data:
const userId = user._luaProfile.userId;        // ✅ Recommended
const fullName = user._luaProfile.fullName;
const emails = user._luaProfile.emailAddresses;

// user.userId still works but is deprecated

💥 Breaking Changes

These changes may require updates to your existing code.
JobInstance now receives the full Job entity with activeVersion:
// Before
const schedule = job.schedule;
const id = job.jobId;

// After
const schedule = job.activeVersion.schedule;
const id = job.id;
await job.trigger(); // New method
The welcomeMessage field has been removed from LuaAgent configuration:
  • For voice: use voiceConfig.welcomeMessage
  • For chat widgets: use WebchatChannelConfig.welcomeMessage
Webhook execute functions now receive a single event object:
// Before
execute: async (query, headers, body) => {
  // handle webhook
}

// After
execute: async (event) => {
  const { query, headers, body, timestamp } = event;
  // handle webhook
}
PreProcessorResult now uses a discriminated union:
// Block response
return { action: 'block', response: 'Blocked' };

// Proceed response
return { 
  action: 'proceed', 
  modifiedMessage: [{ type: 'text', text: '...' }] 
};
  • modifiedMessage is now ChatMessage[] (array)
  • Added priority field for execution order
  • Removed context field

🔧 Improvements

  • Data API Type Safety: searchText parameter added to Data.create() and Data.update(), data parameter type changed to Record<string, any>
  • PostProcessor Simplified: Return type now requires modifiedResponse: string, removed async field
  • Compilation: Handle .js extensions for Node16/NodeNext module resolution
  • Template: Minimal by default, use --with-examples flag for examples
  • Web UI: React Query, Sonner toasts, improved env panels, docs in toolbar

🛠️ Refactoring

  • Removed context field from webhooks, jobs, and postprocessors
  • Removed version field from LuaSkill, LuaJob, and processor configurations
  • Improved push command: displays both webhookId and webhook-name URL formats
  • Rewritten interfaces/jobs.ts to match lua-api DTOs exactly

v3.0.3

Released: October 30, 2025

🎯 User API Enhancement

Enhanced User.get() method now accepts an optional userId parameter:
// Get current user (existing behavior)
const userData = await User.get();

// NEW: Get specific user by ID
const specificUser = await User.get('user_123456');
Use Cases:
  • Fetch data for specific users in admin tools
  • Access user information in webhooks/jobs
  • Multi-user data operations
  • User management features
This enhancement allows tools, webhooks, and jobs to access any user’s data, enabling more sophisticated multi-user scenarios.

v3.0.2

Released: October 30, 2025

🚀 Major Improvements to Compilation System

This release brings comprehensive dependency bundling, debug mode, enhanced validation, and critical bug fixes.
All components now properly bundle external dependencies:
  • LuaWebhooks bundle dependencies (e.g., Stripe, axios)
  • LuaJobs bundle dependencies
  • PreProcessors bundle dependencies (e.g., lodash)
  • PostProcessors bundle dependencies (e.g., date-fns)
  • Nested Jobs (Jobs.create()) independently bundle their own dependencies
Impact: All compiled components are now truly portable and self-contained, requiring no dependency installation on deployment targets.
Added --debug flag to lua compile command:
lua compile --debug
# or
LUA_DEBUG=true lua compile
Features:
  • Verbose step-by-step logging
  • Shows detected imports and dependencies
  • Displays bundle sizes (uncompressed and compressed)
  • Preserves temp files for inspection
  • Shows timing information for each component
  • Full error stack traces
  • tsconfig.json validation - Clear error if missing or invalid
  • Empty bundle detection - Warns about suspiciously small bundles (under 100 bytes)
  • Bundle output validation - Ensures esbuild creates valid output
  • Null config handling - Graceful compilation without lua.skill.yaml
  • Safe optional chaining - Fixed crash when agentData is null
Context-aware error messages with actionable hints:
  • Dependency resolution failures → “Run npm install”
  • TypeScript syntax errors → “Check syntax in filename.ts”
  • Missing files → Shows expected path
  • Full stack traces in debug mode
Enhanced resolveImportPath() to support:
  • .ts, .tsx, .js, .jsx files
  • Directory imports (index.ts, index.tsx, index.js)
Critical Fix: Relative imports now work correctly in Jobs, Webhooks, and Processors:
// ✅ Now works perfectly
import { MyService } from "../services/MyService";
// ✅ Also works
import { MyService } from "@/services/MyService";

🐛 Bug Fixes

  • Fixed null reference error when compiling without LuaAgent
  • Fixed crash when lua.skill.yaml is missing
  • Fixed compilation with empty agent name/persona
  • Critical: Fixed relative import resolution in all component types

🧹 Code Quality

  • Removed obsolete dynamic-job-bundler.ts
  • Extracted common helpers (extractRelevantImports, bundleAndCompressExecuteFunction)
  • Reduced bundling.ts from 1,149 to 1,036 lines (9.8% reduction)
  • Added 27 comprehensive tests for bundling, execution, validation, and relative imports

v3.0.0

Released: October 2025

🎉 Major Release

Version 3.0.0 focuses on developer experience, deployment automation, and real-time chat capabilities.

✨ New Features

The flagship feature: a single, intuitive way to configure your entire agent.Before (v2.x):
export const skill1 = new LuaSkill({ name: 'skill1', tools: [] });
export const skill2 = new LuaSkill({ name: 'skill2', tools: [] });
export const webhook1 = new LuaWebhook({ name: 'webhook1', execute: async () => 'ok' });
After (v3.0.0):
export const agent = new LuaAgent({
  name: 'my-assistant',
  persona: 'You are a helpful AI assistant...',
  skills: [skill1, skill2],
  webhooks: [webhook1],
  jobs: [job1],
  preProcessors: [processor1],
  postProcessors: [processor2]
});
Benefits:
  • Single source of truth
  • Clearer organization
  • Automatic YAML synchronization
  • Better IDE support
Real-time chat responses with improved UX:
lua chat
  • ✅ Animated typing indicator while waiting
  • ✅ Text streams character-by-character
  • ✅ Sandbox and production environment selection
  • ✅ Uses /chat/stream endpoint for real-time updates
New command for deploying all components without prompts:
# Push all with auto-versioning
lua push all --force

# Push and deploy to production
lua push all --force --auto-deploy
What it does:
  1. Compiles project
  2. Reads all components from lua.skill.yaml
  3. Increments patch versions automatically
  4. Pushes all components to server
  5. Deploys to production (if --auto-deploy)
Features:
  • Auto-bumps patch versions (e.g., 1.0.01.0.1)
  • Perfect for CI/CD pipelines
  • Retry mechanism with exponential backoff
Flexible authentication with multiple sources (priority order):
  1. System Keychain (macOS Keychain, Windows Credential Vault, Linux libsecret)
  2. Environment Variable (LUA_API_KEY)
  3. .env File (LUA_API_KEY=...)
Usage in CI/CD:
export LUA_API_KEY=your-key
lua push all --force --auto-deploy
Bidirectional synchronization ensures consistency:On lua init:
  • Agent name, persona → YAML + index.ts LuaAgent
On lua compile:
  • LuaAgent persona → YAML
No manual synchronization needed!

🔧 Improvements

  • Excluded lua-cli internals from bundles
  • Reduced bundle sizes by 50-70%
  • Fixed relative import issues
  • Proper sandbox globals (tools use sandbox-provided APIs)
  • code field now properly compressed and included
  • Execute function properly converts to strings
  • Excludes lua-cli imports from job execute functions
  • Better metadata support for passing data
  • Comprehensive template with 30+ example tools
  • Quick Start Guide for new users
  • TypeScript examples with best practices
  • CI/CD integration examples

🐛 Bug Fixes

Bundling:
  • Fixed Cannot find module '../services/ApiService' in pre-bundled tools
  • Fixed process.cwd is not a function in sandbox execution
  • Fixed lua-cli API code being bundled into tools
Push & Deploy:
  • Fixed webhooks and jobs not found during push all
  • Fixed missing tools array causing validation errors
  • Fixed deployment timing issues with retry mechanism
Chat:
  • Fixed welcome message reading from lua.skill.yaml
  • Fixed streaming endpoint integration
  • Fixed typing indicator cleanup on errors

💥 Breaking Changes

These changes require updates to your existing code.
Old Way:
export const skill1 = new LuaSkill({ name: 'skill1', tools: [] });
export const skill2 = new LuaSkill({ name: 'skill2', tools: [] });
New Way:
export const agent = new LuaAgent({
  skills: [skill1, skill2]
});
Migration:
  1. Wrap your existing skills in a LuaAgent
  2. Add name and persona fields
  3. Run lua compile to sync with YAML
  • Old: /chat/generate/:agentId
  • New: /chat/stream/:agentId
No action needed - handled automatically by CLI.
Jobs must use metadata for data passing:
await Jobs.create({
  metadata: { userId: input.userId },
  execute: async (job) => {
    const userId = job.metadata.userId;
  }
});

📊 Statistics

MetricBeforeAfter
Bundle overhead~500KB50-70% smaller
Compilation speed-30% faster
Template examples530+
CLI commands-25+

Upgrade Guides

From v3.0.x to v3.1.0

npm install [email protected]
Required changes:
  1. Update JobInstance access patterns (use activeVersion.schedule, id instead of jobId)
  2. Update webhook execute functions to use event object
  3. Update PreProcessor responses to use discriminated union
  4. Remove welcomeMessage from LuaAgent (configure on channel/voice instead)

From v2.x to v3.0.0

npm install [email protected]
Required changes:
  1. Wrap skills in a LuaAgent configuration
  2. Update jobs to use metadata for data passing
  3. Run lua compile to sync with YAML
// src/index.ts
import { LuaAgent } from 'lua-cli';

export const agent = new LuaAgent({
  name: 'my-agent',
  persona: 'Your agent persona...',
  skills: [/* your existing skills */],
});