@nexus-cortex/core 4.45.0 → 4.47.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.
Files changed (108) hide show
  1. package/dist/adapters/ChatCompletionsAPIAdapter.d.ts.map +1 -1
  2. package/dist/adapters/ChatCompletionsAPIAdapter.js +3 -1
  3. package/dist/adapters/ChatCompletionsAPIAdapter.js.map +1 -1
  4. package/dist/adapters/GatewayTranslationLayer.d.ts.map +1 -1
  5. package/dist/adapters/GatewayTranslationLayer.js +11 -6
  6. package/dist/adapters/GatewayTranslationLayer.js.map +1 -1
  7. package/dist/config/RuntimeConfigRegistry.d.ts.map +1 -1
  8. package/dist/config/RuntimeConfigRegistry.js +1 -0
  9. package/dist/config/RuntimeConfigRegistry.js.map +1 -1
  10. package/dist/config/SettingsLoader.d.ts.map +1 -1
  11. package/dist/config/SettingsLoader.js +1 -0
  12. package/dist/config/SettingsLoader.js.map +1 -1
  13. package/dist/config/SettingsSchema.d.ts +3 -0
  14. package/dist/config/SettingsSchema.d.ts.map +1 -1
  15. package/dist/config/SettingsSchema.js +9 -0
  16. package/dist/config/SettingsSchema.js.map +1 -1
  17. package/dist/index.d.ts +2 -0
  18. package/dist/index.d.ts.map +1 -1
  19. package/dist/index.js +1 -0
  20. package/dist/index.js.map +1 -1
  21. package/dist/models/cards/huggingface/hf-router.d.ts +19 -0
  22. package/dist/models/cards/huggingface/hf-router.d.ts.map +1 -0
  23. package/dist/models/cards/huggingface/hf-router.js +33 -0
  24. package/dist/models/cards/huggingface/hf-router.js.map +1 -0
  25. package/dist/models/cards/huggingface/hf-space-models.d.ts +22 -0
  26. package/dist/models/cards/huggingface/hf-space-models.d.ts.map +1 -0
  27. package/dist/models/cards/huggingface/hf-space-models.js +56 -0
  28. package/dist/models/cards/huggingface/hf-space-models.js.map +1 -0
  29. package/dist/models/cards/huggingface/hf-space.d.ts +11 -0
  30. package/dist/models/cards/huggingface/hf-space.d.ts.map +1 -0
  31. package/dist/models/cards/huggingface/hf-space.js +27 -0
  32. package/dist/models/cards/huggingface/hf-space.js.map +1 -0
  33. package/dist/models/cards/huggingface/index.d.ts +3 -2
  34. package/dist/models/cards/huggingface/index.d.ts.map +1 -1
  35. package/dist/models/cards/huggingface/index.js +5 -2
  36. package/dist/models/cards/huggingface/index.js.map +1 -1
  37. package/dist/models/cards/local/index.d.ts +1 -0
  38. package/dist/models/cards/local/index.d.ts.map +1 -1
  39. package/dist/models/cards/local/index.js +2 -0
  40. package/dist/models/cards/local/index.js.map +1 -1
  41. package/dist/models/cards/local/local-openai.d.ts +17 -0
  42. package/dist/models/cards/local/local-openai.d.ts.map +1 -0
  43. package/dist/models/cards/local/local-openai.js +33 -0
  44. package/dist/models/cards/local/local-openai.js.map +1 -0
  45. package/dist/models/cards/xai/grok-4-5.d.ts +13 -0
  46. package/dist/models/cards/xai/grok-4-5.d.ts.map +1 -0
  47. package/dist/models/cards/xai/grok-4-5.js +25 -0
  48. package/dist/models/cards/xai/grok-4-5.js.map +1 -0
  49. package/dist/models/cards/xai/index.d.ts +1 -0
  50. package/dist/models/cards/xai/index.d.ts.map +1 -1
  51. package/dist/models/cards/xai/index.js +1 -0
  52. package/dist/models/cards/xai/index.js.map +1 -1
  53. package/dist/models/configurators/HFSpaceConfigurator.d.ts +42 -0
  54. package/dist/models/configurators/HFSpaceConfigurator.d.ts.map +1 -0
  55. package/dist/models/configurators/HFSpaceConfigurator.js +71 -0
  56. package/dist/models/configurators/HFSpaceConfigurator.js.map +1 -0
  57. package/dist/models/configurators/HuggingFaceConfigurator.d.ts +7 -7
  58. package/dist/models/configurators/HuggingFaceConfigurator.d.ts.map +1 -1
  59. package/dist/models/configurators/HuggingFaceConfigurator.js +13 -6
  60. package/dist/models/configurators/HuggingFaceConfigurator.js.map +1 -1
  61. package/dist/models/configurators/LocalModelConfigurator.d.ts +7 -0
  62. package/dist/models/configurators/LocalModelConfigurator.d.ts.map +1 -1
  63. package/dist/models/configurators/LocalModelConfigurator.js +11 -1
  64. package/dist/models/configurators/LocalModelConfigurator.js.map +1 -1
  65. package/dist/models/configurators/QwenConfigurator.d.ts +0 -4
  66. package/dist/models/configurators/QwenConfigurator.d.ts.map +1 -1
  67. package/dist/models/configurators/QwenConfigurator.js +6 -7
  68. package/dist/models/configurators/QwenConfigurator.js.map +1 -1
  69. package/dist/models/hfSpace/normalize.d.ts +34 -0
  70. package/dist/models/hfSpace/normalize.d.ts.map +1 -0
  71. package/dist/models/hfSpace/normalize.js +195 -0
  72. package/dist/models/hfSpace/normalize.js.map +1 -0
  73. package/dist/models/registry/ModularModelRegistry.d.ts.map +1 -1
  74. package/dist/models/registry/ModularModelRegistry.js +17 -1
  75. package/dist/models/registry/ModularModelRegistry.js.map +1 -1
  76. package/dist/orchestrator/APIClient.d.ts +18 -0
  77. package/dist/orchestrator/APIClient.d.ts.map +1 -1
  78. package/dist/orchestrator/APIClient.js +101 -0
  79. package/dist/orchestrator/APIClient.js.map +1 -1
  80. package/dist/orchestrator/CortexOrchestrator.d.ts +13 -0
  81. package/dist/orchestrator/CortexOrchestrator.d.ts.map +1 -1
  82. package/dist/orchestrator/CortexOrchestrator.js +51 -0
  83. package/dist/orchestrator/CortexOrchestrator.js.map +1 -1
  84. package/dist/system-messages/SystemMessageLoader.d.ts +13 -0
  85. package/dist/system-messages/SystemMessageLoader.d.ts.map +1 -1
  86. package/dist/system-messages/SystemMessageLoader.js +30 -2
  87. package/dist/system-messages/SystemMessageLoader.js.map +1 -1
  88. package/dist/system-messages/memoryArchive.d.ts +28 -0
  89. package/dist/system-messages/memoryArchive.d.ts.map +1 -0
  90. package/dist/system-messages/memoryArchive.js +125 -0
  91. package/dist/system-messages/memoryArchive.js.map +1 -0
  92. package/dist/training/ResearchBacklog.d.ts +27 -0
  93. package/dist/training/ResearchBacklog.d.ts.map +1 -1
  94. package/dist/training/ResearchBacklog.js +143 -0
  95. package/dist/training/ResearchBacklog.js.map +1 -1
  96. package/dist/training/TurnPredictionStore.d.ts +58 -0
  97. package/dist/training/TurnPredictionStore.d.ts.map +1 -0
  98. package/dist/training/TurnPredictionStore.js +85 -0
  99. package/dist/training/TurnPredictionStore.js.map +1 -0
  100. package/package.json +4 -3
  101. package/dist/models/cards/huggingface/llama-3-8b-instruct.d.ts +0 -17
  102. package/dist/models/cards/huggingface/llama-3-8b-instruct.d.ts.map +0 -1
  103. package/dist/models/cards/huggingface/llama-3-8b-instruct.js +0 -25
  104. package/dist/models/cards/huggingface/llama-3-8b-instruct.js.map +0 -1
  105. package/dist/models/cards/huggingface/mistral-7b-instruct.d.ts +0 -10
  106. package/dist/models/cards/huggingface/mistral-7b-instruct.d.ts.map +0 -1
  107. package/dist/models/cards/huggingface/mistral-7b-instruct.js +0 -18
  108. package/dist/models/cards/huggingface/mistral-7b-instruct.js.map +0 -1
