dsh-plugin-local-infer 0.1.0 → 0.1.2

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 (73) hide show
  1. package/LICENSE +7 -0
  2. package/README.md +8 -1
  3. package/cordis.patch.yml +6 -6
  4. package/docs/screenshot-20261014.png +0 -0
  5. package/docs/zh/README.md +100 -0
  6. package/dsh/client.js +644 -143
  7. package/dsh/host.js +1 -1
  8. package/package.json +14 -11
  9. package/packages/core/lib/adapter.d.ts +75 -4
  10. package/packages/core/lib/debug.d.ts +1 -1
  11. package/packages/core/lib/debug.js +1 -1
  12. package/packages/core/lib/index.d.ts +3 -2
  13. package/packages/core/lib/index.js +2 -1
  14. package/packages/core/lib/launch-command.d.ts +13 -0
  15. package/packages/core/lib/launch-command.js +64 -0
  16. package/packages/core/lib/models.d.ts +2 -1
  17. package/packages/core/lib/models.js +10 -1
  18. package/packages/core/lib/status.d.ts +9 -1
  19. package/packages/core/lib/status.js +6 -1
  20. package/packages/core/package.json +1 -1
  21. package/packages/providers/lib/acquire.d.ts +125 -0
  22. package/packages/providers/lib/acquire.js +325 -0
  23. package/packages/providers/lib/adapters.d.ts +43 -6
  24. package/packages/providers/lib/adapters.js +386 -58
  25. package/packages/providers/lib/debug.d.ts +1 -1
  26. package/packages/providers/lib/debug.js +1 -1
  27. package/packages/providers/lib/deps.d.ts +6 -4
  28. package/packages/providers/lib/deps.js +17 -3
  29. package/packages/providers/lib/engines.d.ts +6 -5
  30. package/packages/providers/lib/engines.js +12 -4
  31. package/packages/providers/lib/guidelines.d.ts +2 -2
  32. package/packages/providers/lib/guidelines.js +17 -1
  33. package/packages/providers/lib/hyperqwen.d.ts +2 -2
  34. package/packages/providers/lib/hyperqwen.js +1 -1
  35. package/packages/providers/lib/index.d.ts +10 -4
  36. package/packages/providers/lib/index.js +9 -5
  37. package/packages/providers/lib/infernix.d.ts +170 -0
  38. package/packages/providers/lib/infernix.js +671 -0
  39. package/packages/providers/lib/llamacpp.d.ts +2 -2
  40. package/packages/providers/lib/llamacpp.js +1 -1
  41. package/packages/providers/lib/model-defaults.d.ts +7 -5
  42. package/packages/providers/lib/model-defaults.js +28 -4
  43. package/packages/providers/lib/ninfer.d.ts +9 -2
  44. package/packages/providers/lib/ninfer.js +10 -3
  45. package/packages/providers/lib/platform.d.ts +31 -0
  46. package/packages/providers/lib/platform.js +58 -0
  47. package/packages/providers/lib/presets.d.ts +2 -2
  48. package/packages/providers/lib/presets.js +1 -1
  49. package/packages/providers/lib/strata.d.ts +2 -2
  50. package/packages/providers/lib/strata.js +1 -1
  51. package/packages/providers/lib/vram.d.ts +2 -2
  52. package/packages/providers/lib/vram.js +1 -1
  53. package/packages/providers/package.json +3 -3
  54. package/packages/service/lib/index.d.ts +63 -20
  55. package/packages/service/lib/index.js +279 -43
  56. package/packages/service/lib/types.d.ts +44 -2
  57. package/packages/service/package.json +2 -2
  58. package/packages/tool/lib/index.d.ts +1 -1
  59. package/packages/tool/lib/index.js +1 -1
  60. package/packages/tool/package.json +3 -3
  61. package/packages/ui/lib/deps.d.ts +2 -2
  62. package/packages/ui/lib/deps.js +1 -1
  63. package/packages/ui/lib/form.d.ts +2 -2
  64. package/packages/ui/lib/form.js +1 -1
  65. package/packages/ui/lib/index.d.ts +1 -1
  66. package/packages/ui/lib/index.js +1 -1
  67. package/packages/ui/lib/meter.d.ts +2 -2
  68. package/packages/ui/lib/meter.js +1 -1
  69. package/packages/ui/lib/route.d.ts +84 -13
  70. package/packages/ui/lib/route.js +496 -56
  71. package/packages/ui/lib/warnings.d.ts +2 -2
  72. package/packages/ui/lib/warnings.js +1 -1
  73. package/packages/ui/package.json +5 -5
