Gemma 4 · Edge / On-Device · Track 01

SparePart

Offline drone diagnostics for field teams. A photo becomes a strict, validated repair path on the machine, or the system refuses.

SparePart guided drone inspection interface showing a complementary photo and deterministic agreement gate
Recorded QA run on localhost · real Gemma 4 output · Pydantic accepted Static case study · no inference runs on this page
Vision modelGemma 4 local
Output contractPydantic validated
Network boundaryLoopback only
Final decisionHuman go / no-go

Photo in. Evidence out. No cloud dependency.

The operator stays inside one continuous workflow. Gemma 4 handles visual perception; Pydantic and deterministic code enforce the boundaries around that output.

01 / Capture

Any drone photo

Gallery, camera, drag and drop, or clipboard. The app does not fetch an external URL.

02 / Diagnose

Gemma 4 vision

The model runs through a local runtime and describes only visible damage.

03 / Validate

Strict structured output

Pydantic accepts the JSON contract or SparePart rejects the result after one retry.

04 / Repair

Scannable field actions

Numbered guidance remains a proposal. Mechanical inspection stays with the operator.

Results and failure modes are published together.

Frozen evaluation on 14 photos with real visible damage. The comparison baseline ignores the image and always predicts “propeller.”

Gemma 410/14

71% subsystem identification.

Non-vision baseline6/14

43% when always predicting propeller.

Median latency10.0 s

Measured per photo on the local machine.

Schema validity14/14

Every evaluated output passed Pydantic.

Strongest scope

Visible propeller, arm, frame, and gear damage.

Known blind spots

Battery and gimbal damage were missed in this dataset.

Localization limit

Left/right localization is not presented as reliable.

No flight clearance

A visual diagnosis never authorizes return to flight.

One more view, without giving the model final authority.

After the first diagnosis, Gemma 4 can request one complementary angle through a constrained InspectionRequest. A second diagnosis runs independently, then deterministic code checks subsystem, damage family, confidence, uncertainty, and drone presence.

QA disclosure: the same public drone image was reused for the recorded second pass to validate the mechanics of the pipeline. This is not claimed as independent multi-angle corroboration.

Desktop guided inspection layout Mobile deterministic two-view gate

The evidence is online. The inference stays on the machine.

This page is a static, shareable case study. The executable Gradio application, model calls, evaluation scripts, dataset notes, and refusal logic are available in the repository.