@elizaos/core 1.0.0-beta.49 → 1.0.0-beta.50

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.
@@ -1,4 +1,6 @@
1
1
  import type { Agent, Component, Entity, IDatabaseAdapter, Log, Memory, MemoryMetadata, Participant, Relationship, Room, Task, UUID, World } from './types';
2
+ import { type Pool as PgPool } from 'pg';
3
+ import { PGlite } from '@electric-sql/pglite';
2
4
  /**
3
5
  * An abstract class representing a database adapter for managing various entities
4
6
  * like entities, memories, entities, goals, and rooms.
@@ -25,6 +27,11 @@ export declare abstract class DatabaseAdapter<DB = unknown> implements IDatabase
25
27
  * @returns A Promise that resolves when closing is complete.
26
28
  */
27
29
  abstract close(): Promise<void>;
30
+ /**
31
+ * Retrieves a connection to the database.
32
+ * @returns A Promise that resolves to the database connection.
33
+ */
34
+ abstract getConnection(): Promise<PGlite | PgPool>;
28
35
  /**
29
36
  * Retrieves an account by its ID.
30
37
  * @param entityId The UUID of the user account to retrieve.
@@ -430,6 +437,7 @@ export declare abstract class DatabaseAdapter<DB = unknown> implements IDatabase
430
437
  abstract getTasks(params: {
431
438
  roomId?: UUID;
432
439
  tags?: string[];
440
+ entityId?: UUID;
433
441
  }): Promise<Task[]>;
434
442
  /**
435
443
  * Retrieves a specific task by its ID.
package/dist/index.d.ts CHANGED
@@ -6,10 +6,8 @@ export * from './logger';
6
6
  export * from './prompts';
7
7
  export * from './roles';
8
8
  export * from './runtime';
9
+ export * from './search';
9
10
  export * from './settings';
10
- export * from './uuid';
11
- export * from './audioUtils';
12
11
  export * from './utils';
13
- export * from './cloudflare';
14
12
  export * from './instrumentation/types';
15
13
  export * from './instrumentation/service';