Specs / 9. System Architecture Overview

9. System Architecture Overview

TiltCheck is intentionally modular, low-cost, and founder-friendly.

© 2024–2025 TiltCheck Ecosystem (Created by jmenichole). All Rights Reserved.

9. System Architecture Overview

TiltCheck is intentionally modular, low-cost, and founder-friendly.

The architecture emphasizes:

This document provides a complete overview of the system’s high-level architecture, module interactions, event flow, storage layers, and safety boundaries.

---

CI/CD and Required Checks

We protect main with two lightweight, user-facing checks to prevent regressions:

See docs/tiltcheck/17-branch-protection.md for the full ruleset rationale and how these map to GitHub Actions job names.

---

9.1 High-Level Architecture Diagram

┌────────────────────────────────────────────────────────────┐

│ Discord UI │

│ (Slash Commands, Buttons, Mod Tools, Ephemeral Messages) │

└───────────┬───────────────────────────┬────────────────────┘

▼ ▼

┌──────────────┐ ┌──────────────┐

│ Command Hub │ │ Event Router │

│ (Cloudflare) │ │ (Cloudflare) │

└───────┬──────┘ └──────┬───────┘

┌───────┼──────────────────────────┼───────────────────┐

▼ ▼ ▼ ▼

JustTheTip SusLink CollectClock FreeSpinScan

│ │ │ │

▼ ▼ ▼ ▼

Non-Custody Risk Analysis Bonus Engine Promo Validation

Wallet API Engine + Prediction + Prediction

│ │ │ │

└────────┴──────────────┬────────┴──────────────┬──────┘

▼ ▼

┌────────────────────────────────────────┐

│ Trust Engines │

│ Casino Trust + Degen Trust │

└───────────┬─────────────────────────────┘

▼

┌─────────────────────────────┐

│ Data Models + Storage │

│ SQLite / Supabase / KV Store │

└─────────────────────────────┘

---

9.2 Layer Breakdown (Top → Bottom)

Layer 1: User Interface Layer

TiltCheck uses Discord as the primary UI:

Benefits:

---

Layer 2: Command Hub (Cloudflare Worker Recommended)

The Command Hub handles:

It also handles outbound Discord interactions:

---

Layer 3: Event Router

A lightweight event dispatcher sending tasks to:

Event router handles asynchronous operations like:

Cloudflare Workers + queues are ideal for this.

---

Layer 4: Modules (Independent Micro-Tools)

Each module exposes:

Modules never call each other directly — only via events.

This prevents entanglement and keeps the system modular.

---

Layer 5: Trust Engines

Shared global insight layer:

1. Casino Trust Engine

2. Degen Trust Engine

Modules feed these engines with signals; engines return:

Trust engines unify the entire ecosystem.

---

Layer 6: Storage Layer

TiltCheck supports hybrid free-tier storage:

Primary Options:

Storage Decisions:

| Data Type | Storage |

|-----------|---------|

| URLs, scans | KV / SQLite |

| Casino bonus logs | Postgres or SQLite |

| User trust signals | Postgres |

| NFT identity links | SQLite |

| Promo submissions | Postgres |

| Swap attempts | KV |

| Agent funding intelligence | JSON or KV |

---

9.3 Financial Architecture (Non-Custodial)

TiltCheck NEVER holds funds.

Flow:

User Wallet → (fee deduction) → Target Wallet or Jupiter Swap

No custody means:

Fees (flat only) always go:

fee amount → founder wallet

before anything else happens.

---

9.4 Discord Architecture

Key Channels:

Key Permission Roles:

---

9.5 Module Interaction Examples

Example A: User submits free spins link

/submit

↓

SusLink scans

↓

FreeSpinScan classifies + queues for mod review

↓

Casino Trust Engine logs casino promo reliability

↓

Mod approves

↓

Bot posts to correct channel

---

Example B: User tips someone via JustTheTip

/tip @user 1 SOL

↓

Calculate flat fee

↓

User approves transaction

↓

Blockchain processes

↓

Bot posts confirmation

↓

Degen Trust Engine logs behavioral context

---

Example C: User rage spins → TiltCheck detects tilt

Aggressive chat + rapid timestamps

↓

Tilt Engine flags tilt likelihood

↓

User receives soft nudge

↓

If continued → cooldown suggestion

↓

If chosen → vault lock triggered

---

9.6 Security Architecture

TiltCheck ensures:

---

9.7 Scaling Model

TiltCheck is scalable because:

The system expands only when needed — not preemptively.

---

9.8 Future Web UI (Optional)

Eventually, TiltCheck Arena can host:

But Discord remains the primary interface until scaling demands a UI.

---

End of 9-architecture.md