Text Generation
MLX
Safetensors
English
information-extraction
structured-output
json
small-language-model
apple-silicon
from-scratch
post-training
research
Instructions to use OpenSML/OpenSML-JSONLite-175M with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use OpenSML/OpenSML-JSONLite-175M with MLX:
# Make sure mlx-lm is installed # pip install --upgrade mlx-lm # if on a CUDA device, also pip install mlx[cuda] # Generate text with mlx-lm from mlx_lm import load, generate model, tokenizer = load("OpenSML/OpenSML-JSONLite-175M") prompt = "Once upon a time in" text = generate(model, tokenizer, prompt=prompt, verbose=True) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- MLX LM
How to use OpenSML/OpenSML-JSONLite-175M with MLX LM:
Generate or start a chat session
# Install MLX LM uv tool install mlx-lm # Generate some text mlx_lm.generate --model "OpenSML/OpenSML-JSONLite-175M" --prompt "Once upon a time"
- Atomic Chat
Clarify intended use and verified JSON limitations
Browse filesAdd a plain-language scope section before usage examples and detailed limitations beside evaluation results. Synchronize the run guide, source archive and checksums. Model weights, tokenizer and native inference algorithm are unchanged.
- PACKAGING_VERIFICATION.json +7 -2
- README.md +10 -0
- RUN_GUIDE.md +10 -0
- SHA256SUMS +6 -6
- TECHNICAL_REPORT.md +34 -1
- inference.py +1 -1
- native_bundle.zip +2 -2
PACKAGING_VERIFICATION.json
CHANGED
|
@@ -5,7 +5,7 @@
|
|
| 5 |
"weight_file": "model.safetensors",
|
| 6 |
"weight_bytes": 351242342,
|
| 7 |
"weight_sha256": "781597baeb9b51d535fc27cd6f941dbc202e01d62c8d963587a3f3d565128560",
|
| 8 |
-
"native_bundle_sha256": "
|
| 9 |
"runtime": "stock MLX 0.32.3; Apple Silicon; Python 3.11",
|
| 10 |
"requests": 60,
|
| 11 |
"raw_runtime_matches": 60,
|
|
@@ -14,5 +14,10 @@
|
|
| 14 |
"root_runner_verification": "source archive hash and snapshot verified; live CLI receipt saved separately",
|
| 15 |
"json_assembly": false,
|
| 16 |
"output_repair": false,
|
| 17 |
-
"tokenizer_root_matches_bundle": true
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 18 |
}
|
|
|
|
| 5 |
"weight_file": "model.safetensors",
|
| 6 |
"weight_bytes": 351242342,
|
| 7 |
"weight_sha256": "781597baeb9b51d535fc27cd6f941dbc202e01d62c8d963587a3f3d565128560",
|
| 8 |
+
"native_bundle_sha256": "c5bb8eaa1dd4e3bbfb094192c3b91203f20aba776eb73dc29fc47831fa043087",
|
| 9 |
"runtime": "stock MLX 0.32.3; Apple Silicon; Python 3.11",
|
| 10 |
"requests": 60,
|
| 11 |
"raw_runtime_matches": 60,
|
|
|
|
| 14 |
"root_runner_verification": "source archive hash and snapshot verified; live CLI receipt saved separately",
|
| 15 |
"json_assembly": false,
|
| 16 |
"output_repair": false,
|
| 17 |
+
"tokenizer_root_matches_bundle": true,
|
| 18 |
+
"documentation_update": {
|
| 19 |
+
"date": "2026-10-20",
|
| 20 |
+
"scope": "Intended use and limitations; updated documentation archive",
|
| 21 |
+
"model_tokenizer_and_native_inference_algorithm_unchanged": true
|
| 22 |
+
}
|
| 23 |
}
|
README.md
CHANGED
|
@@ -33,6 +33,16 @@ datasets:
|
|
| 33 |
|
| 34 |
The model was fine-tuned for grounded question answering, exact and focused field extraction, and direct JSON generation. Its final joint JSON extraction stage combines original training replay, multiple-value examples and authored prose. Weights are provided as `model.safetensors`. The pretrained ancestor is [OpenSML-Base-175M](https://huggingface.co/OpenSML/OpenSML-Base-175M).
|
| 35 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 36 |
## Run locally
|
| 37 |
|
| 38 |
```bash
|
|
|
|
| 33 |
|
| 34 |
The model was fine-tuned for grounded question answering, exact and focused field extraction, and direct JSON generation. Its final joint JSON extraction stage combines original training replay, multiple-value examples and authored prose. Weights are provided as `model.safetensors`. The pretrained ancestor is [OpenSML-Base-175M](https://huggingface.co/OpenSML/OpenSML-Base-175M).
|
| 35 |
|
| 36 |
+
## Intended use and limitations
|
| 37 |
+
|
| 38 |
+
This is a research model for **extracting information that is explicitly stated in short English text** and placing it into one flat JSON object. Supply a schema with clear field descriptions. The verified runner accepts 1β8 required fields containing strings, nullable strings or arrays of strings. Dates and numbers are copied as text rather than normalized or converted.
|
| 39 |
+
|
| 40 |
+
**Expect extraction mistakes.** The model can shorten a name or title, miss or merge list items, confuse who or what a value belongs to, or supply a value when the right answer is empty. Unfamiliar field names and domains need their own testing. There is no established number of entities it will always extract correctly; only 3 of the 6 observed three/four/five-item probes were completely correct.
|
| 41 |
+
|
| 42 |
+
**Outside the verified scope:** nested objects, arrays of objects, numeric or Boolean outputs, optional-property logic, enums, references and advanced schema constraints. General chat, multilingual input and long-document extraction are also unverified. This describes the released runner's tested contract, not a claim that the weights can never produce these formats.
|
| 43 |
+
|
| 44 |
+
**Check both structure and meaning.** Parse the output, validate it against the schema, and check the values against the source. The reported 100% schema validity applies to the observed 1,444-request evaluation; complete correctness there was 88.02%. It is not a promise for new inputs. The instruction, source, schema and generated answer must share the 2,048-token context; the supplied runner allows up to 256 output tokens.
|
| 45 |
+
|
| 46 |
## Run locally
|
| 47 |
|
| 48 |
```bash
|
RUN_GUIDE.md
CHANGED
|
@@ -6,6 +6,16 @@ The runnable package includes model.safetensors, tokenizer/config, native MLX
|
|
| 6 |
model source, a source archive, 60 examples, results and verification records.
|
| 7 |
Verified platform: Apple Silicon macOS, Python 3.11, stock MLX 0.32.3.
|
| 8 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9 |
```bash
|
| 10 |
python3 -m venv .venv
|
| 11 |
source .venv/bin/activate
|
|
|
|
| 6 |
model source, a source archive, 60 examples, results and verification records.
|
| 7 |
Verified platform: Apple Silicon macOS, Python 3.11, stock MLX 0.32.3.
|
| 8 |
|
| 9 |
+
## Intended use and limitations
|
| 10 |
+
|
| 11 |
+
This is a research model for **extracting information that is explicitly stated in short English text** and placing it into one flat JSON object. Supply a schema with clear field descriptions. The verified runner accepts 1β8 required fields containing strings, nullable strings or arrays of strings. Dates and numbers are copied as text rather than normalized or converted.
|
| 12 |
+
|
| 13 |
+
**Expect extraction mistakes.** The model can shorten a name or title, miss or merge list items, confuse who or what a value belongs to, or supply a value when the right answer is empty. Unfamiliar field names and domains need their own testing. There is no established number of entities it will always extract correctly; only 3 of the 6 observed three/four/five-item probes were completely correct.
|
| 14 |
+
|
| 15 |
+
**Outside the verified scope:** nested objects, arrays of objects, numeric or Boolean outputs, optional-property logic, enums, references and advanced schema constraints. General chat, multilingual input and long-document extraction are also unverified. This describes the released runner's tested contract, not a claim that the weights can never produce these formats.
|
| 16 |
+
|
| 17 |
+
**Check both structure and meaning.** Parse the output, validate it against the schema, and check the values against the source. The reported 100% schema validity applies to the observed 1,444-request evaluation; complete correctness there was 88.02%. It is not a promise for new inputs. The instruction, source, schema and generated answer must share the 2,048-token context; the supplied runner allows up to 256 output tokens.
|
| 18 |
+
|
| 19 |
```bash
|
| 20 |
python3 -m venv .venv
|
| 21 |
source .venv/bin/activate
|
SHA256SUMS
CHANGED
|
@@ -3,19 +3,19 @@
|
|
| 3 |
9a4fb5f559d82ed0120a57139eb1e1c616bfdb18c39cca7b1e9bcab24ef968bc INFERENCE_VERIFICATION.json
|
| 4 |
74a074f90bd5e7a26d5f6cd5757ddc1fbfcc72e259e0b23a210fa48d91b35fdb JSONLITE_RESULTS.json
|
| 5 |
c71d239df91726fc519c6eb72d318ec65820627232b2f796219e87dcf35d0ab4 LICENSE
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
c6191baf937bce61f1b747acfbcb975a17eef6e8a598682a751a1031d1cfee23 SOURCE_NOTICE.md
|
| 10 |
-
|
| 11 |
e4e44da050abbd930748ec91731ddf1be16be83a4aa59bd8c4fc63478b384a03 THIRD_PARTY_NOTICES.md
|
| 12 |
663087d32872824f7f2fec425ad4054f308913c43da7c3f83521c7011967fdbe checkpoint_metadata.json
|
| 13 |
a365a7697b463bacc6e44e26d11a1e62d43d96b5d52c70c2e9df8d4513f86537 checkpoint_provenance.json
|
| 14 |
ecec6f191822d16a3da0b571fa129f5016e1243ca7d567de476a9d0e8ad66646 complete-request-exact.svg
|
| 15 |
981e02e7777980705770cacf19f16d76ea74e85e7edb018f875ddb4766afe19d config.json
|
| 16 |
-
|
| 17 |
781597baeb9b51d535fc27cd6f941dbc202e01d62c8d963587a3f3d565128560 model.safetensors
|
| 18 |
-
|
| 19 |
641fe860d6fd24547fe4d15bd852190f00ddec31bd74eb7ca9eeae74031c2f0c pretraining-training-loss.png
|
| 20 |
c7b1a3c0efb09ef3b5416a24072e48b25e2cc1f122fb5ed638c0f95b72594af9 requirements.txt
|
| 21 |
e095f0413a11fa91fbb58f37d00e4c6bcda59beb89b28f6f680db1436a7e8891 tokenizer.json
|
|
|
|
| 3 |
9a4fb5f559d82ed0120a57139eb1e1c616bfdb18c39cca7b1e9bcab24ef968bc INFERENCE_VERIFICATION.json
|
| 4 |
74a074f90bd5e7a26d5f6cd5757ddc1fbfcc72e259e0b23a210fa48d91b35fdb JSONLITE_RESULTS.json
|
| 5 |
c71d239df91726fc519c6eb72d318ec65820627232b2f796219e87dcf35d0ab4 LICENSE
|
| 6 |
+
7e092bbf3d2e770493e1e31cee471e04f59f2b26355d4ded86565e3e39bc8ade PACKAGING_VERIFICATION.json
|
| 7 |
+
5e828c09db086de986dad8eafebebeb6ce21185934a6e8e6236cab049741ff2d README.md
|
| 8 |
+
e54ba0ed507dd5da8a6fe54cd420f91f0db1bed31e75fc8ff5934fe883f638bc RUN_GUIDE.md
|
| 9 |
c6191baf937bce61f1b747acfbcb975a17eef6e8a598682a751a1031d1cfee23 SOURCE_NOTICE.md
|
| 10 |
+
7bb05614604bf206027f8897409959dae8fbd67e417addc63da55d8f3eac3fb8 TECHNICAL_REPORT.md
|
| 11 |
e4e44da050abbd930748ec91731ddf1be16be83a4aa59bd8c4fc63478b384a03 THIRD_PARTY_NOTICES.md
|
| 12 |
663087d32872824f7f2fec425ad4054f308913c43da7c3f83521c7011967fdbe checkpoint_metadata.json
|
| 13 |
a365a7697b463bacc6e44e26d11a1e62d43d96b5d52c70c2e9df8d4513f86537 checkpoint_provenance.json
|
| 14 |
ecec6f191822d16a3da0b571fa129f5016e1243ca7d567de476a9d0e8ad66646 complete-request-exact.svg
|
| 15 |
981e02e7777980705770cacf19f16d76ea74e85e7edb018f875ddb4766afe19d config.json
|
| 16 |
+
6c8e504441f93b0d1ed428bc0cd7973788b7be8b7b7983d47ad20ce8b7a1ddeb inference.py
|
| 17 |
781597baeb9b51d535fc27cd6f941dbc202e01d62c8d963587a3f3d565128560 model.safetensors
|
| 18 |
+
c5bb8eaa1dd4e3bbfb094192c3b91203f20aba776eb73dc29fc47831fa043087 native_bundle.zip
|
| 19 |
641fe860d6fd24547fe4d15bd852190f00ddec31bd74eb7ca9eeae74031c2f0c pretraining-training-loss.png
|
| 20 |
c7b1a3c0efb09ef3b5416a24072e48b25e2cc1f122fb5ed638c0f95b72594af9 requirements.txt
|
| 21 |
e095f0413a11fa91fbb58f37d00e4c6bcda59beb89b28f6f680db1436a7e8891 tokenizer.json
|
TECHNICAL_REPORT.md
CHANGED
|
@@ -12,6 +12,16 @@ This is a custom native MLX architecture, not a Transformers/MLX-LM auto-loader
|
|
| 12 |
|
| 13 |
This report supersedes the earlier fieldwise SFT-093 release. Its historical report is retained as `HISTORICAL_SFT093_REPORT.md`; those adapter-assisted scores are not current native JSON scores. No release-readiness or arbitrary-schema reliability claim is made.
|
| 14 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 15 |
## 2. Exact inherited lineage
|
| 16 |
|
| 17 |
`Stage A β grounded QA β requested-field extraction β focused extraction β native JSON foundation β cardinality/replay extraction β joint JSON extraction SFT`
|
|
@@ -203,7 +213,7 @@ The run uses full-weight BF16 compute with FP32-master AdamW, batch 64, microbat
|
|
| 203 |
|
| 204 |
## 8. Prompt, schema and native inference
|
| 205 |
|
| 206 |
-
Supply source text and a flat closed JSON Schema with 1β8 required fields. Supported properties are strings, nullable strings and arrays of strings.
|
| 207 |
|
| 208 |
The fixed instruction is followed by compact `{"source_text":...,"schema":...}` and native SFT role tokens. It issues exactly one autoregressive whole-object generation with temperature 0, repetition penalty 1 and at most 256 output tokens. No fieldwise assembly, repair, schema-constrained decoder, normalization, reference answer, frozen teacher or secondary model is used at inference. Parsing/schema checks only annotate the raw generated text afterward.
|
| 209 |
|
|
@@ -255,6 +265,29 @@ The 1,444 requests comprise the original canonical and schema-stress views; some
|
|
| 255 |
|
| 256 |
## 10. Failure audit and limitations
|
| 257 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 258 |
There are 173 entirely incorrect original-test requests and 24 previously correct requests become incorrect. Errors include incomplete copying, wrong roles, missing or extra values and unsupported values. All seven domain totals improve, but per-request retention is not perfect. On the six longer-list probes only three are correct. Flat schema validity is 100% on this test, not a guarantee for arbitrary prompts, schema types or novel domains. No general chat, reasoning, code, multilingual, long-document or safety readiness claim is made. The authored development panel is small and repeatedly observed.
|
| 259 |
|
| 260 |
## 11. Packaging, verification and reproduction
|
|
|
|
| 12 |
|
| 13 |
This report supersedes the earlier fieldwise SFT-093 release. Its historical report is retained as `HISTORICAL_SFT093_REPORT.md`; those adapter-assisted scores are not current native JSON scores. No release-readiness or arbitrary-schema reliability claim is made.
|
| 14 |
|
| 15 |
+
### Intended use in plain language
|
| 16 |
+
|
| 17 |
+
This is a research model for **extracting information that is explicitly stated in short English text** and placing it into one flat JSON object. Supply a schema with clear field descriptions. The verified runner accepts 1β8 required fields containing strings, nullable strings or arrays of strings. Dates and numbers are copied as text rather than normalized or converted.
|
| 18 |
+
|
| 19 |
+
**Expect extraction mistakes.** The model can shorten a name or title, miss or merge list items, confuse who or what a value belongs to, or supply a value when the right answer is empty. Unfamiliar field names and domains need their own testing. There is no established number of entities it will always extract correctly; only 3 of the 6 observed three/four/five-item probes were completely correct.
|
| 20 |
+
|
| 21 |
+
**Outside the verified scope:** nested objects, arrays of objects, numeric or Boolean outputs, optional-property logic, enums, references and advanced schema constraints. General chat, multilingual input and long-document extraction are also unverified. This describes the released runner's tested contract, not a claim that the weights can never produce these formats.
|
| 22 |
+
|
| 23 |
+
**Check both structure and meaning.** Parse the output, validate it against the schema, and check the values against the source. The reported 100% schema validity applies to the observed 1,444-request evaluation; complete correctness there was 88.02%. It is not a promise for new inputs. The instruction, source, schema and generated answer must share the 2,048-token context; the supplied runner allows up to 256 output tokens.
|
| 24 |
+
|
| 25 |
## 2. Exact inherited lineage
|
| 26 |
|
| 27 |
`Stage A β grounded QA β requested-field extraction β focused extraction β native JSON foundation β cardinality/replay extraction β joint JSON extraction SFT`
|
|
|
|
| 213 |
|
| 214 |
## 8. Prompt, schema and native inference
|
| 215 |
|
| 216 |
+
Supply source text and a flat closed JSON Schema with 1β8 required fields. Supported properties are strings, nullable strings and arrays of strings. The requested behavior is to return every required key, with [] for absent arrays and null for absent nullable strings; generated answers can still be incorrect. Copy case/spelling and complete values; preserve source order. Nested schemas, numbers/booleans, enums and advanced constraints are outside the verified runner contract. The supplied runner rejects overlong inputs without truncation.
|
| 217 |
|
| 218 |
The fixed instruction is followed by compact `{"source_text":...,"schema":...}` and native SFT role tokens. It issues exactly one autoregressive whole-object generation with temperature 0, repetition penalty 1 and at most 256 output tokens. No fieldwise assembly, repair, schema-constrained decoder, normalization, reference answer, frozen teacher or secondary model is used at inference. Parsing/schema checks only annotate the raw generated text afterward.
|
| 219 |
|
|
|
|
| 265 |
|
| 266 |
## 10. Failure audit and limitations
|
| 267 |
|
| 268 |
+
### What the released model is intended to do
|
| 269 |
+
|
| 270 |
+
The intended task is short English text extraction into a supplied, flat object schema: copy stated values into the requested fields, keep separate entities as separate string-array items, and use empty arrays or nullable strings for absent information where the schema allows it. Clear field descriptions matter. The runner accepts 1β8 required fields with strings, nullable strings or arrays of strings; dates and numeric expressions remain strings. Those input limits describe the runner contract and do not guarantee that every accepted request will be answered correctly.
|
| 271 |
+
|
| 272 |
+
### What can still go wrong
|
| 273 |
+
|
| 274 |
+
The model can shorten names or titles, omit or merge list members, confuse roles or field meanings, and fill a missing field with an unsupported value. Corrections, unfamiliar field names, new domains and complex associations require application-specific evaluation. No tested field count or entity count establishes a reliable extraction maximum. Optional-property logic, nesting, arrays of records, numeric/Boolean outputs, enums, references and advanced constraints are outside the released runner's verified contract. Root-level arrays or primitives, general chat, multilingual use and long-document extraction are not supported claims of this release. Unverified does not mean impossible for the weights; it means the supplied runner and release evidence do not establish dependable support.
|
| 275 |
+
|
| 276 |
+
| Evidence for this released checkpoint | What it establishes | What it does not establish |
|
| 277 |
+
| --- | --- | --- |
|
| 278 |
+
| 1,271/1,444 complete requests correct (88.02%) | Exact whole-answer performance on the documented, previously observed SNIPS-derived panel | Equivalent accuracy on arbitrary schemas or new domains |
|
| 279 |
+
| 1,444/1,444 schema-valid outputs | All outputs met the tested flat schemas in that evaluation | Correct extracted values, or universal schema compliance |
|
| 280 |
+
| 49/60 complete playground requests correct (81.67%) | Performance on a separate observed diagnostic panel | A fresh blind benchmark or a general production reliability rate |
|
| 281 |
+
| 3/6 complete three/four/five-item probes correct | Larger lists remain inconsistent | A guaranteed maximum number of extractable entities |
|
| 282 |
+
|
| 283 |
+
These measurements use the released checkpoint identified in section 1. Local research checkpoints are separate artifacts; their broader-schema or per-family scores are not measurements of this release. The panels have prior research exposure and must not be pooled into one accuracy number.
|
| 284 |
+
|
| 285 |
+
### Checks required in an application
|
| 286 |
+
|
| 287 |
+
Parse the raw output, validate it against the supplied schema, then check that extracted values are supported by the source and assigned to the right fields. A valid string can still name the wrong person, omit an item or invent a value; schema validation cannot detect all such errors. The runner's `success` flag means structural validity and natural completion, not semantic correctness. The full instruction, source, schema and answer share a 2,048-token context, and the released runner allows up to 256 generated tokens. Overlong inputs are rejected rather than truncated. Validate the complete workflow on representative application data before relying on its outputs.
|
| 288 |
+
|
| 289 |
+
### Additional failure-audit observations
|
| 290 |
+
|
| 291 |
There are 173 entirely incorrect original-test requests and 24 previously correct requests become incorrect. Errors include incomplete copying, wrong roles, missing or extra values and unsupported values. All seven domain totals improve, but per-request retention is not perfect. On the six longer-list probes only three are correct. Flat schema validity is 100% on this test, not a guarantee for arbitrary prompts, schema types or novel domains. No general chat, reasoning, code, multilingual, long-document or safety readiness claim is made. The authored development panel is small and repeatedly observed.
|
| 292 |
|
| 293 |
## 11. Packaging, verification and reproduction
|
inference.py
CHANGED
|
@@ -12,7 +12,7 @@ import tempfile
|
|
| 12 |
import zipfile
|
| 13 |
|
| 14 |
ROOT = Path(__file__).resolve().parent
|
| 15 |
-
BUNDLE_SHA256 = "
|
| 16 |
|
| 17 |
def main():
|
| 18 |
archive = ROOT / "native_bundle.zip"
|
|
|
|
| 12 |
import zipfile
|
| 13 |
|
| 14 |
ROOT = Path(__file__).resolve().parent
|
| 15 |
+
BUNDLE_SHA256 = "c5bb8eaa1dd4e3bbfb094192c3b91203f20aba776eb73dc29fc47831fa043087"
|
| 16 |
|
| 17 |
def main():
|
| 18 |
archive = ROOT / "native_bundle.zip"
|
native_bundle.zip
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:c5bb8eaa1dd4e3bbfb094192c3b91203f20aba776eb73dc29fc47831fa043087
|
| 3 |
+
size 12835333
|