CoolFace
Modelpublic

davidburhans/gevva-e2b-multimodal

sourceHugging Faceapache-2.0updated 7h agoView on Hugging Face
0likes
Model Card

⚡ Gevva e2b Multimodal: Vision-Grounded 128K System 1 Decision Engine

<p align="center"> <a href="https://colab.research.google.com/github/davidburhans/gevva/blob/main/notebooks/gevvaquickstart.ipynb"><img src="https://colab.research.google.com/assets/colab-badge.svg" alt="Open In Colab"></a> <a href="https://pypi.org/project/gevva/"><img src="https://img.shields.io/pypi/v/gevva.svg?logo=pypi&logoColor=white" alt="PyPI"></a> <a href="https://huggingface.co/google/gemma-4-E2B-it"><img src="https://img.shields.io/badge/BaseModel-Gemma--4--E2B--it-blue.svg" alt="Base Model"></a> <a href="https://github.com/davidburhans/gevva"><img src="https://img.shields.io/badge/MultimodalAccuracy-88.8%25-brightgreen.svg" alt="Multimodal Accuracy"></a> <a href="https://github.com/davidburhans/gevva"><img src="https://img.shields.io/badge/Invoice%26TableVerification-96.4%25-gold.svg" alt="Table Accuracy"></a> <a href="https://github.com/davidburhans/gevva"><img src="https://img.shields.io/badge/ContextWindow-128K(131%2C072tokens)-purple.svg" alt="Context Window"></a> <a href="https://github.com/davidburhans/gevva"><img src="https://img.shields.io/badge/Latency(P50)-16.5ms(RTX_5090)-orange.svg" alt="Latency"></a> <a href="https://opensource.org/licenses/Apache-2.0"><img src="https://img.shields.io/badge/License-Apache--2.0-red.svg" alt="License"></a> </p>


⚡ Executive Overview

Gevva e2b Multimodal is the vision-enabled variant of the Gevva family of System 1 Decision Engines. Built on Google's instruction-tuned multimodal foundation model google/gemma-4-E2B-it, this model pairs a non-autoregressive sequence classification head with Google's frozen SigLIP vision tower and a fully fine-tuned cross-modal projection layer (embed_vision).

Rather than generating text autoregressively (500–3,000 ms), Gevva e2b Multimodal evaluates visual scenes, charts, diagrams, and invoices against declarative textual hypotheses in a single forward pass (~16.5 ms), producing rigorously calibrated probabilities:

$$\text{Class} \in \{\text{Contradiction (0)}, \text{Entailment (1)}, \text{Neutral (2)}\}$$


👁️ Multimodal Visual Grounding Benchmark Results

Evaluated on held-out visual entailment suites across diverse document, infographic, and real-world scenes:

Visual DomainBaseline Text-Only Cross-Encoder**Gevva e2b Multimodal**Absolute Gain
Invoices & Tabular Documents75.00%96.43%+21.43%
Charts & Financial Graphs91.04%92.00%+0.96%
Spatial Scenes & Geometry78.57%87.04%+8.47%
Overall Visual Grounding81.12%88.76%+7.64%

🏆 System 1 Decision & JevBench Performance

While adding high-accuracy vision grounding, the model maintains high decision-making integrity across text benchmarks:

  • —JevBench Easy Tier: 100.00% (48/48) — Zero regression on solved primitives.
  • —JevBench Standard Tier: 88.89% (64/72) — Parity with text flagship.
  • —Grouped Multi-Choice Decision Accuracy: 92.72% across enterprise decision workflows.
  • —Classic NLI Entailment: 87.40% anchor accuracy (no catastrophic forgetting).
  • —Inference Speed: 16.5 ms ($p_{50}$) single-item forward pass on NVIDIA RTX 5090.

🚀 Quickstart Guide

1. Using the Gevva SDK (pip install gevva)

python
from PIL import Image
from gevva import GevvaCrossEncoder

# Load model directly from Hugging Face
model = GevvaCrossEncoder("davidburhans/gevva-e2b-multimodal")
# (Also accessible via branch: GevvaCrossEncoder("davidburhans/gevva-e2b", revision="multimodal"))

# Example A: Visual Entailment (Verifying an invoice or receipt image)
image = Image.open("invoice.jpg").convert("RGB")
claim = "The total balance due is exactly $1,420.50."

pred = model.predict(
    pairs=[("An invoice is displayed.", claim)],
    images=[image],
)[0]

print(f"Probabilities: {pred.probabilities}")
print(f"Verdict: {pred.predicted_label}")
# Output: 'entailment' (Confidence: 0.941)

