Core ML models for Privacy AI

Core ML conversions used by Privacy AI, mirrored here so the app downloads from one place.

laya/ โ€” Laya multilingual typed-decision model

A non-autoregressive decision model: it answers typed questions about a piece of text and returns probabilities in a single forward pass. It never generates text.

Primitive Question Answer
choice "which of these labels?" softmax over the option set
noul "is this statement true?" P(true)
score "how much, on this ordinal scale?" the expected level

Two sequence-length buckets of the same checkpoint, both e8 (int8 embedding table, float16 encoder and head):

File Sequence length Reads about Installed
laya/laya_multilingual_e8_L512_options32.mlmodelc 512 380 tokens of state 484 MB
laya/laya_multilingual_e8_L1024_options32.mlmodelc 1024 765 tokens of state 487 MB

Both share laya/tokenizer.json (Gemma 256k BPE). They cost nearly the same on disk because the 256k embedding table dominates, so the choice between them is about context length and latency, not size.

Interface

inputs:  input_ids     int32   [1, L]      attention_mask int32 [1, L]
         marker_map    float32 [1, 32, L]  question_type  float32 [1, 3]
outputs: logits [1, 32]   probabilities [1, 32]   action_probabilities [1, 2]

question_type is a one-hot over choice=0, score=1, noul=2. marker_map row i is a one-hot at the position of option i's [MASK] token. Up to 32 options per question.

Sequence format:

[CLS] <type> question: <instructions> [SEP] ([MASK] <option>)* [SEP] <state> [SEP]

with head_max_len = 256 and each option's body clipped to 48 tokens.

Notes

  • logits are raw and uncalibrated โ€” the checkpoint ships no fitted temperature. Apply your own temperature before the softmax if you need calibrated confidence.
  • action_probabilities is already softmaxed inside the graph.
  • Run with cpuAndNeuralEngine if you need predictions to survive app backgrounding; the GPU partition cannot submit work in the background. .all is roughly 3x faster at L512 when the app is in the foreground.

Provenance

Converted from convaiinnovations/laya (multilingual, revision 1c5edc17a7acd8701df6fc341c0d179f1c62c982), encoder jhu-clsp/mmBERT-base. Conversion originally published as FluidInference/laya-coreml.

Apache 2.0, as upstream.

Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support