# ElizaOS Developer Update - 2025-05-15

## 1. Core Framework

### Enhanced Agent Runtime and Plugin System
We've significantly improved the plugin architecture to better support third-party integrations and standardize the plugin development experience:

- Added support for direct installation of plugins from Git repositories, including both HTTPS and shorthand GitHub formats ([#4568](https://github.com/elizaos/eliza/pull/4568), [#4577](https://github.com/elizaos/eliza/pull/4577))
- Introduced a plugin-specification submodule for standardized plugin development ([#4553](https://github.com/elizaos/eliza/pull/4553))
- Enhanced model handling in AgentRuntime to support provider selection and priority settings ([#4507](https://github.com/elizaos/eliza/pull/4507))

```typescript
// Example of improved model registration with provider and priority
registerModel({
  modelType: ModelType.TEXT_LARGE,
  provider: "anthropic",
  priority: 1,
  handler: async (input, options) => {
    // Model-specific handling
  }
});
```

### Database and Performance Improvements
- Implemented proper per-project isolation for database directories to prevent cross-project contamination ([#4497](https://github.com/elizaos/eliza/pull/4497))
- Added comprehensive integration tests for all major database operations ([#4518](https://github.com/elizaos/eliza/pull/4518))
- Improved agent loading speed when handling multiple agents ([#4519](https://github.com/elizaos/eliza/pull/4519))

## 2. New Features

### Enhanced Message Processing
We've rolled out a completely redesigned message handling system:

- Implemented an event-driven, asynchronous flow for agent message handling ([#4594](https://github.com/elizaos/eliza/pull/4594))
- Added support for dynamic response scenarios where the agent may choose not to reply
- Guaranteed that `onComplete` is always called in message handlers regardless of errors ([#4589](https://github.com/elizaos/eliza/pull/4589))

```typescript
// New message handler with error and timeout protection
export async function messageReceivedHandler(
  message: Message,
  runtime: AgentRuntime,
  onComplete?: () => void
) {
  try {
    // Message processing logic here
    const response = await processMessageWithTemplate(message, runtime);
    // Additional processing and action execution
  } catch (error) {
    logger.error(`Error processing message: ${error}`);
  } finally {
    // Always execute the callback even if an error occurs
    if (onComplete) onComplete();
  }
}
```

### Advanced CLI Features
- Added the ability to test plugin installation and operation directly through the CLI ([#4582](https://github.com/elizaos/eliza/pull/4582))
- Improved the `elizaos agent` command with fixes for JSON output and file handling ([#4560](https://github.com/elizaos/eliza/pull/4560))
- Enhanced environment variable management with improved listing and warning systems ([#4610](https://github.com/elizaos/eliza/pull/4610))

## 3. Bug Fixes

### Critical Fixes
- Resolved a critical issue with JSON serialization to handle invalid Unicode escape sequences in logs ([#4458](https://github.com/elizaos/eliza/pull/4458))
- Fixed foreign key constraint violation when deleting agents ([#4510](https://github.com/elizaos/eliza/pull/4510))
- Addressed LLM response parsing to support custom fields and properly clean empty message headers ([#4580](https://github.com/elizaos/eliza/pull/4580))

```typescript
// Fix for message processing that preserves custom fields
export function processResponse(response: any): ProcessedResponse {
  const { text, action, ...rest } = response;
  
  // Clean up empty headers
  const cleanText = text?.replace(/^#+\s*\n+/gm, '');
  
  return {
    text: cleanText || '',
    action: action || '',
    ...rest // Preserve other custom fields returned by LLM
  };
}
```

### Community Manager Configuration
- Fixed the community manager configuration to use plugin-local-ai by default ([#4557](https://github.com/elizaos/eliza/pull/4557))
- Added missing topics in Twitter post templates for community and social media manager profiles ([#4595](https://github.com/elizaos/eliza/pull/4595))

## 4. API Changes

### Improved Plugin Routes
- Fixed plugin routes to make them properly accessible via API endpoints ([#4415](https://github.com/elizaos/eliza/pull/4415))
- Added API key authentication middleware with a dialog for unauthorized access ([#4420](https://github.com/elizaos/eliza/pull/4420))

```typescript
// Access plugin routes via the following pattern:
// /api/agents/AGENT_UUID_OR_NAME/plugins/PLUGIN_NAME/ROUTE_FROM_PLUGIN
```

### Enhanced Knowledge Management
- Improved the consistency of how knowledge items are associated with agents ([#4581](https://github.com/elizaos/eliza/pull/4581))
- Fixed scoping of worldId and entityId for proper knowledge retrieval

## 5. Social Media Integrations

### Twitter/X Improvements
- Added Twitter timeline functionality for bot interactions ([#4429](https://github.com/elizaos/eliza/pull/4429))
- Fixed Twitter media generation and enabled tweet with media functionality ([#4241](https://github.com/elizaos/eliza/issues/4241))
- Implemented Twitter interaction reactions ([#4181](https://github.com/elizaos/eliza/issues/4181))

```typescript
// Configure Twitter timeline interaction
// in your environment or .env file
ENABLE_TWITTER_POST_GENERATION=true
ENABLE_ACTION_PROCESSING=true
TWITTER_TARGET_USERS=user1,user2

// In character.json
{
  "settings": {
    "twitter": {
      "enable_replies": true,
      "enable_timeline_search": true,
      "enable_follow_thanks": true,
      "enable_auto_retweet": false
    }
  }
}
```

### Discord Integration
- Fixed Discord service unregister timeout ([#4450](https://github.com/elizaos/eliza/pull/4450))
- Resolved issues with Discord @username mentions not properly highlighting and sending notifications

## 6. Model Provider Updates

### OpenAI
- Extended the OpenAI plugin to support custom embedding endpoints ([#4421](https://github.com/elizaos/eliza/pull/4421))
- Added model usage tracking for embeddings and image descriptions ([#4438](https://github.com/elizaos/eliza/pull/4438))

```typescript
// Configure a separate OpenAI endpoint for embeddings
// in your environment or .env file
OPENAI_EMBEDDING_API_URL=https://custom-embedding-service.example.com/v1
```

### Switch to Small Models for Replies
- Updated the reply action to use small models instead of large ones for faster responses ([#4416](https://github.com/elizaos/eliza/pull/4416))
- Modified the reply system to skip LLM calls when existing responses are found ([#4608](https://github.com/elizaos/eliza/pull/4608))

### Community Highlights
- Substantial discussions around AI model preferences have occurred in the community, with many developers reporting they've switched to Gemini for certain tasks
- Nous Research has begun pre-training a 40B parameter LLM using MLA Architecture with FineWeb, FineWeb-2, and The Stack v2

## 7. Breaking Changes

### Monorepo Cleanup
We've removed several plugins from the monorepo to support a more modular ecosystem. These plugins are now maintained in separate repositories:

- Removed: browser, storage-s3, local-ai, ollama, groq, venice, redpill, anthropic, elevenlabs, solana, and openai plugins ([#4406](https://github.com/elizaos/eliza/pull/4406), [#4402](https://github.com/elizaos/eliza/pull/4402), [#4439](https://github.com/elizaos/eliza/pull/4439), [#4437](https://github.com/elizaos/eliza/pull/4437))

To include these plugins in your project, install them from npm:

```bash
npm install @elizaos/plugin-openai @elizaos/plugin-anthropic
# or
pnpm add @elizaos/plugin-openai @elizaos/plugin-anthropic
```

### Character Configuration Migration
- Update any character files using the removed plugins to reference them as external dependencies
- The community manager character now uses plugin-local-ai by default ([#4557](https://github.com/elizaos/eliza/pull/4557))
- For Twitter integration, ensure your character has the correct settings for interaction types

Remember to check your plugin versions when migrating from v1 to v2, as the import patterns have changed.