@adaptic/utils 0.0.985 → 0.0.987

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,13 @@
1
1
  import { type EffectiveTradingPolicy } from "../schemas/effective-policy.schema";
2
2
  /**
3
- * Conservative default trading policy used as the baseline when no
4
- * user-customized policy exists. All nested preference sub-objects are
5
- * passed as empty objects so Zod applies their field-level defaults.
3
+ * Default trading policy used as the baseline when no user-customized policy
4
+ * exists. Calibrated for short-horizon day trading / HFT-microstructuring /
5
+ * scalping (intraday holds, 5-min-bar-sized stops, fast cooldowns) per the
6
+ * 2026-05-10 audit, replacing the previous swing-trading calibration.
7
+ *
8
+ * All nested preference sub-objects are passed as empty objects so Zod applies
9
+ * their field-level defaults (which are themselves tuned for scalping in their
10
+ * respective schema files).
6
11
  *
7
12
  * Key choices:
8
13
  * - Advisory-only autonomy (no autonomous execution)
@@ -11,6 +16,14 @@ import { type EffectiveTradingPolicy } from "../schemas/effective-policy.schema"
11
16
  * - No shorting or margin (user must opt-in)
12
17
  * - All protective overlays disabled (user must opt-in)
13
18
  * - No LLM providers pre-configured
19
+ * - Tighter per-trade allocation (2% vs 5%) and concurrency (8 positions vs 20)
20
+ * reflecting the increased turnover and decreased per-position conviction
21
+ * characteristic of scalping
22
+ * - Faster equity wash-trade cooldown (5s vs 30s) — FINRA Rule 5210 governs
23
+ * opposing-side wash trades; same-side intraday re-entry can be much faster
24
+ * - Tighter daily-loss circuit breaker (2% vs 3%) reflecting that scalping
25
+ * strategies should fail fast rather than burn the day's risk budget on
26
+ * one bad regime
14
27
  */
15
28
  export declare const DEFAULT_TRADING_POLICY: EffectiveTradingPolicy;
16
29
  //# sourceMappingURL=default-trading-policy.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"default-trading-policy.d.ts","sourceRoot":"","sources":["../../../../src/trading-policy/defaults/default-trading-policy.ts"],"names":[],"mappings":"AACA,OAAO,EAEL,KAAK,sBAAsB,EAC5B,MAAM,oCAAoC,CAAC;AAE5C;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,sBAAsB,EAAE,sBAoDjC,CAAC"}
