@elizaos/core 1.0.0-alpha.62 → 1.0.0-alpha.64

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. package/dist/actions/choice.d.ts +1 -1
  2. package/dist/actions/followRoom.d.ts +1 -1
  3. package/dist/actions/ignore.d.ts +1 -1
  4. package/dist/actions/muteRoom.d.ts +1 -1
  5. package/dist/actions/none.d.ts +1 -1
  6. package/dist/actions/reply.d.ts +1 -1
  7. package/dist/actions/roles.d.ts +1 -1
  8. package/dist/actions/sendMessage.d.ts +1 -1
  9. package/dist/actions/settings.d.ts +1 -1
  10. package/dist/actions/unfollowRoom.d.ts +1 -1
  11. package/dist/actions/unmuteRoom.d.ts +1 -1
  12. package/dist/actions/updateEntity.d.ts +1 -1
  13. package/dist/actions.d.ts +1 -1
  14. package/dist/bootstrap.d.ts +1 -1
  15. package/dist/database.d.ts +18 -5
  16. package/dist/entities.d.ts +1 -1
  17. package/dist/evaluators/reflection.d.ts +1 -1
  18. package/dist/index.d.ts +12 -12
  19. package/dist/index.js +844 -1071
  20. package/dist/prompts.d.ts +1 -1
  21. package/dist/providers/actions.d.ts +1 -1
  22. package/dist/providers/anxiety.d.ts +1 -1
  23. package/dist/providers/attachments.d.ts +1 -1
  24. package/dist/providers/capabilities.d.ts +1 -1
  25. package/dist/providers/character.d.ts +1 -1
  26. package/dist/providers/choice.d.ts +1 -1
  27. package/dist/providers/entities.d.ts +1 -1
  28. package/dist/providers/evaluators.d.ts +1 -1
  29. package/dist/providers/facts.d.ts +1 -1
  30. package/dist/providers/knowledge.d.ts +1 -1
  31. package/dist/providers/providers.d.ts +1 -1
  32. package/dist/providers/recentMessages.d.ts +1 -1
  33. package/dist/providers/relationships.d.ts +1 -1
  34. package/dist/providers/roles.d.ts +1 -1
  35. package/dist/providers/settings.d.ts +1 -1
  36. package/dist/providers/shouldRespond.d.ts +1 -1
  37. package/dist/providers/time.d.ts +1 -1
  38. package/dist/roles.d.ts +1 -1
  39. package/dist/runtime.d.ts +36 -13
  40. package/dist/services/index.d.ts +1 -0
  41. package/dist/services/scenario.d.ts +1 -1
  42. package/dist/services/task.d.ts +1 -1
  43. package/dist/services/websocket.d.ts +73 -0
  44. package/dist/settings.d.ts +1 -1
  45. package/dist/test_resources/constants.d.ts +1 -1
  46. package/dist/types.d.ts +50 -41
  47. package/dist/uuid.d.ts +2 -2
  48. package/package.json +74 -70
  49. package/dist/environment.d.ts +0 -403
@@ -1,4 +1,4 @@
1
- import { type Action } from "../types";
1
+ import { type Action } from '../types';
2
2
  /**
3
3
  * Represents an action that allows selecting an option for a pending task that has multiple options.
4
4
  * @type {Action}
@@ -1,4 +1,4 @@
1
- import { type Action } from "../types";
1
+ import { type Action } from '../types';
2
2
  /**
3
3
  * Template for deciding if {{agentName}} should start following a room.
4
4
  * The decision is based on various criteria, including recent messages and user interactions.
@@ -1,4 +1,4 @@
1
- import type { Action } from "../types";
1
+ import type { Action } from '../types';
2
2
  /**
3
3
  * Action representing the IGNORE action. This action is used when ignoring the user in a conversation.
4
4
  *
@@ -1,4 +1,4 @@
1
- import { type Action } from "../types";
1
+ import { type Action } from '../types';
2
2
  /**
3
3
  * Template string for deciding if the agent should mute a room and stop responding unless explicitly mentioned.
4
4
  *
@@ -1,4 +1,4 @@
1
- import type { Action } from "../types";
1
+ import type { Action } from '../types';
2
2
  /**
3
3
  * Represents the none action.
4
4
  *
@@ -1,4 +1,4 @@
1
- import { type Action } from "../types";
1
+ import { type Action } from '../types';
2
2
  /**
3
3
  * Represents an action that allows the agent to reply to the current conversation with a generated message.
4
4
  *
@@ -1,4 +1,4 @@
1
- import { type Action } from "../types";
1
+ import { type Action } from '../types';
2
2
  /**
3
3
  * Represents an action to update the role of a user within a server.
4
4
  * @typedef {Object} Action
@@ -1,4 +1,4 @@
1
- import { type Action } from "../types";
1
+ import { type Action } from '../types';
2
2
  /**
3
3
  * Represents an action to send a message to a user or room.
4
4
  *
@@ -1,4 +1,4 @@
1
- import { type Action, type IAgentRuntime, type WorldSettings } from "../types";
1
+ import { type Action, type IAgentRuntime, type WorldSettings } from '../types';
2
2
  /**
3
3
  * Gets settings state from world metadata
4
4
  */
