Big task: Uszy Piotra — Mistral inbox sidecar / privacy-first policy router #645
Labels
No labels
W6d-automerge-calibration
agent/claude-code
agent/codex
agent/hermes
agent/iskra
agent/ollama
agent/patchwarden
automerge-candidate
class/security-sensitive
cutover-gate
dependency/blocked
dependency/blocks-others
dependency/cross-repo
dependency/needs-confirmation
domain:agents
domain:ci
domain:docs
domain:forgejo
domain:infra
domain:memory
domain:runtime
domain:signal
domain:ux
flow/architecture
flow/blocked
flow/deployed
flow/done
flow/implementation
flow/intake
flow/maintained
flow/observed
flow/ready
flow/refining
flow/retired
flow/review
iterating
judge/codex-candidate
judge/hermes-candidate
judge/low-confidence
judge/needs-refinement
judge/operator-needed
judge/p0
judge/p1
judge/p2
judge/p3
judge/park
judge/patchwarden-candidate
judge/stale-priority
kind/adr
kind/bug
kind/chore
kind/feature
kind/infra
kind/ops
kind/refactor
kind/research
large-impact
merge/auto
merge/manual
merge/manual-dependency-conflict
merge/manual-failing-tests
merge/manual-merge-conflict
merge/manual-missing-review
merge/manual-operator-preference
merge/manual-red-zone
merge/manual-security-sensitive
merge/manual-unclear-scope
merge/manual-unknown
meta
mode:operator-only
mode:patchwarden-iskra-approved
mode:safe-auto
needs-operator-decision
needs-triage
not-ready
observed/erroring
observed/needs-followup
observed/pending
observed/retire-candidate
observed/unused
observed/used
operator-emotional
owner-attention
phase/02
phase/03
priority:p0
priority:p1
priority:p2
priority:p3
proposed
ready-for-agent
ready-for-operator
recovery
review:claude-reviewed
review:codex-reviewed
review:dziadek-reviewed
review:needs-human
risk/exposure
risk/process
risk/product
risk/runtime
safety:external-write
safety:no-prod-mutation
safety:prod-impact
safety:secret-touch
size/large
size/medium
size/small
size/tiny
size/unknown
source/adr
source/agent-generated
source/manual
source/operator-chat
source/voice-note
status:blocked
status:codex-ready
status:merged:pending-evidence
status:needs-evidence
status:operator-needed
status:parked
tier/full
tier/lite
tier/stacked
tier:0-platform-substrate
tier:1-iskra-value-layer
tier:2-tools-products-modules
type:bug
type:chore
type:docs
type:feat
type:policy
type:research
No milestone
No project
No assignees
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
pdurlej/platform#645
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Context
This issue captures a Signal-originated product/security discussion about Uszy Piotra: a privacy-first inbox sidecar where OpenClaw/Iskra remains the main harness/router/memory layer, while Mistral may act as a fast Polish-language processing layer for classification, triage, safe summaries, and structured receipts.
Local detailed artifact:
/home/openclaw/.openclaw/workspace/artifacts/2026-05-30-uszy-piotra-mistral-inbox-sidecar.mdKan card:
mz95ewhkj06sPrivacy note: this issue intentionally contains a sanitized technical artifact, not a raw private Signal transcript.
Why this matters
Working hypothesis:
Mistral appears interesting because of:
Architecture hypothesis
OpenClaw / Iskra
Mistral API / local Mistral
Critical red-team conclusion
This should be treated as:
Non-negotiable red lines
local_only/super_privatemessages.Suggested v0 scope
Build a boring, falsifiable benchmark + policy router, not an inbox autopilot.
Deliverables:
Initial JSON receipt sketch
Open questions
platformthe right repo, or should this become a dedicateduszy-piotrarepo?Repo split proposal after Piotr's follow-up:
This should probably not live as a single monolithic issue.
Platform-owned part
Keep here in
pdurlej/platform:OpenClaw-owned part
Should become a linked issue in the OpenClaw/Iskra repo once the canonical repo is identified:
cloud_allowed/local_only/fallback_to_cloud: forbiddengates,Linkage
This issue should remain the platform/security epic. The OpenClaw issue should be the implementation/harness epic and link back here.
Pending: identify canonical OpenClaw/Iskra repo. Public Forgejo repo list currently does not show an obvious
openclawrepo underpdurlej; visible Claw-adjacent repo ispdurlej/judging-claw, which does not look canonical for this work.Linked OpenClaw/Iskra implementation issue created: pdurlej/iskra-openclaw#392
Split now is:
platform#645= infrastructure/security/local deployment/data locality epiciskra-openclaw#392= OpenClaw policy router, receipts, model routing, Signal/runtime UX guardsArchitecture decision: assume Mistral API is non-ZDR at MVP start
Piotr confirmed a pragmatic assumption from the current Mistral account/plan reality:
This changes the MVP risk model:
Required policy implication
Return to the earlier scaled mail access concept:
tier_0_headers_only: Mistral may see only headers/minimal metadata.tier_1_low_sensitivity: Mistral may see sanitized snippets/content for classification.tier_2_private: local-only content; Mistral gets at most metadata.tier_3_secrets: passwords, credentials, secrets, medical/legal/highly private content; never send raw content to Mistral.Examples of hard block / headers-only:
super_private/local_only.Design consequence
The critical v0 component is a sensitivity gate before model routing, not the model itself.
Mistral API should be treated as a fast non-ZDR processor behind a strict policy gate. Local models become the later path to true ZDR-like behavior.
Proposed pipeline v0 from Piotr audio note
Piotr sketched a pragmatic first architecture for Uszy Piotra with Mistral API as a fast non-ZDR processing layer behind local safety gates.
Ingestion
Sources:
Local first-pass gate
Before anything reaches Mistral API:
Hard rule: blocked/highly sensitive messages are headers-only or local-only.
Mistral API role
For Gmail/low-sensitivity messages that pass the gate, Mistral API receives enough content for richer classification and triage.
Mistral may:
Mistral is not the final decision-maker. It gives taste/signal to Iskra.
Iskra/OpenClaw role
Iskra has a polling/checkpoint script that checks the shared Obsidian/headless surface every N minutes.
If Mistral reports new mail:
FastMail variant
For FastMail:
This keeps outbound blast radius low.
Why this is attractive
Open questions / risks
Roadmap / model layering from Piotr audio note
Piotr proposed a more explicit layered architecture for Uszy Piotra and broader ingest workflows.
Local small safety model
Investigate OpenAI's small/local Hugging Face model as a candidate for the local sensitivity gate. Desired role:
Mistral as critical processing layer
Mistral/Mistral-family models are becoming central to this design:
Local server v1.0
Future target:
Broader ingest path
If this pattern works for mail, it can generalize to:
Mistral becomes a reusable ingestion/triage layer, not just mail tooling.
Proposed privacy/power ladder
From most private/weakest to least private/strongest:
Important wording: this is about the underlying engine privacy/power tradeoff, not Iskra's persona.
Action items
Quick verification: OpenAI local model candidate + Ollama key status + DeepSeek blocker
OpenAI local model candidate
Found the likely model Piotr referred to:
openai/gpt-oss-20bgpt-ossfamily.harmonyresponse format; using it as a classifier/gate needs adapter/wrapper work, not just naive prompting.This is a plausible candidate for the local sensitivity gate, but should be benchmarked specifically on:
Ollama API key status
Checked without exposing the secret:
/opt/hermes-agency/.envcontains:OLLAMA_BASE_URLset, host:https://ollama.comOLLAMA_API_KEYsetOLLAMA_TIMEOUT_MSsetOLLAMA_API_KEY; it only exposesZAI_API_KEYamong matching provider keys./home-platform/apps/openclawpath does not currently expose an Ollama key to OpenClaw render.Implication: Ollama cloud key exists in Hermes env, but OpenClaw-family unattended secret contract may need cleanup/bridging before Iskra can use it safely.
DeepSeek V4 Cloud blocker
Attempted to spawn red-team with:
deepseek/deepseek-v4deepseek/deepseek-chatBoth were rejected by current OpenClaw model allowlist:
model not allowed.Need either:
Strategic defer until 2026-06-08
Piotr noted this should be deferred until around 8 June 2026.
Reason: Apple is expected to present AI-related capabilities around then, and Piotr is planning hardware upgrades (iPhone 18 Pro and likely MacBook/Mac-side upgrade). This may materially change what local models can run on-device / on Mac and therefore affects the local-vs-cloud architecture.
Decision implication:
Correction / better local safety-gate candidate:
openai/privacy-filterPiotr pointed to the more relevant OpenAI Hugging Face model:
This is a much better first safety-gate candidate than treating
gpt-oss-20bas the primary local classifier.Why it fits
openai/privacy-filteris a bidirectional token-classification model for PII detection and masking, intended for high-throughput on-prem data sanitization workflows.Relevant properties from the model card:
account_numberprivate_addressprivate_emailprivate_personprivate_phoneprivate_urlprivate_datesecretUpdated gate proposal
Use layers:
openai/privacy-filteras local PII/secret span detector + masker.Caveats
Do not over-trust it:
Architecture consequence
privacy-filtershould become the first serious local redaction/sanitization candidate for v0.gpt-oss-20bremains a possible second-pass semantic classifier, not the first PII detector.WWDC / Apple AI watchlist for June 8 defer
Piotr shared a GPT-generated WWDC expectation note. Treat as unverified forecast, not fact.
It strengthens the existing defer: do not lock local-vs-cloud architecture until after Apple's AI announcements are clear.
What to watch for
The important question is not “new Siri” but whether Apple exposes local/on-device AI capabilities to developers.
Decision-changing announcements would include:
Why it matters for Uszy Piotra / Iskra
If Apple gives developer-accessible local inference on Apple Silicon, several parts of the roadmap may move from custom infra to native macOS/iOS capabilities:
This could reduce reliance on:
Conservative expectation
Apple may only ship a constrained foundation layer, not a complete agent platform. Expect a 2–3 year expansion curve.
Decision after WWDC
After 2026-06-08, revisit:
RS2000 resource constraint / benchmark requirement
Piotr added an important operational constraint:
The local privacy/sensitivity gate must not murder the RS2000 Netcup VPS, at least for the headers-only analysis path.
Minimal v0 assumption
For early v0, do not assume full message-body local inference on RS2000.
Start with:
Acceptance criterion
A candidate local model/gate is acceptable for RS2000 only if it can run continuously or frequently without destabilizing the VPS.
Benchmark before adopting:
Consequence for
openai/privacy-filteropenai/privacy-filteris promising, but must be tested in a very small headers-only benchmark first. If 1.5B token-classification is too heavy on RS2000, fallback options are:Design principle
RS2000 should remain the reliable always-on orchestrator. It must not become the overloaded inference box by accident.
Related capability bug created:
pdurlej/iskra-openclaw#394
Summary: Ollama API key exists in Hermes env, but normal Iskra/OpenClaw runtime does not receive it through
/run/user/1000/openclaw/runtime.env/ OpenClaw Infisical render path, so Ollama cannot yet be used as an Iskra red-team/model-routing lane without a secret-contract fix.Fallback if local model is too heavy: deterministic-first gates + prior art search
Piotr added a useful constraint/attitude:
If RS2000 cannot comfortably run a local privacy model, do not force an LLM into the gate. Instead, make the early system more deterministic and lean on prior art.
Design implication
For v0, a deterministic-heavy gate may be a feature, not a compromise:
Candidate deterministic layers
Before any LLM/cloud routing:
Prior art requirement
Before building custom gates from scratch, search for existing libraries/repos/tools that already solve parts of this:
Assumption: many people/repos have already tackled pieces of this better than a bespoke first attempt.
Acceptance update
The MVP should compare at least two gate shapes:
openai/privacy-filteror other local classifier.If #1 is “good enough” for initial routing, prefer it for v0 and postpone heavier model gates to Mac/local server phase.
Quick prior-art scout for deterministic/privacy gates
Initial web scout confirms there is existing prior art worth evaluating before writing bespoke gates.
Candidate families:
PII / redaction
Secret scanning / credentials
Evaluation requirement
Before choosing, benchmark for:
Cost / subscription economics — missing part from Piotr's earlier note
Piotr correctly called out that the earlier capture underweighted the cost-vs-benefit layer.
Current pricing signals checked
Mistral official pricing page:
$14.99/moexcluding taxes.$24.99/user/moexcluding taxes.$2/M inputand$6/M output.$1.5/M inputand$7.5/M output.Ollama official pricing page:
$100/mo, 10 cloud models at once, 5x more usage than Pro.Architecture cost read
For mail triage, pure API cost may be low if we keep the payload small:
So the cost danger is not “one email classification”. The danger is scope creep:
Subscription vs API take
Mistral Pro/Vibe subscription may be financially attractive if it gives useful UI/agent/workflow/connectors for Piotr, but it should not be assumed to replace API billing or provide ZDR.
For automated mailbox processing, API is likely the cleaner integration contract unless Mistral's subscription connectors/workflows expose stable automation and acceptable privacy controls.
Ollama Pro/Cloud is more interesting as a fixed-cost experimental/escalation layer:
Cost controls needed in v0
Provisional decision
Before June 8 / Apple AI clarity:
One important correction
The cost case improves dramatically if the deterministic/local gate is strong: it keeps most messages out of expensive/less-private layers and makes cloud calls sparse, small, and auditable.
Local runner preference: P-Harness
Piotr added that he has a good experience with P-Harness and it is likely the preferred local harness for this class of work.
Why it matters
P-Harness fits the intended role:
Proposed use in Uszy Piotra
Evaluate P-Harness as the local execution layer for:
openai/privacy-filterbenchmark,Design implication
Prefer building the first local gate prototype as a P-Harness callable task/job rather than inventing a new daemon prematurely.
The runner should return a safe structured receipt:
Open question
Need to document the exact P-Harness interface available to Iskra/OpenClaw and where its local config lives.
Matrix room created for ongoing project discussion
Created a separate Matrix/Element room so this project does not dominate Signal DM:
#uszy-piotra:pdurlej.com!pdQVfdAEshAzqMeMLv:pdurlej.com@iskra:pdurlej.comPurpose: dedicated discussion lane for Uszy Piotra / inbox privacy gate, including Gmail/FastMail/WhatsApp triage, deterministic gates,
openai/privacy-filter, Mistral API as non-ZDR layer, Ollama/DeepSeek red-team, P-Harness, and post-WWDC Apple AI decisions.Groq STT check on Piotr's long voice note
Piotr clarified he meant Groq (cheap/fast transcription API), not Grok/xAI.
Tested Groq STT on the long voice note from 2026-05-30 16:37 (
f329bdf8-...aac, copied as.m4abecause Groq rejected.aacextension despite m4a container).Result:
whisper-large-v3-turboImportant recovered points from the second half:
Operational note:
Groq STT is viable as a fallback/secondary transcription lane for long Polish Signal voice notes, especially when the built-in transcript looks mangled in the second half. Need
.aac→.m4aextension/container handling or transcoding before upload.Org / decomposition (claude, per operator — Iskra's vision drives; I structure, not redesign). Iskra's architecture stands: OpenClaw/Iskra = harness / router / memory / policy / audit / decision / security boundary; Mistral = fast Polish-first processing sidecar. Implementable phases:
Phase 0 — Policy + privacy design (Iskra-owned, operator-gated). What may Mistral see (sanitized only?), the privacy boundary, policy-router rules, receipt/audit shape. The gate — nothing integrates until Phase 0 is set.
Phase 1 — Mistral sidecar PoC (Codex). Local/API Mistral doing Polish-first classification / triage / safe-summary on SANITIZED input only. Stateless.
agent/codex.Phase 2 — OpenClaw router wiring (Iskra). OpenClaw decides what goes to Mistral, gets structured receipts, makes the final decision. Iskra's runtime.
Phase 3 — Receipts + audit (Codex + Iskra). Structured receipts into the memory layer — ties to ADR-0025 (no secrets, receipted).
Evaluation criterion (Iskra's, kept): Polish-first contextual understanding — tone, urgency, irony, social register — not generic benchmarks.
Sequence: Phase 0 → 1 → 2 → 3.
Deep research follow-up (claude, 2026-06-01) — building on Iskra's epic, not redoing it.
Iskra's 17-comment capture is the foundation (tiers 0–3, pipeline, prior-art, costs, P-Harness, June-8 defer). I deliberately add only what's not already here: a sharper architectural frame, fresh Mistral data, the missing testable core, a red-team seam, and a defer-safe work split for Codex.
1. The crux nobody named: this is TWO problems, not one "gate"
The thread keeps saying "the gate" as if it's one thing. It's two orthogonal problems, and conflating them is what makes RS2000 sizing feel impossible:
openai/privacy-filterspan detection + allow/deny sender rules. Cheap, auditable, RS2000-friendly, low prompt-injection surface. HIGH confidence.Consequence: the leak-prevention gate does not need an LLM at all. It runs deterministic on RS2000 (headers-only first), masks/sanitizes, and only the sanitized output reaches the semantic model — where cloud Mistral is acceptable for low-sensitivity. This dissolves the "don't murder RS2000" tension: RS2000 = deterministic router + masker; the heavy semantic model lives wherever (cloud-tier_1, or local-after-June-8). Build A first; treat B as a separate track.
2. Fresh Mistral map (2026-06-01, public sources) → drops into Iskra's tiers + open questions
gpt-oss-20b(smaller, instruct-native, no harmony-format wrapper). → the local-only tier_2 path post-June-8.3. ZDR reality update — sharpens Iskra's "assume non-ZDR"
Iskra's "treat Mistral API as non-ZDR" is right for the non-Enterprise plan, but the posture isn't binary:
(Verify pricing + ZDR/DPA terms against the live Mistral pages before committing spend/contract — these move.)
4. The missing testable core: a falsifiable Polish-first eval
Iskra's thesis is "evaluate on Polish contextual understanding, not generic benchmarks." But the eval method is named, not designed — so the hypothesis is currently unfalsifiable. This is the single highest-leverage artifact, and it's pure data (no model, no runtime):
passive_aggressive/manipulative),polish_nuance_flags(irony,hidden_pressure), privacy_tier (0–3).Turns "Mistral feels better for Polish" into a number. Defer-independent — build it now.
5. Red-team seam: the receipt IS an exfiltration channel (+ memory-plane tie)
Iskra has a "no logs reconstruct content" red-line, but the receipt schema itself is the risk surface, and it's not yet named as a channel:
summary_safe+ a rich set of structured flags can together reconstruct the sensitive message. And receipts flow into the memory layer (ADR-0025). So:6. Best advice for Codex — the defer-safe split (build NOW vs wait for June 8)
The June-8 defer (Apple WWDC + Piotr's hardware) only gates the local-model + hardware choices. Most of v0 is defer-independent — Codex can start these now with zero risk that WWDC invalidates them, zero runtime mutation, zero operator-gated decisions:
▶ Start now (defer-proof, pure docs/data/offline-benchmark):
⏸ Wait for June 8 (hardware/Apple-dependent):
privacy-filtervs Apple-native foundation API).Why this helps Codex: five concrete shippable artifacts that the hardware decision cannot invalidate — Phase 0 gets real teeth while the hardware-coupled choices stay parked exactly as Iskra wants.
Sequence stays Iskra's Phase 0 → 1 → 2 → 3. This just fills Phase 0 with defer-safe deliverables and gives the eval its falsifiability. Iskra owns the privacy contract + the persona/decision layer; this is structural scaffolding under her vision, not a redesign of it.
Sources (2026-06-01): Mistral 3 / Ministral 3, Mistral models overview, Mistral ZDR help, Mistral data storage/retention, Mistral DPA. Pricing/ZDR move — verify live before spend/contract.
M08 cleanup by codex: moving this larger product sidecar to M10 Improvements per operator decision. It remains valuable, but it should not block the focused M08 Iskra/OpenClaw value-loop closeout.
Iskra judgment
pdurlej/platform#issue#645judge/p3iskraviaopenclawRationale: This is P3 parked because the inbox sidecar idea is strategically aligned and privacy-relevant but large, product-sensitive, and not ready for direct implementation.
Caveat: Do not turn this into an implementation ticket until the privacy policy, evaluation criteria, and product boundary are made explicit.
Structured openclaw.judge.v0 payload