1
+ {"version":3,"file":"default-trading-policy.d.ts","sourceRoot":"","sources":["../../../../src/trading-policy/defaults/default-trading-policy.ts"],"names":[],"mappings":"AACA,OAAO,EAEL,KAAK,sBAAsB,EAC5B,MAAM,oCAAoC,CAAC;AAE5C;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,eAAO,MAAM,sBAAsB,EAAE,sBA+DjC,CAAC"}
@@ -32,6 +32,26 @@ export declare const EffectiveTradingPolicySchema: z.ZodObject<{
32
32
  perTradeEquityAllocationPct: z.ZodNumber;
33
33
  /** Percentage of the crypto allocation slice of account equity allocated per crypto trade. Canonical replacement for legacy AlpacaAccount.cryptoTradeAllocationPct. */
34
34
  perTradeCryptoAllocationPct: z.ZodNumber;
35
+ /**
36
+ * Wash-trade cooldown period in milliseconds for equities. Defines the
37
+ * minimum elapsed time between opposing-side fills on the same symbol per
38
+ * FINRA Rule 5210, mirroring the 30s default already enforced for crypto.
39
+ * Mirrors `TradingPolicy.equityWashTradeCooldownMs` in backend-legacy.
40
+ * Optional so that legacy snapshots that pre-date this field continue to
41
+ * parse cleanly; consumers should fall back to a 30_000ms static default
42
+ * when undefined.
43
+ */
44
+ equityWashTradeCooldownMs: z.ZodOptional<z.ZodNumber>;
45
+ /**
46
+ * Maximum daily portfolio loss as a fraction of account equity, evaluated
47
+ * intraday from the broker's `equity` vs `last_equity` delta. Breach
48
+ * activates a 24h `BLOCK_NEW_OPENS` halt per Reg-T daily-loss-limit
49
+ * controls. Optional so legacy snapshots parse cleanly; consumers
50
+ * should fall back to the static default in `defaultRiskConfig.dailyLossLimits.maxDailyLossPercent`
51
+ * (3%) when undefined. Range constrained to [0, 1) — a 100% daily-loss
52
+ * threshold would be nonsensical.
53
+ */
54
+ maxDailyLossPercent: z.ZodOptional<z.ZodNumber>;
35
55
  macroOverlayEnabled: z.ZodBoolean;
36
56
  sectorOverlayEnabled: z.ZodBoolean;
37
57
  volatilityOverlayEnabled: z.ZodBoolean;
@@ -1349,6 +1369,8 @@ export declare const EffectiveTradingPolicySchema: z.ZodObject<{
1349
1369
  newsEventRiskOverlayEnabled: boolean;
1350
1370
  exchangeHealthOverlayEnabled: boolean;
1351
1371
  dataQualitySentinelEnabled: boolean;
1372
+ equityWashTradeCooldownMs?: number | undefined;
1373
+ maxDailyLossPercent?: number | undefined;
1352
1374
  }, {
1353
1375
  maxLeverage: number;
1354
1376
  perTradeCryptoAllocationPct: number;
@@ -1673,6 +1695,8 @@ export declare const EffectiveTradingPolicySchema: z.ZodObject<{
1673
1695
  retainDecisionArtifactsDays?: number | undefined;
1674
1696
  tradeConfirmEmail?: "all" | "none" | undefined;
1675
1697
  } | undefined;
1698
+ equityWashTradeCooldownMs?: number | undefined;
1699
+ maxDailyLossPercent?: number | undefined;
1676
1700
  }>;
1677
1701
  /** Inferred TypeScript type for a fully-resolved effective trading policy. */
1678
1702
  export type EffectiveTradingPolicy = z.infer<typeof EffectiveTradingPolicySchema>;
@@ -1 +1 @@
1
- {"version":3,"file":"effective-policy.schema.d.ts","sourceRoot":"","sources":["../../../../src/trading-policy/schemas/effective-policy.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAYrD;;;;GAIG;AACH,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;IAuBvC,oJAAoJ;;IAEpJ,uKAAuK;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA4BH,CAAC;AAEH,8EAA8E;AAC9E,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAC1C,OAAO,4BAA4B,CACpC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"execution-prefs.schema.d.ts","sourceRoot":"","sources":["../../../../src/trading-policy/schemas/execution-prefs.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAUxB;;;;;;;GAOG;AACH,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA8BrC,CAAC;AAEH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAAyC,CAAC;AAE3E,0DAA0D;AAC1D,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC"}
1
+ {"version":3,"file":"execution-prefs.schema.d.ts","sourceRoot":"","sources":["../../../../src/trading-policy/schemas/execution-prefs.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAUxB;;;;;;;GAOG;AACH,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAuCrC,CAAC;AAEH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAAyC,CAAC;AAE3E,0DAA0D;AAC1D,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"position-management-prefs.schema.d.ts","sourceRoot":"","sources":["../../../../src/trading-policy/schemas/position-management-prefs.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAQxB;;;;;;;GAOG;AACH,eAAO,MAAM,mCAAmC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAuC9C,CAAC;AAEH,eAAO,MAAM,6BAA6B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GACO,CAAC;AAElD,oEAAoE;AACpE,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAC3C,OAAO,6BAA6B,CACrC,CAAC"}
1
+ {"version":3,"file":"position-management-prefs.schema.d.ts","sourceRoot":"","sources":["../../../../src/trading-policy/schemas/position-management-prefs.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAQxB;;;;;;;GAOG;AACH,eAAO,MAAM,mCAAmC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAoD9C,CAAC;AAEH,eAAO,MAAM,6BAA6B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GACO,CAAC;AAElD,oEAAoE;AACpE,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAC3C,OAAO,6BAA6B,CACrC,CAAC"}
@@ -28,7 +28,11 @@ export declare const RiskBudgetPrefsObjectSchema: z.ZodObject<{
28
28
  weekendExposureCapPct: z.ZodDefault<z.ZodNumber>;
29
29
  eventRiskExposureCapPct: z.ZodDefault<z.ZodNumber>;
30
30
  gapRiskSensitivity: z.ZodDefault<z.ZodEnum<["low", "medium", "high"]>>;
31
- /** Per-trade equity allocation as % of account equity. Replaces legacy AlpacaAccount.tradeAllocationPct. */
31
+ /**
32
+ * Per-trade equity allocation as % of account equity. Replaces legacy AlpacaAccount.tradeAllocationPct.
33
+ * Smaller per-trade size (2% vs 5%) for scalping — shorter holds + higher
34
+ * concurrency demand smaller per-position bets.
35
+ */
32
36
  perTradeAllocationPct: z.ZodDefault<z.ZodNumber>;
33
37
  /** Per-trade crypto allocation as % of account equity. Replaces legacy AlpacaAccount.cryptoTradeAllocationPct. */
34
38
  perTradeCryptoAllocationPct: z.ZodDefault<z.ZodNumber>;
@@ -112,7 +116,11 @@ export declare const RiskBudgetPrefsSchema: z.ZodDefault<z.ZodObject<{
112
116
  weekendExposureCapPct: z.ZodDefault<z.ZodNumber>;
113
117
  eventRiskExposureCapPct: z.ZodDefault<z.ZodNumber>;
114
118
  gapRiskSensitivity: z.ZodDefault<z.ZodEnum<["low", "medium", "high"]>>;
115
- /** Per-trade equity allocation as % of account equity. Replaces legacy AlpacaAccount.tradeAllocationPct. */
119
+ /**
120
+ * Per-trade equity allocation as % of account equity. Replaces legacy AlpacaAccount.tradeAllocationPct.
121
+ * Smaller per-trade size (2% vs 5%) for scalping — shorter holds + higher
122
+ * concurrency demand smaller per-position bets.
123
+ */
116
124
  perTradeAllocationPct: z.ZodDefault<z.ZodNumber>;
117
125
  /** Per-trade crypto allocation as % of account equity. Replaces legacy AlpacaAccount.cryptoTradeAllocationPct. */
118
126
  perTradeCryptoAllocationPct: z.ZodDefault<z.ZodNumber>;
@@ -1 +1 @@
1
- {"version":3,"file":"risk-budget-prefs.schema.d.ts","sourceRoot":"","sources":["../../../../src/trading-policy/schemas/risk-budget-prefs.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;GAOG;AACH,eAAO,MAAM,2BAA2B;;;;;;;;;;;;;;;;;;;;;IAsBtC,4GAA4G;;IAE5G,kHAAkH;;IAGlH,+EAA+E;;IAE/E,wEAAwE;;IAExE,6FAA6F;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAE7F,CAAC;AAEH,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;IAbhC,4GAA4G;;IAE5G,kHAAkH;;IAGlH,+EAA+E;;IAE/E,wEAAwE;;IAExE,6FAA6F;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAInB,CAAC;AAE7E,4DAA4D;AAC5D,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC"}
1
+ {"version":3,"file":"risk-budget-prefs.schema.d.ts","sourceRoot":"","sources":["../../../../src/trading-policy/schemas/risk-budget-prefs.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;GAOG;AACH,eAAO,MAAM,2BAA2B;;;;;;;;;;;;;;;;;;;;;IA4BtC;;;;OAIG;;IAEH,kHAAkH;;IAGlH,+EAA+E;;IAE/E,wEAAwE;;IAExE,6FAA6F;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAE7F,CAAC;AAEH,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;IAjBhC;;;;OAIG;;IAEH,kHAAkH;;IAGlH,+EAA+E;;IAE/E,wEAAwE;;IAExE,6FAA6F;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAInB,CAAC;AAE7E,4DAA4D;AAC5D,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC"}
@@ -57,9 +57,17 @@ export declare const SignalConsumptionPrefsObjectSchema: z.ZodObject<{
57
57
  earningsBlackoutEnabled: z.ZodDefault<z.ZodBoolean>;
58
58
  earningsBlackoutHoursBefore: z.ZodDefault<z.ZodNumber>;
59
59
  earningsBlackoutHoursAfter: z.ZodDefault<z.ZodNumber>;
60
- /** Minimum price movement % to qualify as a tradeable signal. Replaces legacy AlpacaAccount.minPercentageChange. */
60
+ /**
61
+ * Minimum price movement % to qualify as a tradeable signal. Replaces legacy AlpacaAccount.minPercentageChange.
62
+ * Tighter intraday move filter (15bps vs 50bps) — scalping captures
63
+ * sub-percent moves that the swing-trading default would have ignored.
64
+ */
61
65
  minPercentageChange: z.ZodDefault<z.ZodNumber>;
62
- /** Minimum average daily volume to qualify a symbol for trading. Replaces legacy AlpacaAccount.volumeThreshold. */
66
+ /**
67
+ * Minimum average daily volume to qualify a symbol for trading. Replaces legacy AlpacaAccount.volumeThreshold.
68
+ * Higher floor (100k vs 50k) — scalping requires consistent liquidity to
69
+ * keep slippage within the tightened maxSlippageTolerancePct (0.3%).
70
+ */
63
71
  volumeThreshold: z.ZodDefault<z.ZodNumber>;
64
72
  }, "strip", z.ZodTypeAny, {
65
73
  minPercentageChange: number;
@@ -180,9 +188,17 @@ export declare const SignalConsumptionPrefsSchema: z.ZodDefault<z.ZodObject<{
180
188
  earningsBlackoutEnabled: z.ZodDefault<z.ZodBoolean>;
181
189
  earningsBlackoutHoursBefore: z.ZodDefault<z.ZodNumber>;
182
190
  earningsBlackoutHoursAfter: z.ZodDefault<z.ZodNumber>;
183
- /** Minimum price movement % to qualify as a tradeable signal. Replaces legacy AlpacaAccount.minPercentageChange. */
191
+ /**
192
+ * Minimum price movement % to qualify as a tradeable signal. Replaces legacy AlpacaAccount.minPercentageChange.
193
+ * Tighter intraday move filter (15bps vs 50bps) — scalping captures
194
+ * sub-percent moves that the swing-trading default would have ignored.
195
+ */
184
196
  minPercentageChange: z.ZodDefault<z.ZodNumber>;
185
- /** Minimum average daily volume to qualify a symbol for trading. Replaces legacy AlpacaAccount.volumeThreshold. */
197
+ /**
198
+ * Minimum average daily volume to qualify a symbol for trading. Replaces legacy AlpacaAccount.volumeThreshold.
199
+ * Higher floor (100k vs 50k) — scalping requires consistent liquidity to
200
+ * keep slippage within the tightened maxSlippageTolerancePct (0.3%).
201
+ */
186
202
  volumeThreshold: z.ZodDefault<z.ZodNumber>;
187
203
  }, "strip", z.ZodTypeAny, {
188
204
  minPercentageChange: number;
@@ -1 +1 @@
1
- {"version":3,"file":"signal-consumption-prefs.schema.d.ts","sourceRoot":"","sources":["../../../../src/trading-policy/schemas/signal-consumption-prefs.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAiBxB;;;;;;;GAOG;AACH,eAAO,MAAM,kCAAkC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAwC7C,oHAAoH;;IAEpH,mHAAmH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAEnH,CAAC;AAEH,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IANvC,oHAAoH;;IAEpH,mHAAmH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAKrE,CAAC;AAEjD,mEAAmE;AACnE,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAC1C,OAAO,4BAA4B,CACpC,CAAC"}
1
+ {"version":3,"file":"signal-consumption-prefs.schema.d.ts","sourceRoot":"","sources":["../../../../src/trading-policy/schemas/signal-consumption-prefs.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAiBxB;;;;;;;GAOG;AACH,eAAO,MAAM,kCAAkC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAqD7C;;;;OAIG;;IAEH;;;;OAIG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAEH,CAAC;AAEH,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAdvC;;;;OAIG;;IAEH;;;;OAIG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAK2C,CAAC;AAEjD,mEAAmE;AACnE,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAC1C,OAAO,4BAA4B,CACpC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adaptic/utils",
3
- "version": "0.0.985",
3
+ "version": "0.0.987",
4
4
  "author": "Adaptic.ai",
5
5
  "description": "Utility functions used in Adaptic app and Lambda functions",
6
6
  "always-build-npm": true,