Papers
arxiv:2611.37400

Exact Embedding Verification on an Edge NPU: Measurements and Deployment Constraints

Published on Nov 27
· Submitted by
Georgios Feretzakis
on Dec 2
Authors:
,

Abstract

On an edge NPU, exact verification of text-embedding packs is fast enough for concurrent language-model use, but INT8 embedding deviations make cosine-tolerance verification vulnerable, so bitwise comparison against reproducible reference vectors is required.

Offline retrieval-augmented generation (RAG) on edge devices receives knowledge as signed packs of text and precomputed embedding vectors. Prior work showed that a signature does not bind the vectors to the text, that any verifier which accepts recomputed vectors within a cosine tolerance concedes a predictable share of queries, and that on a Raspberry Pi 5 the recomputation needed for exact checks costs a concurrently running language model 23-31% of its decoding speed on the CPU. Here we ask whether a neural processing unit (NPU) makes exact verification practical. On a Raspberry Pi 5 with a Hailo-8L accelerator, verifying 8 text-vector pairs per second costs the language model 1.3% of its decoding speed instead of 23-31%, and re-embedding a 1,745-window corpus takes 3.4 s instead of 72.9 s in FP32 on the CPU. The NPU's INT8 embeddings deviate from floating point (median cosine 0.917), so a tolerance set at the empirical 0.1% quantile of honest NPU-FP32 cosine similarities (0.784, about 38 degrees) would let an attacker who controls the vectors displace the correct document for essentially all evaluated queries; with that tolerance applied as an angular budget in a separate BGE-M3 experiment, an end-to-end attack lowers correct answers from 0.75 to 0.35. The same chip, however, returns bit-identical embeddings across repetitions, batch sizes and processes, which makes exact comparison against a reference generated on the same tested device and configuration possible. We also describe how to deploy exact verification: the device recomputes every chunk, retrieves only with its own vectors and, where the reference comes from a computation shown to reproduce its output, compares shipped reference vectors bit for bit; a mismatch is treated as an integrity event to be investigated rather than resolved by a tolerance; and a signed manifest binds every element that determines the bits.

Community

Paper submitter

We ask whether a neural processing unit makes exact embedding verification practical for offline RAG on edge devices. This follows Signed but Steerable (arXiv:2611.06498), which showed that a signature does not bind shipped vectors to their text and that a verifier accepting recomputed vectors within a cosine tolerance concedes a predictable share of queries. We measured a Raspberry Pi 5 with a Hailo-8L accelerator next to a local language model running on the CPU.

Key findings:

  • Cost: verifying 8 text-vector pairs per second costs the language model 1.3% of its decoding speed on the NPU, against 23-31% on the CPU; re-embedding a 1,745-window corpus takes 3.4 s instead of 72.9 s in FP32 on the CPU.
  • Determinism: the chip returned bit-identical embeddings across repetitions, batch sizes 1, 8 and 32, and a fresh process, which makes exact comparison against a reference generated on the same tested device and configuration possible.
  • The tolerance trap: the NPU's INT8 embeddings deviate from floating point (median cosine 0.917). A tolerance set at the empirical 0.1% quantile of honest NPU-FP32 cosines (0.784, about 38 degrees) would let an attacker who controls the vectors displace the correct document for essentially all evaluated queries; applied as an angular budget in a separate BGE-M3 experiment, an end-to-end attack lowers correct answers from 0.75 to 0.35.
  • Deployment design (no new measurements): the device recomputes every chunk and retrieves only with its own vectors; where the reference comes from a computation shown to reproduce its output, it compares shipped reference vectors bit for bit; a mismatch is an integrity event to investigate, not something to resolve with a tolerance; and a signed manifest binds every element that determines the bits.

These results concern the design of tolerance-based verification, not the chip: none of them indicates a defect of the Hailo-8L. Hailo granted written permission to publish the Hailo-8L results; they are not official Hailo benchmarks and do not imply endorsement by Hailo. The CPU micro-benchmark data are open (GitHub and Zenodo links above).

Sign up or log in to comment

Get this paper in your agent:

hf papers read 2611.37400
Don't have the latest CLI?
curl -LsSf https://hf.co/cli/install.sh | bash

Models citing this paper 0

No model linking this paper

Cite arxiv.org/abs/2611.37400 in a model README.md to link it from this page.

Datasets citing this paper 0

No dataset linking this paper

Cite arxiv.org/abs/2611.37400 in a dataset README.md to link it from this page.

Spaces citing this paper 0

No Space linking this paper

Cite arxiv.org/abs/2611.37400 in a Space README.md to link it from this page.

Collections including this paper 1