backtest-kit 3.0.11 → 3.0.12

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/build/index.cjs CHANGED
@@ -26769,6 +26769,7 @@ class ExchangeUtils {
26769
26769
  const Exchange = new ExchangeUtils();
26770
26770
 
26771
26771
  const WARM_CANDLES_METHOD_NAME = "cache.warmCandles";
26772
+ const CHECK_CANDLES_METHOD_NAME = "cache.checkCandles";
26772
26773
  const MS_PER_MINUTE$1 = 60000;
26773
26774
  const INTERVAL_MINUTES$1 = {
26774
26775
  "1m": 1,
@@ -26799,6 +26800,67 @@ const PRINT_PROGRESS_FN = (fetched, total, symbol, interval) => {
26799
26800
  process.stdout.write("\n");
26800
26801
  }
26801
26802
  };
26803
+ /**
26804
+ * Checks cached candle timestamps for correct interval alignment.
26805
+ * Reads JSON files directly from persist storage without using abstractions.
26806
+ *
26807
+ * @param params - Validation parameters
26808
+ */
26809
+ async function checkCandles(params) {
26810
+ const { symbol, exchangeName, interval, baseDir = "./dump/data/candle" } = params;
26811
+ bt.loggerService.info(CHECK_CANDLES_METHOD_NAME, params);
26812
+ const step = INTERVAL_MINUTES$1[interval];
26813
+ if (!step) {
26814
+ throw new Error(`checkCandles: unsupported interval=${interval}`);
26815
+ }
26816
+ const stepMs = step * MS_PER_MINUTE$1;
26817
+ const dir = path.join(baseDir, exchangeName, symbol, interval);
26818
+ try {
26819
+ await fs.stat(dir);
26820
+ }
26821
+ catch {
26822
+ throw new Error(`checkCandles: cache directory not found: ${dir}`);
26823
+ }
26824
+ // First pass: count files via async iterator (no memory allocation for file list)
26825
+ let totalFiles = 0;
26826
+ for await (const entry of await fs.opendir(dir)) {
26827
+ if (entry.isFile() && entry.name.endsWith(".json")) {
26828
+ totalFiles++;
26829
+ }
26830
+ }
26831
+ if (totalFiles === 0) {
26832
+ throw new Error(`checkCandles: no cached candles in ${dir}`);
26833
+ }
26834
+ // Second pass: check each file via async iterator with progress
26835
+ let checkd = 0;
26836
+ let prevTimestamp = null;
26837
+ let prevName = null;
26838
+ PRINT_PROGRESS_FN(checkd, totalFiles, symbol, interval);
26839
+ for await (const entry of await fs.opendir(dir)) {
26840
+ if (!entry.isFile() || !entry.name.endsWith(".json")) {
26841
+ continue;
26842
+ }
26843
+ const filePath = path.join(dir, entry.name);
26844
+ const raw = await fs.readFile(filePath, "utf-8");
26845
+ const candle = JSON.parse(raw);
26846
+ const { timestamp } = candle;
26847
+ const aligned = ALIGN_TO_INTERVAL_FN(timestamp, step);
26848
+ if (timestamp !== aligned) {
26849
+ throw new Error(`checkCandles: ${entry.name} timestamp=${timestamp} is not aligned to ${interval} boundary (expected=${aligned})`);
26850
+ }
26851
+ if (prevTimestamp !== null) {
26852
+ const gap = timestamp - prevTimestamp;
26853
+ if (gap !== stepMs) {
26854
+ throw new Error(`checkCandles: gap between ${prevName} and ${entry.name} is ${gap}ms, expected ${stepMs}ms`);
26855
+ }
26856
+ }
26857
+ prevTimestamp = timestamp;
26858
+ prevName = entry.name;
26859
+ checkd++;
26860
+ PRINT_PROGRESS_FN(checkd, totalFiles, symbol, interval);
26861
+ }
26862
+ console.log(`checkCandles: OK ${totalFiles} candles ${symbol} ${interval}`);
26863
+ }
26802
26864
  /**
26803
26865
  * Pre-caches candles for a date range into persist storage.
26804
26866
  * Downloads all candles matching the interval from `from` to `to`.
@@ -37295,6 +37357,7 @@ exports.addRiskSchema = addRiskSchema;
37295
37357
  exports.addSizingSchema = addSizingSchema;
37296
37358
  exports.addStrategySchema = addStrategySchema;
37297
37359
  exports.addWalkerSchema = addWalkerSchema;
37360
+ exports.checkCandles = checkCandles;
37298
37361
  exports.commitActivateScheduled = commitActivateScheduled;
37299
37362
  exports.commitBreakeven = commitBreakeven;
37300
37363
  exports.commitCancelScheduled = commitCancelScheduled;
package/build/index.mjs CHANGED
@@ -2,7 +2,7 @@ import { createActivator } from 'di-kit';
2
2
  import { scoped } from 'di-scoped';
3
3
  import { Subject, makeExtendable, singleshot, getErrorMessage, memoize, not, errorData, trycatch, retry, queued, sleep, randomString, str, isObject, ToolRegistry, typo, and, resolveDocuments, timeout, TIMEOUT_SYMBOL as TIMEOUT_SYMBOL$1, compose, singlerun } from 'functools-kit';
4
4
  import * as fs from 'fs/promises';
5
- import fs__default from 'fs/promises';
5
+ import fs__default, { stat, opendir, readFile } from 'fs/promises';
6
6
  import path, { join, dirname } from 'path';
7
7
  import crypto from 'crypto';
8
8
  import os from 'os';
@@ -26749,6 +26749,7 @@ class ExchangeUtils {
26749
26749
  const Exchange = new ExchangeUtils();
26750
26750
 
26751
26751
  const WARM_CANDLES_METHOD_NAME = "cache.warmCandles";
26752
+ const CHECK_CANDLES_METHOD_NAME = "cache.checkCandles";
26752
26753
  const MS_PER_MINUTE$1 = 60000;
26753
26754
  const INTERVAL_MINUTES$1 = {
26754
26755
  "1m": 1,
@@ -26779,6 +26780,67 @@ const PRINT_PROGRESS_FN = (fetched, total, symbol, interval) => {
26779
26780
  process.stdout.write("\n");
26780
26781
  }
26781
26782
  };
26783
+ /**
26784
+ * Checks cached candle timestamps for correct interval alignment.
26785
+ * Reads JSON files directly from persist storage without using abstractions.
26786
+ *
26787
+ * @param params - Validation parameters
26788
+ */
26789
+ async function checkCandles(params) {
26790
+ const { symbol, exchangeName, interval, baseDir = "./dump/data/candle" } = params;
26791
+ bt.loggerService.info(CHECK_CANDLES_METHOD_NAME, params);
26792
+ const step = INTERVAL_MINUTES$1[interval];
26793
+ if (!step) {
26794
+ throw new Error(`checkCandles: unsupported interval=${interval}`);
26795
+ }
26796
+ const stepMs = step * MS_PER_MINUTE$1;
26797
+ const dir = join(baseDir, exchangeName, symbol, interval);
26798
+ try {
26799
+ await stat(dir);
26800
+ }
26801
+ catch {
26802
+ throw new Error(`checkCandles: cache directory not found: ${dir}`);
26803
+ }
26804
+ // First pass: count files via async iterator (no memory allocation for file list)
26805
+ let totalFiles = 0;
26806
+ for await (const entry of await opendir(dir)) {
26807
+ if (entry.isFile() && entry.name.endsWith(".json")) {
26808
+ totalFiles++;
26809
+ }
26810
+ }
26811
+ if (totalFiles === 0) {
26812
+ throw new Error(`checkCandles: no cached candles in ${dir}`);
26813
+ }
26814
+ // Second pass: check each file via async iterator with progress
26815
+ let checkd = 0;
26816
+ let prevTimestamp = null;
26817
+ let prevName = null;
26818
+ PRINT_PROGRESS_FN(checkd, totalFiles, symbol, interval);
26819
+ for await (const entry of await opendir(dir)) {
26820
+ if (!entry.isFile() || !entry.name.endsWith(".json")) {
26821
+ continue;
26822
+ }
26823
+ const filePath = join(dir, entry.name);
26824
+ const raw = await readFile(filePath, "utf-8");
26825
+ const candle = JSON.parse(raw);
26826
+ const { timestamp } = candle;
26827
+ const aligned = ALIGN_TO_INTERVAL_FN(timestamp, step);
26828
+ if (timestamp !== aligned) {
26829
+ throw new Error(`checkCandles: ${entry.name} timestamp=${timestamp} is not aligned to ${interval} boundary (expected=${aligned})`);
26830
+ }
26831
+ if (prevTimestamp !== null) {
26832
+ const gap = timestamp - prevTimestamp;
26833
+ if (gap !== stepMs) {
26834
+ throw new Error(`checkCandles: gap between ${prevName} and ${entry.name} is ${gap}ms, expected ${stepMs}ms`);
26835
+ }
26836
+ }
26837
+ prevTimestamp = timestamp;
26838
+ prevName = entry.name;
26839
+ checkd++;
26840
+ PRINT_PROGRESS_FN(checkd, totalFiles, symbol, interval);
26841
+ }
26842
+ console.log(`checkCandles: OK ${totalFiles} candles ${symbol} ${interval}`);
26843
+ }
26782
26844
  /**
26783
26845
  * Pre-caches candles for a date range into persist storage.
26784
26846
  * Downloads all candles matching the interval from `from` to `to`.
@@ -37231,4 +37293,4 @@ const set = (object, path, value) => {
37231
37293
  }
37232
37294
  };
37233
37295
 
37234
- export { ActionBase, Backtest, Breakeven, Cache, Constant, Exchange, ExecutionContextService, Heat, Live, Markdown, MarkdownFileBase, MarkdownFolderBase, MethodContextService, Notification, NotificationBacktest, NotificationLive, Partial, Performance, PersistBase, PersistBreakevenAdapter, PersistCandleAdapter, PersistNotificationAdapter, PersistPartialAdapter, PersistRiskAdapter, PersistScheduleAdapter, PersistSignalAdapter, PersistStorageAdapter, PositionSize, Report, ReportBase, Risk, Schedule, Storage, StorageBacktest, StorageLive, Strategy, Walker, addActionSchema, addExchangeSchema, addFrameSchema, addRiskSchema, addSizingSchema, addStrategySchema, addWalkerSchema, commitActivateScheduled, commitBreakeven, commitCancelScheduled, commitClosePending, commitPartialLoss, commitPartialProfit, commitTrailingStop, commitTrailingTake, emitters, formatPrice, formatQuantity, get, getActionSchema, getAveragePrice, getBacktestTimeframe, getCandles, getColumns, getConfig, getContext, getDate, getDefaultColumns, getDefaultConfig, getExchangeSchema, getFrameSchema, getMode, getNextCandles, getOrderBook, getRawCandles, getRiskSchema, getSizingSchema, getStrategySchema, getSymbol, getWalkerSchema, hasTradeContext, backtest as lib, listExchangeSchema, listFrameSchema, listRiskSchema, listSizingSchema, listStrategySchema, listWalkerSchema, listenActivePing, listenActivePingOnce, listenBacktestProgress, listenBreakevenAvailable, listenBreakevenAvailableOnce, listenDoneBacktest, listenDoneBacktestOnce, listenDoneLive, listenDoneLiveOnce, listenDoneWalker, listenDoneWalkerOnce, listenError, listenExit, listenPartialLossAvailable, listenPartialLossAvailableOnce, listenPartialProfitAvailable, listenPartialProfitAvailableOnce, listenPerformance, listenRisk, listenRiskOnce, listenSchedulePing, listenSchedulePingOnce, listenSignal, listenSignalBacktest, listenSignalBacktestOnce, listenSignalLive, listenSignalLiveOnce, listenSignalOnce, listenStrategyCommit, listenStrategyCommitOnce, listenValidation, listenWalker, listenWalkerComplete, listenWalkerOnce, listenWalkerProgress, overrideActionSchema, overrideExchangeSchema, overrideFrameSchema, overrideRiskSchema, overrideSizingSchema, overrideStrategySchema, overrideWalkerSchema, parseArgs, roundTicks, set, setColumns, setConfig, setLogger, stopStrategy, validate, warmCandles };
37296
+ export { ActionBase, Backtest, Breakeven, Cache, Constant, Exchange, ExecutionContextService, Heat, Live, Markdown, MarkdownFileBase, MarkdownFolderBase, MethodContextService, Notification, NotificationBacktest, NotificationLive, Partial, Performance, PersistBase, PersistBreakevenAdapter, PersistCandleAdapter, PersistNotificationAdapter, PersistPartialAdapter, PersistRiskAdapter, PersistScheduleAdapter, PersistSignalAdapter, PersistStorageAdapter, PositionSize, Report, ReportBase, Risk, Schedule, Storage, StorageBacktest, StorageLive, Strategy, Walker, addActionSchema, addExchangeSchema, addFrameSchema, addRiskSchema, addSizingSchema, addStrategySchema, addWalkerSchema, checkCandles, commitActivateScheduled, commitBreakeven, commitCancelScheduled, commitClosePending, commitPartialLoss, commitPartialProfit, commitTrailingStop, commitTrailingTake, emitters, formatPrice, formatQuantity, get, getActionSchema, getAveragePrice, getBacktestTimeframe, getCandles, getColumns, getConfig, getContext, getDate, getDefaultColumns, getDefaultConfig, getExchangeSchema, getFrameSchema, getMode, getNextCandles, getOrderBook, getRawCandles, getRiskSchema, getSizingSchema, getStrategySchema, getSymbol, getWalkerSchema, hasTradeContext, backtest as lib, listExchangeSchema, listFrameSchema, listRiskSchema, listSizingSchema, listStrategySchema, listWalkerSchema, listenActivePing, listenActivePingOnce, listenBacktestProgress, listenBreakevenAvailable, listenBreakevenAvailableOnce, listenDoneBacktest, listenDoneBacktestOnce, listenDoneLive, listenDoneLiveOnce, listenDoneWalker, listenDoneWalkerOnce, listenError, listenExit, listenPartialLossAvailable, listenPartialLossAvailableOnce, listenPartialProfitAvailable, listenPartialProfitAvailableOnce, listenPerformance, listenRisk, listenRiskOnce, listenSchedulePing, listenSchedulePingOnce, listenSignal, listenSignalBacktest, listenSignalBacktestOnce, listenSignalLive, listenSignalLiveOnce, listenSignalOnce, listenStrategyCommit, listenStrategyCommitOnce, listenValidation, listenWalker, listenWalkerComplete, listenWalkerOnce, listenWalkerProgress, overrideActionSchema, overrideExchangeSchema, overrideFrameSchema, overrideRiskSchema, overrideSizingSchema, overrideStrategySchema, overrideWalkerSchema, parseArgs, roundTicks, set, setColumns, setConfig, setLogger, stopStrategy, validate, warmCandles };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "backtest-kit",
3
- "version": "3.0.11",
3
+ "version": "3.0.12",
4
4
  "description": "A TypeScript library for trading system backtest",
5
5
  "author": {
6
6
  "name": "Petr Tripolsky",
package/types.d.ts CHANGED
@@ -326,6 +326,27 @@ interface ICacheCandlesParams {
326
326
  /** End date of the caching range (inclusive) */
327
327
  to: Date;
328
328
  }