@@ -1,4 +1,4 @@
1
- import { type Action } from "../types";
1
+ import { type Action } from '../types';
2
2
  /**
3
3
  * Action for unfollowing a room.
4
4
  *
@@ -1,4 +1,4 @@
1
- import { type Action } from "../types";
1
+ import { type Action } from '../types';
2
2
  /**
3
3
  * Template for determining if an agent should unmute a previously muted room.
4
4
  * * @type { string }
@@ -1,4 +1,4 @@
1
- import { type Action } from "../types";
1
+ import { type Action } from '../types';
2
2
  /**
3
3
  * Action for updating contact details for a user entity.
4
4
  *
package/dist/actions.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import type { Action } from "./types";
1
+ import type { Action } from './types';
2
2
  /**
3
3
  * Composes a set of example conversations based on provided actions and a specified count.
4
4
  * It randomly selects examples from the provided actions and formats them with generated names.
@@ -1,4 +1,4 @@
1
- import { type Media, type Plugin } from "./types";
1
+ import { type Media, type Plugin } from './types';
2
2
  type MediaData = {
3
3
  data: Buffer;
4
4
  mediaType: string;
@@ -1,4 +1,4 @@
1
- import type { Agent, Component, Entity, IDatabaseAdapter, Log, Memory, Participant, Relationship, Room, Task, UUID, World } from "./types";
1
+ import type { Agent, Component, Entity, IDatabaseAdapter, Log, Memory, Participant, Relationship, Room, Task, UUID, World, MemoryMetadata } from './types';
2
2
  /**
3
3
  * An abstract class representing a database adapter for managing various entities
4
4
  * like entities, memories, entities, goals, and rooms.
@@ -85,10 +85,14 @@ export declare abstract class DatabaseAdapter<DB = unknown> implements IDatabase
85
85
  * @returns A Promise that resolves to an array of Memory objects.
86
86
  */
87
87
  abstract getMemories(params: {
88
- roomId: UUID;
88
+ entityId?: UUID;
89
+ agentId?: UUID;
90
+ roomId?: UUID;
89
91
  count?: number;
90
92
  unique?: boolean;
91
93
  tableName: string;
94
+ start?: number;
95
+ end?: number;
92
96
  }): Promise<Memory[]>;
93
97
  abstract getMemoriesByRoomIds(params: {
94
98
  roomIds: UUID[];
@@ -171,6 +175,15 @@ export declare abstract class DatabaseAdapter<DB = unknown> implements IDatabase
171
175
  * @returns A Promise that resolves when the memory has been created.
172
176
  */
173
177
  abstract createMemory(memory: Memory, tableName: string, unique?: boolean): Promise<UUID>;
178
+ /**
179
+ * Updates an existing memory in the database.
180
+ * @param memory The memory object with updated content and optional embedding
181
+ * @returns Promise resolving to boolean indicating success
182
+ */
183
+ abstract updateMemory(memory: Partial<Memory> & {
184
+ id: UUID;
185
+ metadata?: MemoryMetadata;
186
+ }): Promise<boolean>;
174
187
  /**
175
188
  * Removes a specific memory from the database.
176
189
  * @param memoryId The UUID of the memory to remove.
@@ -238,7 +251,7 @@ export declare abstract class DatabaseAdapter<DB = unknown> implements IDatabase
238
251
  * @param roomId Optional UUID to assign to the new room.
239
252
  * @returns A Promise that resolves to the UUID of the created room.
240
253
  */
241
- abstract createRoom({ id, source, type, channelId, serverId, worldId, }: Room): Promise<UUID>;
254
+ abstract createRoom({ id, source, type, channelId, serverId, worldId }: Room): Promise<UUID>;
242
255
  /**
243
256
  * Updates a specific room in the database.
244
257
  * @param room The room object with updated properties.
@@ -289,8 +302,8 @@ export declare abstract class DatabaseAdapter<DB = unknown> implements IDatabase
289
302
  * @returns A Promise that resolves to an array of UUIDs representing the participants.
290
303
  */
291
304
  abstract getParticipantsForRoom(roomId: UUID): Promise<UUID[]>;
292
- abstract getParticipantUserState(roomId: UUID, entityId: UUID): Promise<"FOLLOWED" | "MUTED" | null>;
293
- abstract setParticipantUserState(roomId: UUID, entityId: UUID, state: "FOLLOWED" | "MUTED" | null): Promise<void>;
305
+ abstract getParticipantUserState(roomId: UUID, entityId: UUID): Promise<'FOLLOWED' | 'MUTED' | null>;
306
+ abstract setParticipantUserState(roomId: UUID, entityId: UUID, state: 'FOLLOWED' | 'MUTED' | null): Promise<void>;
294
307
  /**
295
308
  * Creates a new relationship between two users.
296
309
  * @param params Object containing the relationship details including entity IDs, agent ID, optional tags and metadata
@@ -1,4 +1,4 @@
1
- import { type Entity, type IAgentRuntime, type Memory, type State, type UUID } from "./types";
1
+ import { type Entity, type IAgentRuntime, type Memory, type State, type UUID } from './types';
2
2
  /**
3
3
  * Finds an entity by name in the given runtime environment.
4
4
  *
@@ -1,2 +1,2 @@
1
- import { type Evaluator } from "../types";
1
+ import { type Evaluator } from '../types';
2
2
  export declare const reflectionEvaluator: Evaluator;
package/dist/index.d.ts CHANGED
@@ -1,12 +1,12 @@
1
- export * from "./types";
2
- export * from "./actions";
3
- export * from "./database";
4
- export * from "./entities";
5
- export * from "./environment";
6
- export * from "./import";
7
- export * from "./logger";
8
- export * from "./prompts";
9
- export * from "./roles";
10
- export * from "./runtime";
11
- export * from "./settings";
12
- export * from "./uuid";
1
+ export * from './types';
2
+ export * from './actions';
3
+ export * from './database';
4
+ export * from './entities';
5
+ export * from './import';
6
+ export * from './logger';
7
+ export * from './prompts';
8
+ export * from './roles';
9
+ export * from './runtime';
10
+ export * from './settings';
11
+ export * from './uuid';
12
+ export * from './services';