@thanh01.pmt/curriculum-kit 1.4.4 → 1.4.5

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,4 +1,4 @@
1
- import { S as StreamRunnerOptions } from '../streamRunner-DtQq0HV_.cjs';
1
+ import { S as StreamRunnerOptions } from '../streamRunner-CYESG6IE.cjs';
2
2
 
3
3
  /**
4
4
  * Media Types — image generation, image search, video search cho học liệu.
@@ -1,4 +1,4 @@
1
- import { S as StreamRunnerOptions } from '../streamRunner-DtQq0HV_.js';
1
+ import { S as StreamRunnerOptions } from '../streamRunner-CYESG6IE.js';
2
2
 
3
3
  /**
4
4
  * Media Types — image generation, image search, video search cho học liệu.
@@ -502,8 +502,8 @@ function extractThoughtAndContent(rawText) {
502
502
  content: content.trim()
503
503
  };
504
504
  }
505
- var DEFAULT_ARTIFACT_STREAM_IDLE_MS = 45e3;
506
- var DEFAULT_ARTIFACT_STREAM_TOTAL_MS = 42e4;
505
+ var DEFAULT_ARTIFACT_STREAM_IDLE_MS = 9e4;
506
+ var DEFAULT_ARTIFACT_STREAM_TOTAL_MS = 48e4;
507
507
  function createStreamAbortController(options) {
508
508
  const envIdle = Number(process.env.ARTIFACT_STREAM_IDLE_TIMEOUT_MS || process.env.STREAM_IDLE_TIMEOUT_MS);
509
509
  const envTotal = Number(process.env.ARTIFACT_STREAM_TOTAL_TIMEOUT_MS || process.env.STREAM_TOTAL_TIMEOUT_MS);
@@ -718,7 +718,9 @@ Guidelines:
718
718
  if (isNvidiaPreferred || uniqueNvidiaModels.length > 0) {
719
719
  for (const model of uniqueNvidiaModels) {
720
720
  try {
721
- const idle = createStreamAbortController({ idleMs: options.idleTimeoutMs, totalMs: options.timeoutMs });
721
+ const nvdIdle = options.idleTimeoutMs ?? 18e4;
722
+ const nvdTotal = options.timeoutMs ?? 6e5;
723
+ const idle = createStreamAbortController({ idleMs: nvdIdle, totalMs: nvdTotal });
722
724
  const res = await fetch("https://integrate.api.nvidia.com/v1/chat/completions", {
723
725
  method: "POST",
724
726
  headers: {
@@ -915,7 +917,9 @@ Guidelines:
915
917
  const { provider, model } = target;
916
918
  if (provider === "nvidia" && nvidiaKey && isProviderEnabled("nvidia")) {
917
919
  try {
918
- const idle = createStreamAbortController({ idleMs: options.idleTimeoutMs, totalMs: options.timeoutMs });
920
+ const nvdIdle = options.idleTimeoutMs ?? 18e4;
921
+ const nvdTotal = options.timeoutMs ?? 6e5;
922
+ const idle = createStreamAbortController({ idleMs: nvdIdle, totalMs: nvdTotal });
919
923
  const res = await fetch("https://integrate.api.nvidia.com/v1/chat/completions", {
920
924
  method: "POST",
921
925
  headers: {