Intelligence sync: central brain, local brain
Devices synchronize verified knowledge, not model weights. Nothing retrains on-device. This page describes the split, what actually travels, and the security properties that make it safe to trust a downloaded pack.
trusted feeds ─┐
official sites ─┼──▶ CENTRAL INTELLIGENCE SERVICE
admin reports ─┤ quarantine → verify → label
human labels ─┘ evaluate for false positives
│
▼
┌──────────────────┐
│ SIGNED PACK │ serial N, Ed25519
└────────┬─────────┘
┌───────────────┼───────────────┐
▼ ▼ ▼
Android/iOS browser ext desktop/local API
LOCAL BRAIN
├── deterministic rules
├── entity facts (official domains / senders / phones)
├── threat indicators (confidence · source · region · expiry)
└── small local LLM → offline verdict + explanation
↑ cloud escalation only for uncertain
cases, only with consent
Why the central service is not "an LLM that decides"
The central brain is a governed publishing pipeline. A model may help summarize or triage, but nothing reaches a device because a model said so. Publication requires: quarantine → verification → false-positive evaluation against the labelled corpus → signature → staged rollout with rollback.
That governance is the product. Anyone can run a model over scam text; almost nobody maintains a verified, regionally-scoped, false-positive-tested knowledge base — and that is also what makes the labelled corpus (Phase 0 of the roadmap) strategically important rather than just a QA chore.
What travels to devices
| Payload | Cadence | Notes |
|---|---|---|
| Rule changes | Weekly-ish | Regex + weights; changes evaluation semantics |
| Entity facts | Weekly-ish | Official domains, sender IDs, phone numbers |
| Threat indicators | Hourly/daily | Malicious domains, reported numbers, campaign phrases |
| Score calibration | Rare | Floors and thresholds; must match the server exactly |
| Model / adapter | Rarely | Large, and behaviour-changing — treat as an app release |
GET /v1/rules/pack returns the full pack; GET /v1/rules/delta?since_serial=N returns only what changed. Indicator churn is high and rule churn is low, so delta sync is what keeps mobile battery and bandwidth sane.
Full resync is forced when rules, entities, or scoring change: those alter evaluation semantics, and a device applying new indicators with old scoring would disagree with the server. The delta response says so explicitly via full_resync_required.
Indicator metadata, and why each field earns its place
{
"id": "ind_9f2",
"kind": "domain",
"value": "enbd-secure-login.top",
"source": "human_verified",
"confidence": 1.0,
"regions": ["AE"],
"campaign": "enbd-otp-2026-q3",
"expires_at": "2027-07-23T00:00:00Z"
}
- source is provenance, and it caps confidence. An automated scraper cannot publish above 0.5 no matter how certain it claims to be; only human verification reaches 1.0. Without this, one bad scrape outranks a reviewer.
- regions prevents a UK campaign from raising false positives in the UAE. Empty means global.
- expiry defaults by provenance — automated indicators live 14 days, verified facts a year. Scam infrastructure is disposable; stale indicators are how a detector slowly becomes wrong.
- campaign groups indicators so one takedown can retire a whole set, and so explanations can say "this belongs to a known campaign".
Expired ≠ deleted. An expired indicator stops contributing to the score but stays visible for explanation and audit. Silent disappearance would make a device quietly less protective with no signal that anything changed.
Signing: the property that makes this safe
Devices trust packs to decide what is a scam. TLS protects the channel — it does not protect against a compromised CDN edge, a stolen origin, or a hostile mirror. An attacker who can alter a pack could disable detection silently, or flag a real bank as a scam.
So every pack is signed with Ed25519 at the source, and every client verifies before activating.
{
"envelope_version": 1,
"key_id": "prod-2026-1",
"algorithm": "ed25519",
"payload_sha256": "…",
"signature": "base64…",
"payload": { /* the pack */ }
}
Rules that make this real rather than decorative:
- Fail closed. Verification failure means discard the download and keep the previously trusted pack. Never fall back to accepting unsigned data.
- Unknown
key_idis a rejection, not a prompt to trust. That is what makes rotation safe: ship the new public key in an app release, then start signing with it. - Canonical serialization — sorted keys, no whitespace, UTF-8 — so signer and verifier agree byte for byte. Any deviation fails, which is the desired behaviour.
- The private key never sits on the API server in production. Packs are signed offline or in a KMS and the API serves the pre-signed artifact. A key in server settings means development mode, and
/v1/capabilitiesreportssigning: "dev"so nobody mistakes it for production.
Implementation: backend/app/intel/signing.py, clients/android/.../rules/PackVerifier.kt, clients/ios/ScamGuardKit/API/PackVerifier.swift. Tests in backend/tests/test_intelligence.py cover tampering, wrong keys, unknown key ids, and rotation on the server side; the iOS port was additionally verified against a live dev-signed pack (correct key, unknown key, tampered payload, tampered hash, unsigned/required combinations) rather than by inspection alone.
Rollback
Each publication gets a serial. Rolling back is serving serial N−1 and letting devices delta down to it. A staged rollout (1% → 10% → 100%) with false-positive telemetry between stages is what makes rollback rare; the capability is what makes a bad publication survivable.
Never hot-fix a bad indicator by editing in place — publish a new serial that removes it, so every device converges on the same known state.
Privacy: what devices send back
Feedback is what keeps the corpus growing, and it must not become a message collection pipeline. Default upload shape:
- message hash (not the message)
- redacted indicators (domains, sender IDs — never PII)
- engine evidence: matched rule ids, scores, claim status
- the user's own scam/safe label
- locale and pack serial
Raw message text requires separate, explicit research consent, presented as its own choice — not bundled into a terms-of-service checkbox. The processing disclosure already tells users what left their device; feedback must be held to the same standard.
The local model
qwen3:8b is right for the desktop/Ollama deployment and far too heavy as a mobile baseline. Qwen3 ships 0.6B / 1.7B / 4B variants; the sensible plan is 1.7B quantized as the mobile baseline, 4B on capable devices, selected at runtime from available RAM — the same "probe, don't assume" approach used for call-audio capability.
Runtime candidates, to be benchmarked rather than chosen on reputation:
| Runtime | Notes |
|---|---|
| llama.cpp Android | Mature, GGUF quantization, most control |
| MLC LLM | Good GPU/NPU utilization, unified iOS+Android |
| ExecuTorch | PyTorch-native, strong iOS story |
Benchmark on real mid-range hardware, measuring: time to first token, tokens/sec, peak RSS, battery drain per analysis, thermal throttling after ten consecutive analyses, and app size increase. Battery and thermals decide this, not accuracy — a model that drains 4% per call will be uninstalled regardless of how well it reads intent.
Keep the tier boundary intact: the local model interprets language and explains. It never overrides deterministic floors, exactly as the server LLM does not (see safety invariants).
What this changes about pricing
Local inference runs on the user's hardware, so there is no per-analysis GPU bill — the cost argument in the roadmap applies to cloud escalation, not to on-device analysis. That makes a genuinely useful free tier sustainable, which matters for adoption in a product whose value depends on being installed before the scam arrives.
| Tier | What you get | Marginal cost |
|---|---|---|
| Free | Offline rules, entity verification, small local model | ~zero |
| Family | Protected contacts, alerts to a guardian, family dashboard | low |
| Advanced | Cloud escalation for uncertain cases, real-time intelligence, cross-device | metered |
| Enterprise | Intelligence API, campaign monitoring, org policy, reporting | contract |
Cloud escalation being a paid feature is also the honest framing: it is the tier where data leaves the device, so it should be the tier the user deliberately buys.
Build order
- Indicator store + delta sync — done (
backend/app/intel/) - Signing + client verification — done, fail-closed (Android and iOS)
- Central service: feed ingestion, quarantine, verification workflow
- Staged rollout + rollback tooling
- Privacy-preserving feedback endpoint (hashes and evidence, not messages)
- On-device model benchmark, then integration behind the existing LLM interface
Steps 3–5 need the labelled corpus to exist first: without it there is nothing to evaluate a candidate publication against, and publishing unevaluated indicators is how a detector acquires a false-positive problem.