Capability first · transport second

OllamaModelIdentifier.js

Recognizes Ollama model identifier syntax and compares ordinary resident-model aliases without changing requests.

SDK 0.97.1Runtime 0.8.12Protocol arcane/1
On this page

Overview

Recognizes Ollama model identifier syntax and compares ordinary resident-model aliases without changing requests.

  • Artifact
    OllamaModelIdentifier.js · esm
  • Classification
    public first party
  • Availability
    Cross-host
  • Normalization
    Exact identifier/null or boolean results; alias comparison applies Ollama's default registry, namespace and tag without changing either input.

Import and lifecycle

JavaScript
import * as module from '/node_modules/arcane-os/runtime/arcane/modules/OllamaModelIdentifier.js';

Pure syntax recognition and name comparison; performs no I/O or model loading and does not change outbound requests.

Application-facing behavior: normalizeOllamaModelIdentifier(), isOllamaModelIdentifier(), sameOllamaModelIdentifier(left, right).

Protocol and host implementation

In-process only This detail does not widen the application-facing API or grant authority.

Exports, signatures, parameters, and results

BindingFormDeclaration or signatureParameter syntax
normalizeOllamaModelIdentifierfunctionfunction normalizeOllamaModelIdentifier(value)value
isOllamaModelIdentifierfunctionfunction isOllamaModelIdentifier(value)value
sameOllamaModelIdentifierfunctionfunction sameOllamaModelIdentifier(left,right)left,right
CallableKindExact public signatureParameter syntax
normalizeOllamaModelIdentifierexported-functionfunction normalizeOllamaModelIdentifier(value)value
isOllamaModelIdentifierexported-functionfunction isOllamaModelIdentifier(value)value
sameOllamaModelIdentifierexported-functionfunction sameOllamaModelIdentifier(left,right)left,right

Parameter meanings and results

normalizeOllamaModelIdentifier(value) returns the exact accepted identifier or null, including null for surrounding whitespace; isOllamaModelIdentifier(value) returns boolean. sameOllamaModelIdentifier(left,right) compares strings case-insensitively with the default registry.ollama.ai host, library namespace and latest tag. Explicit different hosts, namespaces and tags remain distinct; non-string inputs return false. Comparison does not rewrite either input or establish model residency.

Events, side effects, and errors

Source-literal CustomEvent dispatches

No source-literal CustomEvent dispatch is part of this artifact.

Lifecycle and event flow

This artifact has no additional documented lifecycle event flow.

Direct coded failures

This artifact directly assigns no stable coded failure.

Exported Error subclasses

This artifact exports no Error subclass.

Documented failure behavior

No additional module-specific rejection behavior is documented.

Availability and capabilities

Cross-host. Exact identifier/null or boolean results; alias comparison applies Ollama's default registry, namespace and tag without changing either input.

None.

Contract example

JavaScript
import {sameOllamaModelIdentifier} from '/node_modules/arcane-os/runtime/arcane/modules/OllamaModelIdentifier.js';

console.log(sameOllamaModelIdentifier('moon-cheese', 'registry.ollama.ai/library/moon-cheese:latest'));

No direct Core call is claimed for this artifact. Any injected provider or consuming module retains its own documented authority.