@elizaos/plugin-sql 1.5.9-alpha.1 → 1.5.9-alpha.3

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 (99) hide show
  1. package/dist/browser/index.browser.js +25928 -0
  2. package/dist/browser/index.browser.js.map +137 -0
  3. package/dist/browser/index.d.ts +2 -0
  4. package/dist/{base.d.ts → browser/src/base.d.ts} +0 -1
  5. package/dist/browser/src/index.browser.d.ts +11 -0
  6. package/dist/{pglite → browser/src/pglite}/adapter.d.ts +0 -1
  7. package/dist/{pglite → browser/src/pglite}/manager.d.ts +0 -1
  8. package/dist/{schema → browser/src/schema}/agent.d.ts +0 -1
  9. package/dist/{schema → browser/src/schema}/cache.d.ts +0 -1
  10. package/dist/{schema → browser/src/schema}/channel.d.ts +0 -1
  11. package/dist/{schema → browser/src/schema}/channelParticipant.d.ts +0 -1
  12. package/dist/{schema → browser/src/schema}/component.d.ts +0 -1
  13. package/dist/{schema → browser/src/schema}/embedding.d.ts +0 -1
  14. package/dist/{schema → browser/src/schema}/entity.d.ts +0 -1
  15. package/dist/{schema → browser/src/schema}/factory.d.ts +0 -1
  16. package/dist/{schema → browser/src/schema}/index.d.ts +0 -1
  17. package/dist/{schema → browser/src/schema}/log.d.ts +0 -1
  18. package/dist/{schema → browser/src/schema}/memory.d.ts +0 -1
  19. package/dist/{schema → browser/src/schema}/message.d.ts +0 -1
  20. package/dist/{schema → browser/src/schema}/messageServer.d.ts +0 -1
  21. package/dist/{schema → browser/src/schema}/participant.d.ts +0 -1
  22. package/dist/{schema → browser/src/schema}/relationship.d.ts +0 -1
  23. package/dist/{schema → browser/src/schema}/room.d.ts +0 -1
  24. package/dist/{schema → browser/src/schema}/serverAgent.d.ts +0 -1
  25. package/dist/{schema → browser/src/schema}/tasks.d.ts +0 -1
  26. package/dist/{schema → browser/src/schema}/types.d.ts +0 -1
  27. package/dist/{schema → browser/src/schema}/world.d.ts +0 -1
  28. package/dist/{types.d.ts → browser/src/types.d.ts} +0 -1
  29. package/dist/browser/src/utils.browser.d.ts +21 -0
  30. package/dist/browser/tsconfig.build.tsbuildinfo +1 -0
  31. package/dist/index.d.ts +2 -33
  32. package/dist/node/index.d.ts +2 -0
  33. package/dist/{index.js → node/index.node.js} +18 -18
  34. package/dist/{index.js.map → node/index.node.js.map} +5 -5
  35. package/dist/node/src/base.d.ts +893 -0
  36. package/dist/{custom-migrator.d.ts → node/src/custom-migrator.d.ts} +0 -1
  37. package/dist/node/src/index.d.ts +32 -0
  38. package/dist/node/src/index.node.d.ts +9 -0
  39. package/dist/{migration-service.d.ts → node/src/migration-service.d.ts} +0 -1
  40. package/dist/{pg → node/src/pg}/adapter.d.ts +0 -1
  41. package/dist/{pg → node/src/pg}/manager.d.ts +0 -1
  42. package/dist/node/src/pglite/adapter.d.ts +74 -0
  43. package/dist/node/src/pglite/manager.d.ts +21 -0
  44. package/dist/node/src/schema/agent.d.ts +327 -0
  45. package/dist/node/src/schema/cache.d.ts +97 -0
  46. package/dist/node/src/schema/channel.d.ts +177 -0
  47. package/dist/node/src/schema/channelParticipant.d.ts +41 -0
  48. package/dist/node/src/schema/component.d.ts +163 -0
  49. package/dist/node/src/schema/embedding.d.ts +193 -0
  50. package/dist/node/src/schema/entity.d.ts +122 -0
  51. package/dist/node/src/schema/factory.d.ts +59 -0
  52. package/dist/node/src/schema/index.d.ts +17 -0
  53. package/dist/node/src/schema/log.d.ts +114 -0
  54. package/dist/node/src/schema/memory.d.ts +188 -0
  55. package/dist/node/src/schema/message.d.ts +1 -0
  56. package/dist/node/src/schema/messageServer.d.ts +126 -0
  57. package/dist/node/src/schema/participant.d.ts +114 -0
  58. package/dist/node/src/schema/relationship.d.ts +156 -0
  59. package/dist/node/src/schema/room.d.ts +192 -0
  60. package/dist/node/src/schema/serverAgent.d.ts +41 -0
  61. package/dist/node/src/schema/tasks.d.ts +225 -0
  62. package/dist/node/src/schema/types.d.ts +68 -0
  63. package/dist/node/src/schema/world.d.ts +114 -0
  64. package/dist/node/src/types.d.ts +15 -0
  65. package/dist/{utils.d.ts → node/src/utils.d.ts} +0 -1
  66. package/dist/node/src/utils.node.d.ts +6 -0
  67. package/dist/node/tsconfig.build.node.tsbuildinfo +1 -0
  68. package/package.json +21 -14
  69. package/types/index.d.ts +21 -0
  70. package/dist/base.d.ts.map +0 -1
  71. package/dist/custom-migrator.d.ts.map +0 -1
  72. package/dist/index.d.ts.map +0 -1
  73. package/dist/migration-service.d.ts.map +0 -1
  74. package/dist/pg/adapter.d.ts.map +0 -1
  75. package/dist/pg/manager.d.ts.map +0 -1
  76. package/dist/pglite/adapter.d.ts.map +0 -1
  77. package/dist/pglite/manager.d.ts.map +0 -1
  78. package/dist/schema/agent.d.ts.map +0 -1
  79. package/dist/schema/cache.d.ts.map +0 -1
  80. package/dist/schema/channel.d.ts.map +0 -1
  81. package/dist/schema/channelParticipant.d.ts.map +0 -1
  82. package/dist/schema/component.d.ts.map +0 -1
  83. package/dist/schema/embedding.d.ts.map +0 -1
  84. package/dist/schema/entity.d.ts.map +0 -1
  85. package/dist/schema/factory.d.ts.map +0 -1
  86. package/dist/schema/index.d.ts.map +0 -1
  87. package/dist/schema/log.d.ts.map +0 -1
  88. package/dist/schema/memory.d.ts.map +0 -1
  89. package/dist/schema/message.d.ts.map +0 -1
  90. package/dist/schema/messageServer.d.ts.map +0 -1
  91. package/dist/schema/participant.d.ts.map +0 -1
  92. package/dist/schema/relationship.d.ts.map +0 -1
  93. package/dist/schema/room.d.ts.map +0 -1
  94. package/dist/schema/serverAgent.d.ts.map +0 -1
  95. package/dist/schema/tasks.d.ts.map +0 -1
  96. package/dist/schema/types.d.ts.map +0 -1
  97. package/dist/schema/world.d.ts.map +0 -1
  98. package/dist/types.d.ts.map +0 -1
  99. package/dist/utils.d.ts.map +0 -1
