@empressaio/atom-contract 1.7.0
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/CHANGELOG.md +360 -0
- package/README.md +379 -0
- package/dist/composition.d.ts +112 -0
- package/dist/composition.d.ts.map +1 -0
- package/dist/composition.js +80 -0
- package/dist/composition.js.map +1 -0
- package/dist/conformance/common.d.ts +21 -0
- package/dist/conformance/common.d.ts.map +1 -0
- package/dist/conformance/common.js +29 -0
- package/dist/conformance/common.js.map +1 -0
- package/dist/conformance/fixtures.d.ts +13 -0
- package/dist/conformance/fixtures.d.ts.map +1 -0
- package/dist/conformance/fixtures.js +63 -0
- package/dist/conformance/fixtures.js.map +1 -0
- package/dist/conformance/index.d.ts +11 -0
- package/dist/conformance/index.d.ts.map +1 -0
- package/dist/conformance/index.js +11 -0
- package/dist/conformance/index.js.map +1 -0
- package/dist/conformance/validate.d.ts +49 -0
- package/dist/conformance/validate.d.ts.map +1 -0
- package/dist/conformance/validate.js +138 -0
- package/dist/conformance/validate.js.map +1 -0
- package/dist/conformance/verify-chain.d.ts +25 -0
- package/dist/conformance/verify-chain.d.ts.map +1 -0
- package/dist/conformance/verify-chain.js +76 -0
- package/dist/conformance/verify-chain.js.map +1 -0
- package/dist/context.d.ts +134 -0
- package/dist/context.d.ts.map +1 -0
- package/dist/context.js +110 -0
- package/dist/context.js.map +1 -0
- package/dist/encumbrances/administrative-rule.d.ts +128 -0
- package/dist/encumbrances/administrative-rule.d.ts.map +1 -0
- package/dist/encumbrances/administrative-rule.js +18 -0
- package/dist/encumbrances/administrative-rule.js.map +1 -0
- package/dist/encumbrances/common.d.ts +153 -0
- package/dist/encumbrances/common.d.ts.map +1 -0
- package/dist/encumbrances/common.js +124 -0
- package/dist/encumbrances/common.js.map +1 -0
- package/dist/encumbrances/constraint-resolution.d.ts +169 -0
- package/dist/encumbrances/constraint-resolution.d.ts.map +1 -0
- package/dist/encumbrances/constraint-resolution.js +41 -0
- package/dist/encumbrances/constraint-resolution.js.map +1 -0
- package/dist/encumbrances/fixtures.d.ts +16 -0
- package/dist/encumbrances/fixtures.d.ts.map +1 -0
- package/dist/encumbrances/fixtures.js +107 -0
- package/dist/encumbrances/fixtures.js.map +1 -0
- package/dist/encumbrances/index.d.ts +15 -0
- package/dist/encumbrances/index.d.ts.map +1 -0
- package/dist/encumbrances/index.js +15 -0
- package/dist/encumbrances/index.js.map +1 -0
- package/dist/encumbrances/recorded-instrument.d.ts +131 -0
- package/dist/encumbrances/recorded-instrument.d.ts.map +1 -0
- package/dist/encumbrances/recorded-instrument.js +19 -0
- package/dist/encumbrances/recorded-instrument.js.map +1 -0
- package/dist/encumbrances/restriction-clause.d.ts +120 -0
- package/dist/encumbrances/restriction-clause.d.ts.map +1 -0
- package/dist/encumbrances/restriction-clause.js +17 -0
- package/dist/encumbrances/restriction-clause.js.map +1 -0
- package/dist/encumbrances/restriction-corpus.d.ts +44 -0
- package/dist/encumbrances/restriction-corpus.d.ts.map +1 -0
- package/dist/encumbrances/restriction-corpus.js +14 -0
- package/dist/encumbrances/restriction-corpus.js.map +1 -0
- package/dist/export/downloadable-atom.d.ts +133 -0
- package/dist/export/downloadable-atom.d.ts.map +1 -0
- package/dist/export/downloadable-atom.js +115 -0
- package/dist/export/downloadable-atom.js.map +1 -0
- package/dist/export/index.d.ts +6 -0
- package/dist/export/index.d.ts.map +1 -0
- package/dist/export/index.js +6 -0
- package/dist/export/index.js.map +1 -0
- package/dist/history.d.ts +124 -0
- package/dist/history.d.ts.map +1 -0
- package/dist/history.js +170 -0
- package/dist/history.js.map +1 -0
- package/dist/index.d.ts +29 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +20 -0
- package/dist/index.js.map +1 -0
- package/dist/inline-reference.d.ts +60 -0
- package/dist/inline-reference.d.ts.map +1 -0
- package/dist/inline-reference.js +73 -0
- package/dist/inline-reference.js.map +1 -0
- package/dist/obligation.d.ts +131 -0
- package/dist/obligation.d.ts.map +1 -0
- package/dist/obligation.js +55 -0
- package/dist/obligation.js.map +1 -0
- package/dist/og/common.d.ts +253 -0
- package/dist/og/common.d.ts.map +1 -0
- package/dist/og/common.js +195 -0
- package/dist/og/common.js.map +1 -0
- package/dist/og/completion.d.ts +70 -0
- package/dist/og/completion.d.ts.map +1 -0
- package/dist/og/completion.js +22 -0
- package/dist/og/completion.js.map +1 -0
- package/dist/og/equipment-state.d.ts +55 -0
- package/dist/og/equipment-state.d.ts.map +1 -0
- package/dist/og/equipment-state.js +25 -0
- package/dist/og/equipment-state.js.map +1 -0
- package/dist/og/fixtures.d.ts +40 -0
- package/dist/og/fixtures.d.ts.map +1 -0
- package/dist/og/fixtures.js +255 -0
- package/dist/og/fixtures.js.map +1 -0
- package/dist/og/index.d.ts +23 -0
- package/dist/og/index.d.ts.map +1 -0
- package/dist/og/index.js +23 -0
- package/dist/og/index.js.map +1 -0
- package/dist/og/mineral-lease.d.ts +150 -0
- package/dist/og/mineral-lease.d.ts.map +1 -0
- package/dist/og/mineral-lease.js +24 -0
- package/dist/og/mineral-lease.js.map +1 -0
- package/dist/og/ownership-interest.d.ts +163 -0
- package/dist/og/ownership-interest.d.ts.map +1 -0
- package/dist/og/ownership-interest.js +36 -0
- package/dist/og/ownership-interest.js.map +1 -0
- package/dist/og/pad.d.ts +101 -0
- package/dist/og/pad.d.ts.map +1 -0
- package/dist/og/pad.js +19 -0
- package/dist/og/pad.js.map +1 -0
- package/dist/og/production-timeseries.d.ts +154 -0
- package/dist/og/production-timeseries.d.ts.map +1 -0
- package/dist/og/production-timeseries.js +37 -0
- package/dist/og/production-timeseries.js.map +1 -0
- package/dist/og/revenue-allocation-unit.d.ts +762 -0
- package/dist/og/revenue-allocation-unit.d.ts.map +1 -0
- package/dist/og/revenue-allocation-unit.js +105 -0
- package/dist/og/revenue-allocation-unit.js.map +1 -0
- package/dist/og/rrc-lease.d.ts +124 -0
- package/dist/og/rrc-lease.d.ts.map +1 -0
- package/dist/og/rrc-lease.js +29 -0
- package/dist/og/rrc-lease.js.map +1 -0
- package/dist/og/tract.d.ts +88 -0
- package/dist/og/tract.d.ts.map +1 -0
- package/dist/og/tract.js +30 -0
- package/dist/og/tract.js.map +1 -0
- package/dist/og/well.d.ts +201 -0
- package/dist/og/well.d.ts.map +1 -0
- package/dist/og/well.js +40 -0
- package/dist/og/well.js.map +1 -0
- package/dist/og/wellbore.d.ts +61 -0
- package/dist/og/wellbore.d.ts.map +1 -0
- package/dist/og/wellbore.js +25 -0
- package/dist/og/wellbore.js.map +1 -0
- package/dist/og/zone.d.ts +45 -0
- package/dist/og/zone.d.ts.map +1 -0
- package/dist/og/zone.js +16 -0
- package/dist/og/zone.js.map +1 -0
- package/dist/read-contract/common.d.ts +74 -0
- package/dist/read-contract/common.d.ts.map +1 -0
- package/dist/read-contract/common.js +54 -0
- package/dist/read-contract/common.js.map +1 -0
- package/dist/read-contract/consequence.d.ts +99 -0
- package/dist/read-contract/consequence.d.ts.map +1 -0
- package/dist/read-contract/consequence.js +46 -0
- package/dist/read-contract/consequence.js.map +1 -0
- package/dist/read-contract/fixtures.d.ts +8 -0
- package/dist/read-contract/fixtures.d.ts.map +1 -0
- package/dist/read-contract/fixtures.js +44 -0
- package/dist/read-contract/fixtures.js.map +1 -0
- package/dist/read-contract/index.d.ts +14 -0
- package/dist/read-contract/index.d.ts.map +1 -0
- package/dist/read-contract/index.js +14 -0
- package/dist/read-contract/index.js.map +1 -0
- package/dist/read-contract/model-attribution.d.ts +85 -0
- package/dist/read-contract/model-attribution.d.ts.map +1 -0
- package/dist/read-contract/model-attribution.js +30 -0
- package/dist/read-contract/model-attribution.js.map +1 -0
- package/dist/read-contract/read-contract.d.ts +455 -0
- package/dist/read-contract/read-contract.d.ts.map +1 -0
- package/dist/read-contract/read-contract.js +46 -0
- package/dist/read-contract/read-contract.js.map +1 -0
- package/dist/registration.d.ts +192 -0
- package/dist/registration.d.ts.map +1 -0
- package/dist/registration.js +15 -0
- package/dist/registration.js.map +1 -0
- package/dist/registry.d.ts +128 -0
- package/dist/registry.d.ts.map +1 -0
- package/dist/registry.js +122 -0
- package/dist/registry.js.map +1 -0
- package/dist/render.d.ts +30 -0
- package/dist/render.d.ts.map +1 -0
- package/dist/render.js +44 -0
- package/dist/render.js.map +1 -0
- package/dist/scope.d.ts +46 -0
- package/dist/scope.d.ts.map +1 -0
- package/dist/scope.js +17 -0
- package/dist/scope.js.map +1 -0
- package/dist/temporal/anticipatory-atom.d.ts +123 -0
- package/dist/temporal/anticipatory-atom.d.ts.map +1 -0
- package/dist/temporal/anticipatory-atom.js +124 -0
- package/dist/temporal/anticipatory-atom.js.map +1 -0
- package/dist/temporal/common.d.ts +47 -0
- package/dist/temporal/common.d.ts.map +1 -0
- package/dist/temporal/common.js +100 -0
- package/dist/temporal/common.js.map +1 -0
- package/dist/temporal/fixtures.d.ts +7 -0
- package/dist/temporal/fixtures.d.ts.map +1 -0
- package/dist/temporal/fixtures.js +21 -0
- package/dist/temporal/fixtures.js.map +1 -0
- package/dist/temporal/index.d.ts +13 -0
- package/dist/temporal/index.d.ts.map +1 -0
- package/dist/temporal/index.js +13 -0
- package/dist/temporal/index.js.map +1 -0
- package/dist/temporal/interval-query.d.ts +42 -0
- package/dist/temporal/interval-query.d.ts.map +1 -0
- package/dist/temporal/interval-query.js +49 -0
- package/dist/temporal/interval-query.js.map +1 -0
- package/dist/temporal/node-id.d.ts +112 -0
- package/dist/temporal/node-id.d.ts.map +1 -0
- package/dist/temporal/node-id.js +208 -0
- package/dist/temporal/node-id.js.map +1 -0
- package/dist/temporal/would-affect-edge.d.ts +66 -0
- package/dist/temporal/would-affect-edge.d.ts.map +1 -0
- package/dist/temporal/would-affect-edge.js +113 -0
- package/dist/temporal/would-affect-edge.js.map +1 -0
- package/dist/testing/index.d.ts +98 -0
- package/dist/testing/index.d.ts.map +1 -0
- package/dist/testing/index.js +225 -0
- package/dist/testing/index.js.map +1 -0
- package/dist/vda.d.ts +46 -0
- package/dist/vda.d.ts.map +1 -0
- package/dist/vda.js +42 -0
- package/dist/vda.js.map +1 -0
- package/dist/workspace/brief-run.d.ts +104 -0
- package/dist/workspace/brief-run.d.ts.map +1 -0
- package/dist/workspace/brief-run.js +32 -0
- package/dist/workspace/brief-run.js.map +1 -0
- package/dist/workspace/common.d.ts +42 -0
- package/dist/workspace/common.d.ts.map +1 -0
- package/dist/workspace/common.js +26 -0
- package/dist/workspace/common.js.map +1 -0
- package/dist/workspace/fixtures.d.ts +10 -0
- package/dist/workspace/fixtures.d.ts.map +1 -0
- package/dist/workspace/fixtures.js +93 -0
- package/dist/workspace/fixtures.js.map +1 -0
- package/dist/workspace/index.d.ts +13 -0
- package/dist/workspace/index.d.ts.map +1 -0
- package/dist/workspace/index.js +13 -0
- package/dist/workspace/index.js.map +1 -0
- package/dist/workspace/property-workspace.d.ts +148 -0
- package/dist/workspace/property-workspace.d.ts.map +1 -0
- package/dist/workspace/property-workspace.js +21 -0
- package/dist/workspace/property-workspace.js.map +1 -0
- package/dist/workspace/workspace-attachment.d.ts +99 -0
- package/dist/workspace/workspace-attachment.d.ts.map +1 -0
- package/dist/workspace/workspace-attachment.js +35 -0
- package/dist/workspace/workspace-attachment.js.map +1 -0
- package/dist/workspace/workspace-share-edge.d.ts +115 -0
- package/dist/workspace/workspace-share-edge.d.ts.map +1 -0
- package/dist/workspace/workspace-share-edge.js +22 -0
- package/dist/workspace/workspace-share-edge.js.map +1 -0
- package/package.json +107 -0
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Anticipatory event atoms — future-dated claims in the event family.
|
|
3
|
+
*
|
|
4
|
+
* `valid_from` MAY be in the future for anticipatory atoms. This is the
|
|
5
|
+
* only atom type where future valid_from is semantically correct.
|
|
6
|
+
*/
|
|
7
|
+
import { z } from "zod";
|
|
8
|
+
import type { AnticipatoryClaimType, AtomFamily } from "./common.js";
|
|
9
|
+
/** Calibration basis for anticipatory atom confidence. */
|
|
10
|
+
export type AnticipatoryConfidenceBasis = "asserted" | "live";
|
|
11
|
+
export declare const ANTICIPATORY_CONFIDENCE_BASIS_SCHEMA: z.ZodEnum<["asserted", "live"]>;
|
|
12
|
+
/**
|
|
13
|
+
* Confidence on a newly deposited anticipatory atom.
|
|
14
|
+
*
|
|
15
|
+
* `basis` is always `"asserted"` until the resolution calibration loop
|
|
16
|
+
* has accumulated enough outcomes to support `"live"`. Depositors MUST
|
|
17
|
+
* NOT emit `"live"` on initial anticipatory writes — the validator
|
|
18
|
+
* rejects it as a hard error.
|
|
19
|
+
*/
|
|
20
|
+
export interface AnticipatoryConfidence {
|
|
21
|
+
readonly basis: AnticipatoryConfidenceBasis;
|
|
22
|
+
readonly estimate: number;
|
|
23
|
+
}
|
|
24
|
+
export declare const ANTICIPATORY_CONFIDENCE_SCHEMA: z.ZodReadonly<z.ZodObject<{
|
|
25
|
+
basis: z.ZodEnum<["asserted", "live"]>;
|
|
26
|
+
estimate: z.ZodNumber;
|
|
27
|
+
}, "strip", z.ZodTypeAny, {
|
|
28
|
+
estimate: number;
|
|
29
|
+
basis: "asserted" | "live";
|
|
30
|
+
}, {
|
|
31
|
+
estimate: number;
|
|
32
|
+
basis: "asserted" | "live";
|
|
33
|
+
}>>;
|
|
34
|
+
/**
|
|
35
|
+
* An anticipatory atom in the event family.
|
|
36
|
+
*
|
|
37
|
+
* Unknown `anticipatory.<kind>` sub-kinds inherit base event-family
|
|
38
|
+
* read behavior; consumers MUST NOT special-case sub-kind lists.
|
|
39
|
+
*/
|
|
40
|
+
export interface AnticipatoryAtom {
|
|
41
|
+
readonly family: Extract<AtomFamily, "event">;
|
|
42
|
+
readonly claim_type: AnticipatoryClaimType;
|
|
43
|
+
/** ISO 8601 timestamp; MAY be in the future. */
|
|
44
|
+
readonly valid_from: string;
|
|
45
|
+
readonly confidence: AnticipatoryConfidence;
|
|
46
|
+
readonly source: string;
|
|
47
|
+
readonly external_id: string;
|
|
48
|
+
}
|
|
49
|
+
export declare const ANTICIPATORY_ATOM_SCHEMA: z.ZodReadonly<z.ZodObject<{
|
|
50
|
+
family: z.ZodLiteral<"event">;
|
|
51
|
+
claim_type: z.ZodString;
|
|
52
|
+
valid_from: z.ZodString;
|
|
53
|
+
confidence: z.ZodReadonly<z.ZodObject<{
|
|
54
|
+
basis: z.ZodEnum<["asserted", "live"]>;
|
|
55
|
+
estimate: z.ZodNumber;
|
|
56
|
+
}, "strip", z.ZodTypeAny, {
|
|
57
|
+
estimate: number;
|
|
58
|
+
basis: "asserted" | "live";
|
|
59
|
+
}, {
|
|
60
|
+
estimate: number;
|
|
61
|
+
basis: "asserted" | "live";
|
|
62
|
+
}>>;
|
|
63
|
+
source: z.ZodString;
|
|
64
|
+
external_id: z.ZodString;
|
|
65
|
+
}, "strip", z.ZodTypeAny, {
|
|
66
|
+
confidence: Readonly<{
|
|
67
|
+
estimate: number;
|
|
68
|
+
basis: "asserted" | "live";
|
|
69
|
+
}>;
|
|
70
|
+
source: string;
|
|
71
|
+
family: "event";
|
|
72
|
+
claim_type: string;
|
|
73
|
+
valid_from: string;
|
|
74
|
+
external_id: string;
|
|
75
|
+
}, {
|
|
76
|
+
confidence: Readonly<{
|
|
77
|
+
estimate: number;
|
|
78
|
+
basis: "asserted" | "live";
|
|
79
|
+
}>;
|
|
80
|
+
source: string;
|
|
81
|
+
family: "event";
|
|
82
|
+
claim_type: string;
|
|
83
|
+
valid_from: string;
|
|
84
|
+
external_id: string;
|
|
85
|
+
}>>;
|
|
86
|
+
export type AnticipatoryAtomValidationCode = "invalid-claim-type" | "invalid-valid-from" | "invalid-confidence-basis" | "invalid-confidence";
|
|
87
|
+
export interface AnticipatoryAtomValidationIssue {
|
|
88
|
+
readonly code: AnticipatoryAtomValidationCode;
|
|
89
|
+
readonly path: string;
|
|
90
|
+
readonly message: string;
|
|
91
|
+
readonly severity: "error" | "warning";
|
|
92
|
+
}
|
|
93
|
+
export interface AnticipatoryAtomValidationResult {
|
|
94
|
+
readonly ok: boolean;
|
|
95
|
+
readonly atom?: AnticipatoryAtom;
|
|
96
|
+
readonly issues: ReadonlyArray<AnticipatoryAtomValidationIssue>;
|
|
97
|
+
}
|
|
98
|
+
export interface ValidateAnticipatoryAtomInput {
|
|
99
|
+
family: unknown;
|
|
100
|
+
claim_type: unknown;
|
|
101
|
+
valid_from: unknown;
|
|
102
|
+
confidence: unknown;
|
|
103
|
+
source: unknown;
|
|
104
|
+
external_id: unknown;
|
|
105
|
+
}
|
|
106
|
+
/**
|
|
107
|
+
* Validate and round-trip an anticipatory atom. Future `valid_from` is
|
|
108
|
+
* permitted. Non-`asserted` confidence basis on new deposits is rejected.
|
|
109
|
+
*/
|
|
110
|
+
export declare function validateAnticipatoryAtom(input: ValidateAnticipatoryAtomInput): AnticipatoryAtomValidationResult;
|
|
111
|
+
/**
|
|
112
|
+
* Data-quality warning: future `valid_from` on a non-anticipatory atom.
|
|
113
|
+
* Not a hard error — backends may still persist, but callers should flag.
|
|
114
|
+
*/
|
|
115
|
+
export declare function warnFutureValidFromOnNonAnticipatory(input: {
|
|
116
|
+
claim_type: string;
|
|
117
|
+
valid_from: string;
|
|
118
|
+
asOf?: Date;
|
|
119
|
+
}): AnticipatoryAtomValidationIssue | null;
|
|
120
|
+
export declare function createAnticipatoryAtom(input: Omit<AnticipatoryAtom, "confidence"> & {
|
|
121
|
+
confidence?: Pick<AnticipatoryConfidence, "estimate">;
|
|
122
|
+
}): AnticipatoryAtom;
|
|
123
|
+
//# sourceMappingURL=anticipatory-atom.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"anticipatory-atom.d.ts","sourceRoot":"","sources":["../../src/temporal/anticipatory-atom.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAOxB,OAAO,KAAK,EAAE,qBAAqB,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAErE,0DAA0D;AAC1D,MAAM,MAAM,2BAA2B,GAAG,UAAU,GAAG,MAAM,CAAC;AAE9D,eAAO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AChB,UAAU,EAAE,OAAO,CAAC;IACpB,UAAU,EAAE,OAAO,CAAC;IACpB,UAAU,EAAE,OAAO,CAAC;IACpB,MAAM,EAAE,OAAO,CAAC;IAChB,WAAW,EAAE,OAAO,CAAC;CACtB;AAED;;;GAGG;AACH,wBAAgB,wBAAwB,CACtC,KAAK,EAAE,6BAA6B,GACnC,gCAAgC,CAkElC;AAED;;;GAGG;AACH,wBAAgB,oCAAoC,CAAC,KAAK,EAAE;IAC1D,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,CAAC,EAAE,IAAI,CAAC;CACb,GAAG,+BAA+B,GAAG,IAAI,CAgBzC;AAED,wBAAgB,sBAAsB,CACpC,KAAK,EAAE,IAAI,CAAC,gBAAgB,EAAE,YAAY,CAAC,GAAG;IAC5C,UAAU,CAAC,EAAE,IAAI,CAAC,sBAAsB,EAAE,UAAU,CAAC,CAAC;CACvD,GACA,gBAAgB,CAelB"}
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Anticipatory event atoms — future-dated claims in the event family.
|
|
3
|
+
*
|
|
4
|
+
* `valid_from` MAY be in the future for anticipatory atoms. This is the
|
|
5
|
+
* only atom type where future valid_from is semantically correct.
|
|
6
|
+
*/
|
|
7
|
+
import { z } from "zod";
|
|
8
|
+
import { ATOM_FAMILY_SCHEMA, isAnticipatoryClaimType, isIsoTimestamp, } from "./common.js";
|
|
9
|
+
export const ANTICIPATORY_CONFIDENCE_BASIS_SCHEMA = z.enum(["asserted", "live"]);
|
|
10
|
+
export const ANTICIPATORY_CONFIDENCE_SCHEMA = z
|
|
11
|
+
.object({
|
|
12
|
+
basis: ANTICIPATORY_CONFIDENCE_BASIS_SCHEMA,
|
|
13
|
+
estimate: z.number().min(0).max(1),
|
|
14
|
+
})
|
|
15
|
+
.readonly();
|
|
16
|
+
export const ANTICIPATORY_ATOM_SCHEMA = z
|
|
17
|
+
.object({
|
|
18
|
+
family: z.literal("event"),
|
|
19
|
+
claim_type: z.string().min(1),
|
|
20
|
+
valid_from: z.string().min(1),
|
|
21
|
+
confidence: ANTICIPATORY_CONFIDENCE_SCHEMA,
|
|
22
|
+
source: z.string().min(1),
|
|
23
|
+
external_id: z.string().min(1),
|
|
24
|
+
})
|
|
25
|
+
.readonly();
|
|
26
|
+
/**
|
|
27
|
+
* Validate and round-trip an anticipatory atom. Future `valid_from` is
|
|
28
|
+
* permitted. Non-`asserted` confidence basis on new deposits is rejected.
|
|
29
|
+
*/
|
|
30
|
+
export function validateAnticipatoryAtom(input) {
|
|
31
|
+
const issues = [];
|
|
32
|
+
const parsed = ANTICIPATORY_ATOM_SCHEMA.safeParse(input);
|
|
33
|
+
if (!parsed.success) {
|
|
34
|
+
return {
|
|
35
|
+
ok: false,
|
|
36
|
+
issues: [
|
|
37
|
+
{
|
|
38
|
+
code: "invalid-claim-type",
|
|
39
|
+
path: "",
|
|
40
|
+
message: parsed.error.message,
|
|
41
|
+
severity: "error",
|
|
42
|
+
},
|
|
43
|
+
],
|
|
44
|
+
};
|
|
45
|
+
}
|
|
46
|
+
const data = parsed.data;
|
|
47
|
+
const familyParsed = ATOM_FAMILY_SCHEMA.safeParse(data.family);
|
|
48
|
+
if (!familyParsed.success || familyParsed.data !== "event") {
|
|
49
|
+
issues.push({
|
|
50
|
+
code: "invalid-claim-type",
|
|
51
|
+
path: "family",
|
|
52
|
+
message: 'anticipatory atoms must use family "event"',
|
|
53
|
+
severity: "error",
|
|
54
|
+
});
|
|
55
|
+
}
|
|
56
|
+
if (!isAnticipatoryClaimType(data.claim_type)) {
|
|
57
|
+
issues.push({
|
|
58
|
+
code: "invalid-claim-type",
|
|
59
|
+
path: "claim_type",
|
|
60
|
+
message: `claim_type must match anticipatory.<kind>; got "${data.claim_type}"`,
|
|
61
|
+
severity: "error",
|
|
62
|
+
});
|
|
63
|
+
}
|
|
64
|
+
if (!isIsoTimestamp(data.valid_from)) {
|
|
65
|
+
issues.push({
|
|
66
|
+
code: "invalid-valid-from",
|
|
67
|
+
path: "valid_from",
|
|
68
|
+
message: `valid_from must be a valid ISO 8601 timestamp; got "${data.valid_from}"`,
|
|
69
|
+
severity: "error",
|
|
70
|
+
});
|
|
71
|
+
}
|
|
72
|
+
if (data.confidence.basis !== "asserted") {
|
|
73
|
+
issues.push({
|
|
74
|
+
code: "invalid-confidence-basis",
|
|
75
|
+
path: "confidence.basis",
|
|
76
|
+
message: `new anticipatory atoms require confidence.basis "asserted"; got "${data.confidence.basis}"`,
|
|
77
|
+
severity: "error",
|
|
78
|
+
});
|
|
79
|
+
}
|
|
80
|
+
if (issues.some((i) => i.severity === "error")) {
|
|
81
|
+
return { ok: false, issues };
|
|
82
|
+
}
|
|
83
|
+
return {
|
|
84
|
+
ok: true,
|
|
85
|
+
atom: data,
|
|
86
|
+
issues,
|
|
87
|
+
};
|
|
88
|
+
}
|
|
89
|
+
/**
|
|
90
|
+
* Data-quality warning: future `valid_from` on a non-anticipatory atom.
|
|
91
|
+
* Not a hard error — backends may still persist, but callers should flag.
|
|
92
|
+
*/
|
|
93
|
+
export function warnFutureValidFromOnNonAnticipatory(input) {
|
|
94
|
+
if (isAnticipatoryClaimType(input.claim_type))
|
|
95
|
+
return null;
|
|
96
|
+
if (!isIsoTimestamp(input.valid_from))
|
|
97
|
+
return null;
|
|
98
|
+
const asOf = input.asOf ?? new Date();
|
|
99
|
+
const validFromMs = Date.parse(input.valid_from);
|
|
100
|
+
if (validFromMs <= asOf.getTime())
|
|
101
|
+
return null;
|
|
102
|
+
return {
|
|
103
|
+
code: "invalid-valid-from",
|
|
104
|
+
path: "valid_from",
|
|
105
|
+
message: "future valid_from is only semantically valid for anticipatory atoms; " +
|
|
106
|
+
`claim_type "${input.claim_type}" is not anticipatory`,
|
|
107
|
+
severity: "warning",
|
|
108
|
+
};
|
|
109
|
+
}
|
|
110
|
+
export function createAnticipatoryAtom(input) {
|
|
111
|
+
const candidate = {
|
|
112
|
+
...input,
|
|
113
|
+
confidence: {
|
|
114
|
+
basis: "asserted",
|
|
115
|
+
estimate: input.confidence?.estimate ?? 0.5,
|
|
116
|
+
},
|
|
117
|
+
};
|
|
118
|
+
const result = validateAnticipatoryAtom(candidate);
|
|
119
|
+
if (!result.ok || !result.atom) {
|
|
120
|
+
throw new Error(result.issues.map((i) => i.message).join("; ") || "invalid anticipatory atom");
|
|
121
|
+
}
|
|
122
|
+
return result.atom;
|
|
123
|
+
}
|
|
124
|
+
//# sourceMappingURL=anticipatory-atom.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"anticipatory-atom.js","sourceRoot":"","sources":["../../src/temporal/anticipatory-atom.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EACL,kBAAkB,EAClB,uBAAuB,EACvB,cAAc,GACf,MAAM,aAAa,CAAC;AAMrB,MAAM,CAAC,MAAM,oCAAoC,GAAG,CAAC,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC,CAAC;AAejF,MAAM,CAAC,MAAM,8BAA8B,GAAG,CAAC;KAC5C,MAAM,CAAC;IACN,KAAK,EAAE,oCAAoC;IAC3C,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;CACnC,CAAC;KACD,QAAQ,EAAE,CAAC;AAkBd,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC;KACtC,MAAM,CAAC;IACN,MAAM,EAAE,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC;IAC1B,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;IAC7B,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;IAC7B,UAAU,EAAE,8BAA8B;IAC1C,MAAM,EAAE,CAAC,CAAC,MAA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E,oBAAoB;QAC1B,IAAI,EAAE,YAAY;QAClB,OAAO,EACL,uEAAuE;YACvE,eAAe,KAAK,CAAC,UAAU,uBAAuB;QACxD,QAAQ,EAAE,SAAS;KACpB,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,sBAAsB,CACpC,KAEC;IAED,MAAM,SAAS,GAAG;QAChB,GAAG,KAAK;QACR,UAAU,EAAE;YACV,KAAK,EAAE,UAAmB;YAC1B,QAAQ,EAAE,KAAK,CAAC,UAAU,EAAE,QAAQ,IAAI,GAAG;SAC5C;KACF,CAAC;IACF,MAAM,MAAM,GAAG,wBAAwB,CAAC,SAAS,CAAC,CAAC;IACnD,IAAI,CAAC,MAAM,CAAC,EAAE,IAAI,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC;QAC/B,MAAM,IAAI,KAAK,CACb,MAAM,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,2BAA2B,CAC9E,CAAC;IACJ,CAAC;IACD,OAAO,MAAM,CAAC,IAAI,CAAC;AACrB,CAAC"}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Temporal-Context Engine substrate types (TCE spec).
|
|
3
|
+
*
|
|
4
|
+
* Atom families, claim-type vocabulary, node-type prefixes, and edge
|
|
5
|
+
* unions consumed by hauska-engine retrieval and cc-agent-C / cc-agent-E.
|
|
6
|
+
*/
|
|
7
|
+
import { z } from "zod";
|
|
8
|
+
/**
|
|
9
|
+
* Top-level atom family discriminator. Anticipatory atoms slot into the
|
|
10
|
+
* `"event"` family — no separate family value is introduced in v1.6.0.
|
|
11
|
+
*/
|
|
12
|
+
export type AtomFamily = "event" | "claim" | "observation" | "derived";
|
|
13
|
+
export declare const ATOM_FAMILY_VALUES: ReadonlyArray<AtomFamily>;
|
|
14
|
+
export declare const ATOM_FAMILY_SCHEMA: z.ZodEnum<["event", "claim", "observation", "derived"]>;
|
|
15
|
+
/** Base event-family claim types (non-anticipatory). */
|
|
16
|
+
export type BaseEventClaimType = "event.resolution" | "event.filing" | "event.notice" | "event.observation";
|
|
17
|
+
export declare const BASE_EVENT_CLAIM_TYPE_VALUES: ReadonlyArray<BaseEventClaimType>;
|
|
18
|
+
/**
|
|
19
|
+
* Anticipatory claim types use the open-ended prefix `anticipatory.<kind>`.
|
|
20
|
+
* Unknown sub-kinds (e.g. `anticipatory.calendar_item`,
|
|
21
|
+
* `anticipatory.legislative_item`, `anticipatory.regulatory_notice`) fall
|
|
22
|
+
* back to base event-family behavior at read time.
|
|
23
|
+
*/
|
|
24
|
+
export type AnticipatoryClaimType = `anticipatory.${string}`;
|
|
25
|
+
/** Event-family claim types including the anticipatory prefix pattern. */
|
|
26
|
+
export type EventClaimType = BaseEventClaimType | AnticipatoryClaimType;
|
|
27
|
+
/** Claim-type union across all families (v1.6.0 extends the event family). */
|
|
28
|
+
export type ClaimType = EventClaimType;
|
|
29
|
+
/** Requires a non-empty sub-kind after `anticipatory.` — bare `anticipatory` fails. */
|
|
30
|
+
export declare const ANTICIPATORY_CLAIM_TYPE_PATTERN: RegExp;
|
|
31
|
+
export declare function isAnticipatoryClaimType(claimType: string): claimType is AnticipatoryClaimType;
|
|
32
|
+
export declare function isEventClaimType(claimType: string): claimType is EventClaimType;
|
|
33
|
+
/**
|
|
34
|
+
* Registered node-type ID prefixes. Every stable graph node ID begins with
|
|
35
|
+
* one of these prefixes. 1.7.0 extension: O&G prefixes per ADR-025.
|
|
36
|
+
*/
|
|
37
|
+
export type NodeTypePrefix = "parcel_" | "jurisdiction_" | "code-section_" | "security_" | "evt_" | "well_" | "wbore_" | "cmpl_" | "zone_" | "pad_" | "mlease_" | "rrclease_" | "tract_" | "intr_" | "oblg_" | "prodts_" | "equip_" | "unit_";
|
|
38
|
+
export declare const NODE_TYPE_PREFIX_VALUES: ReadonlyArray<NodeTypePrefix>;
|
|
39
|
+
export declare const NODE_TYPE_PREFIX_SCHEMA: z.ZodEnum<["parcel_", "jurisdiction_", "code-section_", "security_", "evt_", "well_", "wbore_", "cmpl_", "zone_", "pad_", "mlease_", "rrclease_", "tract_", "intr_", "oblg_", "prodts_", "equip_", "unit_"]>;
|
|
40
|
+
/** ISO 8601 calendar date (YYYY-MM-DD). */
|
|
41
|
+
export declare const ISO_DATE_PATTERN: RegExp;
|
|
42
|
+
export declare function isIsoDate(value: string): boolean;
|
|
43
|
+
/** ISO 8601 timestamp — date or date-time. */
|
|
44
|
+
export declare function isIsoTimestamp(value: string): boolean;
|
|
45
|
+
export declare function hasNodeTypePrefix(nodeId: string, prefix: NodeTypePrefix): boolean;
|
|
46
|
+
export declare function detectNodeTypePrefix(nodeId: string): NodeTypePrefix | null;
|
|
47
|
+
//# sourceMappingURL=common.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"common.d.ts","sourceRoot":"","sources":["../../src/temporal/common.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;GAGG;AACH,MAAM,MAAM,UAAU,GAAG,OAAO,GAAG,OAAO,GAAG,aAAa,GAAG,SAAS,CAAC;AAEvE,eAAO,MAAM,kBAAkB,EAAE,aAAa,CAAC,UAAU,CAKxD,CAAC;AAEF,eAAO,MAAM,kBAAkB,yDAK7B,CAAC;AAEH,wDAAwD;AACxD,MAAM,MAAM,kBAAkB,GAC1B,kBAAkB,GAClB,cAAc,GACd,cAAc,GACd,mBAAmB,CAAC;AAExB,eAAO,MAAM,4BAA4B,EAAE,aAAa,CAAC,kBAAkB,CAK1E,CAAC;AAEF;;;;;GAKG;AACH,MAAM,MAAM,qBAAqB,GAAG,gBAAgB,MAAM,EAAE,CAAC;AAE7D,0EAA0E;AAC1E,MAAM,MAAM,cAAc,GAAG,kBAAkB,GAAG,qBAAqB,CAAC;AAExE,8EAA8E;AAC9E,MAAM,MAAM,SAAS,GAAG,cAAc,CAAC;AAEvC,uFAAuF;AACvF,eAAO,MAAM,+BAA+B,QAAsC,CAAC;AAEnF,wBAAgB,uBAAuB,CACrC,SAAS,EAAE,MAAM,GAChB,SAAS,IAAI,qBAAqB,CAEpC;AAED,wBAAgB,gBAAgB,CAAC,SAAS,EAAE,MAAM,GAAG,SAAS,IAAI,cAAc,CAK/E;AAED;;;GAGG;AACH,MAAM,MAAM,cAAc,GACtB,SAAS,GACT,eAAe,GACf,eAAe,GACf,WAAW,GACX,MAAM,GACN,OAAO,GACP,QAAQ,GACR,OAAO,GACP,OAAO,GACP,MAAM,GACN,SAAS,GACT,WAAW,GACX,QAAQ,GACR,OAAO,GACP,OAAO,GACP,SAAS,GACT,QAAQ,GACR,OAAO,CAAC;AAEZ,eAAO,MAAM,uBAAuB,EAAE,aAAa,CAAC,cAAc,CAmBjE,CAAC;AAEF,eAAO,MAAM,uBAAuB,8MAmBlC,CAAC;AAEH,2CAA2C;AAC3C,eAAO,MAAM,gBAAgB,QAAwB,CAAC;AAEtD,wBAAgB,SAAS,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAIhD;AAED,8CAA8C;AAC9C,wBAAgB,cAAc,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAGrD;AAED,wBAAgB,iBAAiB,CAC/B,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,cAAc,GACrB,OAAO,CAET;AAED,wBAAgB,oBAAoB,CAAC,MAAM,EAAE,MAAM,GAAG,cAAc,GAAG,IAAI,CAK1E"}
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Temporal-Context Engine substrate types (TCE spec).
|
|
3
|
+
*
|
|
4
|
+
* Atom families, claim-type vocabulary, node-type prefixes, and edge
|
|
5
|
+
* unions consumed by hauska-engine retrieval and cc-agent-C / cc-agent-E.
|
|
6
|
+
*/
|
|
7
|
+
import { z } from "zod";
|
|
8
|
+
export const ATOM_FAMILY_VALUES = [
|
|
9
|
+
"event",
|
|
10
|
+
"claim",
|
|
11
|
+
"observation",
|
|
12
|
+
"derived",
|
|
13
|
+
];
|
|
14
|
+
export const ATOM_FAMILY_SCHEMA = z.enum([
|
|
15
|
+
"event",
|
|
16
|
+
"claim",
|
|
17
|
+
"observation",
|
|
18
|
+
"derived",
|
|
19
|
+
]);
|
|
20
|
+
export const BASE_EVENT_CLAIM_TYPE_VALUES = [
|
|
21
|
+
"event.resolution",
|
|
22
|
+
"event.filing",
|
|
23
|
+
"event.notice",
|
|
24
|
+
"event.observation",
|
|
25
|
+
];
|
|
26
|
+
/** Requires a non-empty sub-kind after `anticipatory.` — bare `anticipatory` fails. */
|
|
27
|
+
export const ANTICIPATORY_CLAIM_TYPE_PATTERN = /^anticipatory\.[^.]+(?:\.[^.]+)*$/;
|
|
28
|
+
export function isAnticipatoryClaimType(claimType) {
|
|
29
|
+
return ANTICIPATORY_CLAIM_TYPE_PATTERN.test(claimType);
|
|
30
|
+
}
|
|
31
|
+
export function isEventClaimType(claimType) {
|
|
32
|
+
if (BASE_EVENT_CLAIM_TYPE_VALUES.includes(claimType)) {
|
|
33
|
+
return true;
|
|
34
|
+
}
|
|
35
|
+
return isAnticipatoryClaimType(claimType);
|
|
36
|
+
}
|
|
37
|
+
export const NODE_TYPE_PREFIX_VALUES = [
|
|
38
|
+
"parcel_",
|
|
39
|
+
"jurisdiction_",
|
|
40
|
+
"code-section_",
|
|
41
|
+
"security_",
|
|
42
|
+
"evt_",
|
|
43
|
+
"well_",
|
|
44
|
+
"wbore_",
|
|
45
|
+
"cmpl_",
|
|
46
|
+
"zone_",
|
|
47
|
+
"pad_",
|
|
48
|
+
"mlease_",
|
|
49
|
+
"rrclease_",
|
|
50
|
+
"tract_",
|
|
51
|
+
"intr_",
|
|
52
|
+
"oblg_",
|
|
53
|
+
"prodts_",
|
|
54
|
+
"equip_",
|
|
55
|
+
"unit_",
|
|
56
|
+
];
|
|
57
|
+
export const NODE_TYPE_PREFIX_SCHEMA = z.enum([
|
|
58
|
+
"parcel_",
|
|
59
|
+
"jurisdiction_",
|
|
60
|
+
"code-section_",
|
|
61
|
+
"security_",
|
|
62
|
+
"evt_",
|
|
63
|
+
"well_",
|
|
64
|
+
"wbore_",
|
|
65
|
+
"cmpl_",
|
|
66
|
+
"zone_",
|
|
67
|
+
"pad_",
|
|
68
|
+
"mlease_",
|
|
69
|
+
"rrclease_",
|
|
70
|
+
"tract_",
|
|
71
|
+
"intr_",
|
|
72
|
+
"oblg_",
|
|
73
|
+
"prodts_",
|
|
74
|
+
"equip_",
|
|
75
|
+
"unit_",
|
|
76
|
+
]);
|
|
77
|
+
/** ISO 8601 calendar date (YYYY-MM-DD). */
|
|
78
|
+
export const ISO_DATE_PATTERN = /^\d{4}-\d{2}-\d{2}$/;
|
|
79
|
+
export function isIsoDate(value) {
|
|
80
|
+
if (!ISO_DATE_PATTERN.test(value))
|
|
81
|
+
return false;
|
|
82
|
+
const parsed = Date.parse(`${value}T00:00:00.000Z`);
|
|
83
|
+
return !Number.isNaN(parsed);
|
|
84
|
+
}
|
|
85
|
+
/** ISO 8601 timestamp — date or date-time. */
|
|
86
|
+
export function isIsoTimestamp(value) {
|
|
87
|
+
const parsed = Date.parse(value);
|
|
88
|
+
return !Number.isNaN(parsed);
|
|
89
|
+
}
|
|
90
|
+
export function hasNodeTypePrefix(nodeId, prefix) {
|
|
91
|
+
return nodeId.startsWith(prefix);
|
|
92
|
+
}
|
|
93
|
+
export function detectNodeTypePrefix(nodeId) {
|
|
94
|
+
for (const prefix of NODE_TYPE_PREFIX_VALUES) {
|
|
95
|
+
if (nodeId.startsWith(prefix))
|
|
96
|
+
return prefix;
|
|
97
|
+
}
|
|
98
|
+
return null;
|
|
99
|
+
}
|
|
100
|
+
//# sourceMappingURL=common.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"common.js","sourceRoot":"","sources":["../../src/temporal/common.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,CAA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OAAO;CACR,CAAC,CAAC;AAEH,2CAA2C;AAC3C,MAAM,CAAC,MAAM,gBAAgB,GAAG,qBAAqB,CAAC;AAEtD,MAAM,UAAU,SAAS,CAAC,KAAa;IACrC,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,KAAK,CAAC;QAAE,OAAO,KAAK,CAAC;IAChD,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,KAAK,gBAAgB,CAAC,CAAC;IACpD,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;AAC/B,CAAC;AAED,8CAA8C;AAC9C,MAAM,UAAU,cAAc,CAAC,KAAa;IAC1C,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;IACjC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;AAC/B,CAAC;AAED,MAAM,UAAU,iBAAiB,CAC/B,MAAc,EACd,MAAsB;IAEtB,OAAO,MAAM,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC;AACnC,CAAC;AAED,MAAM,UAAU,oBAAoB,CAAC,MAAc;IACjD,KAAK,MAAM,MAAM,IAAI,uBAAuB,EAAE,CAAC;QAC7C,IAAI,MAAM,CAAC,UAAU,CAAC,MAAM,CAAC;YAAE,OAAO,MAAM,CAAC;IAC/C,CAAC;IACD,OAAO,IAAI,CAAC;AACd,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { AnticipatoryAtom } from "./anticipatory-atom.js";
|
|
2
|
+
import type { WouldAffectEdge } from "./would-affect-edge.js";
|
|
3
|
+
export declare const SAMPLE_EVT_NODE_ID: string;
|
|
4
|
+
/** Anticipatory atom with future valid_from — valid round-trip fixture. */
|
|
5
|
+
export declare const SAMPLE_ANTICIPATORY_ATOM: AnticipatoryAtom;
|
|
6
|
+
export declare const SAMPLE_WOULD_AFFECT_EDGE: WouldAffectEdge;
|
|
7
|
+
//# sourceMappingURL=fixtures.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fixtures.d.ts","sourceRoot":"","sources":["../../src/temporal/fixtures.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC/D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAK9D,eAAO,MAAM,kBAAkB,QAG9B,CAAC;AAEF,2EAA2E;AAC3E,eAAO,MAAM,wBAAwB,EAAE,gBAOtC,CAAC;AAEF,eAAO,MAAM,wBAAwB,EAAE,eAMtC,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { deriveEvtNodeId } from "./node-id.js";
|
|
2
|
+
const SAMPLE_SOURCE = "legislative-tracker";
|
|
3
|
+
const SAMPLE_EXTERNAL_ID = "tx-hb-1234-2026";
|
|
4
|
+
export const SAMPLE_EVT_NODE_ID = deriveEvtNodeId(SAMPLE_SOURCE, SAMPLE_EXTERNAL_ID);
|
|
5
|
+
/** Anticipatory atom with future valid_from — valid round-trip fixture. */
|
|
6
|
+
export const SAMPLE_ANTICIPATORY_ATOM = {
|
|
7
|
+
family: "event",
|
|
8
|
+
claim_type: "anticipatory.legislative_item",
|
|
9
|
+
valid_from: "2027-01-15T00:00:00.000Z",
|
|
10
|
+
confidence: { basis: "asserted", estimate: 0.6 },
|
|
11
|
+
source: SAMPLE_SOURCE,
|
|
12
|
+
external_id: SAMPLE_EXTERNAL_ID,
|
|
13
|
+
};
|
|
14
|
+
export const SAMPLE_WOULD_AFFECT_EDGE = {
|
|
15
|
+
type: "would_affect",
|
|
16
|
+
sourceNodeId: SAMPLE_EVT_NODE_ID,
|
|
17
|
+
targetSubjectId: "parcel_abc123def456",
|
|
18
|
+
effectiveDate: "2027-06-01",
|
|
19
|
+
immutable: true,
|
|
20
|
+
};
|
|
21
|
+
//# sourceMappingURL=fixtures.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fixtures.js","sourceRoot":"","sources":["../../src/temporal/fixtures.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAI/C,MAAM,aAAa,GAAG,qBAAqB,CAAC;AAC5C,MAAM,kBAAkB,GAAG,iBAAiB,CAAC;AAE7C,MAAM,CAAC,MAAM,kBAAkB,GAAG,eAAe,CAC/C,aAAa,EACb,kBAAkB,CACnB,CAAC;AAEF,2EAA2E;AAC3E,MAAM,CAAC,MAAM,wBAAwB,GAAqB;IACxD,MAAM,EAAE,OAAO;IACf,UAAU,EAAE,+BAA+B;IAC3C,UAAU,EAAE,0BAA0B;IACtC,UAAU,EAAE,EAAE,KAAK,EAAE,UAAU,EAAE,QAAQ,EAAE,GAAG,EAAE;IAChD,MAAM,EAAE,aAAa;IACrB,WAAW,EAAE,kBAAkB;CAChC,CAAC;AAEF,MAAM,CAAC,MAAM,wBAAwB,GAAoB;IACvD,IAAI,EAAE,cAAc;IACpB,YAAY,EAAE,kBAAkB;IAChC,eAAe,EAAE,qBAAqB;IACtC,aAAa,EAAE,YAAY;IAC3B,SAAS,EAAE,IAAI;CAChB,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Temporal-Context Engine types for @empressaio/atom-contract v1.6.0.
|
|
3
|
+
*
|
|
4
|
+
* Import from `@empressaio/atom-contract/temporal`. Adds anticipatory event
|
|
5
|
+
* atoms, would_affect structural edges, and the evt_ node-type prefix.
|
|
6
|
+
*/
|
|
7
|
+
export * from "./common.js";
|
|
8
|
+
export * from "./node-id.js";
|
|
9
|
+
export * from "./anticipatory-atom.js";
|
|
10
|
+
export * from "./would-affect-edge.js";
|
|
11
|
+
export * from "./interval-query.js";
|
|
12
|
+
export * from "./fixtures.js";
|
|
13
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/temporal/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,wBAAwB,CAAC;AACvC,cAAc,wBAAwB,CAAC;AACvC,cAAc,qBAAqB,CAAC;AACpC,cAAc,eAAe,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Temporal-Context Engine types for @empressaio/atom-contract v1.6.0.
|
|
3
|
+
*
|
|
4
|
+
* Import from `@empressaio/atom-contract/temporal`. Adds anticipatory event
|
|
5
|
+
* atoms, would_affect structural edges, and the evt_ node-type prefix.
|
|
6
|
+
*/
|
|
7
|
+
export * from "./common.js";
|
|
8
|
+
export * from "./node-id.js";
|
|
9
|
+
export * from "./anticipatory-atom.js";
|
|
10
|
+
export * from "./would-affect-edge.js";
|
|
11
|
+
export * from "./interval-query.js";
|
|
12
|
+
export * from "./fixtures.js";
|
|
13
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/temporal/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,wBAAwB,CAAC;AACvC,cAAc,wBAAwB,CAAC;AACvC,cAAc,qBAAqB,CAAC;AACpC,cAAc,eAAe,CAAC"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Interval / as-of query helpers for temporal atoms.
|
|
3
|
+
*
|
|
4
|
+
* Current-state queries that filter `valid_from <= now` silently exclude
|
|
5
|
+
* anticipatory atoms whose valid_from is in the future. These helpers make
|
|
6
|
+
* that exclusion explicit and offer an opt-in to surface anticipatory atoms.
|
|
7
|
+
*/
|
|
8
|
+
export interface TemporalAtomSlice {
|
|
9
|
+
readonly claim_type: string;
|
|
10
|
+
readonly valid_from: string;
|
|
11
|
+
}
|
|
12
|
+
export interface FilterAtomsForAsOfOptions {
|
|
13
|
+
/** Reference instant for the query. Defaults to `new Date()`. */
|
|
14
|
+
readonly asOf?: Date;
|
|
15
|
+
/**
|
|
16
|
+
* When true, anticipatory atoms with future valid_from are included and
|
|
17
|
+
* tagged. When false (default), they are excluded from current-state
|
|
18
|
+
* results — never silently dropped without the caller opting in.
|
|
19
|
+
*/
|
|
20
|
+
readonly includeAnticipatory?: boolean;
|
|
21
|
+
}
|
|
22
|
+
export interface FilteredTemporalAtom<T extends TemporalAtomSlice> {
|
|
23
|
+
readonly atom: T;
|
|
24
|
+
/** True when valid_from is after asOf (anticipatory, not yet effective). */
|
|
25
|
+
readonly isFutureAnticipatory: boolean;
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Returns true when the atom is visible at `asOf`.
|
|
29
|
+
*
|
|
30
|
+
* - Non-anticipatory: requires `valid_from <= asOf`.
|
|
31
|
+
* - Anticipatory with `includeAnticipatory`: always visible (flagged if future).
|
|
32
|
+
* - Anticipatory without `includeAnticipatory`: excluded when valid_from > asOf.
|
|
33
|
+
*/
|
|
34
|
+
export declare function isAtomVisibleAtAsOf(atom: TemporalAtomSlice, options?: FilterAtomsForAsOfOptions): boolean;
|
|
35
|
+
/**
|
|
36
|
+
* Filter atoms for an as-of query. Anticipatory atoms with future
|
|
37
|
+
* valid_from are either included (with `isFutureAnticipatory: true`) or
|
|
38
|
+
* explicitly excluded — never silently dropped from a result set the
|
|
39
|
+
* caller believed was complete.
|
|
40
|
+
*/
|
|
41
|
+
export declare function filterAtomsForAsOf<T extends TemporalAtomSlice>(atoms: ReadonlyArray<T>, options?: FilterAtomsForAsOfOptions): ReadonlyArray<FilteredTemporalAtom<T>>;
|
|
42
|
+
//# sourceMappingURL=interval-query.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"interval-query.d.ts","sourceRoot":"","sources":["../../src/temporal/interval-query.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAIH,MAAM,WAAW,iBAAiB;IAChC,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;CAC7B;AAED,MAAM,WAAW,yBAAyB;IACxC,iEAAiE;IACjE,QAAQ,CAAC,IAAI,CAAC,EAAE,IAAI,CAAC;IACrB;;;;OAIG;IACH,QAAQ,CAAC,mBAAmB,CAAC,EAAE,OAAO,CAAC;CACxC;AAED,MAAM,WAAW,oBAAoB,CAAC,CAAC,SAAS,iBAAiB;IAC/D,QAAQ,CAAC,IAAI,EAAE,CAAC,CAAC;IACjB,4EAA4E;IAC5E,QAAQ,CAAC,oBAAoB,EAAE,OAAO,CAAC;CACxC;AAED;;;;;;GAMG;AACH,wBAAgB,mBAAmB,CACjC,IAAI,EAAE,iBAAiB,EACvB,OAAO,GAAE,yBAA8B,GACtC,OAAO,CAaT;AAED;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,CAAC,SAAS,iBAAiB,EAC5D,KAAK,EAAE,aAAa,CAAC,CAAC,CAAC,EACvB,OAAO,GAAE,yBAA8B,GACtC,aAAa,CAAC,oBAAoB,CAAC,CAAC,CAAC,CAAC,CAiBxC"}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Interval / as-of query helpers for temporal atoms.
|
|
3
|
+
*
|
|
4
|
+
* Current-state queries that filter `valid_from <= now` silently exclude
|
|
5
|
+
* anticipatory atoms whose valid_from is in the future. These helpers make
|
|
6
|
+
* that exclusion explicit and offer an opt-in to surface anticipatory atoms.
|
|
7
|
+
*/
|
|
8
|
+
import { isAnticipatoryClaimType, isIsoTimestamp } from "./common.js";
|
|
9
|
+
/**
|
|
10
|
+
* Returns true when the atom is visible at `asOf`.
|
|
11
|
+
*
|
|
12
|
+
* - Non-anticipatory: requires `valid_from <= asOf`.
|
|
13
|
+
* - Anticipatory with `includeAnticipatory`: always visible (flagged if future).
|
|
14
|
+
* - Anticipatory without `includeAnticipatory`: excluded when valid_from > asOf.
|
|
15
|
+
*/
|
|
16
|
+
export function isAtomVisibleAtAsOf(atom, options = {}) {
|
|
17
|
+
const asOf = options.asOf ?? new Date();
|
|
18
|
+
if (!isIsoTimestamp(atom.valid_from))
|
|
19
|
+
return false;
|
|
20
|
+
const validFromMs = Date.parse(atom.valid_from);
|
|
21
|
+
const isFuture = validFromMs > asOf.getTime();
|
|
22
|
+
if (isAnticipatoryClaimType(atom.claim_type)) {
|
|
23
|
+
if (options.includeAnticipatory)
|
|
24
|
+
return true;
|
|
25
|
+
return !isFuture;
|
|
26
|
+
}
|
|
27
|
+
return !isFuture;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Filter atoms for an as-of query. Anticipatory atoms with future
|
|
31
|
+
* valid_from are either included (with `isFutureAnticipatory: true`) or
|
|
32
|
+
* explicitly excluded — never silently dropped from a result set the
|
|
33
|
+
* caller believed was complete.
|
|
34
|
+
*/
|
|
35
|
+
export function filterAtomsForAsOf(atoms, options = {}) {
|
|
36
|
+
const asOf = options.asOf ?? new Date();
|
|
37
|
+
const results = [];
|
|
38
|
+
for (const atom of atoms) {
|
|
39
|
+
if (!isIsoTimestamp(atom.valid_from))
|
|
40
|
+
continue;
|
|
41
|
+
const validFromMs = Date.parse(atom.valid_from);
|
|
42
|
+
const isFutureAnticipatory = isAnticipatoryClaimType(atom.claim_type) && validFromMs > asOf.getTime();
|
|
43
|
+
if (!isAtomVisibleAtAsOf(atom, options))
|
|
44
|
+
continue;
|
|
45
|
+
results.push({ atom, isFutureAnticipatory });
|
|
46
|
+
}
|
|
47
|
+
return results;
|
|
48
|
+
}
|
|
49
|
+
//# sourceMappingURL=interval-query.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"interval-query.js","sourceRoot":"","sources":["../../src/temporal/interval-query.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,uBAAuB,EAAE,cAAc,EAAE,M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