@ai-matrx/agents 0.59.268 → 0.59.269

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.
@@ -1106,7 +1106,15 @@ interface LocalModel {
1106
1106
  /** At least one variant is offered (Matrx 2 lists it). */
1107
1107
  offered?: boolean;
1108
1108
  /** The later of the model's and its presentation's updated_at: what an admin edit sends as expected_updated_at. */
1109
- updated_at?: string | null;
1109
+ updated_at?: string | null; /**
1110
+ * Set only when `readModelCatalog(client, { devices })` asked: the computers that hold every required file of
1111
+ * one of this model's listed variants (models/device-models.ts `availableOnDevices`). Absent otherwise.
1112
+ */
1113
+ available_on?: Array<{
1114
+ app_instance_id: string;
1115
+ variant_id: string;
1116
+ device_model_file_ids: string[];
1117
+ }>;
1110
1118
  }
1111
1119
  interface LocalCompatRow {
1112
1120
  hardware_class: HardwareClass;
@@ -1595,13 +1603,13 @@ declare function orderCatalogGroups<T extends OrderedLike>(models: readonly T[],
1595
1603
  * one order (`orderCatalogModels` over ai.model_presentation.display_order). `curatedList` is the
1596
1604
  * only way a surface turns rows into its list, so two surfaces cannot drift apart.
1597
1605
  */
1598
- type Row$1 = Record<string, unknown>;
1606
+ type Row$2 = Record<string, unknown>;
1599
1607
  /** A structural subset of `SupabaseClient` (only `schema().from().select()` is used). */
1600
1608
  interface CuratedCatalogClient {
1601
1609
  schema(name: string): {
1602
1610
  from(table: string): {
1603
1611
  select(columns: string): PromiseLike<{
1604
- data: Row$1[] | null;
1612
+ data: Row$2[] | null;
1605
1613
  error: {
1606
1614
  message: string;
1607
1615
  } | null;
@@ -1655,20 +1663,20 @@ interface CuratedModel {
1655
1663
  */
1656
1664
  declare const EXCLUDED_REVIEW_STATES: ReadonlySet<string>;
1657
1665
  /** Whether a variant row stays on the curated list (live, and not rejected or withdrawn). */
1658
- declare const isListedVariant: (v: Row$1) => boolean;
1666
+ declare const isListedVariant: (v: Row$2) => boolean;
1659
1667
  /** The four raw ai.* reads the curated list is shaped from (live rows only; RLS applies). */
1660
1668
  interface CuratedRows {
1661
- models: Row$1[];
1662
- variants: Row$1[];
1663
- presentations: Row$1[];
1664
- providers: Row$1[];
1669
+ models: Row$2[];
1670
+ variants: Row$2[];
1671
+ presentations: Row$2[];
1672
+ providers: Row$2[];
1665
1673
  }
1666
1674
  /** Shape raw ai.* rows into the curated models (pure; the query below feeds it). Rejected and withdrawn variants are left out. */
1667
1675
  declare function shapeCuratedModels(input: {
1668
- models: Row$1[];
1669
- variants: Row$1[];
1670
- presentations: Row$1[];
1671
- providers: Row$1[];
1676
+ models: Row$2[];
1677
+ variants: Row$2[];
1678
+ presentations: Row$2[];
1679
+ providers: Row$2[];
1672
1680
  }): CuratedModel[];
1673
1681
  /** The four reads behind the curated list (live rows of ai.model_definition, model_variant, model_presentation, provider). */
1674
1682
  declare function readCuratedRows(client: CuratedCatalogClient): Promise<CuratedRows>;
@@ -1683,6 +1691,94 @@ declare function curatedList<T extends CuratedModel>(models: readonly T[], { off
1683
1691
  offeredOnly: boolean;
1684
1692
  }): T[];
1685
1693
 
1694
+ /**
1695
+ * `@ai-matrx/agents/models` — WHICH COMPUTER HOLDS WHICH CATALOG MODEL. A local model is ONE catalog row
1696
+ * (ai.model_definition / model_variant / model_artifact); there are no per-device catalog rows. Placement
1697
+ * lives in ai.device_model_file (one row per model file a computer found, `artifact_id` → ai.model_artifact).
1698
+ * `readModelCatalog(client, { devices })` and `resolveDeviceModel` (catalog-reader.ts) read it through here.
1699
+ *
1700
+ * The rules (mirrored by the server's device provider; FEATURE.md § Device-served models):
1701
+ * - a file counts only when it is not deleted and its `state` is in DEVICE_FILE_USABLE_STATES;
1702
+ * - a variant is available on a computer only when EVERY required artifact of it has a usable file there.
1703
+ * Required = the artifacts whose `required_for` holds `core` (the same set `requiredArtifacts(v, [])`
1704
+ * fetches); a variant with no `core` artifact requires all of its artifacts; a variant with no artifact
1705
+ * is never available. Optional files (an mmproj, `required_for: ["vision"]`) never block it, and are
1706
+ * listed in `device_model_file_ids` when present.
1707
+ */
1708
+ type Row$1 = Record<string, unknown>;
1709
+ /** How a device-served run says it is served: run settings `{ served_via: "device", … }`. */
1710
+ declare const DEVICE_SERVED_VIA: "device";
1711
+ /**
1712
+ * The ai.device_model_file states whose catalog file can be loaded (the column holds present, missing,
1713
+ * corrupt, unmatched, hashing, unverified_match). Only `present` is a verified copy of the catalog artifact;
1714
+ * `unverified_match` is a same-size file whose hash is not proven, `hashing` is not finished.
1715
+ */
1716
+ declare const DEVICE_FILE_USABLE_STATES: readonly string[];
1717
+ /**
1718
+ * The states in which a person's OWN file (artifact_id null: no catalog artifact) can be loaded: it is on
1719
+ * disk with its content known. Matrx 2 records a scanned file that matches no catalog artifact as `unmatched`.
1720
+ */
1721
+ declare const DEVICE_OWN_FILE_USABLE_STATES: readonly string[];
1722
+ /** One computer that holds every required file of one variant. */
1723
+ interface DeviceAvailability {
1724
+ app_instance_id: string;
1725
+ variant_id: string;
1726
+ /** The usable ai.device_model_file ids of this variant on that computer (required and optional), in artifact order. */
1727
+ device_model_file_ids: string[];
1728
+ }
1729
+ /** The run settings of a device-served model. There is no ai.provider row and no pricing row: the ledger counts 0 points. */
1730
+ interface DeviceServedSettings {
1731
+ served_via: typeof DEVICE_SERVED_VIA;
1732
+ /** The computer (public.app_instances.id). */
1733
+ app_instance_id: string;
1734
+ /** ai.model_definition.id, or an ai.device_model_file.id (artifact_id null) for a person's own model. */
1735
+ local_model_id: string;
1736
+ /** ai.model_variant.id; absent = the device's best available variant (default first, then selection_rank). */
1737
+ variant_id?: string;
1738
+ }
1739
+ /** One ai.device_model_file row, as the reader returns it. */
1740
+ interface DeviceModelFile {
1741
+ id: string;
1742
+ app_instance_id: string;
1743
+ root_id: string;
1744
+ /** Null when the person does not share folder paths (the path stays in the computer's local store). */
1745
+ rel_path: string | null;
1746
+ size_bytes: number | null;
1747
+ sha256: string | null;
1748
+ artifact_id: string | null;
1749
+ state: string;
1750
+ organization_id: string | null;
1751
+ }
1752
+ declare function toDeviceModelFile(r: Row$1): DeviceModelFile;
1753
+ /**
1754
+ * THE ai.device_model_file read: live rows in `states`, on the given computers (all the caller can see when
1755
+ * omitted; RLS keeps it to the person's own). A failed read throws, naming the table.
1756
+ */
1757
+ declare function readDeviceModelFiles(client: unknown, opts?: {
1758
+ appInstanceIds?: readonly string[];
1759
+ states?: readonly string[];
1760
+ }): Promise<DeviceModelFile[]>;
1761
+ /** A variant's artifacts as the availability rule reads them (raw ai.model_artifact ids). */
1762
+ interface AvailabilityVariant {
1763
+ id: string;
1764
+ artifacts: ReadonlyArray<{
1765
+ id: string;
1766
+ required_for: readonly string[];
1767
+ }>;
1768
+ }
1769
+ /** The artifacts a computer must hold for the variant to be available: `core`, or all when none is `core`. */
1770
+ declare function requiredArtifactIds(v: AvailabilityVariant): string[];
1771
+ /**
1772
+ * Pure: for each variant, the computers that hold every required artifact of it (DEVICE_FILE_USABLE_STATES
1773
+ * files only; others are ignored). Computers in code-point order.
1774
+ */
1775
+ declare function availableOnDevices(variants: readonly AvailabilityVariant[], files: readonly DeviceModelFile[]): Map<string, DeviceAvailability[]>;
1776
+ /** A device-model request the device cannot serve. `code` says why; the message names the model and computer. */
1777
+ declare class DeviceModelUnavailableError extends Error {
1778
+ readonly code: "not_on_device" | "unknown_model" | "unknown_variant" | "file_not_usable" | "not_own_file";
1779
+ constructor(code: DeviceModelUnavailableError["code"], message: string);
1780
+ }
1781
+
1686
1782
  /**
1687
1783
  * `@ai-matrx/agents/models` — THE model-catalog reader. Every surface that shows the downloadable-model
1688
1784
  * catalog (AI Matrx admin › Applications › Catalogs, Matrx 2 › Models, any later client) reads it here,
@@ -1725,6 +1821,13 @@ interface LocalCatalogClient {
1725
1821
  interface ReadModelCatalogOptions {
1726
1822
  /** Apps (default true): only offered models and their offered variants. The admin page passes false. */
1727
1823
  offeredOnly?: boolean;
1824
+ /**
1825
+ * Also read ai.device_model_file and give each model `available_on` (default off: output unchanged).
1826
+ * `true` = every computer the caller can see; `{ appInstanceIds }` = only those computers.
1827
+ */
1828
+ devices?: boolean | {
1829
+ appInstanceIds?: readonly string[];
1830
+ };
1728
1831
  }
1729
1832
  /** The catalog kinds whose rows live in the unified catalog (ai.*): the admin Catalogs page's model kinds. */
1730
1833
  declare const MODEL_CATALOG_KINDS: ReadonlySet<string>;
@@ -1757,6 +1860,29 @@ declare function catalogFingerprint(catalog: LocalModelCatalog): string;
1757
1860
  * by what they do and is said in `warnings`.
1758
1861
  */
1759
1862
  declare function readModelCatalog(client: CuratedCatalogClient, opts?: ReadModelCatalogOptions): Promise<LocalModelCatalog>;
1863
+ /** What `resolveDeviceModel` returns: a catalog model to load from the device's files, or a person's own file. */
1864
+ type DeviceModelResolution = {
1865
+ own: false;
1866
+ model: LocalModel;
1867
+ variant: LocalVariant;
1868
+ files: DeviceModelFile[];
1869
+ } | {
1870
+ own: true;
1871
+ file: DeviceModelFile;
1872
+ };
1873
+ /**
1874
+ * THE device-served model lookup (the client's local chat and the server's device provider both use it;
1875
+ * FEATURE.md § Device-served models). `local_model_id` is an ai.model_definition.id, or an
1876
+ * ai.device_model_file.id with no artifact (a person's own model, `{ own: true, file }`). Returns the catalog
1877
+ * model, the variant (`variant_id`, else the device's default-then-best-ranked available one) and the
1878
+ * device's file rows to load. Refuses with DeviceModelUnavailableError, by name, when the device does not
1879
+ * hold it. Reads listed variants (offeredOnly false): a model on the computer runs even after it is unoffered.
1880
+ */
1881
+ declare function resolveDeviceModel(client: CuratedCatalogClient, req: {
1882
+ app_instance_id: string;
1883
+ local_model_id: string;
1884
+ variant_id?: string;
1885
+ }): Promise<DeviceModelResolution>;
1760
1886
 
1761
1887
  /**
1762
1888
  * `@ai-matrx/agents/models` — THE fit rules: what a model can do for a purpose, read from the
@@ -1914,5 +2040,5 @@ declare function announceModelCatalogChanged(payload?: ModelCatalogChangePayload
1914
2040
  /** Bind the host's bus client: every `catalog_changed` it delivers reaches every model reader. Returns the unbind. */
1915
2041
  declare function followModelCatalogChanges(subscribe: ModelCatalogDirectiveSubscribe): () => void;
1916
2042
 
1917
- export { CHAT_DEFAULT_MODEL_KNOB, CONTENT_TYPES, DEFAULT_CAPABILITIES, EMPTY_MODEL_RECORDS, EXCLUDED_REVIEW_STATES, FEATURE_BUCKETS, FEATURE_BUCKET_ORDER, FEATURE_KEYS, FILE_TYPE_QUANT, GgufError, INPUT_MODALITIES, INTERACTION_MODES, MAX_SUCCESSION_HOPS, MODEL_CATALOG_KINDS, MODEL_FAVORITE_ENTITY_TYPE, NEW_AGENT_DEFAULT_MODEL_KNOB, OUTPUT_MODALITIES, SERVICE_LABEL, SERVICE_LABEL_PLURAL, TOP_TIER_COST_RATING, TOP_TIER_LOCKED_TITLE, acceptsTextInstructions, announceModelCatalogChanged, blendedPrice, buildModelClassIndex, buildSuccessionIndex, catalogFingerprint, catalogForApp, catalogKeyColumn, catalogKindOf, cheapestAdequateModel, classConfigKey, collapseTiersByClass, costRatingTier, costRatingWord, createModelCatalog, createModelFavorites, createModelRecords, curatedList, displayOrderOf, favoriteIdsEqual, fetchCuratedModels, findNonCanonicalCapabilityValues, fitsMemory, fitsNeed, fitsThisComputer, followModelCatalogChanges, formatMemoryBytes, fromDiscovery, ggufEngine, ggufFacts, groupFeatures, hardwareClassesOf, hasCompatibleDecisionInteraction, isChatModelCapability, isContentType, isConversationalModelCapability, isDecisionModelCapability, isFeatureKey, isHelperGguf, isInteractionMode, isListedVariant, isLocalModelCatalog, isManagedAgentModelCapability, isModelCatalogChange, isProjectorName, isSupersedable, isTopTierRating, judgeHeaderFacts, mergeAuditRecordIntoCapabilities, missingShards, modelCatalogRevision, modelClassKnobFor, modelClassName, modelClassPinOf, modelDisplayLabel, modelsForSelectionPurpose, normalizeArch, normalizeModel, normalizeModels, normalizeOs, normalizePromptSettings, onModelCatalogChanged, orderCatalogGroups, orderCatalogModels, outputFormatControlKey, parseCapabilities, pickProjector, priceTierRating, quantFromName, rankVariants, readCuratedRows, readGgufHeader, readModelCatalog, readModelIdentities, readPublicModel, reconcileModelFavoriteIds, reportModelDiagnostic, requireCanonicalCapabilities, requiredArtifacts, resetSuccessionLogForTests, resolveLiveModelId, resolveModelMapKnob, resolveNewAgentModelId, resolvePreferredModelChoice, resolveSuccessor, runtimesOnEngine, seesImages, selectActiveModels, selectActiveModelsReady, selectAllModelOptions, selectAllModels, selectAllModelsReady, selectDeprecatedModels, selectDeprecatedModelsReady, selectModelById, selectModelClassConfig, selectModelClassName, selectModelControls, selectModelDetailError, selectModelFetchType, selectModelFullyLoaded, selectModelIdentityById, selectModelIdentityLookupStatus, selectModelLabelById, selectModelLabelWithClass, selectModelNameById, selectModelOptions, selectVariant, serviceCountLabel, setModelDiagnosticsSink, shapeCuratedModels, shardFileName, shardName, speedRatingLabel, speedRatingWord, splitSetProblems, takesInput, toAuditRecord, validateModelSet, variantVerdict, withModelClass };
1918
- export type { AdminOffering, AdminPricingBand, ArtifactUse, AuditCapabilitiesRecord, CapabilitiesParseContext, CatalogKeyColumn, CatalogKindInput, CatalogModel, CatalogTier, CheapestAdequateOptions, CompatStatus, ContentType, CuratedCatalogClient, CuratedModel, CuratedPresentation, CuratedRows, CuratedVariant, DecidedBy, DeviceGraphics, DeviceHardware, DiscoveryAmbiguity, DiscoveryArtifact, DiscoveryMedia, DiscoveryResult, DiscoveryRuntime, DiscoverySource, DiscoveryVariant, FeatureBucket, FeatureBucketMeta, FeatureKey, FitCapabilities, GgufHeader, GgufRead, GgufTensor, GroupedFeatures, HardwareClass, HardwareClasses, HeaderFlag, HeaderJudgement, HeaderRefusal, Interaction, InteractionMode, LocalArtifact, LocalCatalogClient, LocalCatalogQuery, LocalCompatRow, LocalModel, LocalModelCatalog, LocalPresentation, LocalRuntime, LocalRuntimeBuild, LocalVariant, Modality, ModelCapabilities, ModelCatalog, ModelCatalogChangePayload, ModelCatalogClient, ModelCatalogConfig, ModelCatalogDirectiveSubscribe, ModelCatalogErrorSink, ModelCatalogPgError, ModelCatalogPgResult, ModelCatalogQuery, ModelCatalogState, ModelCatalogVariant, ModelCatalogVariantState, ModelClassConfig, ModelClassEntry, ModelClassIndex, ModelDiagnosticEntry, ModelDiagnosticsSink, ModelFavorites, ModelFavoritesCache, ModelFavoritesClient, ModelFavoritesConfig, ModelFavoritesErrorSink, ModelFavoritesState, ModelFetchScope, ModelFileHandle, ModelFit, ModelIdentityRow, ModelJson, ModelLabelSource, ModelNeed, ModelOfferingRow, ModelOption, ModelOptionWithLifecycle, ModelRecord, ModelRecordFetchType, ModelRecords, ModelRecordsClient, ModelRecordsConfig, ModelRecordsState, ModelSelectionPurpose, ModelSetEnv, ModelSetFacts, ModelSetValidation, NewAgentModel, NoSelection, OrderedLike, PreferredModelChoice, PreferredModelChoicePorts, PriceTier, PricedCatalogModel, PublicModelClient, RankOptions, RankedVariant, ReadModelCatalogOptions, SelectDevice, Selection, ShardName, SuccessionClient, SuccessionIndex, SuccessionNode, VariantDiscovery, VariantVerdict, Want };
2043
+ export { CHAT_DEFAULT_MODEL_KNOB, CONTENT_TYPES, DEFAULT_CAPABILITIES, DEVICE_FILE_USABLE_STATES, DEVICE_OWN_FILE_USABLE_STATES, DEVICE_SERVED_VIA, DeviceModelUnavailableError, EMPTY_MODEL_RECORDS, EXCLUDED_REVIEW_STATES, FEATURE_BUCKETS, FEATURE_BUCKET_ORDER, FEATURE_KEYS, FILE_TYPE_QUANT, GgufError, INPUT_MODALITIES, INTERACTION_MODES, MAX_SUCCESSION_HOPS, MODEL_CATALOG_KINDS, MODEL_FAVORITE_ENTITY_TYPE, NEW_AGENT_DEFAULT_MODEL_KNOB, OUTPUT_MODALITIES, SERVICE_LABEL, SERVICE_LABEL_PLURAL, TOP_TIER_COST_RATING, TOP_TIER_LOCKED_TITLE, acceptsTextInstructions, announceModelCatalogChanged, availableOnDevices, blendedPrice, buildModelClassIndex, buildSuccessionIndex, catalogFingerprint, catalogForApp, catalogKeyColumn, catalogKindOf, cheapestAdequateModel, classConfigKey, collapseTiersByClass, costRatingTier, costRatingWord, createModelCatalog, createModelFavorites, createModelRecords, curatedList, displayOrderOf, favoriteIdsEqual, fetchCuratedModels, findNonCanonicalCapabilityValues, fitsMemory, fitsNeed, fitsThisComputer, followModelCatalogChanges, formatMemoryBytes, fromDiscovery, ggufEngine, ggufFacts, groupFeatures, hardwareClassesOf, hasCompatibleDecisionInteraction, isChatModelCapability, isContentType, isConversationalModelCapability, isDecisionModelCapability, isFeatureKey, isHelperGguf, isInteractionMode, isListedVariant, isLocalModelCatalog, isManagedAgentModelCapability, isModelCatalogChange, isProjectorName, isSupersedable, isTopTierRating, judgeHeaderFacts, mergeAuditRecordIntoCapabilities, missingShards, modelCatalogRevision, modelClassKnobFor, modelClassName, modelClassPinOf, modelDisplayLabel, modelsForSelectionPurpose, normalizeArch, normalizeModel, normalizeModels, normalizeOs, normalizePromptSettings, onModelCatalogChanged, orderCatalogGroups, orderCatalogModels, outputFormatControlKey, parseCapabilities, pickProjector, priceTierRating, quantFromName, rankVariants, readCuratedRows, readDeviceModelFiles, readGgufHeader, readModelCatalog, readModelIdentities, readPublicModel, reconcileModelFavoriteIds, reportModelDiagnostic, requireCanonicalCapabilities, requiredArtifactIds, requiredArtifacts, resetSuccessionLogForTests, resolveDeviceModel, resolveLiveModelId, resolveModelMapKnob, resolveNewAgentModelId, resolvePreferredModelChoice, resolveSuccessor, runtimesOnEngine, seesImages, selectActiveModels, selectActiveModelsReady, selectAllModelOptions, selectAllModels, selectAllModelsReady, selectDeprecatedModels, selectDeprecatedModelsReady, selectModelById, selectModelClassConfig, selectModelClassName, selectModelControls, selectModelDetailError, selectModelFetchType, selectModelFullyLoaded, selectModelIdentityById, selectModelIdentityLookupStatus, selectModelLabelById, selectModelLabelWithClass, selectModelNameById, selectModelOptions, selectVariant, serviceCountLabel, setModelDiagnosticsSink, shapeCuratedModels, shardFileName, shardName, speedRatingLabel, speedRatingWord, splitSetProblems, takesInput, toAuditRecord, toDeviceModelFile, validateModelSet, variantVerdict, withModelClass };
2044
+ export type { AdminOffering, AdminPricingBand, ArtifactUse, AuditCapabilitiesRecord, AvailabilityVariant, CapabilitiesParseContext, CatalogKeyColumn, CatalogKindInput, CatalogModel, CatalogTier, CheapestAdequateOptions, CompatStatus, ContentType, CuratedCatalogClient, CuratedModel, CuratedPresentation, CuratedRows, CuratedVariant, DecidedBy, DeviceAvailability, DeviceGraphics, DeviceHardware, DeviceModelFile, DeviceModelResolution, DeviceServedSettings, DiscoveryAmbiguity, DiscoveryArtifact, DiscoveryMedia, DiscoveryResult, DiscoveryRuntime, DiscoverySource, DiscoveryVariant, FeatureBucket, FeatureBucketMeta, FeatureKey, FitCapabilities, GgufHeader, GgufRead, GgufTensor, GroupedFeatures, HardwareClass, HardwareClasses, HeaderFlag, HeaderJudgement, HeaderRefusal, Interaction, InteractionMode, LocalArtifact, LocalCatalogClient, LocalCatalogQuery, LocalCompatRow, LocalModel, LocalModelCatalog, LocalPresentation, LocalRuntime, LocalRuntimeBuild, LocalVariant, Modality, ModelCapabilities, ModelCatalog, ModelCatalogChangePayload, ModelCatalogClient, ModelCatalogConfig, ModelCatalogDirectiveSubscribe, ModelCatalogErrorSink, ModelCatalogPgError, ModelCatalogPgResult, ModelCatalogQuery, ModelCatalogState, ModelCatalogVariant, ModelCatalogVariantState, ModelClassConfig, ModelClassEntry, ModelClassIndex, ModelDiagnosticEntry, ModelDiagnosticsSink, ModelFavorites, ModelFavoritesCache, ModelFavoritesClient, ModelFavoritesConfig, ModelFavoritesErrorSink, ModelFavoritesState, ModelFetchScope, ModelFileHandle, ModelFit, ModelIdentityRow, ModelJson, ModelLabelSource, ModelNeed, ModelOfferingRow, ModelOption, ModelOptionWithLifecycle, ModelRecord, ModelRecordFetchType, ModelRecords, ModelRecordsClient, ModelRecordsConfig, ModelRecordsState, ModelSelectionPurpose, ModelSetEnv, ModelSetFacts, ModelSetValidation, NewAgentModel, NoSelection, OrderedLike, PreferredModelChoice, PreferredModelChoicePorts, PriceTier, PricedCatalogModel, PublicModelClient, RankOptions, RankedVariant, ReadModelCatalogOptions, SelectDevice, Selection, ShardName, SuccessionClient, SuccessionIndex, SuccessionNode, VariantDiscovery, VariantVerdict, Want };
@@ -1106,7 +1106,15 @@ interface LocalModel {
1106
1106
  /** At least one variant is offered (Matrx 2 lists it). */
1107
1107
  offered?: boolean;
1108
1108
  /** The later of the model's and its presentation's updated_at: what an admin edit sends as expected_updated_at. */
1109
- updated_at?: string | null;
1109
+ updated_at?: string | null; /**
1110
+ * Set only when `readModelCatalog(client, { devices })` asked: the computers that hold every required file of
1111
+ * one of this model's listed variants (models/device-models.ts `availableOnDevices`). Absent otherwise.
1112
+ */
1113
+ available_on?: Array<{
1114
+ app_instance_id: string;
1115
+ variant_id: string;
1116
+ device_model_file_ids: string[];
1117
+ }>;
1110
1118
  }
1111
1119
  interface LocalCompatRow {
1112
1120
  hardware_class: HardwareClass;
@@ -1595,13 +1603,13 @@ declare function orderCatalogGroups<T extends OrderedLike>(models: readonly T[],
1595
1603
  * one order (`orderCatalogModels` over ai.model_presentation.display_order). `curatedList` is the
1596
1604
  * only way a surface turns rows into its list, so two surfaces cannot drift apart.
1597
1605
  */
1598
- type Row$1 = Record<string, unknown>;
1606
+ type Row$2 = Record<string, unknown>;
1599
1607
  /** A structural subset of `SupabaseClient` (only `schema().from().select()` is used). */
1600
1608
  interface CuratedCatalogClient {
1601
1609
  schema(name: string): {
1602
1610
  from(table: string): {
1603
1611
  select(columns: string): PromiseLike<{
1604
- data: Row$1[] | null;
1612
+ data: Row$2[] | null;
1605
1613
  error: {
1606
1614
  message: string;
1607
1615
  } | null;
@@ -1655,20 +1663,20 @@ interface CuratedModel {
1655
1663
  */
1656
1664
  declare const EXCLUDED_REVIEW_STATES: ReadonlySet<string>;
1657
1665
  /** Whether a variant row stays on the curated list (live, and not rejected or withdrawn). */
1658
- declare const isListedVariant: (v: Row$1) => boolean;
1666
+ declare const isListedVariant: (v: Row$2) => boolean;
1659
1667
  /** The four raw ai.* reads the curated list is shaped from (live rows only; RLS applies). */
1660
1668
  interface CuratedRows {
1661
- models: Row$1[];
1662
- variants: Row$1[];
1663
- presentations: Row$1[];
1664
- providers: Row$1[];
1669
+ models: Row$2[];
1670
+ variants: Row$2[];
1671
+ presentations: Row$2[];
1672
+ providers: Row$2[];
1665
1673
  }
1666
1674
  /** Shape raw ai.* rows into the curated models (pure; the query below feeds it). Rejected and withdrawn variants are left out. */
1667
1675
  declare function shapeCuratedModels(input: {
1668
- models: Row$1[];
1669
- variants: Row$1[];
1670
- presentations: Row$1[];
1671
- providers: Row$1[];
1676
+ models: Row$2[];
1677
+ variants: Row$2[];
1678
+ presentations: Row$2[];
1679
+ providers: Row$2[];
1672
1680
  }): CuratedModel[];
1673
1681
  /** The four reads behind the curated list (live rows of ai.model_definition, model_variant, model_presentation, provider). */
1674
1682
  declare function readCuratedRows(client: CuratedCatalogClient): Promise<CuratedRows>;
@@ -1683,6 +1691,94 @@ declare function curatedList<T extends CuratedModel>(models: readonly T[], { off
1683
1691
  offeredOnly: boolean;
1684
1692
  }): T[];
1685
1693
 
1694
+ /**
1695
+ * `@ai-matrx/agents/models` — WHICH COMPUTER HOLDS WHICH CATALOG MODEL. A local model is ONE catalog row
1696
+ * (ai.model_definition / model_variant / model_artifact); there are no per-device catalog rows. Placement
1697
+ * lives in ai.device_model_file (one row per model file a computer found, `artifact_id` → ai.model_artifact).
1698
+ * `readModelCatalog(client, { devices })` and `resolveDeviceModel` (catalog-reader.ts) read it through here.
1699
+ *
1700
+ * The rules (mirrored by the server's device provider; FEATURE.md § Device-served models):
1701
+ * - a file counts only when it is not deleted and its `state` is in DEVICE_FILE_USABLE_STATES;
1702
+ * - a variant is available on a computer only when EVERY required artifact of it has a usable file there.
1703
+ * Required = the artifacts whose `required_for` holds `core` (the same set `requiredArtifacts(v, [])`
1704
+ * fetches); a variant with no `core` artifact requires all of its artifacts; a variant with no artifact
1705
+ * is never available. Optional files (an mmproj, `required_for: ["vision"]`) never block it, and are
1706
+ * listed in `device_model_file_ids` when present.
1707
+ */
1708
+ type Row$1 = Record<string, unknown>;
1709
+ /** How a device-served run says it is served: run settings `{ served_via: "device", … }`. */
1710
+ declare const DEVICE_SERVED_VIA: "device";
1711
+ /**
1712
+ * The ai.device_model_file states whose catalog file can be loaded (the column holds present, missing,
1713
+ * corrupt, unmatched, hashing, unverified_match). Only `present` is a verified copy of the catalog artifact;
1714
+ * `unverified_match` is a same-size file whose hash is not proven, `hashing` is not finished.
1715
+ */
1716
+ declare const DEVICE_FILE_USABLE_STATES: readonly string[];
1717
+ /**
1718
+ * The states in which a person's OWN file (artifact_id null: no catalog artifact) can be loaded: it is on
1719
+ * disk with its content known. Matrx 2 records a scanned file that matches no catalog artifact as `unmatched`.
1720
+ */
1721
+ declare const DEVICE_OWN_FILE_USABLE_STATES: readonly string[];
1722
+ /** One computer that holds every required file of one variant. */
1723
+ interface DeviceAvailability {
1724
+ app_instance_id: string;
1725
+ variant_id: string;
1726
+ /** The usable ai.device_model_file ids of this variant on that computer (required and optional), in artifact order. */
1727
+ device_model_file_ids: string[];
1728
+ }
1729
+ /** The run settings of a device-served model. There is no ai.provider row and no pricing row: the ledger counts 0 points. */
1730
+ interface DeviceServedSettings {
1731
+ served_via: typeof DEVICE_SERVED_VIA;
1732
+ /** The computer (public.app_instances.id). */
1733
+ app_instance_id: string;
1734
+ /** ai.model_definition.id, or an ai.device_model_file.id (artifact_id null) for a person's own model. */
1735
+ local_model_id: string;
1736
+ /** ai.model_variant.id; absent = the device's best available variant (default first, then selection_rank). */
1737
+ variant_id?: string;
1738
+ }
1739
+ /** One ai.device_model_file row, as the reader returns it. */
1740
+ interface DeviceModelFile {
1741
+ id: string;
1742
+ app_instance_id: string;
1743
+ root_id: string;
1744
+ /** Null when the person does not share folder paths (the path stays in the computer's local store). */
1745
+ rel_path: string | null;
1746
+ size_bytes: number | null;
1747
+ sha256: string | null;
1748
+ artifact_id: string | null;
1749
+ state: string;
1750
+ organization_id: string | null;
1751
+ }
1752
+ declare function toDeviceModelFile(r: Row$1): DeviceModelFile;
1753
+ /**
1754
+ * THE ai.device_model_file read: live rows in `states`, on the given computers (all the caller can see when
1755
+ * omitted; RLS keeps it to the person's own). A failed read throws, naming the table.
1756
+ */
1757
+ declare function readDeviceModelFiles(client: unknown, opts?: {
1758
+ appInstanceIds?: readonly string[];
1759
+ states?: readonly string[];
1760
+ }): Promise<DeviceModelFile[]>;
1761
+ /** A variant's artifacts as the availability rule reads them (raw ai.model_artifact ids). */
1762
+ interface AvailabilityVariant {
1763
+ id: string;
1764
+ artifacts: ReadonlyArray<{
1765
+ id: string;
1766
+ required_for: readonly string[];
1767
+ }>;
1768
+ }
1769
+ /** The artifacts a computer must hold for the variant to be available: `core`, or all when none is `core`. */
1770
+ declare function requiredArtifactIds(v: AvailabilityVariant): string[];
1771
+ /**
1772
+ * Pure: for each variant, the computers that hold every required artifact of it (DEVICE_FILE_USABLE_STATES
1773
+ * files only; others are ignored). Computers in code-point order.
1774
+ */
1775
+ declare function availableOnDevices(variants: readonly AvailabilityVariant[], files: readonly DeviceModelFile[]): Map<string, DeviceAvailability[]>;
1776
+ /** A device-model request the device cannot serve. `code` says why; the message names the model and computer. */
1777
+ declare class DeviceModelUnavailableError extends Error {
1778
+ readonly code: "not_on_device" | "unknown_model" | "unknown_variant" | "file_not_usable" | "not_own_file";
1779
+ constructor(code: DeviceModelUnavailableError["code"], message: string);
1780
+ }
1781
+
1686
1782
  /**
1687
1783
  * `@ai-matrx/agents/models` — THE model-catalog reader. Every surface that shows the downloadable-model
1688
1784
  * catalog (AI Matrx admin › Applications › Catalogs, Matrx 2 › Models, any later client) reads it here,
@@ -1725,6 +1821,13 @@ interface LocalCatalogClient {
1725
1821
  interface ReadModelCatalogOptions {
1726
1822
  /** Apps (default true): only offered models and their offered variants. The admin page passes false. */
1727
1823
  offeredOnly?: boolean;
1824
+ /**
1825
+ * Also read ai.device_model_file and give each model `available_on` (default off: output unchanged).
1826
+ * `true` = every computer the caller can see; `{ appInstanceIds }` = only those computers.
1827
+ */
1828
+ devices?: boolean | {
1829
+ appInstanceIds?: readonly string[];
1830
+ };
1728
1831
  }
1729
1832
  /** The catalog kinds whose rows live in the unified catalog (ai.*): the admin Catalogs page's model kinds. */
1730
1833
  declare const MODEL_CATALOG_KINDS: ReadonlySet<string>;
@@ -1757,6 +1860,29 @@ declare function catalogFingerprint(catalog: LocalModelCatalog): string;
1757
1860
  * by what they do and is said in `warnings`.
1758
1861
  */
1759
1862
  declare function readModelCatalog(client: CuratedCatalogClient, opts?: ReadModelCatalogOptions): Promise<LocalModelCatalog>;
1863
+ /** What `resolveDeviceModel` returns: a catalog model to load from the device's files, or a person's own file. */
1864
+ type DeviceModelResolution = {
1865
+ own: false;
1866
+ model: LocalModel;
1867
+ variant: LocalVariant;
1868
+ files: DeviceModelFile[];
1869
+ } | {
1870
+ own: true;
1871
+ file: DeviceModelFile;
1872
+ };
1873
+ /**
1874
+ * THE device-served model lookup (the client's local chat and the server's device provider both use it;
1875
+ * FEATURE.md § Device-served models). `local_model_id` is an ai.model_definition.id, or an
1876
+ * ai.device_model_file.id with no artifact (a person's own model, `{ own: true, file }`). Returns the catalog
1877
+ * model, the variant (`variant_id`, else the device's default-then-best-ranked available one) and the
1878
+ * device's file rows to load. Refuses with DeviceModelUnavailableError, by name, when the device does not
1879
+ * hold it. Reads listed variants (offeredOnly false): a model on the computer runs even after it is unoffered.
1880
+ */
1881
+ declare function resolveDeviceModel(client: CuratedCatalogClient, req: {
1882
+ app_instance_id: string;
1883
+ local_model_id: string;
1884
+ variant_id?: string;
1885
+ }): Promise<DeviceModelResolution>;
1760
1886
 
1761
1887
  /**
1762
1888
  * `@ai-matrx/agents/models` — THE fit rules: what a model can do for a purpose, read from the
@@ -1914,5 +2040,5 @@ declare function announceModelCatalogChanged(payload?: ModelCatalogChangePayload
1914
2040
  /** Bind the host's bus client: every `catalog_changed` it delivers reaches every model reader. Returns the unbind. */
1915
2041
  declare function followModelCatalogChanges(subscribe: ModelCatalogDirectiveSubscribe): () => void;
1916
2042
 
1917
- export { CHAT_DEFAULT_MODEL_KNOB, CONTENT_TYPES, DEFAULT_CAPABILITIES, EMPTY_MODEL_RECORDS, EXCLUDED_REVIEW_STATES, FEATURE_BUCKETS, FEATURE_BUCKET_ORDER, FEATURE_KEYS, FILE_TYPE_QUANT, GgufError, INPUT_MODALITIES, INTERACTION_MODES, MAX_SUCCESSION_HOPS, MODEL_CATALOG_KINDS, MODEL_FAVORITE_ENTITY_TYPE, NEW_AGENT_DEFAULT_MODEL_KNOB, OUTPUT_MODALITIES, SERVICE_LABEL, SERVICE_LABEL_PLURAL, TOP_TIER_COST_RATING, TOP_TIER_LOCKED_TITLE, acceptsTextInstructions, announceModelCatalogChanged, blendedPrice, buildModelClassIndex, buildSuccessionIndex, catalogFingerprint, catalogForApp, catalogKeyColumn, catalogKindOf, cheapestAdequateModel, classConfigKey, collapseTiersByClass, costRatingTier, costRatingWord, createModelCatalog, createModelFavorites, createModelRecords, curatedList, displayOrderOf, favoriteIdsEqual, fetchCuratedModels, findNonCanonicalCapabilityValues, fitsMemory, fitsNeed, fitsThisComputer, followModelCatalogChanges, formatMemoryBytes, fromDiscovery, ggufEngine, ggufFacts, groupFeatures, hardwareClassesOf, hasCompatibleDecisionInteraction, isChatModelCapability, isContentType, isConversationalModelCapability, isDecisionModelCapability, isFeatureKey, isHelperGguf, isInteractionMode, isListedVariant, isLocalModelCatalog, isManagedAgentModelCapability, isModelCatalogChange, isProjectorName, isSupersedable, isTopTierRating, judgeHeaderFacts, mergeAuditRecordIntoCapabilities, missingShards, modelCatalogRevision, modelClassKnobFor, modelClassName, modelClassPinOf, modelDisplayLabel, modelsForSelectionPurpose, normalizeArch, normalizeModel, normalizeModels, normalizeOs, normalizePromptSettings, onModelCatalogChanged, orderCatalogGroups, orderCatalogModels, outputFormatControlKey, parseCapabilities, pickProjector, priceTierRating, quantFromName, rankVariants, readCuratedRows, readGgufHeader, readModelCatalog, readModelIdentities, readPublicModel, reconcileModelFavoriteIds, reportModelDiagnostic, requireCanonicalCapabilities, requiredArtifacts, resetSuccessionLogForTests, resolveLiveModelId, resolveModelMapKnob, resolveNewAgentModelId, resolvePreferredModelChoice, resolveSuccessor, runtimesOnEngine, seesImages, selectActiveModels, selectActiveModelsReady, selectAllModelOptions, selectAllModels, selectAllModelsReady, selectDeprecatedModels, selectDeprecatedModelsReady, selectModelById, selectModelClassConfig, selectModelClassName, selectModelControls, selectModelDetailError, selectModelFetchType, selectModelFullyLoaded, selectModelIdentityById, selectModelIdentityLookupStatus, selectModelLabelById, selectModelLabelWithClass, selectModelNameById, selectModelOptions, selectVariant, serviceCountLabel, setModelDiagnosticsSink, shapeCuratedModels, shardFileName, shardName, speedRatingLabel, speedRatingWord, splitSetProblems, takesInput, toAuditRecord, validateModelSet, variantVerdict, withModelClass };
1918
- export type { AdminOffering, AdminPricingBand, ArtifactUse, AuditCapabilitiesRecord, CapabilitiesParseContext, CatalogKeyColumn, CatalogKindInput, CatalogModel, CatalogTier, CheapestAdequateOptions, CompatStatus, ContentType, CuratedCatalogClient, CuratedModel, CuratedPresentation, CuratedRows, CuratedVariant, DecidedBy, DeviceGraphics, DeviceHardware, DiscoveryAmbiguity, DiscoveryArtifact, DiscoveryMedia, DiscoveryResult, DiscoveryRuntime, DiscoverySource, DiscoveryVariant, FeatureBucket, FeatureBucketMeta, FeatureKey, FitCapabilities, GgufHeader, GgufRead, GgufTensor, GroupedFeatures, HardwareClass, HardwareClasses, HeaderFlag, HeaderJudgement, HeaderRefusal, Interaction, InteractionMode, LocalArtifact, LocalCatalogClient, LocalCatalogQuery, LocalCompatRow, LocalModel, LocalModelCatalog, LocalPresentation, LocalRuntime, LocalRuntimeBuild, LocalVariant, Modality, ModelCapabilities, ModelCatalog, ModelCatalogChangePayload, ModelCatalogClient, ModelCatalogConfig, ModelCatalogDirectiveSubscribe, ModelCatalogErrorSink, ModelCatalogPgError, ModelCatalogPgResult, ModelCatalogQuery, ModelCatalogState, ModelCatalogVariant, ModelCatalogVariantState, ModelClassConfig, ModelClassEntry, ModelClassIndex, ModelDiagnosticEntry, ModelDiagnosticsSink, ModelFavorites, ModelFavoritesCache, ModelFavoritesClient, ModelFavoritesConfig, ModelFavoritesErrorSink, ModelFavoritesState, ModelFetchScope, ModelFileHandle, ModelFit, ModelIdentityRow, ModelJson, ModelLabelSource, ModelNeed, ModelOfferingRow, ModelOption, ModelOptionWithLifecycle, ModelRecord, ModelRecordFetchType, ModelRecords, ModelRecordsClient, ModelRecordsConfig, ModelRecordsState, ModelSelectionPurpose, ModelSetEnv, ModelSetFacts, ModelSetValidation, NewAgentModel, NoSelection, OrderedLike, PreferredModelChoice, PreferredModelChoicePorts, PriceTier, PricedCatalogModel, PublicModelClient, RankOptions, RankedVariant, ReadModelCatalogOptions, SelectDevice, Selection, ShardName, SuccessionClient, SuccessionIndex, SuccessionNode, VariantDiscovery, VariantVerdict, Want };
2043
+ export { CHAT_DEFAULT_MODEL_KNOB, CONTENT_TYPES, DEFAULT_CAPABILITIES, DEVICE_FILE_USABLE_STATES, DEVICE_OWN_FILE_USABLE_STATES, DEVICE_SERVED_VIA, DeviceModelUnavailableError, EMPTY_MODEL_RECORDS, EXCLUDED_REVIEW_STATES, FEATURE_BUCKETS, FEATURE_BUCKET_ORDER, FEATURE_KEYS, FILE_TYPE_QUANT, GgufError, INPUT_MODALITIES, INTERACTION_MODES, MAX_SUCCESSION_HOPS, MODEL_CATALOG_KINDS, MODEL_FAVORITE_ENTITY_TYPE, NEW_AGENT_DEFAULT_MODEL_KNOB, OUTPUT_MODALITIES, SERVICE_LABEL, SERVICE_LABEL_PLURAL, TOP_TIER_COST_RATING, TOP_TIER_LOCKED_TITLE, acceptsTextInstructions, announceModelCatalogChanged, availableOnDevices, blendedPrice, buildModelClassIndex, buildSuccessionIndex, catalogFingerprint, catalogForApp, catalogKeyColumn, catalogKindOf, cheapestAdequateModel, classConfigKey, collapseTiersByClass, costRatingTier, costRatingWord, createModelCatalog, createModelFavorites, createModelRecords, curatedList, displayOrderOf, favoriteIdsEqual, fetchCuratedModels, findNonCanonicalCapabilityValues, fitsMemory, fitsNeed, fitsThisComputer, followModelCatalogChanges, formatMemoryBytes, fromDiscovery, ggufEngine, ggufFacts, groupFeatures, hardwareClassesOf, hasCompatibleDecisionInteraction, isChatModelCapability, isContentType, isConversationalModelCapability, isDecisionModelCapability, isFeatureKey, isHelperGguf, isInteractionMode, isListedVariant, isLocalModelCatalog, isManagedAgentModelCapability, isModelCatalogChange, isProjectorName, isSupersedable, isTopTierRating, judgeHeaderFacts, mergeAuditRecordIntoCapabilities, missingShards, modelCatalogRevision, modelClassKnobFor, modelClassName, modelClassPinOf, modelDisplayLabel, modelsForSelectionPurpose, normalizeArch, normalizeModel, normalizeModels, normalizeOs, normalizePromptSettings, onModelCatalogChanged, orderCatalogGroups, orderCatalogModels, outputFormatControlKey, parseCapabilities, pickProjector, priceTierRating, quantFromName, rankVariants, readCuratedRows, readDeviceModelFiles, readGgufHeader, readModelCatalog, readModelIdentities, readPublicModel, reconcileModelFavoriteIds, reportModelDiagnostic, requireCanonicalCapabilities, requiredArtifactIds, requiredArtifacts, resetSuccessionLogForTests, resolveDeviceModel, resolveLiveModelId, resolveModelMapKnob, resolveNewAgentModelId, resolvePreferredModelChoice, resolveSuccessor, runtimesOnEngine, seesImages, selectActiveModels, selectActiveModelsReady, selectAllModelOptions, selectAllModels, selectAllModelsReady, selectDeprecatedModels, selectDeprecatedModelsReady, selectModelById, selectModelClassConfig, selectModelClassName, selectModelControls, selectModelDetailError, selectModelFetchType, selectModelFullyLoaded, selectModelIdentityById, selectModelIdentityLookupStatus, selectModelLabelById, selectModelLabelWithClass, selectModelNameById, selectModelOptions, selectVariant, serviceCountLabel, setModelDiagnosticsSink, shapeCuratedModels, shardFileName, shardName, speedRatingLabel, speedRatingWord, splitSetProblems, takesInput, toAuditRecord, toDeviceModelFile, validateModelSet, variantVerdict, withModelClass };
2044
+ export type { AdminOffering, AdminPricingBand, ArtifactUse, AuditCapabilitiesRecord, AvailabilityVariant, CapabilitiesParseContext, CatalogKeyColumn, CatalogKindInput, CatalogModel, CatalogTier, CheapestAdequateOptions, CompatStatus, ContentType, CuratedCatalogClient, CuratedModel, CuratedPresentation, CuratedRows, CuratedVariant, DecidedBy, DeviceAvailability, DeviceGraphics, DeviceHardware, DeviceModelFile, DeviceModelResolution, DeviceServedSettings, DiscoveryAmbiguity, DiscoveryArtifact, DiscoveryMedia, DiscoveryResult, DiscoveryRuntime, DiscoverySource, DiscoveryVariant, FeatureBucket, FeatureBucketMeta, FeatureKey, FitCapabilities, GgufHeader, GgufRead, GgufTensor, GroupedFeatures, HardwareClass, HardwareClasses, HeaderFlag, HeaderJudgement, HeaderRefusal, Interaction, InteractionMode, LocalArtifact, LocalCatalogClient, LocalCatalogQuery, LocalCompatRow, LocalModel, LocalModelCatalog, LocalPresentation, LocalRuntime, LocalRuntimeBuild, LocalVariant, Modality, ModelCapabilities, ModelCatalog, ModelCatalogChangePayload, ModelCatalogClient, ModelCatalogConfig, ModelCatalogDirectiveSubscribe, ModelCatalogErrorSink, ModelCatalogPgError, ModelCatalogPgResult, ModelCatalogQuery, ModelCatalogState, ModelCatalogVariant, ModelCatalogVariantState, ModelClassConfig, ModelClassEntry, ModelClassIndex, ModelDiagnosticEntry, ModelDiagnosticsSink, ModelFavorites, ModelFavoritesCache, ModelFavoritesClient, ModelFavoritesConfig, ModelFavoritesErrorSink, ModelFavoritesState, ModelFetchScope, ModelFileHandle, ModelFit, ModelIdentityRow, ModelJson, ModelLabelSource, ModelNeed, ModelOfferingRow, ModelOption, ModelOptionWithLifecycle, ModelRecord, ModelRecordFetchType, ModelRecords, ModelRecordsClient, ModelRecordsConfig, ModelRecordsState, ModelSelectionPurpose, ModelSetEnv, ModelSetFacts, ModelSetValidation, NewAgentModel, NoSelection, OrderedLike, PreferredModelChoice, PreferredModelChoicePorts, PriceTier, PricedCatalogModel, PublicModelClient, RankOptions, RankedVariant, ReadModelCatalogOptions, SelectDevice, Selection, ShardName, SuccessionClient, SuccessionIndex, SuccessionNode, VariantDiscovery, VariantVerdict, Want };