/** * import/foreign/registry.ts — config-driven adapter selection and the public * port entry points. * * Given a checkpoint's `config.json`, pick the adapter by `model_type` / * `architectures` and run its plan. An architecture nobody claims fails loudly * with the list of what IS supported — and, for a transformer checkpoint, says * why no map could ever exist for it. */ import type { NamedTensor } from "../../export/tensors.js"; import type { HybridMambaModelConfig } from "../../model/mamba_model.js"; import { type PortDiscard, type PortedTensors, type SynthesisedTarget } from "./plan.js"; import type { ForeignConfig, ForeignMambaAdapter } from "./adapter.js"; /** Every foreign SSM architecture this engine can warm-start from. */ export declare const FOREIGN_MAMBA_ADAPTERS: readonly ForeignMambaAdapter[]; /** A completed port: the model to build, its weights, and what didn't line up. */ export interface PortedCheckpoint extends PortedTensors { /** Construct a `HybridMambaModel` with this to receive {@link PortedTensors.weights}. */ modelConfig: HybridMambaModelConfig; } export type { PortDiscard, SynthesisedTarget }; /** * The adapter that claims this checkpoint. Throws — never guesses — when no * adapter matches, because a wrong map produces a model that loads and then * generates noise. */ export declare function foreignMambaAdapterFor(config: ForeignConfig): ForeignMambaAdapter; /** * Port a foreign checkpoint's tensors onto this engine's parameters. The result * is device-free — {@link applyPortedWeights} uploads it into a live model. */ export declare function portForeignMamba(config: ForeignConfig, tensors: NamedTensor[]): PortedCheckpoint; /** Convenience: port straight from a `.safetensors` buffer. */ export declare function portForeignMambaSafetensors(config: ForeignConfig, bytes: Uint8Array): PortedCheckpoint; //# sourceMappingURL=registry.d.ts.map