@@ -0,0 +1,58 @@
1
+ /**
2
+ * How the ACTUAL next message relates to the displayed prediction (the TUI
3
+ * ghost-text prefill). Spec §5.1 tri-state — splits the exam stream from
4
+ * suggestion telemetry:
5
+ * - 'none' — the prediction was never rendered to the user (late helper,
6
+ * display-holdout, or a non-TUI surface). Cleanest exam grade.
7
+ * - 'shown' — the ghost was rendered but the user typed independently.
8
+ * Exam-eligible; the shown-vs-none score gap measures semantic
9
+ * anchoring at the population level.
10
+ * - 'inserted' — the user Tab/→-accepted the ghost (edited or not). Excluded
11
+ * from the graduation exam; match_score re-reads as suggestion
12
+ * retention/usefulness (1.0 = accepted verbatim).
13
+ */
14
+ export type PrefillProvenance = 'none' | 'shown' | 'inserted';
15
+ export interface TurnPredictionRecord {
16
+ /** deterministic id: <sessionId>:<turnNumber> */
17
+ record_id: string;
18
+ session_id: string;
19
+ turn_number: number;
20
+ /** model that produced the prediction (helper today; the apprentice later). */
21
+ predictor_model: string;
22
+ /** the one-line turn summary generated alongside the prediction. */
23
+ summary: string | null;
24
+ predicted_next: string;
25
+ /** the user's ACTUAL next message (flattened to text). */
26
+ actual_next: string;
27
+ /** deterministic token-F1 in [0,1] — see predictionMatchScore. */
28
+ match_score: number;
29
+ predicted_at_ms: number;
30
+ scored_at_ms: number;
31
+ /** §5.1 provenance of actual_next relative to the displayed prediction. */
32
+ prefill_provenance: PrefillProvenance;
33
+ }
34
+ /** Pending prediction held between turns (in-memory on the orchestrator). */
35
+ export interface PendingTurnPrediction {
36
+ sessionId: string;
37
+ turnNumber: number;
38
+ predictorModel: string;
39
+ summary: string | null;
40
+ prediction: string;
41
+ predictedAtMs: number;
42
+ }
43
+ /**
44
+ * Deterministic prediction↔actual similarity: token-level F1 (harmonic mean of
45
+ * precision and recall over unique tokens). 0 = no overlap, 1 = identical token
46
+ * sets. Chosen over embeddings/LLM-judge for reproducibility and zero cost — the
47
+ * spec upgrades the metric only if this under-separates.
48
+ */
49
+ export declare function predictionMatchScore(predicted: string, actual: string): number;
50
+ /** Flatten a user message (string or content-block array) to comparable text. */
51
+ export declare function flattenUserContent(content: string | unknown[]): string;
52
+ /**
53
+ * Score a pending prediction against the actual next user message and append
54
+ * the completed record. Truncates stored texts (the raw payload belongs in R2,
55
+ * not the hot store). Never throws — recording must not affect the turn.
56
+ */
57
+ export declare function scoreAndRecordTurnPrediction(projectRoot: string, pending: PendingTurnPrediction, actualNext: string, nowMs: number, prefillProvenance?: PrefillProvenance): TurnPredictionRecord | null;
58
+ //# sourceMappingURL=TurnPredictionStore.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TurnPredictionStore.d.ts","sourceRoot":"","sources":["../../src/training/TurnPredictionStore.ts"],"names":[],"mappings":"AAqBA;;;;;;;;;;;;GAYG;AACH,MAAM,MAAM,iBAAiB,GAAG,MAAM,GAAG,OAAO,GAAG,UAAU,CAAC;AAE9D,MAAM,WAAW,oBAAoB;IACnC,iDAAiD;IACjD,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,WAAW,EAAE,MAAM,CAAC;IACpB,+EAA+E;IAC/E,eAAe,EAAE,MAAM,CAAC;IACxB,oEAAoE;IACpE,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,cAAc,EAAE,MAAM,CAAC;IACvB,0DAA0D;IAC1D,WAAW,EAAE,MAAM,CAAC;IACpB,kEAAkE;IAClE,WAAW,EAAE,MAAM,CAAC;IACpB,eAAe,EAAE,MAAM,CAAC;IACxB,YAAY,EAAE,MAAM,CAAC;IACrB,2EAA2E;IAC3E,kBAAkB,EAAE,iBAAiB,CAAC;CACvC;AAED,6EAA6E;AAC7E,MAAM,WAAW,qBAAqB;IACpC,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,cAAc,EAAE,MAAM,CAAC;IACvB,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,UAAU,EAAE,MAAM,CAAC;IACnB,aAAa,EAAE,MAAM,CAAC;CACvB;AASD;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAAC,SAAS,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,MAAM,CAU9E;AAED,iFAAiF;AACjF,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,EAAE,GAAG,MAAM,CAOtE;AAED;;;;GAIG;AACH,wBAAgB,4BAA4B,CAC1C,WAAW,EAAE,MAAM,EACnB,OAAO,EAAE,qBAAqB,EAC9B,UAAU,EAAE,MAAM,EAClB,KAAK,EAAE,MAAM,EACb,iBAAiB,GAAE,iBAA0B,GAC5C,oBAAoB,GAAG,IAAI,CAoB7B"}
@@ -0,0 +1,85 @@
1
+ /**
2
+ * Turn-prediction records — the graduation signal (Decision Capture Layer §5).
3
+ *
4
+ * TURN_SUMMARY_PREDICTION has the helper model predict the user's next message
5
+ * post-turn; historically that prediction was attached to the response and then
6
+ * THROWN AWAY. This store completes the loop: when the next user message arrives,
7
+ * the pending prediction is scored against it (cheap deterministic token-F1) and
8
+ * the `(predicted, actual, match_score)` pair is appended to
9
+ * `.cortex/training/turn-predictions.jsonl`.
10
+ *
11
+ * Why it matters: the apprentice-model graduation gate is "predict the next
12
+ * turn; graduate when accuracy clears the stage bar." These records are that
13
+ * metric's raw material — today's predictor is the helper model (the baseline);
14
+ * the apprentice fills the same slot later and is scored the same way.
15
+ *
16
+ * OSS boundary: local JSONL only (no STDB). The nexus-side capture layer mirrors
17
+ * this stream up (`ingest_turn_prediction`), same as the other `.cortex` stores.
18
+ */
19
+ import { join } from 'path';
20
+ import { appendJsonlRotating } from '../orchestrator/cortexTrainingRecord.js';
21
+ const STORE_RELATIVE_PATH = join('.cortex', 'training', 'turn-predictions.jsonl');
22
+ /** Lowercased alphanumeric tokens — the comparison alphabet for the match score. */
23
+ function tokens(s) {
24
+ return (s.toLowerCase().match(/[a-z0-9]+/g) ?? []).filter((t) => t.length > 0);
25
+ }
26
+ /**
27
+ * Deterministic prediction↔actual similarity: token-level F1 (harmonic mean of
28
+ * precision and recall over unique tokens). 0 = no overlap, 1 = identical token
29
+ * sets. Chosen over embeddings/LLM-judge for reproducibility and zero cost — the
30
+ * spec upgrades the metric only if this under-separates.
31
+ */
32
+ export function predictionMatchScore(predicted, actual) {
33
+ const p = new Set(tokens(predicted));
34
+ const a = new Set(tokens(actual));
35
+ if (p.size === 0 || a.size === 0)
36
+ return 0;
37
+ let overlap = 0;
38
+ for (const t of p)
39
+ if (a.has(t))
40
+ overlap++;
41
+ if (overlap === 0)
42
+ return 0;
43
+ const precision = overlap / p.size;
44
+ const recall = overlap / a.size;
45
+ return Math.round(((2 * precision * recall) / (precision + recall)) * 1000) / 1000;
46
+ }
47
+ /** Flatten a user message (string or content-block array) to comparable text. */
48
+ export function flattenUserContent(content) {
49
+ if (typeof content === 'string')
50
+ return content;
51
+ if (!Array.isArray(content))
52
+ return String(content ?? '');
53
+ return content
54
+ .map((b) => (typeof b === 'string' ? b : typeof b?.text === 'string' ? b.text : ''))
55
+ .filter(Boolean)
56
+ .join('\n');
57
+ }
58
+ /**
59
+ * Score a pending prediction against the actual next user message and append
60
+ * the completed record. Truncates stored texts (the raw payload belongs in R2,
61
+ * not the hot store). Never throws — recording must not affect the turn.
62
+ */
63
+ export function scoreAndRecordTurnPrediction(projectRoot, pending, actualNext, nowMs, prefillProvenance = 'none') {
64
+ try {
65
+ const record = {
66
+ record_id: `${pending.sessionId}:${pending.turnNumber}`,
67
+ session_id: pending.sessionId,
68
+ turn_number: pending.turnNumber,
69
+ predictor_model: pending.predictorModel,
70
+ summary: pending.summary ? pending.summary.slice(0, 300) : null,
71
+ predicted_next: pending.prediction.slice(0, 500),
72
+ actual_next: actualNext.slice(0, 500),
73
+ match_score: predictionMatchScore(pending.prediction, actualNext),
74
+ predicted_at_ms: pending.predictedAtMs,
75
+ scored_at_ms: nowMs,
76
+ prefill_provenance: prefillProvenance,
77
+ };
78
+ appendJsonlRotating(join(projectRoot, STORE_RELATIVE_PATH), JSON.stringify(record));
79
+ return record;
80
+ }
81
+ catch {
82
+ return null;
83
+ }
84
+ }
85
+ //# sourceMappingURL=TurnPredictionStore.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TurnPredictionStore.js","sourceRoot":"","sources":["../../src/training/TurnPredictionStore.ts"],"names":[],"mappings":"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"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nexus-cortex/core",
3
- "version": "4.45.0",
3
+ "version": "4.47.0",
4
4
  "description": "Core orchestration library implementing Claude CLI architecture patterns",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -45,9 +45,10 @@