# Example B: Text-Only System 1 Decision / Tool Routing
result = model.route(
    query="Refund transaction tx_9921 because customer never received items",
    tools=[
        "search_documentation: Search knowledge base articles",
        "process_refund: Refund payment to original payment method",
        "cancel_order: Cancel pending fulfillment shipment",
    ]
)
print(f"Selected Tool: {result.selected_tool}")
# Output: 'process_refund'

2. Using Native Hugging Face Transformers

python
import torch
from PIL import Image
from transformers import AutoModelForSequenceClassification, AutoTokenizer
from transformers.models.gemma4.image_processing_pil_gemma4 import Gemma4ImageProcessorPil

model_id = "davidburhans/gevva-e2b-multimodal"
tokenizer = AutoTokenizer.from_pretrained(model_id)
image_processor = Gemma4ImageProcessorPil()
model = AutoModelForSequenceClassification.from_pretrained(
    model_id,
    torch_dtype=torch.bfloat16,
    device_map="cuda",
    trust_remote_code=True,
)

image = Image.open("chart.png").convert("RGB")
feat = image_processor(image, return_tensors="pt")

# Gemma 4 multimodal format:
prompt = "Premise: <|image|>" + ("<|image|>" * 269) + "\nHypothesis: Q3 revenue peaked above $4M.\nPrediction:"
inputs = tokenizer(prompt, return_tensors="pt").to("cuda")

with torch.no_grad():
    outputs = model(
        input_ids=inputs.input_ids,
        attention_mask=inputs.attention_mask,
        pixel_values=feat["pixel_values"].to("cuda", dtype=torch.bfloat16),
        image_position_ids=feat["image_position_ids"].to("cuda"),
    )
    probs = torch.softmax(outputs.logits, dim=-1)

labels = ["contradiction", "entailment", "neutral"]
for label, p in zip(labels, probs[0].tolist()):
    print(f"{label}: {p:.4f}")

🔬 Architectural Details & Design

  • —Backbone: google/gemma-4-E2B-it (2.3B effective parameters).
  • —Vision Tower: Google SigLIP (frozen during sequence classification training).
  • —Trainable Downstream Parameters: embed_vision (multimodal projection adapter) + full language model transformer backbone + sequence classification head (score_head).
  • —Context Length: Up to 128K tokens (131,072) supported natively via RoPE.
  • —Label Mapping: Standard ModernCE / OpenJEV:
  • —0: Contradiction
  • —1: Entailment
  • —2: Neutral

👥 Authors & Co-Authorship

  • —Dave Burhans — Lead Author & Architecture
  • —Gemini 3.8 Flash — Co-Author (Synthetic curriculum generation, 4-judge validator committee, SDK implementation)
  • —GLM 5.3 — Co-Author (Reasoning remediation curriculum, error audits, adversarial methodology review)
  • —GLM 5.3 Flash — Co-Author (Synthetic calibration testing, loss formulation, decision metrics)
  • —Gevva Contributors

🙏 Model & Quant Provider Acknowledgments

The synthetic data generation and multi-judge validation committee were powered by local high-throughput serving on llama-server (port 8080). We gratefully acknowledge and credit:

  • —Foundation Models: Qwen 3.6 27B & Qwen 3.8 Flash Next by the Qwen Team / Alibaba Cloud; DeepSeek V4 Flash by DeepSeek AI; Gemma 4 31B by Google DeepMind.
  • —Quantization & GGUF Creators: Unsloth AI (@unsloth: unsloth/Qwen3.6-27B-MTP-GGUF UD-Q4KXL, unsloth/Qwen3.8-Flash-Next-GGUF UD-IQ4XS), **ISTA-DASLab** ([@ISTA-DASLab](https://huggingface.co/ISTA-DASLab): `ISTA-DASLab/Qwen3.8-Flash-Next-GSQ-RCO-GGUF` IQ3XXS), Bullerwins (@bullerwins): bullerwins/DeepSeek-V4-Flash-0731-GGUF), and Google.

📜 Citation & License

bibtex
@software{gevva2026,
  author = {Burhans, Dave and {Gemini 3.8 Flash} and {GLM 5.3} and {GLM 5.3 Flash} and Contributors},
  title = {Gevva: State-of-the-Art Multimodal 128K System 1 Decision Engine},
  year = {2026},
  publisher = {Hugging Face / GitHub},
  url = {https://github.com/davidburhans/gevva},
  note = {Rank 1 on Global JevBench Leaderboard}
}