diff --git a/AGENTS.md b/AGENTS.md index c723300..1eb5029 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -102,6 +102,12 @@ The following are **deliberate design choices**, not bugs. They are documented i 2. **No authentication or authorization**: There is no login, no API keys, no session management. The app is designed for trusted networks (home LAN, VPN). The README warns users not to expose it to untrusted networks. 3. **Arbitrary bot code execution**: The bot system (`app/bot.py`) executes user-provided Python via `exec()` with full `__builtins__`. This is intentional — bots are a power-user feature for automation. The README explicitly warns that anyone on the network can execute arbitrary code through this. +## Intentional Packet Handling Decision + +Raw packet deduplication is path-aware by design: +- Keep repeats that represent the same payload arriving via different mesh paths (this path diversity is useful). +- Drop packets that are truly identical observations (same payload and same effective pathing observation) to avoid redundant noise. + ## Data Flow ### Incoming Messages diff --git a/app/AGENTS.md b/app/AGENTS.md index 45188b3..0a9913d 100644 --- a/app/AGENTS.md +++ b/app/AGENTS.md @@ -78,6 +78,11 @@ app/ - Message uniqueness: `(type, conversation_key, text, sender_timestamp)`. - Duplicate insert is treated as an echo/repeat; ACK count/path list is updated. +### Raw packet dedup policy + +- Path diversity is meaningful: same payload observed across different paths should be retained/represented. +- Only truly identical packet observations should be dropped as duplicates. + ### Periodic advertisement - Controlled by `app_settings.advert_interval` (seconds). diff --git a/frontend/AGENTS.md b/frontend/AGENTS.md index 0853854..88b6f06 100644 --- a/frontend/AGENTS.md +++ b/frontend/AGENTS.md @@ -107,6 +107,7 @@ Specialized logic is delegated to hooks: - `VisualizerView.tsx` hosts `PacketVisualizer3D.tsx` (desktop split-pane and mobile tabs). - `PacketVisualizer3D` uses persistent Three.js geometries for links/highlights/particles and updates typed-array buffers in-place per frame. - Packet repeat aggregation keys prefer decoder `messageHash` (path-insensitive), with hash fallback for malformed packets. +- Keep packet repeats that add distinct path observations; only drop truly identical duplicate observations. ## WebSocket (`useWebSocket.ts`)