45
45
  "@anthropic-ai/tokenizer": "^0.0.4",
46
46
  "@google/genai": "^1.27.0",
47
47
  "@google/generative-ai": "^0.2.1",
48
+ "@gradio/client": "^2.3.1",
48
49
  "@modelcontextprotocol/sdk": "^1.20.2",
49
- "@nexus-cortex/executors": "4.45.0",
50
- "@nexus-cortex/types": "4.45.0",
50
+ "@nexus-cortex/executors": "4.47.0",
51
+ "@nexus-cortex/types": "4.47.0",
51
52
  "@types/uuid": "^10.0.0",
52
53
  "chokidar": "^3.6.0",
53
54
  "openai": "^4.104.0",
@@ -1,17 +0,0 @@
1
- /**
2
- * Llama 3 8B Instruct (Hugging Face)
3
- * Meta's Llama 3 8B via Hugging Face Inference API
4
- *
5
- * Best for: Open-source alternative, serverless inference
6
- * Cost: FREE (serverless API, rate-limited)
7
- *
8
- * Setup:
9
- * 1. Get API key from: https://huggingface.co/settings/tokens
10
- * 2. Set HUGGINGFACE_API_KEY environment variable
11
- * 3. Model loads on first request (may take 20-30 seconds)
12
- *
13
- * Note: Serverless API is rate-limited. For production, use dedicated endpoints.
14
- */
15
- import type { ModelConfig } from '../../ModelConfig.interface.js';
16
- export declare const llama38bInstructHF: ModelConfig;
17
- //# sourceMappingURL=llama-3-8b-instruct.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"llama-3-8b-instruct.d.ts","sourceRoot":"","sources":["../../../../src/models/cards/huggingface/llama-3-8b-instruct.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAGH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gCAAgC,CAAC;AAElE,eAAO,MAAM,kBAAkB,EAAE,WAQ/B,CAAC"}
@@ -1,25 +0,0 @@
1
- /**
2
- * Llama 3 8B Instruct (Hugging Face)
3
- * Meta's Llama 3 8B via Hugging Face Inference API
4
- *
5
- * Best for: Open-source alternative, serverless inference
6
- * Cost: FREE (serverless API, rate-limited)
7
- *
8
- * Setup:
9
- * 1. Get API key from: https://huggingface.co/settings/tokens
10
- * 2. Set HUGGINGFACE_API_KEY environment variable
11
- * 3. Model loads on first request (may take 20-30 seconds)
12
- *
13
- * Note: Serverless API is rate-limited. For production, use dedicated endpoints.
14
- */
15
- import { createHuggingFaceModelConfig } from '../../configurators/HuggingFaceConfigurator.js';
16
- export const llama38bInstructHF = createHuggingFaceModelConfig({
17
- id: 'llama-3-8b-instruct-hf',
18
- displayName: 'Llama 3 8B Instruct (HF)',
19
- family: 'llama-3',
20
- huggingFaceModelId: 'meta-llama/Meta-Llama-3-8B-Instruct',
21
- contextWindow: 8192,
22
- outputTokens: 2048,
23
- supportsTools: false
24
- });
25
- //# sourceMappingURL=llama-3-8b-instruct.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"llama-3-8b-instruct.js","sourceRoot":"","sources":["../../../../src/models/cards/huggingface/llama-3-8b-instruct.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,OAAO,EAAE,4BAA4B,EAAE,MAAM,gDAAgD,CAAC;AAG9F,MAAM,CAAC,MAAM,kBAAkB,GAAgB,4BAA4B,CAAC;IAC1E,EAAE,EAAE,wBAAwB;IAC5B,WAAW,EAAE,0BAA0B;IACvC,MAAM,EAAE,SAAS;IACjB,kBAAkB,EAAE,qCAAqC;IACzD,aAAa,EAAE,IAAI;IACnB,YAAY,EAAE,IAAI;IAClB,aAAa,EAAE,KAAK;CACrB,CAAC,CAAC"}
@@ -1,10 +0,0 @@
1
- /**
2
- * Mistral 7B Instruct (Hugging Face)
3
- * Mistral AI's 7B model via Hugging Face Inference API
4
- *
5
- * Best for: Fast inference, balanced performance
6
- * Cost: FREE (serverless API, rate-limited)
7
- */
8
- import type { ModelConfig } from '../../ModelConfig.interface.js';
9
- export declare const mistral7bInstructHF: ModelConfig;
10
- //# sourceMappingURL=mistral-7b-instruct.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"mistral-7b-instruct.d.ts","sourceRoot":"","sources":["../../../../src/models/cards/huggingface/mistral-7b-instruct.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAGH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gCAAgC,CAAC;AAElE,eAAO,MAAM,mBAAmB,EAAE,WAQhC,CAAC"}
@@ -1,18 +0,0 @@
1
- /**
2
- * Mistral 7B Instruct (Hugging Face)
3
- * Mistral AI's 7B model via Hugging Face Inference API
4
- *
5
- * Best for: Fast inference, balanced performance
6
- * Cost: FREE (serverless API, rate-limited)
7
- */
8
- import { createHuggingFaceModelConfig } from '../../configurators/HuggingFaceConfigurator.js';
9
- export const mistral7bInstructHF = createHuggingFaceModelConfig({
10
- id: 'mistral-7b-instruct-hf',
11
- displayName: 'Mistral 7B Instruct (HF)',
12
- family: 'mistral',
13
- huggingFaceModelId: 'mistralai/Mistral-7B-Instruct-v0.2',
14
- contextWindow: 32768,
15
- outputTokens: 4096,
16
- supportsTools: false
17
- });
18
- //# sourceMappingURL=mistral-7b-instruct.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"mistral-7b-instruct.js","sourceRoot":"","sources":["../../../../src/models/cards/huggingface/mistral-7b-instruct.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,4BAA4B,EAAE,MAAM,gDAAgD,CAAC;AAG9F,MAAM,CAAC,MAAM,mBAAmB,GAAgB,4BAA4B,CAAC;IAC3E,EAAE,EAAE,wBAAwB;IAC5B,WAAW,EAAE,0BAA0B;IACvC,MAAM,EAAE,SAAS;IACjB,kBAAkB,EAAE,oCAAoC;IACxD,aAAa,EAAE,KAAK;IACpB,YAAY,EAAE,IAAI;IAClB,aAAa,EAAE,KAAK;CACrB,CAAC,CAAC"}