@xyo-network/diviner-forecasting-memory 2.106.0 → 2.107.1
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.
- package/dist/browser/MemoryForecastingDiviner.d.cts +24 -27
- package/dist/browser/MemoryForecastingDiviner.d.cts.map +1 -1
- package/dist/browser/MemoryForecastingDiviner.d.mts +24 -27
- package/dist/browser/MemoryForecastingDiviner.d.mts.map +1 -1
- package/dist/browser/MemoryForecastingDiviner.d.ts +24 -27
- package/dist/browser/MemoryForecastingDiviner.d.ts.map +1 -1
- package/dist/browser/index.cjs +1 -123
- package/dist/browser/index.cjs.map +1 -1
- package/dist/browser/index.js +1 -92
- package/dist/browser/index.js.map +1 -1
- package/dist/neutral/MemoryForecastingDiviner.d.cts +24 -27
- package/dist/neutral/MemoryForecastingDiviner.d.cts.map +1 -1
- package/dist/neutral/MemoryForecastingDiviner.d.mts +24 -27
- package/dist/neutral/MemoryForecastingDiviner.d.mts.map +1 -1
- package/dist/neutral/MemoryForecastingDiviner.d.ts +24 -27
- package/dist/neutral/MemoryForecastingDiviner.d.ts.map +1 -1
- package/dist/neutral/index.cjs +1 -123
- package/dist/neutral/index.cjs.map +1 -1
- package/dist/neutral/index.js +1 -92
- package/dist/neutral/index.js.map +1 -1
- package/dist/node/MemoryForecastingDiviner.d.cts +24 -27
- package/dist/node/MemoryForecastingDiviner.d.cts.map +1 -1
- package/dist/node/MemoryForecastingDiviner.d.mts +24 -27
- package/dist/node/MemoryForecastingDiviner.d.mts.map +1 -1
- package/dist/node/MemoryForecastingDiviner.d.ts +24 -27
- package/dist/node/MemoryForecastingDiviner.d.ts.map +1 -1
- package/dist/node/index.cjs +1 -130
- package/dist/node/index.cjs.map +1 -1
- package/dist/node/index.js +1 -96
- package/dist/node/index.js.map +1 -1
- package/package.json +12 -12
package/dist/node/index.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/index.ts","../../src/MemoryForecastingDiviner.ts"],"sourcesContent":["export * from './MemoryForecastingDiviner'\n","import { assertEx } from '@xylabs/assert'\nimport { exists } from '@xylabs/exists'\nimport { asArchivistInstance } from '@xyo-network/archivist-model'\nimport { BoundWitness } from '@xyo-network/boundwitness-model'\nimport { BoundWitnessDivinerParams, BoundWitnessDivinerQueryPayload, BoundWitnessDivinerQuerySchema } from '@xyo-network/diviner-boundwitness-model'\nimport { AbstractForecastingDiviner, ForecastingDivinerParams } from '@xyo-network/diviner-forecasting-abstract'\nimport {\n arimaForecastingMethod,\n arimaForecastingName,\n seasonalArimaForecastingMethod,\n seasonalArimaForecastingName,\n} from '@xyo-network/diviner-forecasting-method-arima'\nimport { ForecastingDivinerConfigSchema, ForecastingMethod, PayloadValueTransformer } from '@xyo-network/diviner-forecasting-model'\nimport { asDivinerInstance, DivinerInstance } from '@xyo-network/diviner-model'\nimport { Payload, Schema } from '@xyo-network/payload-model'\nimport jsonpath from 'jsonpath'\n\nexport type SupportedForecastingType = typeof arimaForecastingName | typeof seasonalArimaForecastingName\n\nconst getJsonPathTransformer = (pathExpression: string): PayloadValueTransformer => {\n const transformer = (x: Payload): number => {\n const ret = jsonpath.value(x, pathExpression)\n if (typeof ret === 'number') return ret\n throw new Error('Parsed invalid payload value')\n }\n return transformer\n}\n\nexport class MemoryForecastingDiviner<\n TParams extends ForecastingDivinerParams = ForecastingDivinerParams,\n> extends AbstractForecastingDiviner<TParams> {\n static override readonly configSchemas: Schema[] = [...super.configSchemas, ForecastingDivinerConfigSchema]\n static override readonly defaultConfigSchema: Schema = ForecastingDivinerConfigSchema\n\n protected static readonly forecastingMethodDict: Record<SupportedForecastingType, ForecastingMethod> = {\n arimaForecasting: arimaForecastingMethod,\n seasonalArimaForecasting: seasonalArimaForecastingMethod,\n }\n\n /**\n * The max number of records to search during the batch query\n */\n protected readonly batchLimit = 1000\n\n // TODO: Inject via config\n protected readonly maxTrainingLength = 10_000\n\n get boundWitnessDiviner() {\n return assertEx(this.config.boundWitnessDiviner, () => 'No boundWitnessDiviner configured')\n }\n\n protected override get forecastingMethod(): ForecastingMethod {\n const forecastingMethodName = assertEx(this.config.forecastingMethod, () => 'Missing forecastingMethod in config') as SupportedForecastingType\n const forecastingMethod = MemoryForecastingDiviner.forecastingMethodDict[forecastingMethodName]\n if (forecastingMethod) return forecastingMethod\n throw new Error(`Unsupported forecasting method: ${forecastingMethodName}`)\n }\n\n protected override get transformer(): PayloadValueTransformer {\n const pathExpression = assertEx(this.config.jsonPathExpression, () => 'Missing jsonPathExpression in config')\n return getJsonPathTransformer(pathExpression)\n }\n\n protected override async getPayloadsInWindow(startTimestamp: number, stopTimestamp: number): Promise<Payload[]> {\n const addresses = this.config.witnessAddresses\n const payload_schemas = [assertEx(this.config.witnessSchema, () => 'Missing witnessSchema in config')]\n const payloads: Payload[] = []\n const archivist = asArchivistInstance(await this.archivistInstance(), () => 'Unable to resolve archivist')\n const bwDiviner = asDivinerInstance(\n (await this.resolve(this.boundWitnessDiviner)).pop(),\n 'Unable to resolve boundWitnessDiviner',\n ) as DivinerInstance<BoundWitnessDivinerParams, BoundWitnessDivinerQueryPayload, BoundWitness>\n const limit = this.batchLimit\n const witnessSchema = assertEx(this.config.witnessSchema, () => 'Missing witnessSchema in config')\n let timestamp = stopTimestamp\n let more = true\n\n // TODO: Window size vs sample size\n // Loop until there are no more BWs to process or we've got enough payloads to satisfy the training window\n while (more || payloads.length < this.maxTrainingLength) {\n const query: BoundWitnessDivinerQueryPayload = { addresses, limit, payload_schemas, schema: BoundWitnessDivinerQuerySchema, timestamp }\n const boundWitnesses = (await bwDiviner.divine([query])).filter(\n (bw) => bw.timestamp && bw.timestamp >= startTimestamp && bw.timestamp <= stopTimestamp,\n )\n if (boundWitnesses.length === 0) break\n\n // Update the timestamp value for the next batch\n timestamp = boundWitnesses\n .map((bw) => bw.timestamp)\n .filter(exists)\n // eslint-disable-next-line unicorn/no-array-reduce\n .reduce((a, b) => Math.min(a, b), Number.MAX_SAFE_INTEGER)\n if (timestamp === Number.MAX_SAFE_INTEGER) break\n\n // Set the more flag to false if there are fewer documents returned than the batch size\n more = boundWitnesses.length === limit\n\n // Get the corresponding payload hashes from the BWs\n const hashes = boundWitnesses.map((bw) => bw.payload_hashes[bw.payload_schemas.indexOf(witnessSchema)]).filter(exists)\n\n // Get the payloads corresponding to the BW hashes from the archivist\n if (hashes.length > 0) {\n const batchPayloads = (await archivist.get(hashes)).filter(exists)\n payloads.push(...batchPayloads)\n }\n }\n return payloads\n }\n}\n"],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../../src/index.ts","../../src/MemoryForecastingDiviner.ts"],"sourcesContent":["export * from './MemoryForecastingDiviner'\n","import { assertEx } from '@xylabs/assert'\nimport { exists } from '@xylabs/exists'\nimport { asArchivistInstance } from '@xyo-network/archivist-model'\nimport { BoundWitness } from '@xyo-network/boundwitness-model'\nimport { BoundWitnessDivinerParams, BoundWitnessDivinerQueryPayload, BoundWitnessDivinerQuerySchema } from '@xyo-network/diviner-boundwitness-model'\nimport { AbstractForecastingDiviner, ForecastingDivinerParams } from '@xyo-network/diviner-forecasting-abstract'\nimport {\n arimaForecastingMethod,\n arimaForecastingName,\n seasonalArimaForecastingMethod,\n seasonalArimaForecastingName,\n} from '@xyo-network/diviner-forecasting-method-arima'\nimport { ForecastingDivinerConfigSchema, ForecastingMethod, PayloadValueTransformer } from '@xyo-network/diviner-forecasting-model'\nimport { asDivinerInstance, DivinerInstance } from '@xyo-network/diviner-model'\nimport { Payload, Schema } from '@xyo-network/payload-model'\nimport jsonpath from 'jsonpath'\n\nexport type SupportedForecastingType = typeof arimaForecastingName | typeof seasonalArimaForecastingName\n\nconst getJsonPathTransformer = (pathExpression: string): PayloadValueTransformer => {\n const transformer = (x: Payload): number => {\n const ret = jsonpath.value(x, pathExpression)\n if (typeof ret === 'number') return ret\n throw new Error('Parsed invalid payload value')\n }\n return transformer\n}\n\nexport class MemoryForecastingDiviner<\n TParams extends ForecastingDivinerParams = ForecastingDivinerParams,\n> extends AbstractForecastingDiviner<TParams> {\n static override readonly configSchemas: Schema[] = [...super.configSchemas, ForecastingDivinerConfigSchema]\n static override readonly defaultConfigSchema: Schema = ForecastingDivinerConfigSchema\n\n protected static readonly forecastingMethodDict: Record<SupportedForecastingType, ForecastingMethod> = {\n arimaForecasting: arimaForecastingMethod,\n seasonalArimaForecasting: seasonalArimaForecastingMethod,\n }\n\n /**\n * The max number of records to search during the batch query\n */\n protected readonly batchLimit = 1000\n\n // TODO: Inject via config\n protected readonly maxTrainingLength = 10_000\n\n get boundWitnessDiviner() {\n return assertEx(this.config.boundWitnessDiviner, () => 'No boundWitnessDiviner configured')\n }\n\n protected override get forecastingMethod(): ForecastingMethod {\n const forecastingMethodName = assertEx(this.config.forecastingMethod, () => 'Missing forecastingMethod in config') as SupportedForecastingType\n const forecastingMethod = MemoryForecastingDiviner.forecastingMethodDict[forecastingMethodName]\n if (forecastingMethod) return forecastingMethod\n throw new Error(`Unsupported forecasting method: ${forecastingMethodName}`)\n }\n\n protected override get transformer(): PayloadValueTransformer {\n const pathExpression = assertEx(this.config.jsonPathExpression, () => 'Missing jsonPathExpression in config')\n return getJsonPathTransformer(pathExpression)\n }\n\n protected override async getPayloadsInWindow(startTimestamp: number, stopTimestamp: number): Promise<Payload[]> {\n const addresses = this.config.witnessAddresses\n const payload_schemas = [assertEx(this.config.witnessSchema, () => 'Missing witnessSchema in config')]\n const payloads: Payload[] = []\n const archivist = asArchivistInstance(await this.archivistInstance(), () => 'Unable to resolve archivist')\n const bwDiviner = asDivinerInstance(\n (await this.resolve(this.boundWitnessDiviner)).pop(),\n 'Unable to resolve boundWitnessDiviner',\n ) as DivinerInstance<BoundWitnessDivinerParams, BoundWitnessDivinerQueryPayload, BoundWitness>\n const limit = this.batchLimit\n const witnessSchema = assertEx(this.config.witnessSchema, () => 'Missing witnessSchema in config')\n let timestamp = stopTimestamp\n let more = true\n\n // TODO: Window size vs sample size\n // Loop until there are no more BWs to process or we've got enough payloads to satisfy the training window\n while (more || payloads.length < this.maxTrainingLength) {\n const query: BoundWitnessDivinerQueryPayload = { addresses, limit, payload_schemas, schema: BoundWitnessDivinerQuerySchema, timestamp }\n const boundWitnesses = (await bwDiviner.divine([query])).filter(\n (bw) => bw.timestamp && bw.timestamp >= startTimestamp && bw.timestamp <= stopTimestamp,\n )\n if (boundWitnesses.length === 0) break\n\n // Update the timestamp value for the next batch\n timestamp = boundWitnesses\n .map((bw) => bw.timestamp)\n .filter(exists)\n // eslint-disable-next-line unicorn/no-array-reduce\n .reduce((a, b) => Math.min(a, b), Number.MAX_SAFE_INTEGER)\n if (timestamp === Number.MAX_SAFE_INTEGER) break\n\n // Set the more flag to false if there are fewer documents returned than the batch size\n more = boundWitnesses.length === limit\n\n // Get the corresponding payload hashes from the BWs\n const hashes = boundWitnesses.map((bw) => bw.payload_hashes[bw.payload_schemas.indexOf(witnessSchema)]).filter(exists)\n\n // Get the payloads corresponding to the BW hashes from the archivist\n if (hashes.length > 0) {\n const batchPayloads = (await archivist.get(hashes)).filter(exists)\n payloads.push(...batchPayloads)\n }\n }\n return payloads\n }\n}\n"],"mappings":"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","names":["src_exports","__export","MemoryForecastingDiviner","__toCommonJS","import_assert","import_exists","import_archivist_model","import_diviner_boundwitness_model","import_diviner_forecasting_abstract","import_diviner_forecasting_method_arima","import_diviner_forecasting_model","import_diviner_model","import_jsonpath","getJsonPathTransformer","__name","pathExpression","x","ret","jsonpath","value","Error","MemoryForecastingDiviner","AbstractForecastingDiviner","batchLimit","maxTrainingLength","boundWitnessDiviner","assertEx","config","forecastingMethod","forecastingMethodName","forecastingMethodDict","transformer","jsonPathExpression","getPayloadsInWindow","startTimestamp","stopTimestamp","addresses","witnessAddresses","payload_schemas","witnessSchema","payloads","archivist","asArchivistInstance","archivistInstance","bwDiviner","asDivinerInstance","resolve","pop","limit","timestamp","more","length","query","schema","BoundWitnessDivinerQuerySchema","boundWitnesses","divine","filter","bw","map","exists","reduce","a","b","Math","min","Number","MAX_SAFE_INTEGER","hashes","payload_hashes","indexOf","batchPayloads","get","push","__publicField","configSchemas","__superGet","_MemoryForecastingDiviner","ForecastingDivinerConfigSchema","defaultConfigSchema","arimaForecasting","arimaForecastingMethod","seasonalArimaForecasting","seasonalArimaForecastingMethod"]}
|
package/dist/node/index.js
CHANGED
|
@@ -1,97 +1,2 @@
|
|
|
1
|
-
var
|
|
2
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
3
|
-
var __reflectGet = Reflect.get;
|
|
4
|
-
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
5
|
-
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
6
|
-
var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
7
|
-
var __superGet = (cls, obj, key) => __reflectGet(__getProtoOf(cls), key, obj);
|
|
8
|
-
|
|
9
|
-
// src/MemoryForecastingDiviner.ts
|
|
10
|
-
import { assertEx } from "@xylabs/assert";
|
|
11
|
-
import { exists } from "@xylabs/exists";
|
|
12
|
-
import { asArchivistInstance } from "@xyo-network/archivist-model";
|
|
13
|
-
import { BoundWitnessDivinerQuerySchema } from "@xyo-network/diviner-boundwitness-model";
|
|
14
|
-
import { AbstractForecastingDiviner } from "@xyo-network/diviner-forecasting-abstract";
|
|
15
|
-
import { arimaForecastingMethod, seasonalArimaForecastingMethod } from "@xyo-network/diviner-forecasting-method-arima";
|
|
16
|
-
import { ForecastingDivinerConfigSchema } from "@xyo-network/diviner-forecasting-model";
|
|
17
|
-
import { asDivinerInstance } from "@xyo-network/diviner-model";
|
|
18
|
-
import jsonpath from "jsonpath";
|
|
19
|
-
var getJsonPathTransformer = /* @__PURE__ */ __name((pathExpression) => {
|
|
20
|
-
const transformer = /* @__PURE__ */ __name((x) => {
|
|
21
|
-
const ret = jsonpath.value(x, pathExpression);
|
|
22
|
-
if (typeof ret === "number") return ret;
|
|
23
|
-
throw new Error("Parsed invalid payload value");
|
|
24
|
-
}, "transformer");
|
|
25
|
-
return transformer;
|
|
26
|
-
}, "getJsonPathTransformer");
|
|
27
|
-
var _MemoryForecastingDiviner = class _MemoryForecastingDiviner extends AbstractForecastingDiviner {
|
|
28
|
-
/**
|
|
29
|
-
* The max number of records to search during the batch query
|
|
30
|
-
*/
|
|
31
|
-
batchLimit = 1e3;
|
|
32
|
-
// TODO: Inject via config
|
|
33
|
-
maxTrainingLength = 1e4;
|
|
34
|
-
get boundWitnessDiviner() {
|
|
35
|
-
return assertEx(this.config.boundWitnessDiviner, () => "No boundWitnessDiviner configured");
|
|
36
|
-
}
|
|
37
|
-
get forecastingMethod() {
|
|
38
|
-
const forecastingMethodName = assertEx(this.config.forecastingMethod, () => "Missing forecastingMethod in config");
|
|
39
|
-
const forecastingMethod = _MemoryForecastingDiviner.forecastingMethodDict[forecastingMethodName];
|
|
40
|
-
if (forecastingMethod) return forecastingMethod;
|
|
41
|
-
throw new Error(`Unsupported forecasting method: ${forecastingMethodName}`);
|
|
42
|
-
}
|
|
43
|
-
get transformer() {
|
|
44
|
-
const pathExpression = assertEx(this.config.jsonPathExpression, () => "Missing jsonPathExpression in config");
|
|
45
|
-
return getJsonPathTransformer(pathExpression);
|
|
46
|
-
}
|
|
47
|
-
async getPayloadsInWindow(startTimestamp, stopTimestamp) {
|
|
48
|
-
const addresses = this.config.witnessAddresses;
|
|
49
|
-
const payload_schemas = [
|
|
50
|
-
assertEx(this.config.witnessSchema, () => "Missing witnessSchema in config")
|
|
51
|
-
];
|
|
52
|
-
const payloads = [];
|
|
53
|
-
const archivist = asArchivistInstance(await this.archivistInstance(), () => "Unable to resolve archivist");
|
|
54
|
-
const bwDiviner = asDivinerInstance((await this.resolve(this.boundWitnessDiviner)).pop(), "Unable to resolve boundWitnessDiviner");
|
|
55
|
-
const limit = this.batchLimit;
|
|
56
|
-
const witnessSchema = assertEx(this.config.witnessSchema, () => "Missing witnessSchema in config");
|
|
57
|
-
let timestamp = stopTimestamp;
|
|
58
|
-
let more = true;
|
|
59
|
-
while (more || payloads.length < this.maxTrainingLength) {
|
|
60
|
-
const query = {
|
|
61
|
-
addresses,
|
|
62
|
-
limit,
|
|
63
|
-
payload_schemas,
|
|
64
|
-
schema: BoundWitnessDivinerQuerySchema,
|
|
65
|
-
timestamp
|
|
66
|
-
};
|
|
67
|
-
const boundWitnesses = (await bwDiviner.divine([
|
|
68
|
-
query
|
|
69
|
-
])).filter((bw) => bw.timestamp && bw.timestamp >= startTimestamp && bw.timestamp <= stopTimestamp);
|
|
70
|
-
if (boundWitnesses.length === 0) break;
|
|
71
|
-
timestamp = boundWitnesses.map((bw) => bw.timestamp).filter(exists).reduce((a, b) => Math.min(a, b), Number.MAX_SAFE_INTEGER);
|
|
72
|
-
if (timestamp === Number.MAX_SAFE_INTEGER) break;
|
|
73
|
-
more = boundWitnesses.length === limit;
|
|
74
|
-
const hashes = boundWitnesses.map((bw) => bw.payload_hashes[bw.payload_schemas.indexOf(witnessSchema)]).filter(exists);
|
|
75
|
-
if (hashes.length > 0) {
|
|
76
|
-
const batchPayloads = (await archivist.get(hashes)).filter(exists);
|
|
77
|
-
payloads.push(...batchPayloads);
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
return payloads;
|
|
81
|
-
}
|
|
82
|
-
};
|
|
83
|
-
__name(_MemoryForecastingDiviner, "MemoryForecastingDiviner");
|
|
84
|
-
__publicField(_MemoryForecastingDiviner, "configSchemas", [
|
|
85
|
-
...__superGet(_MemoryForecastingDiviner, _MemoryForecastingDiviner, "configSchemas"),
|
|
86
|
-
ForecastingDivinerConfigSchema
|
|
87
|
-
]);
|
|
88
|
-
__publicField(_MemoryForecastingDiviner, "defaultConfigSchema", ForecastingDivinerConfigSchema);
|
|
89
|
-
__publicField(_MemoryForecastingDiviner, "forecastingMethodDict", {
|
|
90
|
-
arimaForecasting: arimaForecastingMethod,
|
|
91
|
-
seasonalArimaForecasting: seasonalArimaForecastingMethod
|
|
92
|
-
});
|
|
93
|
-
var MemoryForecastingDiviner = _MemoryForecastingDiviner;
|
|
94
|
-
export {
|
|
95
|
-
MemoryForecastingDiviner
|
|
96
|
-
};
|
|
1
|
+
var u=Object.defineProperty;var I=Object.getPrototypeOf;var N=Reflect.get;var P=(e,t,s)=>t in e?u(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s;var c=(e,t)=>u(e,"name",{value:t,configurable:!0});var h=(e,t,s)=>P(e,typeof t!="symbol"?t+"":t,s);var b=(e,t,s)=>N(I(e),s,t);import{assertEx as o}from"@xylabs/assert";import{exists as g}from"@xylabs/exists";import{asArchivistInstance as D}from"@xyo-network/archivist-model";import{BoundWitnessDivinerQuerySchema as y}from"@xyo-network/diviner-boundwitness-model";import{AbstractForecastingDiviner as L}from"@xyo-network/diviner-forecasting-abstract";import{arimaForecastingMethod as T,seasonalArimaForecastingMethod as j}from"@xyo-network/diviner-forecasting-method-arima";import{ForecastingDivinerConfigSchema as v}from"@xyo-network/diviner-forecasting-model";import{asDivinerInstance as U}from"@xyo-network/diviner-model";import k from"jsonpath";var C=c(e=>c(s=>{let a=k.value(s,e);if(typeof a=="number")return a;throw new Error("Parsed invalid payload value")},"transformer"),"getJsonPathTransformer"),n=class n extends L{batchLimit=1e3;maxTrainingLength=1e4;get boundWitnessDiviner(){return o(this.config.boundWitnessDiviner,()=>"No boundWitnessDiviner configured")}get forecastingMethod(){let t=o(this.config.forecastingMethod,()=>"Missing forecastingMethod in config"),s=n.forecastingMethodDict[t];if(s)return s;throw new Error(`Unsupported forecasting method: ${t}`)}get transformer(){let t=o(this.config.jsonPathExpression,()=>"Missing jsonPathExpression in config");return C(t)}async getPayloadsInWindow(t,s){let a=this.config.witnessAddresses,E=[o(this.config.witnessSchema,()=>"Missing witnessSchema in config")],m=[],S=D(await this.archivistInstance(),()=>"Unable to resolve archivist"),x=U((await this.resolve(this.boundWitnessDiviner)).pop(),"Unable to resolve boundWitnessDiviner"),d=this.batchLimit,A=o(this.config.witnessSchema,()=>"Missing witnessSchema in config"),f=s,p=!0;for(;p||m.length<this.maxTrainingLength;){let M={addresses:a,limit:d,payload_schemas:E,schema:y,timestamp:f},r=(await x.divine([M])).filter(i=>i.timestamp&&i.timestamp>=t&&i.timestamp<=s);if(r.length===0||(f=r.map(i=>i.timestamp).filter(g).reduce((i,W)=>Math.min(i,W),Number.MAX_SAFE_INTEGER),f===Number.MAX_SAFE_INTEGER))break;p=r.length===d;let l=r.map(i=>i.payload_hashes[i.payload_schemas.indexOf(A)]).filter(g);if(l.length>0){let i=(await S.get(l)).filter(g);m.push(...i)}}return m}};c(n,"MemoryForecastingDiviner"),h(n,"configSchemas",[...b(n,n,"configSchemas"),v]),h(n,"defaultConfigSchema",v),h(n,"forecastingMethodDict",{arimaForecasting:T,seasonalArimaForecasting:j});var w=n;export{w as MemoryForecastingDiviner};
|
|
97
2
|
//# sourceMappingURL=index.js.map
|
package/dist/node/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/MemoryForecastingDiviner.ts"],"sourcesContent":["import { assertEx } from '@xylabs/assert'\nimport { exists } from '@xylabs/exists'\nimport { asArchivistInstance } from '@xyo-network/archivist-model'\nimport { BoundWitness } from '@xyo-network/boundwitness-model'\nimport { BoundWitnessDivinerParams, BoundWitnessDivinerQueryPayload, BoundWitnessDivinerQuerySchema } from '@xyo-network/diviner-boundwitness-model'\nimport { AbstractForecastingDiviner, ForecastingDivinerParams } from '@xyo-network/diviner-forecasting-abstract'\nimport {\n arimaForecastingMethod,\n arimaForecastingName,\n seasonalArimaForecastingMethod,\n seasonalArimaForecastingName,\n} from '@xyo-network/diviner-forecasting-method-arima'\nimport { ForecastingDivinerConfigSchema, ForecastingMethod, PayloadValueTransformer } from '@xyo-network/diviner-forecasting-model'\nimport { asDivinerInstance, DivinerInstance } from '@xyo-network/diviner-model'\nimport { Payload, Schema } from '@xyo-network/payload-model'\nimport jsonpath from 'jsonpath'\n\nexport type SupportedForecastingType = typeof arimaForecastingName | typeof seasonalArimaForecastingName\n\nconst getJsonPathTransformer = (pathExpression: string): PayloadValueTransformer => {\n const transformer = (x: Payload): number => {\n const ret = jsonpath.value(x, pathExpression)\n if (typeof ret === 'number') return ret\n throw new Error('Parsed invalid payload value')\n }\n return transformer\n}\n\nexport class MemoryForecastingDiviner<\n TParams extends ForecastingDivinerParams = ForecastingDivinerParams,\n> extends AbstractForecastingDiviner<TParams> {\n static override readonly configSchemas: Schema[] = [...super.configSchemas, ForecastingDivinerConfigSchema]\n static override readonly defaultConfigSchema: Schema = ForecastingDivinerConfigSchema\n\n protected static readonly forecastingMethodDict: Record<SupportedForecastingType, ForecastingMethod> = {\n arimaForecasting: arimaForecastingMethod,\n seasonalArimaForecasting: seasonalArimaForecastingMethod,\n }\n\n /**\n * The max number of records to search during the batch query\n */\n protected readonly batchLimit = 1000\n\n // TODO: Inject via config\n protected readonly maxTrainingLength = 10_000\n\n get boundWitnessDiviner() {\n return assertEx(this.config.boundWitnessDiviner, () => 'No boundWitnessDiviner configured')\n }\n\n protected override get forecastingMethod(): ForecastingMethod {\n const forecastingMethodName = assertEx(this.config.forecastingMethod, () => 'Missing forecastingMethod in config') as SupportedForecastingType\n const forecastingMethod = MemoryForecastingDiviner.forecastingMethodDict[forecastingMethodName]\n if (forecastingMethod) return forecastingMethod\n throw new Error(`Unsupported forecasting method: ${forecastingMethodName}`)\n }\n\n protected override get transformer(): PayloadValueTransformer {\n const pathExpression = assertEx(this.config.jsonPathExpression, () => 'Missing jsonPathExpression in config')\n return getJsonPathTransformer(pathExpression)\n }\n\n protected override async getPayloadsInWindow(startTimestamp: number, stopTimestamp: number): Promise<Payload[]> {\n const addresses = this.config.witnessAddresses\n const payload_schemas = [assertEx(this.config.witnessSchema, () => 'Missing witnessSchema in config')]\n const payloads: Payload[] = []\n const archivist = asArchivistInstance(await this.archivistInstance(), () => 'Unable to resolve archivist')\n const bwDiviner = asDivinerInstance(\n (await this.resolve(this.boundWitnessDiviner)).pop(),\n 'Unable to resolve boundWitnessDiviner',\n ) as DivinerInstance<BoundWitnessDivinerParams, BoundWitnessDivinerQueryPayload, BoundWitness>\n const limit = this.batchLimit\n const witnessSchema = assertEx(this.config.witnessSchema, () => 'Missing witnessSchema in config')\n let timestamp = stopTimestamp\n let more = true\n\n // TODO: Window size vs sample size\n // Loop until there are no more BWs to process or we've got enough payloads to satisfy the training window\n while (more || payloads.length < this.maxTrainingLength) {\n const query: BoundWitnessDivinerQueryPayload = { addresses, limit, payload_schemas, schema: BoundWitnessDivinerQuerySchema, timestamp }\n const boundWitnesses = (await bwDiviner.divine([query])).filter(\n (bw) => bw.timestamp && bw.timestamp >= startTimestamp && bw.timestamp <= stopTimestamp,\n )\n if (boundWitnesses.length === 0) break\n\n // Update the timestamp value for the next batch\n timestamp = boundWitnesses\n .map((bw) => bw.timestamp)\n .filter(exists)\n // eslint-disable-next-line unicorn/no-array-reduce\n .reduce((a, b) => Math.min(a, b), Number.MAX_SAFE_INTEGER)\n if (timestamp === Number.MAX_SAFE_INTEGER) break\n\n // Set the more flag to false if there are fewer documents returned than the batch size\n more = boundWitnesses.length === limit\n\n // Get the corresponding payload hashes from the BWs\n const hashes = boundWitnesses.map((bw) => bw.payload_hashes[bw.payload_schemas.indexOf(witnessSchema)]).filter(exists)\n\n // Get the payloads corresponding to the BW hashes from the archivist\n if (hashes.length > 0) {\n const batchPayloads = (await archivist.get(hashes)).filter(exists)\n payloads.push(...batchPayloads)\n }\n }\n return payloads\n }\n}\n"],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../../src/MemoryForecastingDiviner.ts"],"sourcesContent":["import { assertEx } from '@xylabs/assert'\nimport { exists } from '@xylabs/exists'\nimport { asArchivistInstance } from '@xyo-network/archivist-model'\nimport { BoundWitness } from '@xyo-network/boundwitness-model'\nimport { BoundWitnessDivinerParams, BoundWitnessDivinerQueryPayload, BoundWitnessDivinerQuerySchema } from '@xyo-network/diviner-boundwitness-model'\nimport { AbstractForecastingDiviner, ForecastingDivinerParams } from '@xyo-network/diviner-forecasting-abstract'\nimport {\n arimaForecastingMethod,\n arimaForecastingName,\n seasonalArimaForecastingMethod,\n seasonalArimaForecastingName,\n} from '@xyo-network/diviner-forecasting-method-arima'\nimport { ForecastingDivinerConfigSchema, ForecastingMethod, PayloadValueTransformer } from '@xyo-network/diviner-forecasting-model'\nimport { asDivinerInstance, DivinerInstance } from '@xyo-network/diviner-model'\nimport { Payload, Schema } from '@xyo-network/payload-model'\nimport jsonpath from 'jsonpath'\n\nexport type SupportedForecastingType = typeof arimaForecastingName | typeof seasonalArimaForecastingName\n\nconst getJsonPathTransformer = (pathExpression: string): PayloadValueTransformer => {\n const transformer = (x: Payload): number => {\n const ret = jsonpath.value(x, pathExpression)\n if (typeof ret === 'number') return ret\n throw new Error('Parsed invalid payload value')\n }\n return transformer\n}\n\nexport class MemoryForecastingDiviner<\n TParams extends ForecastingDivinerParams = ForecastingDivinerParams,\n> extends AbstractForecastingDiviner<TParams> {\n static override readonly configSchemas: Schema[] = [...super.configSchemas, ForecastingDivinerConfigSchema]\n static override readonly defaultConfigSchema: Schema = ForecastingDivinerConfigSchema\n\n protected static readonly forecastingMethodDict: Record<SupportedForecastingType, ForecastingMethod> = {\n arimaForecasting: arimaForecastingMethod,\n seasonalArimaForecasting: seasonalArimaForecastingMethod,\n }\n\n /**\n * The max number of records to search during the batch query\n */\n protected readonly batchLimit = 1000\n\n // TODO: Inject via config\n protected readonly maxTrainingLength = 10_000\n\n get boundWitnessDiviner() {\n return assertEx(this.config.boundWitnessDiviner, () => 'No boundWitnessDiviner configured')\n }\n\n protected override get forecastingMethod(): ForecastingMethod {\n const forecastingMethodName = assertEx(this.config.forecastingMethod, () => 'Missing forecastingMethod in config') as SupportedForecastingType\n const forecastingMethod = MemoryForecastingDiviner.forecastingMethodDict[forecastingMethodName]\n if (forecastingMethod) return forecastingMethod\n throw new Error(`Unsupported forecasting method: ${forecastingMethodName}`)\n }\n\n protected override get transformer(): PayloadValueTransformer {\n const pathExpression = assertEx(this.config.jsonPathExpression, () => 'Missing jsonPathExpression in config')\n return getJsonPathTransformer(pathExpression)\n }\n\n protected override async getPayloadsInWindow(startTimestamp: number, stopTimestamp: number): Promise<Payload[]> {\n const addresses = this.config.witnessAddresses\n const payload_schemas = [assertEx(this.config.witnessSchema, () => 'Missing witnessSchema in config')]\n const payloads: Payload[] = []\n const archivist = asArchivistInstance(await this.archivistInstance(), () => 'Unable to resolve archivist')\n const bwDiviner = asDivinerInstance(\n (await this.resolve(this.boundWitnessDiviner)).pop(),\n 'Unable to resolve boundWitnessDiviner',\n ) as DivinerInstance<BoundWitnessDivinerParams, BoundWitnessDivinerQueryPayload, BoundWitness>\n const limit = this.batchLimit\n const witnessSchema = assertEx(this.config.witnessSchema, () => 'Missing witnessSchema in config')\n let timestamp = stopTimestamp\n let more = true\n\n // TODO: Window size vs sample size\n // Loop until there are no more BWs to process or we've got enough payloads to satisfy the training window\n while (more || payloads.length < this.maxTrainingLength) {\n const query: BoundWitnessDivinerQueryPayload = { addresses, limit, payload_schemas, schema: BoundWitnessDivinerQuerySchema, timestamp }\n const boundWitnesses = (await bwDiviner.divine([query])).filter(\n (bw) => bw.timestamp && bw.timestamp >= startTimestamp && bw.timestamp <= stopTimestamp,\n )\n if (boundWitnesses.length === 0) break\n\n // Update the timestamp value for the next batch\n timestamp = boundWitnesses\n .map((bw) => bw.timestamp)\n .filter(exists)\n // eslint-disable-next-line unicorn/no-array-reduce\n .reduce((a, b) => Math.min(a, b), Number.MAX_SAFE_INTEGER)\n if (timestamp === Number.MAX_SAFE_INTEGER) break\n\n // Set the more flag to false if there are fewer documents returned than the batch size\n more = boundWitnesses.length === limit\n\n // Get the corresponding payload hashes from the BWs\n const hashes = boundWitnesses.map((bw) => bw.payload_hashes[bw.payload_schemas.indexOf(witnessSchema)]).filter(exists)\n\n // Get the payloads corresponding to the BW hashes from the archivist\n if (hashes.length > 0) {\n const batchPayloads = (await archivist.get(hashes)).filter(exists)\n payloads.push(...batchPayloads)\n }\n }\n return payloads\n }\n}\n"],"mappings":"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","names":["assertEx","exists","asArchivistInstance","BoundWitnessDivinerQuerySchema","AbstractForecastingDiviner","arimaForecastingMethod","seasonalArimaForecastingMethod","ForecastingDivinerConfigSchema","asDivinerInstance","jsonpath","getJsonPathTransformer","__name","pathExpression","x","ret","jsonpath","value","Error","MemoryForecastingDiviner","AbstractForecastingDiviner","batchLimit","maxTrainingLength","boundWitnessDiviner","assertEx","config","forecastingMethod","forecastingMethodName","forecastingMethodDict","transformer","jsonPathExpression","getPayloadsInWindow","startTimestamp","stopTimestamp","addresses","witnessAddresses","payload_schemas","witnessSchema","payloads","archivist","asArchivistInstance","archivistInstance","bwDiviner","asDivinerInstance","resolve","pop","limit","timestamp","more","length","query","schema","BoundWitnessDivinerQuerySchema","boundWitnesses","divine","filter","bw","map","exists","reduce","a","b","Math","min","Number","MAX_SAFE_INTEGER","hashes","payload_hashes","indexOf","batchPayloads","get","push","__publicField","configSchemas","__superGet","_MemoryForecastingDiviner","ForecastingDivinerConfigSchema","defaultConfigSchema","arimaForecasting","arimaForecastingMethod","seasonalArimaForecasting","seasonalArimaForecastingMethod"]}
|
package/package.json
CHANGED
|
@@ -12,21 +12,21 @@
|
|
|
12
12
|
"dependencies": {
|
|
13
13
|
"@xylabs/assert": "^3.5.1",
|
|
14
14
|
"@xylabs/exists": "^3.5.1",
|
|
15
|
-
"@xyo-network/archivist-model": "~2.
|
|
16
|
-
"@xyo-network/boundwitness-model": "~2.
|
|
17
|
-
"@xyo-network/diviner-boundwitness-model": "~2.
|
|
18
|
-
"@xyo-network/diviner-forecasting-abstract": "~2.
|
|
19
|
-
"@xyo-network/diviner-forecasting-method-arima": "~2.
|
|
20
|
-
"@xyo-network/diviner-forecasting-model": "~2.
|
|
21
|
-
"@xyo-network/diviner-model": "~2.
|
|
22
|
-
"@xyo-network/payload-model": "~2.
|
|
15
|
+
"@xyo-network/archivist-model": "~2.107.1",
|
|
16
|
+
"@xyo-network/boundwitness-model": "~2.107.1",
|
|
17
|
+
"@xyo-network/diviner-boundwitness-model": "~2.107.1",
|
|
18
|
+
"@xyo-network/diviner-forecasting-abstract": "~2.107.1",
|
|
19
|
+
"@xyo-network/diviner-forecasting-method-arima": "~2.107.1",
|
|
20
|
+
"@xyo-network/diviner-forecasting-model": "~2.107.1",
|
|
21
|
+
"@xyo-network/diviner-model": "~2.107.1",
|
|
22
|
+
"@xyo-network/payload-model": "~2.107.1",
|
|
23
23
|
"jsonpath": "^1.1.1"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
26
|
"@types/jsonpath": "^0.2.4",
|
|
27
|
-
"@xylabs/ts-scripts-yarn3": "^3.11.
|
|
28
|
-
"@xylabs/tsconfig": "^3.11.
|
|
29
|
-
"typescript": "^5.
|
|
27
|
+
"@xylabs/ts-scripts-yarn3": "^3.11.9",
|
|
28
|
+
"@xylabs/tsconfig": "^3.11.9",
|
|
29
|
+
"typescript": "^5.5.2"
|
|
30
30
|
},
|
|
31
31
|
"description": "Primary SDK for using XYO Protocol 2.0",
|
|
32
32
|
"types": "dist/node/index.d.ts",
|
|
@@ -67,6 +67,6 @@
|
|
|
67
67
|
"url": "https://github.com/XYOracleNetwork/sdk-xyo-client-js.git"
|
|
68
68
|
},
|
|
69
69
|
"sideEffects": false,
|
|
70
|
-
"version": "2.
|
|
70
|
+
"version": "2.107.1",
|
|
71
71
|
"type": "module"
|
|
72
72
|
}
|