Commands
Development Mode
Run ElizaOS projects in development mode with hot reloading and debugging
Dev Command
Start the project or plugin in development mode with auto-rebuild, detailed logging, and file change detection.
Usage
Options
Option | Description |
---|---|
-c, --configure | Reconfigure services and AI models (skips using saved configuration) |
--character [paths...] | Character file(s) to use - accepts paths or URLs |
-b, --build | Build the project before starting |
-p, --port <port> | Port to listen on (default: 3000) |
-h, --help | Display help for command |
Usage
Options
Option | Description |
---|---|
-c, --configure | Reconfigure services and AI models (skips using saved configuration) |
--character [paths...] | Character file(s) to use - accepts paths or URLs |
-b, --build | Build the project before starting |
-p, --port <port> | Port to listen on (default: 3000) |
-h, --help | Display help for command |
Basic Development Mode
Development with Configuration
Character File Specification
Combined Options
Development Features
The dev command provides comprehensive development capabilities:
Auto-Rebuild and Restart
- File Watching: Monitors
.ts
,.js
,.tsx
, and.jsx
files for changes - Automatic Rebuilding: Rebuilds project when source files change
- Server Restart: Automatically restarts the server after successful rebuilds
- TypeScript Support: Compiles TypeScript files during rebuilds
Project Detection
- Project Mode: Automatically detects Eliza projects based on package.json configuration
- Plugin Mode: Detects and handles plugin development appropriately
- Monorepo Support: Builds core packages when working in monorepo context
Development Workflow
- Detects whether you’re in a project or plugin directory
- Performs initial build (if needed)
- Starts the server with specified options
- Sets up file watching for source files
- Rebuilds and restarts when files change
File Watching Behavior
Watched Files
- TypeScript files (
.ts
,.tsx
) - JavaScript files (
.js
,.jsx
)
Watched Directories
- Source directory (
src/
) - Project root (if no src directory exists)
Ignored Paths
node_modules/
directorydist/
directory.git/
directory
Debouncing
- Changes are debounced with a 300ms delay to prevent rapid rebuilds
- Multiple rapid changes trigger only one rebuild cycle
Project Type Detection
The dev command uses intelligent project detection:
Plugin Detection
Identifies plugins by checking for:
eliza.type: "plugin"
in package.json- Package name containing
plugin-
- Keywords:
elizaos-plugin
oreliza-plugin
Project Detection
Identifies projects by checking for:
eliza.type: "project"
in package.json- Package name containing
project-
or-org
- Keywords:
elizaos-project
oreliza-project
src/index.ts
with Project export
Monorepo Support
When running in a monorepo context, the dev command:
-
Builds Core Packages: Automatically builds essential monorepo packages:
packages/core
packages/client
packages/plugin-bootstrap
-
Dependency Resolution: Ensures proper build order for dependencies
-
Change Detection: Monitors both core packages and current project for changes
Development Logs
The dev command provides detailed logging:
Character File Handling
Supported Formats
- Local files: Relative or absolute paths
- URLs: HTTP/HTTPS URLs to character files
- Extension optional:
.json
extension is automatically added if missing
Multiple Characters
Multiple character files can be specified using:
- Space separation:
file1.json file2.json
- Comma separation:
"file1.json,file2.json"
- Mixed format:
"file1.json, file2.json"