@discomedia/utils 1.0.14 → 1.0.16

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/index.cjs CHANGED
@@ -311,12 +311,10 @@ class TimeFormatter {
311
311
  */
312
312
  class MarketTimeCalculator {
313
313
  calendar;
314
- formatter;
315
314
  timezone;
316
315
  constructor(timezone = MARKET_CONFIG.TIMEZONE) {
317
316
  this.timezone = timezone;
318
317
  this.calendar = new MarketCalendar(timezone);
319
- this.formatter = new TimeFormatter(timezone);
320
318
  }
321
319
  /**
322
320
  * Get market open/close times for a date
@@ -806,7 +804,7 @@ function getTradingStartAndEndDates(options = {}) {
806
804
  }
807
805
  return { startDate, endDate: endMarketClose };
808
806
  }
809
- // Export the old MARKET_TIMES constant for backward compatibility
807
+ // Export the MARKET_TIMES constant for backward compatibility
810
808
  const MARKET_TIMES = {
811
809
  TIMEZONE: MARKET_CONFIG.TIMEZONE,
812
810
  PRE: {
@@ -9403,7 +9401,7 @@ const makeResponsesAPICall = async (input, options = {}) => {
9403
9401
  * });
9404
9402
  */
9405
9403
  async function makeLLMCall(input, options = {}) {
9406
- const { apiKey, model = DEFAULT_MODEL$1, responseFormat = 'text', tools, useCodeInterpreter = false, useWebSearch = false, imageBase64, imageDetail = 'high', context } = options;
9404
+ const { apiKey, model = DEFAULT_MODEL$1, responseFormat = 'text', tools, useCodeInterpreter = false, useWebSearch = false, imageBase64, imageDetail = 'high', context, } = options;
9407
9405
  // Validate model
9408
9406
  const normalizedModel = normalizeModelName(model);
9409
9407
  if (!isSupportedModel(normalizedModel)) {
@@ -9419,7 +9417,7 @@ async function makeLLMCall(input, options = {}) {
9419
9417
  conversationMessages.push({
9420
9418
  role: contextMsg.role,
9421
9419
  content: contextMsg.content,
9422
- type: 'message'
9420
+ type: 'message',
9423
9421
  });
9424
9422
  }
9425
9423
  // Add current input message
@@ -9433,9 +9431,9 @@ async function makeLLMCall(input, options = {}) {
9433
9431
  type: 'input_image',
9434
9432
  detail: imageDetail,
9435
9433
  image_url: imageBase64.startsWith('data:') ? imageBase64 : `data:image/webp;base64,${imageBase64}`,
9436
- }
9434
+ },
9437
9435
  ],
9438
- type: 'message'
9436
+ type: 'message',
9439
9437
  });
9440
9438
  }
9441
9439
  else {
@@ -9443,7 +9441,7 @@ async function makeLLMCall(input, options = {}) {
9443
9441
  conversationMessages.push({
9444
9442
  role: 'user',
9445
9443
  content: input,
9446
- type: 'message'
9444
+ type: 'message',
9447
9445
  });
9448
9446
  }
9449
9447
  processedInput = conversationMessages;
@@ -9459,10 +9457,10 @@ async function makeLLMCall(input, options = {}) {
9459
9457
  type: 'input_image',
9460
9458
  detail: imageDetail,
9461
9459
  image_url: imageBase64.startsWith('data:') ? imageBase64 : `data:image/webp;base64,${imageBase64}`,
9462
- }
9460
+ },
9463
9461
  ],
9464
- type: 'message'
9465
- }
9462
+ type: 'message',
9463
+ },
9466
9464
  ];
9467
9465
  }
9468
9466
  else {