@@ -0,0 +1,2 @@
1
+ export * from "./index.browser";
2
+ export { default } from "./index.browser";
@@ -891,4 +891,3 @@ export declare abstract class BaseDrizzleAdapter extends DatabaseAdapter<any> {
891
891
  updatedAt: Date;
892
892
  }>;
893
893
  }
894
- //# sourceMappingURL=base.d.ts.map
@@ -0,0 +1,11 @@
1
+ import type { IDatabaseAdapter, UUID } from '@elizaos/core';
2
+ import { type Plugin } from '@elizaos/core';
3
+ /**
4
+ * Create a PGlite adapter for the browser (in-memory by default).
5
+ * No Postgres fallback in browser builds.
6
+ */
7
+ export declare function createDatabaseAdapter(_config: {
8
+ dataDir?: string;
9
+ }, agentId: UUID): IDatabaseAdapter;
10
+ export declare const plugin: Plugin;
11
+ export default plugin;
@@ -72,4 +72,3 @@ export declare class PgliteDatabaseAdapter extends BaseDrizzleAdapter {
72
72
  */
73
73
  getConnection(): Promise<import("@electric-sql/pglite").PGlite>;
74
74
  }
75
- //# sourceMappingURL=adapter.d.ts.map
@@ -19,4 +19,3 @@ export declare class PGliteClientManager implements IDatabaseClientManager<PGlit
19
19
  close(): Promise<void>;
20
20
  private setupShutdownHandlers;
21
21
  }
22
- //# sourceMappingURL=manager.d.ts.map
@@ -325,4 +325,3 @@ export declare const agentTable: import("drizzle-orm/pg-core").PgTableWithColumn
325
325
  };
326
326
  dialect: "pg";
327
327
  }>;
328
- //# sourceMappingURL=agent.d.ts.map
@@ -95,4 +95,3 @@ export declare const cacheTable: import("drizzle-orm/pg-core").PgTableWithColumn
95
95
  };
96
96
  dialect: "pg";
97
97
  }>;
98
- //# sourceMappingURL=cache.d.ts.map
@@ -175,4 +175,3 @@ export declare const channelTable: import("drizzle-orm/pg-core").PgTableWithColu
175
175
  };
176
176
  dialect: "pg";
177
177
  }>;
178
- //# sourceMappingURL=channel.d.ts.map
@@ -39,4 +39,3 @@ export declare const channelParticipantsTable: import("drizzle-orm/pg-core").PgT
39
39
  };
40
40
  dialect: "pg";
41
41
  }>;
42
- //# sourceMappingURL=channelParticipant.d.ts.map
@@ -161,4 +161,3 @@ export declare const componentTable: import("drizzle-orm/pg-core").PgTableWithCo
161
161
  };
162
162
  dialect: "pg";
163
163
  }>;
164
- //# sourceMappingURL=component.d.ts.map
@@ -191,4 +191,3 @@ export type EmbeddingDimensionColumn = 'dim384' | 'dim512' | 'dim768' | 'dim1024
191
191
  * Retrieve the type of a specific column in the EmbeddingTable based on the EmbeddingDimensionColumn key.