@@ -5,9 +5,9 @@
5
5
  * concrete EngineAdapter (Phase 5) composes it into a LaunchPlan. The registry
6
6
  * is the single list the Web card offers, so adding an engine is a data edit
7
7
  * here, never a rewire of the card.
8
- * @module @dsh/dsh-plugin-local-infer/providers/engines
8
+ * @module dsh-plugin-local-infer/providers/engines
9
9
  */
10
- import type { ParameterSpec } from '@dsh/dsh-plugin-local-infer/core';
10
+ import type { ParameterSpec } from 'dsh-plugin-local-infer/core';
11
11
  export interface EngineInfo {
12
12
  id: string;
13
13
  label: string;
@@ -19,9 +19,10 @@ export interface EngineInfo {
19
19
  }
20
20
  /**
21
21
  * The engines the Web card offers, in the order the card lists them. NInfer,
22
- * Hyper-Qwen, and llama.cpp carry parameter surfaces (llama.cpp's is the
23
- * specified set the plan names, verified when the binary lands); Strata is the
24
- * placeholder engine, its surface empty until the engine's flag set lands.
22
+ * Hyper-Qwen, Infernix, and llama.cpp carry parameter surfaces (llama.cpp's
23
+ * is the specified set the plan names, verified when the binary lands);
24
+ * Strata is the placeholder engine, its surface empty until the engine's
25
+ * flag set lands.
25
26
  */
26
27
  export declare const ENGINES: readonly EngineInfo[];
27
28
  //# sourceMappingURL=engines.d.ts.map
@@ -5,17 +5,19 @@
5
5
  * concrete EngineAdapter (Phase 5) composes it into a LaunchPlan. The registry
6
6
  * is the single list the Web card offers, so adding an engine is a data edit
7
7
  * here, never a rewire of the card.
8
- * @module @dsh/dsh-plugin-local-infer/providers/engines
8
+ * @module dsh-plugin-local-infer/providers/engines
9
9
  */
10
10
  import { HYPERQWEN_PARAMETERS } from "./hyperqwen.js";
11
+ import { INFERNIX_PARAMETERS } from "./infernix.js";
11
12
  import { LLAMACPP_PARAMETERS } from "./llamacpp.js";
12
13
  import { NINFER_PARAMETERS } from "./ninfer.js";
13
14
  import { STRATA_PARAMETERS } from "./strata.js";
14
15
  /**
15
16
  * The engines the Web card offers, in the order the card lists them. NInfer,
16
- * Hyper-Qwen, and llama.cpp carry parameter surfaces (llama.cpp's is the
17
- * specified set the plan names, verified when the binary lands); Strata is the
18
- * placeholder engine, its surface empty until the engine's flag set lands.
17
+ * Hyper-Qwen, Infernix, and llama.cpp carry parameter surfaces (llama.cpp's
18
+ * is the specified set the plan names, verified when the binary lands);
19
+ * Strata is the placeholder engine, its surface empty until the engine's
20
+ * flag set lands.
19
21
  */
20
22
  export const ENGINES = [
21
23
  {
@@ -36,6 +38,12 @@ export const ENGINES = [
36
38
  supports: { docker: true, local: true },
37
39
  parameters: LLAMACPP_PARAMETERS,
38
40
  },
41
+ {
42
+ id: 'infernix',
43
+ label: 'Infernix',
44
+ supports: { docker: false, local: true },
45
+ parameters: INFERNIX_PARAMETERS,
46
+ },
39
47
  {
40
48
  id: 'strata',
41
49
  label: 'Strata',
@@ -9,9 +9,9 @@
9
9
  * "exceeds usable VRAM" and "spec needs draft weights" rules) live in the
10
10
  * core `modelGuidelines` and run in the service, because they price against
11
11
  * a model, not against the hardware alone.
12
- * @module @dsh/dsh-plugin-local-infer/providers/guidelines
12
+ * @module dsh-plugin-local-infer/providers/guidelines
13
13
  */
14
- import type { Guideline } from '@dsh/dsh-plugin-local-infer/core';
14
+ import type { Guideline } from 'dsh-plugin-local-infer/core';
15
15
  /**
16
16
  * One pinned Host StateImage, in bytes. The NInfer measured figure for the
17
17
  * 27B artifact (195,897,344 B, the README's Host StateImage size), used as
@@ -9,8 +9,9 @@
9
9
  * "exceeds usable VRAM" and "spec needs draft weights" rules) live in the
10
10
  * core `modelGuidelines` and run in the service, because they price against
11
11
  * a model, not against the hardware alone.
12
- * @module @dsh/dsh-plugin-local-infer/providers/guidelines
12
+ * @module dsh-plugin-local-infer/providers/guidelines
13
13
  */
14
+ import { infernixDraftModelPath } from "./infernix.js";
14
15
  /**
15
16
  * One pinned Host StateImage, in bytes. The NInfer measured figure for the
16
17
  * 27B artifact (195,897,344 B, the README's Host StateImage size), used as
@@ -57,5 +58,20 @@ export const BUILTIN_GUIDELINES = [
57
58
  anchors: ['pinMemory'],
58
59
  when: (config, hw) => hw.wsl2 && config.spec === 'dflash2' && config.pinMemory !== true,
59
60
  },
61
+ {
62
+ // The Infernix dflash2 backend always loads a drafter through
63
+ // --draft-model, so a config that selects dflash2 but names no drafter
64
+ // path (no preset, no Custom path) cannot boot. The rule is Infernix-
65
+ // specific: only Infernix configs carry the draftModelPreset key, so a
66
+ // NInfer dflash2 (which rides the model's own companion weights) never
67
+ // fires it.
68
+ id: 'infernix-dflash2-needs-draft-model',
69
+ level: 'error',
70
+ message: 'dflash2 needs a draft model. Select a DFlash2 model, or switch to Custom and set the Draft model path.',
71
+ anchors: ['draftModelPreset', 'draftModel'],
72
+ when: (config) => config.spec === 'dflash2' &&
73
+ 'draftModelPreset' in config &&
74
+ infernixDraftModelPath(config) === null,
75
+ },
60
76
  ];
61
77
  //# sourceMappingURL=guidelines.js.map
@@ -4,9 +4,9 @@
4
4
  * `docker-compose.yml`, and the `single-user`/`batch` start scripts. The
5
5
  * concepts mirror the NInfer surface; the spelling is a `.env` key the
6
6
  * `HyperQwenAdapter` (Phase 5) writes into the compose environment.
7
- * @module @dsh/dsh-plugin-local-infer/providers/hyperqwen
7
+ * @module dsh-plugin-local-infer/providers/hyperqwen
8
8
  */
9
- import type { EnumOption, ParameterSpec } from '@dsh/dsh-plugin-local-infer/core';
9
+ import type { EnumOption, ParameterSpec } from 'dsh-plugin-local-infer/core';
10
10
  /**
11
11
  * The speculative-decoding backends Hyper-Qwen serves. The launcher's own
12
12
  * default is `mtp`; the single-user speed profile sets `dflash2`.
@@ -4,7 +4,7 @@
4
4
  * `docker-compose.yml`, and the `single-user`/`batch` start scripts. The
5
5
  * concepts mirror the NInfer surface; the spelling is a `.env` key the
6
6
  * `HyperQwenAdapter` (Phase 5) writes into the compose environment.
7
- * @module @dsh/dsh-plugin-local-infer/providers/hyperqwen
7
+ * @module dsh-plugin-local-infer/providers/hyperqwen
8
8
  */
9
9
  /**
10
10
  * The speculative-decoding backends Hyper-Qwen serves. The launcher's own
@@ -1,14 +1,14 @@
1
1
  /**
2
2
  * The concrete providers for the local-inference capability: the engine
3
- * adapters (ninfer, hyperqwen, llamacpp, strata), the NInfer VramModel, the
4
- * built-in presets, the built-in guidelines, and the per-OS SystemDep install
5
- * command data. Each registers itself with `ctx.localInfer`.
3
+ * adapters (ninfer, hyperqwen, llamacpp, infernix, strata), the NInfer
4
+ * VramModel, the built-in presets, the built-in guidelines, and the per-OS
5
+ * SystemDep install command data. Each registers itself with `ctx.localInfer`.
6
6
  *
7
7
  * Phase 3 registers the NInfer measured VramModels and the built-in hardware
8
8
  * guidelines. The engine adapters land in Phase 5. Phase 7 registers the
9
9
  * built-in preset data (the NInfer measured and Hyper-Qwen profile presets)
10
10
  * that the defaults resolver resolves against.
11
- * @module @dsh/dsh-plugin-local-infer/providers
11
+ * @module dsh-plugin-local-infer/providers
12
12
  */
13
13
  import type { Context } from '@deepseek-ai/cordis';
14
14
  export declare const name = "local-infer-providers";
@@ -24,13 +24,19 @@ export { NINFER_VRAM_MODELS, ninferVramModel } from './vram.ts';
24
24
  export { BUILTIN_GUIDELINES, HOST_STATE_IMAGE_BYTES } from './guidelines.ts';
25
25
  export { ENGINES } from './engines.ts';
26
26
  export type { EngineInfo } from './engines.ts';
27
+ export { ENGINE_SOURCES, FORK_REMOTE, buildEngineRepo, engineBuildSteps, engineSource, syncAndRebuildEngine, syncEngineRepo, } from './acquire.ts';
28
+ export type { AcquireLog, EngineSource, EngineStepResult, SyncRebuildRequest, SyncRebuildResult, } from './acquire.ts';
27
29
  export { ENGINE_DEP_PLANS, SYSTEM_DEPS } from './deps.ts';
30
+ export { ENGINE_PLATFORM_DEFAULTS, enginePlatformDefaults } from './platform.ts';
31
+ export type { EnginePlatformDefaults } from './platform.ts';
28
32
  export { BUILTIN_PRESETS, PRESET_SOURCES, extractJsonBlock } from './presets.ts';
29
33
  export { DEFAULT_MODELS, defaultModelFor, defaultModelsForEngine } from './model-defaults.ts';
30
34
  export { HyperQwenAdapter, LLAMACPP_DOCKER_IMAGE, NINFER_DOCKER_IMAGE, NINFER_MODEL_ARTIFACTS, NInferAdapter, STRATA_DOCKER_IMAGE, StrataAdapter, LlamaCppAdapter, customArgEnv, customArgFlags, envFromSpecs, flagsFromSpecs, nodeLifecycleHost, pollHealth, } from './adapters.ts';
31
35
  export type { NInferModelArtifact } from './adapters.ts';
32
36
  export { KV_CACHE_TYPE_OPTIONS, LLAMACPP_MODEL_ARTIFACTS, LLAMACPP_PARAMETERS, llamaCppModelKey, } from './llamacpp.ts';
33
37
  export type { LlamaCppModelArtifact } from './llamacpp.ts';
38
+ export { DFLASH2_CUSTOM_VALUE, DFLASH2_GATE_MESSAGE, INFERNIX_DFLASH2_MODELS, INFERNIX_KV_DTYPE_OPTIONS, INFERNIX_MODEL_ARTIFACTS, INFERNIX_NGRAM_RESIDENCY_OPTIONS, INFERNIX_NGRAM_VOLUMES, INFERNIX_PARAMETERS, INFERNIX_REASONING_LOOP_OPTIONS, INFERNIX_SPEC_OPTIONS, SPEC_GATE_MESSAGE as INFERNIX_SPEC_GATE_MESSAGE, dflash2PresetOptions, infernixArtifactFor, infernixDraftModelPath, infernixGetDownloads, infernixModelKey, } from './infernix.ts';
39
+ export type { InfernixDFlash2Model, InfernixModelArtifact, InfernixNgramVolume, } from './infernix.ts';
34
40
  export { STRATA_PARAMETERS } from './strata.ts';
35
41
  /**
36
42
  * Mount the providers. The NInfer measured VramModels register here so the
@@ -1,16 +1,16 @@
1
1
  /**
2
2
  * The concrete providers for the local-inference capability: the engine
3
- * adapters (ninfer, hyperqwen, llamacpp, strata), the NInfer VramModel, the
4
- * built-in presets, the built-in guidelines, and the per-OS SystemDep install
5
- * command data. Each registers itself with `ctx.localInfer`.
3
+ * adapters (ninfer, hyperqwen, llamacpp, infernix, strata), the NInfer
4
+ * VramModel, the built-in presets, the built-in guidelines, and the per-OS
5
+ * SystemDep install command data. Each registers itself with `ctx.localInfer`.
6
6
  *
7
7
  * Phase 3 registers the NInfer measured VramModels and the built-in hardware
8
8
  * guidelines. The engine adapters land in Phase 5. Phase 7 registers the
9
9
  * built-in preset data (the NInfer measured and Hyper-Qwen profile presets)
10
10
  * that the defaults resolver resolves against.
11
- * @module @dsh/dsh-plugin-local-infer/providers
11
+ * @module dsh-plugin-local-infer/providers
12
12
  */
13
- import { createNodeLifecycleHost, HyperQwenAdapter, LlamaCppAdapter, NInferAdapter, StrataAdapter, } from "./adapters.js";
13
+ import { createNodeLifecycleHost, HyperQwenAdapter, InfernixAdapter, LlamaCppAdapter, NInferAdapter, StrataAdapter, } from "./adapters.js";
14
14
  import { createDshDebugLogger } from "./debug.js";
15
15
  import { ENGINE_DEP_PLANS } from "./deps.js";
16
16
  import { BUILTIN_GUIDELINES } from "./guidelines.js";
@@ -28,11 +28,14 @@ export { CHAT_TEMPLATE_OPTIONS, DEVICE_PROFILE_OPTIONS, KV_DTYPE_OPTIONS, NINFER
28
28
  export { NINFER_VRAM_MODELS, ninferVramModel } from "./vram.js";
29
29
  export { BUILTIN_GUIDELINES, HOST_STATE_IMAGE_BYTES } from "./guidelines.js";
30
30
  export { ENGINES } from "./engines.js";
31
+ export { ENGINE_SOURCES, FORK_REMOTE, buildEngineRepo, engineBuildSteps, engineSource, syncAndRebuildEngine, syncEngineRepo, } from "./acquire.js";
31
32
  export { ENGINE_DEP_PLANS, SYSTEM_DEPS } from "./deps.js";
33
+ export { ENGINE_PLATFORM_DEFAULTS, enginePlatformDefaults } from "./platform.js";
32
34
  export { BUILTIN_PRESETS, PRESET_SOURCES, extractJsonBlock } from "./presets.js";
33
35
  export { DEFAULT_MODELS, defaultModelFor, defaultModelsForEngine } from "./model-defaults.js";
34
36
  export { HyperQwenAdapter, LLAMACPP_DOCKER_IMAGE, NINFER_DOCKER_IMAGE, NINFER_MODEL_ARTIFACTS, NInferAdapter, STRATA_DOCKER_IMAGE, StrataAdapter, LlamaCppAdapter, customArgEnv, customArgFlags, envFromSpecs, flagsFromSpecs, nodeLifecycleHost, pollHealth, } from "./adapters.js";
35
37
  export { KV_CACHE_TYPE_OPTIONS, LLAMACPP_MODEL_ARTIFACTS, LLAMACPP_PARAMETERS, llamaCppModelKey, } from "./llamacpp.js";
38
+ export { DFLASH2_CUSTOM_VALUE, DFLASH2_GATE_MESSAGE, INFERNIX_DFLASH2_MODELS, INFERNIX_KV_DTYPE_OPTIONS, INFERNIX_MODEL_ARTIFACTS, INFERNIX_NGRAM_RESIDENCY_OPTIONS, INFERNIX_NGRAM_VOLUMES, INFERNIX_PARAMETERS, INFERNIX_REASONING_LOOP_OPTIONS, INFERNIX_SPEC_OPTIONS, SPEC_GATE_MESSAGE as INFERNIX_SPEC_GATE_MESSAGE, dflash2PresetOptions, infernixArtifactFor, infernixDraftModelPath, infernixGetDownloads, infernixModelKey, } from "./infernix.js";
36
39
  export { STRATA_PARAMETERS } from "./strata.js";
37
40
  /**
38
41
  * Mount the providers. The NInfer measured VramModels register here so the
@@ -68,6 +71,7 @@ export function apply(ctx) {
68
71
  localInfer.registerEngine(new NInferAdapter(host));
69
72
  localInfer.registerEngine(new HyperQwenAdapter(host));
70
73
  localInfer.registerEngine(new LlamaCppAdapter(host));
74
+ localInfer.registerEngine(new InfernixAdapter(host));
71
75
  localInfer.registerEngine(new StrataAdapter(host));
72
76
  }
73
77
  const plugin = { name, inject, apply };
@@ -0,0 +1,170 @@
1
+ /**
2
+ * Infernix parameter surface. The declarative `ParameterSpec` data for the
3
+ * Infernix engine (https://github.com/wallawalla47/infernix), a C++/CUDA
4
+ * fork of NInfer tuned for Qwen models on a single RTX 50-series GPU,
5
+ * sourced from the project's `docs/cli.md` and `docs/serving.md`. The
6
+ * spelling is an `infernix-serve` CLI flag the `InfernixAdapter` passes onto
7
+ * the process.
8
+ *
9
+ * The surface carries the flags the NInfer surface shares (KV format,
10
+ * context, speculation, sampling) plus the Infernix-only fields: the
11
+ * `--ngram-volume` PLE table for Qwen3.8-Flash-Next, the `--draft-model`
12
+ * DFlash2 companion drafter, the n-gram copy proposal set, the offloaded-
13
+ * expert memory tiers, and the quality routes. Those fields live only on
14
+ * this surface, so the form renderer shows them only while the Infernix
15
+ * engine is selected, and the adapters of the other engines never spell
16
+ * them. Adding a flag here is a data edit, never a core rewire.
17
+ * @module dsh-plugin-local-infer/providers/infernix
18
+ */
19
+ import type { Config, EnumOption, ParameterSpec } from 'dsh-plugin-local-infer/core';
20
+ /**
21
+ * The KV cache quantization formats Infernix serves, in the order the form
22
+ * dropdown lists them. The set differs from NInfer's: the 2-bit and 4-bit-
23
+ * K vector-quantized tiers (vq2, k4v2) replace the KVarN rk tiers, and both
24
+ * hold three to four times the context of INT8 in the same VRAM.
25
+ */
26
+ export declare const INFERNIX_KV_DTYPE_OPTIONS: readonly EnumOption[];
27
+ /**
28
+ * The speculative-decoding backends. `none` loads no speculative backend at
29
+ * all, which is the smallest resident profile.
30
+ */
31
+ export declare const INFERNIX_SPEC_OPTIONS: readonly EnumOption[];
32
+ /**
33
+ * The PLE n-gram table residency modes for Qwen3.8-Flash-Next. `auto` takes
34
+ * pinned RAM only when the RAM ledger keeps every expert in RAM beside it.
35
+ */
36
+ export declare const INFERNIX_NGRAM_RESIDENCY_OPTIONS: readonly EnumOption[];
37
+ /**
38
+ * The reasoning-loop guard modes. The guard ends a reply, or closes the
39
+ * thinking, when the open thinking keeps repeating whole passages.
40
+ */
41
+ export declare const INFERNIX_REASONING_LOOP_OPTIONS: readonly EnumOption[];
42
+ /**
43
+ * The gate message the form shows while the speculation fields are greyed
44
+ * out. It names the fix (pick a backend) and the backends that unlock the
45
+ * fields, so a first-time user knows the next click, not just the constraint.
46
+ */
47
+ export declare const SPEC_GATE_MESSAGE = "Pick a speculation backend first (mtp, dflash, or dflash2)";
48
+ /**
49
+ * The gate message the form shows while the dflash2-only fields are greyed
50
+ * out. It names the fix (pick dflash2) and the reason, so a first-time user
51
+ * knows the next click, not just the constraint.
52
+ */
53
+ export declare const DFLASH2_GATE_MESSAGE = "Pick the dflash2 speculation backend first; the DFlash2 drafter loads with dflash2";
54
+ /**
55
+ * InfernixModelArtifact is the per-model deploy data: the `.infernix` (or
56
+ * `.ninfer`) artifact files, the Hugging Face repo the model download pulls
57
+ * them from, and the model id the server advertises on its OpenAI endpoint.
58
+ * A multi-file artifact (Qwen3.8-Flash-Next) names every shard in `files`
59
+ * and the engine loads the first shard from the model directory. The data
60
+ * is the surface; adding a model is a data edit here, never an adapter
61
+ * rewire.
62
+ */
63
+ export interface InfernixModelArtifact {
64
+ file: string;
65
+ files?: string[];
66
+ repo: string;
67
+ modelId: string;
68
+ }
69
+ /**
70
+ * The Infernix model artifacts, keyed by the config model key. The 27B
71
+ * NVIDIA NVFP4 entry is the default the DEFAULT_MODELS list names; an id no
72
+ * entry names falls back to it, so a bare config always renders a plan. The
73
+ * Flash-Next entry is the recommended Dense8 conversion: its download pulls
74
+ * the whole repo, which carries the FP8 n-gram volume beside the shards, so
75
+ * the `--ngram-volume` flag points at a file the same download left on disk.
76
+ */
77
+ export declare const INFERNIX_MODEL_ARTIFACTS: Record<string, InfernixModelArtifact>;
78
+ /**
79
+ * InfernixDFlash2Model is one common DFlash2 drafter the form's DFlash2 model
80
+ * dropdown offers: the `.infernix` artifact file the hf CLI pulls, the Hugging
81
+ * Face repo it lives in, and the label the dropdown shows. The DFlash2 drafter
82
+ * is a companion model that runs beside a Flash-Next conversion, so it
83
+ * downloads separately from the main model and loads through `--draft-model`.
84
+ * The data is the surface; adding a drafter is a data edit here, never an
85
+ * adapter rewire.
86
+ */
87
+ export interface InfernixDFlash2Model {
88
+ file: string;
89
+ repo: string;
90
+ label: string;
91
+ }
92
+ /**
93
+ * The common DFlash2 drafters the Infernix DFlash2 model dropdown offers, in
94
+ * dropdown order. The Flash-Next DFlash2 is Inco AI's drafter (the 776 MB
95
+ * `.infernix` artifact) that the Infernix README recommends beside any
96
+ * Flash-Next conversion. The list is the single source the dropdown, the
97
+ * `--draft-model` path resolver, and the Get download step read.
98
+ */
99
+ export declare const INFERNIX_DFLASH2_MODELS: readonly InfernixDFlash2Model[];
100
+ /**
101
+ * The dropdown value the DFlash2 model field's Custom entry carries. A
102
+ * selection of this value (or no selection) makes the effective `--draft-model`
103
+ * path fall through to the Draft model path field, so a drafter no list entry
104
+ * names still loads.
105
+ */
106
+ export declare const DFLASH2_CUSTOM_VALUE = "custom";
107
+ /**
108
+ * dflash2PresetOptions renders the DFlash2 model dropdown options: one entry
109
+ * per common drafter (the label, the repo as the note) plus the Custom entry
110
+ * last. The option value is the drafter's artifact file, so the selection
111
+ * resolves back to the model data by file name.
112
+ */
113
+ export declare function dflash2PresetOptions(): readonly EnumOption[];
114
+ /**
115
+ * InfernixNgramVolume is the PLE n-gram table a model key reads: the `.ngram`
116
+ * file and the Hugging Face repo the Get step pulls it from. The volume is kept
117
+ * apart from the model shards and read from an NVMe drive, so the
118
+ * `--ngram-volume` flag points at a file the same download leaves on disk.
119
+ */
120
+ export interface InfernixNgramVolume {
121
+ file: string;
122
+ repo: string;
123
+ }
124
+ /**
125
+ * The PLE n-gram volumes, keyed by the config model key. The Flash-Next entry
126
+ * is the FP8 volume (the recommended one), which ships beside the Dense8 model
127
+ * shards in the same repo, so a Get of the Flash-Next model pulls the table
128
+ * into the model directory.
129
+ */
130
+ export declare const INFERNIX_NGRAM_VOLUMES: Record<string, InfernixNgramVolume>;
131
+ /**
132
+ * infernixDraftModelPath resolves the effective `--draft-model` path a config
133
+ * carries: the selected DFlash2 preset's artifact (the model directory plus the
134
+ * drafter file, the layout the hf CLI download leaves) when a preset is
135
+ * selected, else the Custom Draft model path field. Returns null when neither
136
+ * names a path, which is the misconfiguration the dflash2 guideline names.
137
+ */
138
+ export declare function infernixDraftModelPath(config: Config): string | null;
139
+ /**
140
+ * infernixGetDownloads renders the hf CLI download commands a Get run pulls
141
+ * for a config: the selected DFlash2 drafter (into the model directory, the
142
+ * layout the `--draft-model` path expects) when a preset is selected, and the
143
+ * model key's PLE n-gram volume (into the model directory) when the key names
144
+ * one. The commands are the single source the Get route streams, so a Get
145
+ * leaves the model directory ready to launch.
146
+ */
147
+ export declare function infernixGetDownloads(config: Config, modelDir: string): string[];
148
+ /**
149
+ * The Infernix `ParameterSpec` surface, in form order. The `group` field is
150
+ * the form section; specs without a group render under `General`. The
151
+ * Infernix-only fields (ngramVolume, draftModel, the n-gram proposal set,
152
+ * the expert memory tiers, the quality routes) appear only on this surface,
153
+ * so the form shows them only while the Infernix engine is selected.
154
+ */
155
+ export declare const INFERNIX_PARAMETERS: readonly ParameterSpec[];
156
+ /**
157
+ * The Infernix model key a config carries: the string model value, falling
158
+ * back to the 27B artifact key so a bare config always renders a plan. A
159
+ * value that names a local artifact file (a directory-scanned model, a
160
+ * `.ninfer` or `.infernix` name) passes through unchanged.
161
+ */
162
+ export declare function infernixModelKey(config: Config): string;
163
+ /**
164
+ * infernixArtifactFor resolves the artifact a model key deploys. A key that
165
+ * names a local artifact file passes through the artifact map's 27B entry
166
+ * for the model id, and an id no entry names falls back to the 27B entry, so
167
+ * a bare config always renders a plan.
168
+ */
169
+ export declare function infernixArtifactFor(modelKey: string): InfernixModelArtifact;
170
+ //# sourceMappingURL=infernix.d.ts.map