WobblyDopamine commited on
Commit
c0e4450
Β·
verified Β·
1 Parent(s): 96c5be9

Add model card

Browse files
Files changed (1) hide show
  1. README.md +128 -0
README.md ADDED
@@ -0,0 +1,128 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: other
3
+ license_name: lfm-1.0
4
+ license_link: https://huggingface.co/LiquidAI/LFM2.5-VL-450M/blob/main/LICENSE
5
+ base_model: LiquidAI/LFM2.5-VL-450M
6
+ library_name: transformers
7
+ pipeline_tag: image-text-to-text
8
+ language:
9
+ - en
10
+ tags:
11
+ - vision-language
12
+ - earth-observation
13
+ - remote-sensing
14
+ - sentinel-2
15
+ - vrsbench
16
+ - tailings-dam
17
+ - gistm
18
+ - compliance
19
+ - lora
20
+ - lfm2-vl
21
+ - liquid-ai
22
+ - satdiff
23
+ ---
24
+
25
+ # SatDiff-LFM2.5-VL-450M-stage1
26
+
27
+ A LoRA fine-tune of `LiquidAI/LFM2.5-VL-450M` trained to emit per-claim, contract-framed evidence on Sentinel-2 imagery of regulated dams and tailings storage facilities. Built for the **SatDiff** submission to the Liquid AI "AI in Space" hackathon (Liquid Track, 2026).
28
+
29
+ This is the *evidence-text writer* component of the SatDiff pipeline. It does not perform threshold-based severity classification on its own β€” that work is done deterministically by a Python rules engine downstream of the model. See **Stage 2 (negative result)** below for the methodological reasoning.
30
+
31
+ ## What it does
32
+
33
+ Given (a) Sentinel-2 imagery (RGB + NIR composites for baseline + current pass) and (b) a contract memo prompt that lists per-claim evidence-sourcing rules, this model produces a structured per-claim evidence string for a 5-claim audit schema covering:
34
+
35
+ 1. Impoundment morphology (deposition asymmetry, footprint change)
36
+ 2. Pond management (pond-to-wall distance, area change, turbidity, NDWI)
37
+ 3. Retaining-wall integrity (gully count + width, NDMI on the wall face, SWIR anomaly)
38
+ 4. Deformation (declares "no SAR data available" when SAR is absent)
39
+ 5. Protected-zone encroachment (towns, residential extensions)
40
+
41
+ ## Headline result (held-out evaluation)
42
+
43
+ The base `LFM2.5-VL-450M` parrots the same three indices into every claim's evidence regardless of which physical signal the claim is about. Stage 1 fine-tuning β€” without any SatDiff-specific examples β€” teaches the model to read the per-claim sourcing rules from the prompt and cite the right diff fields.
44
+
45
+ | metric (held-out backtest passes, 6 dates Γ— 5 claims = 30 claims) | base | Stage 1 |
46
+ |---|---:|---:|
47
+ | schema-valid passes | 6/6 | 6/6 |
48
+ | **evidence-correct claims** | **0/30 (0 %)** | **30/30 (100 %)** |
49
+
50
+ The lift comes from generic VRSBench grounding, not from domain-specific examples.
51
+
52
+ ## Training
53
+
54
+ - **Framework**: [`Liquid4All/leap-finetune`](https://github.com/Liquid4All/leap-finetune) (Ray Train + Accelerate, managed via `uv`). Not raw `transformers + peft`.
55
+ - **Base model**: `LiquidAI/LFM2.5-VL-450M`.
56
+ - **Dataset**: VRSBench (NeurIPS 2024) β€” 5 000 captioning + VQA samples (no `[refer]` grounding tasks).
57
+ - **Method**: LoRA SFT, rank as configured in the recipe, 2 epochs.
58
+ - **Hardware**: single RTX 4080 Laptop, 12 GB VRAM, WSL2 + CUDA 12.6.
59
+ - **Wall-clock**: 38 m 15 s.
60
+ - **Eval loss**: base ~3.21 β†’ Stage 1 **1.41** (βˆ’56 %).
61
+
62
+ ## Stage 2 (negative result, not shipped)
63
+
64
+ A second-stage fine-tune was attempted using 29 hand-authored examples (boundary, escalation, routine, catastrophic regimes) plus 17 auto-generated examples from the SatDiff Phase 2 backtest, split 35 train / 11 held-out before training. Stage 2 preserved Stage 1's 100 % evidence-correctness but **worsened** severity adherence on real held-out data (5 β†’ 9 corrections by the downstream rules engine).
65
+
66
+ Diagnosis: the hand-authored cases used contrived metric values around the threshold cliffs (e.g. pond-to-wall = 24 m vs 26 m); the held-out real-data passes lived in a different distribution (pond-to-wall β‰ˆ 9.9 m throughout the failure window). LoRA at this scale (35 examples Γ— 3 epochs β‰ˆ 31 effective steps) cannot reshape multi-tier threshold reasoning.
67
+
68
+ We ship Stage 1, not Stage 2. The Stage 2 checkpoint is intentionally not uploaded β€” it would confuse the model-card story.
69
+
70
+ This is the strongest possible validation of the SatDiff *rules-engine architecture*: severity, action, escalation, and overall-status are computed deterministically by `phase2.aggregate.compute_severity` from physical-diff numbers, *regardless* of what the model emits. Stage 2 attempting and failing to lift the model's threshold reasoning confirms that this work belongs in deterministic Python at our scale.
71
+
72
+ ## Files in this repo
73
+
74
+ - **fp16 transformers checkpoint** (`model.safetensors` + `config.json` + `tokenizer.json` + `chat_template.jinja` + …) β€” load via `transformers.AutoModelForImageTextToText`.
75
+ - **GGUF pair** (`gguf/LFM2.5-VL-450M-stage1-Q8_0.gguf` + `gguf/mmproj-LFM2.5-VL-450M-stage1-Q8_0.gguf`) β€” load via `llama.cpp` / `llama-server`. 362 MB Q8_0 backbone + 182 MB F16 mmproj = 544 MB total.
76
+
77
+ ## Reproducing the headline result
78
+
79
+ ```bash
80
+ # 1. Pull the SatDiff repo + Stage 1 GGUF, bring up the stack:
81
+ git clone <satdiff-repo>
82
+ cd satdiff
83
+ docker compose up -d
84
+
85
+ # 2. Run the Phase 2 backtest against the Stage 1 model:
86
+ python -m phase2.cli --asset jagersfontein \
87
+ --date-range 2021-06-15,2022-10-15 \
88
+ --inference llama_server \
89
+ --model WobblyDopamine/SatDiff-LFM2.5-VL-450M-stage1-Q8_0
90
+
91
+ # 3. Render the per-pass PDF audit reports:
92
+ python -m phase3 --asset jagersfontein --date-range 2021-06-15,2022-10-15
93
+ ```
94
+
95
+ End-to-end latency on RTX 4080 Laptop (sm_89, CUDA 12.6) using the GGUF + llama-server path: **2.38 s/pass** β€” 4.7Γ— over the bf16 transformers path with no schema or evidence-quality regression.
96
+
97
+ ## Intended use
98
+
99
+ This model is the *evidence-text writer* for the SatDiff TSF/dam compliance pipeline. It is **not** a general-purpose VLM and is **not** a severity classifier on its own. Use it as part of the rules-engine pipeline described above.
100
+
101
+ ## Limitations
102
+
103
+ - Trained on a small VRSBench slice; performance outside the SatDiff contract prompt's sourcing rules is unknown.
104
+ - Held-out evaluation was on 6 Jagersfontein passes; transfer to other TSF/dam assets is plausible (the lift comes from generic EO grounding) but unmeasured.
105
+ - Severity grading is performed by a downstream Python rules engine, not by this model. Do not delegate threshold reasoning to the fine-tuned weights at this scale.
106
+ - Cloud-cover gating is upstream; the model is not robust to severe cloud occlusion.
107
+
108
+ ## License
109
+
110
+ This work is released under the **LFM Open License v1.0**, inherited from the base model `LiquidAI/LFM2.5-VL-450M`. See the upstream license at https://huggingface.co/LiquidAI/LFM2.5-VL-450M/blob/main/LICENSE.
111
+
112
+ ## Citation
113
+
114
+ ```bibtex
115
+ @misc{satdiff2026,
116
+ title={SatDiff: A Satellite-Readable Compliance Contract for Tailings and Dam Monitoring},
117
+ author={Scholz, Peter},
118
+ year={2026},
119
+ howpublished={Liquid AI "AI in Space" Hackathon submission, Liquid Track},
120
+ note={Fine-tune of LiquidAI/LFM2.5-VL-450M on VRSBench. Stage 1 evidence-correctness 0/30 β†’ 30/30 on held-out tailings-dam passes. See https://huggingface.co/WobblyDopamine/SatDiff-LFM2.5-VL-450M-stage1.}
121
+ }
122
+ ```
123
+
124
+ ## Acknowledgements
125
+
126
+ - Liquid AI for the LFM2.5-VL-450M base model and the `leap-finetune` framework.
127
+ - DPhi for the SimSat API and the hackathon platform.
128
+ - Torres-Cruz & O'Donovan (2023) for the *Scientific Reports* reconstruction of the Jagersfontein failure that anchored this submission's validation.