192
192
  */
193
193
  export type EmbeddingTableColumn = (typeof embeddingTable._.columns)[EmbeddingDimensionColumn];
194
- //# sourceMappingURL=embedding.d.ts.map
@@ -120,4 +120,3 @@ export declare const entityTable: import("drizzle-orm/pg-core").PgTableWithColum
120
120
  };
121
121
  dialect: "pg";
122
122
  }>;
123
- //# sourceMappingURL=entity.d.ts.map
@@ -57,4 +57,3 @@ export declare class SchemaFactory {
57
57
  }
58
58
  export declare function setDatabaseType(dbType: DatabaseType): void;
59
59
  export declare function getSchemaFactory(): SchemaFactory;
60
- //# sourceMappingURL=factory.d.ts.map
@@ -15,4 +15,3 @@ export { channelTable } from './channel';
15
15
  export { messageTable } from './message';
16
16
  export { channelParticipantsTable } from './channelParticipant';
17
17
  export { serverAgentsTable } from './serverAgent';
18
- //# sourceMappingURL=index.d.ts.map
@@ -112,4 +112,3 @@ export declare const logTable: import("drizzle-orm/pg-core").PgTableWithColumns<
112
112
  };
113
113
  dialect: "pg";
114
114
  }>;
115
- //# sourceMappingURL=log.d.ts.map
@@ -186,4 +186,3 @@ export declare const memoryTable: import("drizzle-orm/pg-core").PgTableWithColum
186
186
  export declare const memoryRelations: import("drizzle-orm").Relations<"memories", {
187
187
  embedding: import("drizzle-orm").One<"embeddings", false>;
188
188
  }>;
189
- //# sourceMappingURL=memory.d.ts.map
@@ -1,2 +1 @@
1
1
  export declare const messageTable: any;
2
- //# sourceMappingURL=message.d.ts.map
@@ -124,4 +124,3 @@ export declare const messageServerTable: import("drizzle-orm/pg-core").PgTableWi
124
124
  };
125
125
  dialect: "pg";
126
126
  }>;
127
- //# sourceMappingURL=messageServer.d.ts.map
@@ -112,4 +112,3 @@ export declare const participantTable: import("drizzle-orm/pg-core").PgTableWith
112
112
  };
113
113
  dialect: "pg";
114
114
  }>;
115
- //# sourceMappingURL=participant.d.ts.map
@@ -154,4 +154,3 @@ export declare const relationshipTable: import("drizzle-orm/pg-core").PgTableWit
154
154
  };
155
155
  dialect: "pg";
156
156
  }>;
157
- //# sourceMappingURL=relationship.d.ts.map
@@ -190,4 +190,3 @@ export declare const roomTable: import("drizzle-orm/pg-core").PgTableWithColumns
190
190
  };
191
191
  dialect: "pg";
192
192
  }>;
193
- //# sourceMappingURL=room.d.ts.map
@@ -39,4 +39,3 @@ export declare const serverAgentsTable: import("drizzle-orm/pg-core").PgTableWit
39
39
  };
40
40
  dialect: "pg";
41
41
  }>;
42
- //# sourceMappingURL=serverAgent.d.ts.map
@@ -223,4 +223,3 @@ export declare const taskTable: import("drizzle-orm/pg-core").PgTableWithColumns
223
223
  };
224
224
  dialect: "pg";
225
225
  }>;
226
- //# sourceMappingURL=tasks.d.ts.map
@@ -66,4 +66,3 @@ export declare const numberTimestamp: {
66
66
  enumValues: undefined;
67
67
  }>;
68
68
  };
69
- //# sourceMappingURL=types.d.ts.map
@@ -112,4 +112,3 @@ export declare const worldTable: import("drizzle-orm/pg-core").PgTableWithColumn
112
112
  };
113
113
  dialect: "pg";
114
114
  }>;
115
- //# sourceMappingURL=world.d.ts.map
@@ -13,4 +13,3 @@ export interface IDatabaseClientManager<T> {
13
13
  getConnection(): T;
14
14
  close(): Promise<void>;
15
15
  }
16
- //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1,21 @@
1
+ /**
2
+ * Browser-safe utils for plugin-sql
3
+ *
4
+ * These versions avoid Node-specific modules (fs/path/dotenv) and simply
5
+ * provide minimal fallbacks appropriate for browser builds.
6
+ */
7
+ /**
8
+ * Expand a tilde-prefixed path.
9
+ * In the browser, paths are not used for storage; just return input.
10
+ */
11
+ export declare function expandTildePath(filepath: string): string;
12
+ /**
13
+ * Resolve an env file path.
14
+ * No-op in browser; returns a placeholder string.
15
+ */
16
+ export declare function resolveEnvFile(_startDir?: string): string;
17
+ /**
18
+ * Resolve PGlite data directory.
19
+ * In browser builds we default to in-memory PGlite; return a stable placeholder.
20
+ */
21
+ export declare function resolvePgliteDir(_dir?: string, _fallbackDir?: string): string;