@breadboard-ai/data-store
Advanced tools
Comparing version 0.1.0 to 0.2.0
@@ -6,4 +6,5 @@ /** | ||
*/ | ||
import { type DataStore } from "@google-labs/breadboard"; | ||
import { type RunStore, type DataStore } from "@google-labs/breadboard"; | ||
export declare function getDataStore(): DataStore; | ||
export declare function getRunStore(forceInMemoryStore?: boolean): RunStore; | ||
//# sourceMappingURL=index.d.ts.map |
@@ -6,6 +6,20 @@ /** | ||
*/ | ||
import { InMemoryStore } from "./in-memory-store.js"; | ||
import { createDefaultDataStore, createDefaultRunStore, } from "@google-labs/breadboard"; | ||
import { IDBRunStore } from "./run/idb-run-store.js"; | ||
// TODO: Allow for other data stores. | ||
export function getDataStore() { | ||
return new InMemoryStore(); | ||
return createDefaultDataStore(); | ||
} | ||
export function getRunStore(forceInMemoryStore = false) { | ||
if (forceInMemoryStore) { | ||
console.log("[Breadboard Run Store] Using In-Memory Store (forced)"); | ||
return createDefaultRunStore(); | ||
} | ||
if ("indexedDB" in globalThis) { | ||
console.log("[Breadboard Run Store] Using IDB Store"); | ||
return new IDBRunStore(); | ||
} | ||
console.log("[Breadboard Run Store] Using In-Memory Store"); | ||
return createDefaultRunStore(); | ||
} | ||
//# sourceMappingURL=index.js.map |
{ | ||
"name": "@breadboard-ai/data-store", | ||
"version": "0.1.0", | ||
"version": "0.2.0", | ||
"description": "A data store implementation to support Breadboard", | ||
@@ -141,5 +141,5 @@ "main": "./dist/src/index.js", | ||
"@types/mocha": "^10.0.7", | ||
"@types/node": "^20.14.12", | ||
"@typescript-eslint/eslint-plugin": "^7.17.0", | ||
"@typescript-eslint/parser": "^7.17.0", | ||
"@types/node": "^22.0.0", | ||
"@typescript-eslint/eslint-plugin": "^7.18.0", | ||
"@typescript-eslint/parser": "^7.18.0", | ||
"@web/dev-server-esbuild": "^1.0.2", | ||
@@ -149,3 +149,3 @@ "@web/test-runner": "^0.18.2", | ||
"esbuild": "^0.23.0", | ||
"typescript": "^5.5.3" | ||
"typescript": "^5.5.4" | ||
}, | ||
@@ -156,5 +156,5 @@ "engines": { | ||
"dependencies": { | ||
"@google-labs/breadboard": "^0.23.0", | ||
"@google-labs/breadboard": "^0.24.0", | ||
"idb": "^8.0.0" | ||
} | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
Network access
Supply chain riskThis module accesses the network.
Found 1 instance in 1 package
17029
212
+ Added@google-labs/breadboard@0.24.0(transitive)
- Removed@google-labs/breadboard@0.23.0(transitive)