329
+ /**
330
+ * Parameters for validating cached candle timestamps.
331
+ * Reads JSON files directly from persist storage directory.
332
+ */
333
+ interface ICheckCandlesParams {
334
+ /** Trading pair symbol (e.g., "BTCUSDT") */
335
+ symbol: string;
336
+ /** Name of the registered exchange schema */
337
+ exchangeName: ExchangeName;
338
+ /** Candle time interval (e.g., "1m", "4h") */
339
+ interval: CandleInterval;
340
+ /** Base directory of candle persist storage (default: "./dump/data/candle") */
341
+ baseDir?: string;
342
+ }
343
+ /**
344
+ * Checks cached candle timestamps for correct interval alignment.
345
+ * Reads JSON files directly from persist storage without using abstractions.
346
+ *
347
+ * @param params - Validation parameters
348
+ */
349
+ declare function checkCandles(params: ICheckCandlesParams): Promise<void>;
329
350
  /**
330
351
  * Pre-caches candles for a date range into persist storage.
331
352
  * Downloads all candles matching the interval from `from` to `to`.
@@ -20798,4 +20819,4 @@ declare const backtest: {
20798
20819
  loggerService: LoggerService;
20799
20820
  };
20800
20821
 
20801
- export { ActionBase, type ActivateScheduledCommit, type ActivateScheduledCommitNotification, type ActivePingContract, Backtest, type BacktestStatisticsModel, Breakeven, type BreakevenAvailableNotification, type BreakevenCommit, type BreakevenCommitNotification, type BreakevenContract, type BreakevenData, Cache, type CancelScheduledCommit, type CandleData, type CandleInterval, type ClosePendingCommit, type ColumnConfig, type ColumnModel, Constant, type CriticalErrorNotification, type DoneContract, type EntityId, Exchange, ExecutionContextService, type FrameInterval, type GlobalConfig, Heat, type HeatmapStatisticsModel, type IActivateScheduledCommitRow, type IBidData, type IBreakevenCommitRow, type ICandleData, type ICommitRow, type IExchangeSchema, type IFrameSchema, type IHeatmapRow, type IMarkdownDumpOptions, type INotificationUtils, type IOrderBookData, type IPartialLossCommitRow, type IPartialProfitCommitRow, type IPersistBase, type IPositionSizeATRParams, type IPositionSizeFixedPercentageParams, type IPositionSizeKellyParams, type IPublicSignalRow, type IReportDumpOptions, type IRiskActivePosition, type IRiskCheckArgs, type IRiskSchema, type IRiskSignalRow, type IRiskValidation, type IRiskValidationFn, type IRiskValidationPayload, type IScheduledSignalCancelRow, type IScheduledSignalRow, type ISignalDto, type ISignalRow, type ISizingCalculateParams, type ISizingCalculateParamsATR, type ISizingCalculateParamsFixedPercentage, type ISizingCalculateParamsKelly, type ISizingParams, type ISizingParamsATR, type ISizingParamsFixedPercentage, type ISizingParamsKelly, type ISizingSchema, type ISizingSchemaATR, type ISizingSchemaFixedPercentage, type ISizingSchemaKelly, type IStorageSignalRow, type IStorageUtils, type IStrategyPnL, type IStrategyResult, type IStrategySchema, type IStrategyTickResult, type IStrategyTickResultActive, type IStrategyTickResultCancelled, type IStrategyTickResultClosed, type IStrategyTickResultIdle, type IStrategyTickResultOpened, type IStrategyTickResultScheduled, type IStrategyTickResultWaiting, type ITrailingStopCommitRow, type ITrailingTakeCommitRow, type IWalkerResults, type IWalkerSchema, type IWalkerStrategyResult, type InfoErrorNotification, Live, type LiveStatisticsModel, Markdown, MarkdownFileBase, MarkdownFolderBase, type MarkdownName, MethodContextService, type MetricStats, Notification, NotificationBacktest, type NotificationData, NotificationLive, type NotificationModel, Partial$1 as Partial, type PartialData, type PartialEvent, type PartialLossAvailableNotification, type PartialLossCommit, type PartialLossCommitNotification, type PartialLossContract, type PartialProfitAvailableNotification, type PartialProfitCommit, type PartialProfitCommitNotification, type PartialProfitContract, type PartialStatisticsModel, Performance, type PerformanceContract, type PerformanceMetricType, type PerformanceStatisticsModel, PersistBase, PersistBreakevenAdapter, PersistCandleAdapter, PersistNotificationAdapter, PersistPartialAdapter, PersistRiskAdapter, PersistScheduleAdapter, PersistSignalAdapter, PersistStorageAdapter, PositionSize, type ProgressBacktestContract, type ProgressWalkerContract, Report, ReportBase, type ReportName, Risk, type RiskContract, type RiskData, type RiskEvent, type RiskRejectionNotification, type RiskStatisticsModel, Schedule, type ScheduleData, type SchedulePingContract, type ScheduleStatisticsModel, type ScheduledEvent, type SignalCancelledNotification, type SignalClosedNotification, type SignalData, type SignalInterval, type SignalOpenedNotification, type SignalScheduledNotification, Storage, StorageBacktest, type StorageData, StorageLive, Strategy, type StrategyActionType, type StrategyCancelReason, type StrategyCloseReason, type StrategyCommitContract, type StrategyEvent, type StrategyStatisticsModel, type TMarkdownBase, type TNotificationUtilsCtor, type TPersistBase, type TPersistBaseCtor, type TReportBase, type TStorageUtilsCtor, type TickEvent, type TrailingStopCommit, type TrailingStopCommitNotification, type TrailingTakeCommit, type TrailingTakeCommitNotification, type ValidationErrorNotification, Walker, type WalkerCompleteContract, type WalkerContract, type WalkerMetric, type SignalData$1 as WalkerSignalData, type WalkerStatisticsModel, addActionSchema, addExchangeSchema, addFrameSchema, addRiskSchema, addSizingSchema, addStrategySchema, addWalkerSchema, commitActivateScheduled, commitBreakeven, commitCancelScheduled, commitClosePending, commitPartialLoss, commitPartialProfit, commitTrailingStop, commitTrailingTake, emitters, formatPrice, formatQuantity, get, getActionSchema, getAveragePrice, getBacktestTimeframe, getCandles, getColumns, getConfig, getContext, getDate, getDefaultColumns, getDefaultConfig, getExchangeSchema, getFrameSchema, getMode, getNextCandles, getOrderBook, getRawCandles, getRiskSchema, getSizingSchema, getStrategySchema, getSymbol, getWalkerSchema, hasTradeContext, backtest as lib, listExchangeSchema, listFrameSchema, listRiskSchema, listSizingSchema, listStrategySchema, listWalkerSchema, listenActivePing, listenActivePingOnce, listenBacktestProgress, listenBreakevenAvailable, listenBreakevenAvailableOnce, listenDoneBacktest, listenDoneBacktestOnce, listenDoneLive, listenDoneLiveOnce, listenDoneWalker, listenDoneWalkerOnce, listenError, listenExit, listenPartialLossAvailable, listenPartialLossAvailableOnce, listenPartialProfitAvailable, listenPartialProfitAvailableOnce, listenPerformance, listenRisk, listenRiskOnce, listenSchedulePing, listenSchedulePingOnce, listenSignal, listenSignalBacktest, listenSignalBacktestOnce, listenSignalLive, listenSignalLiveOnce, listenSignalOnce, listenStrategyCommit, listenStrategyCommitOnce, listenValidation, listenWalker, listenWalkerComplete, listenWalkerOnce, listenWalkerProgress, overrideActionSchema, overrideExchangeSchema, overrideFrameSchema, overrideRiskSchema, overrideSizingSchema, overrideStrategySchema, overrideWalkerSchema, parseArgs, roundTicks, set, setColumns, setConfig, setLogger, stopStrategy, validate, warmCandles };
20822
+ export { ActionBase, type ActivateScheduledCommit, type ActivateScheduledCommitNotification, type ActivePingContract, Backtest, type BacktestStatisticsModel, Breakeven, type BreakevenAvailableNotification, type BreakevenCommit, type BreakevenCommitNotification, type BreakevenContract, type BreakevenData, Cache, type CancelScheduledCommit, type CandleData, type CandleInterval, type ClosePendingCommit, type ColumnConfig, type ColumnModel, Constant, type CriticalErrorNotification, type DoneContract, type EntityId, Exchange, ExecutionContextService, type FrameInterval, type GlobalConfig, Heat, type HeatmapStatisticsModel, type IActivateScheduledCommitRow, type IBidData, type IBreakevenCommitRow, type ICandleData, type ICommitRow, type IExchangeSchema, type IFrameSchema, type IHeatmapRow, type IMarkdownDumpOptions, type INotificationUtils, type IOrderBookData, type IPartialLossCommitRow, type IPartialProfitCommitRow, type IPersistBase, type IPositionSizeATRParams, type IPositionSizeFixedPercentageParams, type IPositionSizeKellyParams, type IPublicSignalRow, type IReportDumpOptions, type IRiskActivePosition, type IRiskCheckArgs, type IRiskSchema, type IRiskSignalRow, type IRiskValidation, type IRiskValidationFn, type IRiskValidationPayload, type IScheduledSignalCancelRow, type IScheduledSignalRow, type ISignalDto, type ISignalRow, type ISizingCalculateParams, type ISizingCalculateParamsATR, type ISizingCalculateParamsFixedPercentage, type ISizingCalculateParamsKelly, type ISizingParams, type ISizingParamsATR, type ISizingParamsFixedPercentage, type ISizingParamsKelly, type ISizingSchema, type ISizingSchemaATR, type ISizingSchemaFixedPercentage, type ISizingSchemaKelly, type IStorageSignalRow, type IStorageUtils, type IStrategyPnL, type IStrategyResult, type IStrategySchema, type IStrategyTickResult, type IStrategyTickResultActive, type IStrategyTickResultCancelled, type IStrategyTickResultClosed, type IStrategyTickResultIdle, type IStrategyTickResultOpened, type IStrategyTickResultScheduled, type IStrategyTickResultWaiting, type ITrailingStopCommitRow, type ITrailingTakeCommitRow, type IWalkerResults, type IWalkerSchema, type IWalkerStrategyResult, type InfoErrorNotification, Live, type LiveStatisticsModel, Markdown, MarkdownFileBase, MarkdownFolderBase, type MarkdownName, MethodContextService, type MetricStats, Notification, NotificationBacktest, type NotificationData, NotificationLive, type NotificationModel, Partial$1 as Partial, type PartialData, type PartialEvent, type PartialLossAvailableNotification, type PartialLossCommit, type PartialLossCommitNotification, type PartialLossContract, type PartialProfitAvailableNotification, type PartialProfitCommit, type PartialProfitCommitNotification, type PartialProfitContract, type PartialStatisticsModel, Performance, type PerformanceContract, type PerformanceMetricType, type PerformanceStatisticsModel, PersistBase, PersistBreakevenAdapter, PersistCandleAdapter, PersistNotificationAdapter, PersistPartialAdapter, PersistRiskAdapter, PersistScheduleAdapter, PersistSignalAdapter, PersistStorageAdapter, PositionSize, type ProgressBacktestContract, type ProgressWalkerContract, Report, ReportBase, type ReportName, Risk, type RiskContract, type RiskData, type RiskEvent, type RiskRejectionNotification, type RiskStatisticsModel, Schedule, type ScheduleData, type SchedulePingContract, type ScheduleStatisticsModel, type ScheduledEvent, type SignalCancelledNotification, type SignalClosedNotification, type SignalData, type SignalInterval, type SignalOpenedNotification, type SignalScheduledNotification, Storage, StorageBacktest, type StorageData, StorageLive, Strategy, type StrategyActionType, type StrategyCancelReason, type StrategyCloseReason, type StrategyCommitContract, type StrategyEvent, type StrategyStatisticsModel, type TMarkdownBase, type TNotificationUtilsCtor, type TPersistBase, type TPersistBaseCtor, type TReportBase, type TStorageUtilsCtor, type TickEvent, type TrailingStopCommit, type TrailingStopCommitNotification, type TrailingTakeCommit, type TrailingTakeCommitNotification, type ValidationErrorNotification, Walker, type WalkerCompleteContract, type WalkerContract, type WalkerMetric, type SignalData$1 as WalkerSignalData, type WalkerStatisticsModel, addActionSchema, addExchangeSchema, addFrameSchema, addRiskSchema, addSizingSchema, addStrategySchema, addWalkerSchema, checkCandles, commitActivateScheduled, commitBreakeven, commitCancelScheduled, commitClosePending, commitPartialLoss, commitPartialProfit, commitTrailingStop, commitTrailingTake, emitters, formatPrice, formatQuantity, get, getActionSchema, getAveragePrice, getBacktestTimeframe, getCandles, getColumns, getConfig, getContext, getDate, getDefaultColumns, getDefaultConfig, getExchangeSchema, getFrameSchema, getMode, getNextCandles, getOrderBook, getRawCandles, getRiskSchema, getSizingSchema, getStrategySchema, getSymbol, getWalkerSchema, hasTradeContext, backtest as lib, listExchangeSchema, listFrameSchema, listRiskSchema, listSizingSchema, listStrategySchema, listWalkerSchema, listenActivePing, listenActivePingOnce, listenBacktestProgress, listenBreakevenAvailable, listenBreakevenAvailableOnce, listenDoneBacktest, listenDoneBacktestOnce, listenDoneLive, listenDoneLiveOnce, listenDoneWalker, listenDoneWalkerOnce, listenError, listenExit, listenPartialLossAvailable, listenPartialLossAvailableOnce, listenPartialProfitAvailable, listenPartialProfitAvailableOnce, listenPerformance, listenRisk, listenRiskOnce, listenSchedulePing, listenSchedulePingOnce, listenSignal, listenSignalBacktest, listenSignalBacktestOnce, listenSignalLive, listenSignalLiveOnce, listenSignalOnce, listenStrategyCommit, listenStrategyCommitOnce, listenValidation, listenWalker, listenWalkerComplete, listenWalkerOnce, listenWalkerProgress, overrideActionSchema, overrideExchangeSchema, overrideFrameSchema, overrideRiskSchema, overrideSizingSchema, overrideStrategySchema, overrideWalkerSchema, parseArgs, roundTicks, set, setColumns, setConfig, setLogger, stopStrategy, validate, warmCandles };