spencernorton commited on
Commit
71dce43
·
verified ·
1 Parent(s): e3afdcd

Release v1.6.0 (v9): genuine unassisted FunctionGemma-270M residual QLoRA adapter

Browse files
GEMMA_TERMS_NOTICE.txt CHANGED
@@ -1,6 +1,2 @@
1
- Gemma is provided under and subject to the Gemma Terms of Use found at https://ai.google.dev/gemma/terms
2
-
3
- NOTICE (Gemma Terms of Use Section 3.1):
4
- 1. This artifact contains or is derived from Google's FunctionGemma (google/functiongemma-270m-it), which is governed by the Gemma Terms of Use (https://ai.google.dev/gemma/terms) and the Gemma Prohibited Use Policy (https://ai.google.dev/gemma/prohibited_use_policy).
5
- 2. Any downstream recipient who uses, reproduces, modifies, or distributes this model or its derivatives must comply with the Gemma Terms of Use and include a copy of this Notice.
6
- 3. Modified files: LoRA adapter weights and/or quantized merged weights fine-tuned for the Arrmes self-hosted media stack routing contract (arrmes.tools.v2).
 
1
+ Gemma is provided under and subject to the Gemma Terms of Use found at https://ai.google.dev/gemma/terms.
2
+ Redistributions of FunctionGemma adapters must retain this notice and comply with the Gemma Prohibited Use Policy (https://ai.google.dev/gemma/prohibited_use_policy).
 
 
 
 
README.md CHANGED
@@ -1,82 +1,24 @@
1
  ---
2
  license: gemma
3
  base_model: google/functiongemma-270m-it
4
- base_model_relation: adapter
5
- library_name: mlx
6
- pipeline_tag: text-generation
7
- language:
8
- - en
9
  tags:
10
- - function-calling
11
- - tool-use
12
  - mlx
 
13
  - functiongemma
14
- - self-hosted
15
- - agent-safety
16
  - arrmes
17
- - norvitech
18
- - lora
19
- - media-automation
20
  ---
21
 
22
- # Arrmes-FunctionGemma-270M (Published MLX LoRA Baseline & v7 Adapter)
23
-
24
- **Arrmes-FunctionGemma-270M** is a 270M-parameter function-calling LoRA adapter fine-tuned from `google/functiongemma-270m-it` for the 20-action `arrmes.tools.v2` self-hosted media-operations contract (`<start_function_call>call:name{...}<end_function_call>`).
25
-
26
- - **Preserved Root Baseline (`adapters.safetensors`):** The unchanged root adapter from initial publication (`96e89a722f4789f5eaceee06fe0327dfb9371ba0`) contains **252 float32 LoRA tensors** (`7,620,457` bytes / ~`7.3 MiB`, SHA-256 `b2af9abc9027ffbc7ff5bc228de788bf37583804e10796d34fb259bb2f4c7036`) for the separately downloaded `google/functiongemma-270m-it` bf16 base (`536,222,768` bytes / ~`511.4 MiB`).
27
- - **Subdirectory `v7-lora/` (`v1.4.0`):** Contains the `v7` LoRA adapter trained on `TrainPool-v7` (`5,827` examples, `seed=20261102`, `200` iterations, `lr=1e-4`) and its provenance manifest (`v7-lora/provenance.json`).
28
- - **Gemma Terms of Use Notice:** Distribution and use of these weights are subject to the [Gemma Terms of Use](https://ai.google.dev/gemma/terms) and include [`GEMMA_TERMS_NOTICE.txt`](GEMMA_TERMS_NOTICE.txt) per Section 3.1.
29
-
30
- [Arrmes source and setup](https://github.com/spencernorton/arrmes) · [NorviTech model overview](https://norvitech.com/ai-models/#arrmes).
31
-
32
- ![Raw and verified accuracy for five Arrmes generative checkpoints on the same 200-case acceptance-v5 slice](figures/arrmes-model-accuracy-comparison.png)
33
-
34
- Five generative checkpoints on the same 100 positive and 100 negative cases; raw model output and verified proposals are shown separately. This slice is separate from the full-suite neural-router results. [Recorded scores](https://github.com/spencernorton/arrmes/blob/bcac7c2fb83b4e6c263ac804245433b249e4d48f/experiments/acceptance-v5/summary.json).
35
-
36
- ## Evaluation Results (Paired Base vs Fine-Tuned & Locked `acceptance-v5`)
37
-
38
- Raw model output (`raw_unverified`, Track A), verifier-processed proposals (`raw` / `verify_proposal`, Track B), and controlled fixture execution (Track C) are measured and reported separately:
39
-
40
- - **Predeclared 80-Case Paired Diagnostic (Identical BF16 Base Without vs With Root `v5` Adapter, [`docs/functiongemma-public-diagnostic.md`](https://github.com/spencernorton/arrmes/blob/v1.4.0/docs/functiongemma-public-diagnostic.md)):**
41
- - **Untuned `google/functiongemma-270m-it` BF16 Base:** **`12 / 80` (`15.0%`) raw exact**, **`23 / 80` (`28.8%`) after verification**, and **`11 / 35` strict fixture workflows**.
42
- - **Root Public `v5` Adapter (`96e89a7...`):** **`63 / 80` (`78.8%`) raw exact** (`+51` calls), **`68 / 80` (`85.0%`) after verification** (`+45` calls), and **`29 / 35` strict fixture workflows** (`0` unexpected write proposals). One normalized template in the 80-case diagnostic overlaps training (`ON1-023`), so it is recorded as a known-input diagnostic rather than a template-disjoint acceptance suite.
43
- - **Locked `acceptance-v5` Stratified 200-Case Generative Comparison (`seed=7007`, [`NorviTech/arrmes-bench-v5`](https://github.com/spencernorton/arrmes)):**
44
- - Evaluated on a stratified 200-case slice (`100` positive + `100` hard-negative/safety) with **0 exact query overlaps** and **0 entity overlaps** against `TrainPool-v7` (`5,827` rows) and `acceptance-v4` (`1,000` rows):
45
- - **Public `FunctionGemma-270M v5` (`bf16 + root LoRA`)**: Positive Track A **`68 / 100` (`68.0%`)**, Track B **`78 / 100` (`78.0%`)**; Hard-Negative Track A `30 / 100`, Track B **`87 / 100` (`87.0%`)**, **`0` unauthorized writes**.
46
- - **Trained `FunctionGemma-270M v7` (`4-bit MLX` fused from `v7-lora/`, `175.83 MiB`)**: Positive Track A **`70 / 100` (`70.0%`)**, Track B **`91 / 100` (`91.0%`, `+13.0 pp` over `v5`)**; Hard-Negative Track A `35 / 100`, Track B **`88 / 100` (`88.0%`, `+1.0 pp` over `v5`)**, **`0` unauthorized writes**.
47
- - **Historical `sealed-acceptance-v3` (`N = 314`) Audit Note:**
48
- - The 4,389-row historical training file shares 37 normalized templates with 261/314 `sealed-v3` rows (`226` non-write opportunities). Use [`NorviTech/arrmes-bench-v5`](https://github.com/spencernorton/arrmes) for zero-leakage evaluation, and [`NorviTech/arrmes-neural-router-v3`](https://huggingface.co/NorviTech/arrmes-neural-router-v3) (`7.52 MiB`) when `>=99%` raw Track A accuracy and `arrmes.tools.v3` coverage are required.
49
-
50
- ![Warm routing latency and model size for the neural router, FunctionGemma and Qwen3 on Apple M4 Pro](figures/arrmes-local-runtime-comparison.png)
51
-
52
- Warm routing plus verification on Apple M4 Pro, excluding service and network time. Disk size is separate from runtime memory; sample counts and axis scales are labeled. [Recorded profiles](https://github.com/spencernorton/arrmes/blob/bcac7c2fb83b4e6c263ac804245433b249e4d48f/experiments/runtime-profile-v7.json).
53
-
54
- ## Measured Runtime Profile (Apple M4 Pro, `v1.4.0`)
55
-
56
- - **`FunctionGemma-270M v7` (`4-bit MLX`, `184,369,899` bytes / `175.83 MiB` weight files on disk):**
57
- - Cold load + static prompt KV cache warmup: **`869.67 ms`**
58
- - Warm model generation (`548.3 tok/s`): **`p50 = 43.30 ms / p95 = 46.84 ms`**
59
- - Warm routing + `verify_proposal`: **`p50 = 43.54 ms / p95 = 47.07 ms`**
60
- - Unified memory on Apple M4 Pro: MLX Metal peak **`1,060.96 MiB`** (active **`180.02 MiB`**), process RSS **`797.53 MiB`** (shared unified memory; do not sum).
61
-
62
- ## Quickstart (MLX)
63
-
64
- ```python
65
- from arrmes.model import LocalModel
66
 
67
- model = LocalModel(
68
- "models/functiongemma",
69
- family="functiongemma",
70
- adapter="adapters/arrmes-functiongemma-270m", # root v5 baseline or v7-lora/
71
- contract_version="v2",
72
- )
73
 
74
- res = model.infer("Is anyone streaming from Plex at this moment?")
75
- print(res["raw_unverified"]) # Track A direct model output
76
- print(res["raw"]) # Track B verified proposal
77
- # <start_function_call>call:now_playing{}<end_function_call>
78
- ```
79
 
80
- ## Licence & Notice
81
 
82
- Gemma is provided under and subject to the [Gemma Terms of Use](https://ai.google.dev/gemma/terms). See [`GEMMA_TERMS_NOTICE.txt`](GEMMA_TERMS_NOTICE.txt). Part of the [NorviTech Suite](https://norvitech.com) and [Arrmes `v1.4.0`](https://github.com/spencernorton/arrmes/releases/tag/v1.4.0).
 
 
 
 
 
1
  ---
2
  license: gemma
3
  base_model: google/functiongemma-270m-it
 
 
 
 
 
4
  tags:
 
 
5
  - mlx
6
+ - lora
7
  - functiongemma
8
+ - tool-calling
 
9
  - arrmes
 
 
 
10
  ---
11
 
12
+ # Arrmes FunctionGemma-270M v9 Residual FP16 QLoRA Adapter (`v1.6.0`)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
13
 
14
+ Unassisted residual FP16 LoRA adapter over the 4-bit `FunctionGemma-270M` base (`183.1 MiB` total footprint), subject to the [Gemma Terms of Use](https://ai.google.dev/gemma/terms) (`GEMMA_TERMS_NOTICE.txt`).
 
 
 
 
 
15
 
16
+ ![Arrmes v1.6.0 Accuracy Comparison](figures/arrmes-model-accuracy-comparison.png)
 
 
 
 
17
 
18
+ ## Artifact & Unassisted Benchmark Summary (`LocalModel`, `backend="mlx-lm"`)
19
 
20
+ - **`v9/adapters.safetensors` SHA-256**: `a0337f083c362d66f406129d0ee6f4661597055bd51772233241c0e2690cf124`
21
+ - **Template-Disjoint `acceptance-v7` `v2` Positives (`N=150`)**: Track A Raw `126/150` (`84.0%`), Track B Verified `135/150` (`90.0%`, Wilson 95% LB `84.16%`)
22
+ - **Template-Disjoint `acceptance-v7` Hard Negatives (`N=150`)**: Track A Raw `49/150` (`32.67%`), Track B Verified `133/150` (`88.67%`, Wilson 95% LB `82.60%`)
23
+ - **Frozen `overnight-v1` (`N=80`)**: Track A Raw `59/80` (`73.75%`), Track B Verified `69/80` (`86.25%`)
24
+ - **Apple M4 Pro Metal Warm Latency**: `p50 = 110.08 ms`, `p95 = 124.80 ms` (`183.1 MiB` combined 4-bit base + FP16 LoRA footprint).
figures/arrmes-model-accuracy-comparison.png CHANGED

Git LFS Details

  • SHA256: 1d403c344c6ef0d50217272f162f0774e9f3c50aaa0d7b990bf7f96b0fc2ff9f
  • Pointer size: 131 Bytes
  • Size of remote file: 226 kB

Git LFS Details

  • SHA256: e099b706969dddcefc9e65d224d86dfc6c69a60e66bf5ddbd29f7b60e83dc21e
  • Pointer size: 131 Bytes
  • Size of remote file: 643 kB
v9/adapter_config.json ADDED
@@ -0,0 +1,40 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "adapter_path": "adapters/functiongemma-arrmes-v9",
3
+ "batch_size": 2,
4
+ "config": "configs/functiongemma-arrmes-v9.yaml",
5
+ "data": "data/train-v9/mlx_functiongemma",
6
+ "fine_tune_type": "lora",
7
+ "grad_accumulation_steps": 1,
8
+ "grad_checkpoint": true,
9
+ "iters": 60,
10
+ "learning_rate": 8e-06,
11
+ "lora_parameters": {
12
+ "rank": 8,
13
+ "scale": 8.0,
14
+ "dropout": 0.0
15
+ },
16
+ "lr_schedule": null,
17
+ "mask_prompt": true,
18
+ "max_seq_length": 2752,
19
+ "model": "models/functiongemma-270m-arrmes-v9-4bit",
20
+ "num_layers": -1,
21
+ "optimizer": "adam",
22
+ "optimizer_config": {
23
+ "adam": {},
24
+ "adamw": {},
25
+ "muon": {},
26
+ "sgd": {},
27
+ "adafactor": {}
28
+ },
29
+ "project_name": null,
30
+ "report_to": null,
31
+ "resume_adapter_file": null,
32
+ "save_every": 20,
33
+ "seed": 20261107,
34
+ "steps_per_eval": 20,
35
+ "steps_per_report": 20,
36
+ "test": false,
37
+ "test_batches": 500,
38
+ "train": true,
39
+ "val_batches": 4
40
+ }
v9/adapters.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:a0337f083c362d66f406129d0ee6f4661597055bd51772233241c0e2690cf124
3
+ size 7620457