Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
92 commits
Select commit Hold shift + click to select a range
b58c74c
feat(agent): add bundled known-addresses dataset for privacy scoring …
rz1989s Apr 8, 2026
9b9a880
feat(agent): add DB helpers for payment link listing, expiry, and adm…
rz1989s Apr 8, 2026
b8187c6
feat(agent): add paymentLink tool — one-time stealth receive URLs
rz1989s Apr 8, 2026
a8cfea4
feat(agent): add privacyScore tool — wallet exposure analysis (0-100)
rz1989s Apr 8, 2026
6ac3a3e
feat(agent): add threatCheck tool — OFAC, exchange, and scam address …
rz1989s Apr 8, 2026
b2adb0b
feat(agent): add invoice tool — structured payment requests with meta…
rz1989s Apr 8, 2026
7d3cfb7
feat(agent): add /pay/:id route with server-rendered payment pages
rz1989s Apr 8, 2026
665cd8f
feat(agent): add admin dashboard with auth, stats, and HTML templates
rz1989s Apr 8, 2026
7b23f2c
feat(agent): wire paymentLink, invoice, privacyScore, threatCheck too…
rz1989s Apr 8, 2026
1957958
fix(agent): address code review — expiry check on confirm, Secure coo…
rz1989s Apr 8, 2026
f101209
feat(agent): add scheduled ops CRUD helpers for crank engine
rz1989s Apr 8, 2026
7c83ae8
feat(agent): add roundAmount tool — denomination rounding for privacy
rz1989s Apr 8, 2026
290f03a
feat(agent): add crank engine — 60s scheduled ops executor
rz1989s Apr 8, 2026
b795761
feat(agent): add scheduleSend tool — delayed private sends
rz1989s Apr 8, 2026
9a54206
feat(agent): add splitSend tool — random chunk splitting with stagger…
rz1989s Apr 8, 2026
b9ab263
feat(agent): add drip tool — DCA-style private distribution
rz1989s Apr 8, 2026
c1a8511
feat(agent): add recurring tool — repeating private payments with jitter
rz1989s Apr 8, 2026
4716b04
feat(agent): add sweep tool — auto-shield incoming wallet funds
rz1989s Apr 8, 2026
058fce9
feat(agent): add consolidate tool — staggered stealth balance merging
rz1989s Apr 8, 2026
8db2b26
fix(agent): fix flaky timing tests in consolidate and split-send (mon…
rz1989s Apr 8, 2026
faadbd1
feat(agent): wire 7 time-based privacy tools + crank engine (21 total…
rz1989s Apr 8, 2026
214f066
chore: swap anthropic sdk for pi-agent-core + pi-ai + infra deps
rz1989s Apr 9, 2026
54a8bd7
feat(agent): extend db schema with 6 new tables + query functions
rz1989s Apr 9, 2026
bc1ecec
feat: add tool schema adapter — Anthropic format to Pi AI format
rz1989s Apr 9, 2026
0144a5d
feat: add EventBus — typed agent coordination layer
rz1989s Apr 9, 2026
1e5e74d
feat: add Pi AI provider config — OpenRouter for SIPHER + HERALD
rz1989s Apr 9, 2026
3693882
feat: add tool groups + routeIntent meta-tool — 4 groups, dynamic loa…
rz1989s Apr 9, 2026
305c719
feat: add AgentPool — multi-tenant agent lifecycle with eviction
rz1989s Apr 9, 2026
34eb799
feat: add SIPHER Pi agent factory — system prompt, fund-moving set, t…
rz1989s Apr 9, 2026
1f36d79
fix: move service-sipher test to packages/agent/tests/
rz1989s Apr 9, 2026
b946ce3
feat: add wallet auth — nonce signing + JWT for SSE stream
rz1989s Apr 9, 2026
ba176ce
feat: add SSE activity stream — wallet-scoped, level-filtered
rz1989s Apr 9, 2026
cc6f592
feat: add ActivityLogger — events to activity_stream with level filte…
rz1989s Apr 9, 2026
6a41db7
fix: move activity-logger test to packages/agent/tests/
rz1989s Apr 9, 2026
b7f316f
feat: add command, confirm, vault, squad API routes
rz1989s Apr 9, 2026
c7abfb6
feat: formalize COURIER identity + emit events to EventBus
rz1989s Apr 9, 2026
15b84c1
feat: wire Plan A infrastructure — EventBus, AgentPool, new routes mo…
rz1989s Apr 9, 2026
ec0cfb2
test: add Plan A integration tests — EventBus, ActivityLogger, AgentP…
rz1989s Apr 9, 2026
fa929d7
chore: add twitter-api-v2 for HERALD X agent
rz1989s Apr 9, 2026
5a79b96
feat: add X API client wrapper — Bearer token + OAuth 1.0a
rz1989s Apr 9, 2026
a53ecb1
feat: add HERALD budget tracker — cost tracking + circuit breaker + g…
rz1989s Apr 9, 2026
745278a
feat: add HERALD read tools — readMentions, readDMs, searchPosts, rea…
rz1989s Apr 9, 2026
aff30fb
feat: add intent classifier — command/question/engagement/spam classi…
rz1989s Apr 9, 2026
99a22d1
feat: add post approval queue — pending, approve, reject, auto-approv…
rz1989s Apr 9, 2026
39d8076
feat: add HERALD API routes — dashboard data + post approval endpoints
rz1989s Apr 9, 2026
3f20cd7
feat: add adaptive poller — mentions, DMs, scheduled posts with backoff
rz1989s Apr 9, 2026
f78c9f6
feat: add HERALD Pi agent factory — system prompt, 9 tools, executor map
rz1989s Apr 9, 2026
c14e3ad
fix: move herald + approval tests to packages/agent/tests/
rz1989s Apr 9, 2026
e1c0a3d
feat: wire HERALD into Express — routes mounted, poller conditional s…
rz1989s Apr 9, 2026
549ee61
fix: cap vitest to 4 forks — prevents orphan processes from parallel …
rz1989s Apr 9, 2026
0c130c6
feat: add SENTINEL configuration — env-driven scan intervals, thresholds
rz1989s Apr 9, 2026
ac815a6
feat: add SENTINEL detector — detection-to-event mapping for 6 event …
rz1989s Apr 9, 2026
12cc101
feat: add refund guard — threshold check, double-processing preventio…
rz1989s Apr 9, 2026
b5289eb
feat: add SENTINEL scanner — vault state, stealth payments, balance c…
rz1989s Apr 9, 2026
b56f4d1
feat: add SENTINEL worker — adaptive scan loop, wallet tracking, backoff
rz1989s Apr 9, 2026
fcbe504
feat: wire SENTINEL into Express — worker started, integration tested
rz1989s Apr 9, 2026
6fab2d5
design: add Guardian Command UI mockups — stream, vault, herald, squa…
rz1989s Apr 9, 2026
5cfd520
feat: install Tailwind CSS 4 + design system tokens + agent constants
rz1989s Apr 9, 2026
baaa680
feat: add API client layer — REST, SSE, wallet auth hooks
rz1989s Apr 9, 2026
0670f00
feat: add app shell — header, bottom nav, view routing, wallet providers
rz1989s Apr 9, 2026
34a8aa1
feat: add command bar — bottom sheet chat with confirmation cards
rz1989s Apr 9, 2026
73cce86
feat: add activity stream view — SSE-powered real-time feed
rz1989s Apr 9, 2026
2f72f88
feat: add vault view — balance, pending ops, activity, fee summary
rz1989s Apr 9, 2026
6b89e90
feat: add HERALD view — X activity, approval queue, DMs, budget bar
rz1989s Apr 9, 2026
be82397
feat: Guardian Command UI complete — all views, command bar, build ve…
rz1989s Apr 9, 2026
1c27190
feat: add squad view — agent status, costs, coordination log, kill sw…
rz1989s Apr 9, 2026
1f8d544
fix: verify ed25519 wallet signature before JWT issuance (closes #71)
rz1989s Apr 9, 2026
512d84d
fix: add column allowlist to updateExecutionLink to prevent SQL injec…
rz1989s Apr 9, 2026
6820fce
fix: add JWT auth to squad, herald, chat, and tool endpoints (closes …
rz1989s Apr 9, 2026
9e0e3a6
fix: add /api/activity route and extend SSE event types (closes #76, …
rz1989s Apr 9, 2026
58f7c9b
fix: rewrite herald poller to recursive setTimeout to prevent permane…
rz1989s Apr 9, 2026
8fef5ad
fix: add .unref() to session purge and crank timers (closes #79)
rz1989s Apr 9, 2026
d5e306f
fix: replace as-any casts with proper types in herald, pi, and DM too…
rz1989s Apr 9, 2026
77209d0
fix: remove duplicate test files from root tests/ directory (closes #84)
rz1989s Apr 9, 2026
7509406
fix: use env-driven network in sentinel scanner instead of hardcoded …
rz1989s Apr 9, 2026
713a2cb
fix: wrap auto-approve in transaction to prevent race condition (clos…
rz1989s Apr 9, 2026
dfd406c
fix: show vault mock data only as fallback when API data unavailable …
rz1989s Apr 9, 2026
46c6cae
fix: address low-priority issues — budget reset, refund guard, comman…
rz1989s Apr 9, 2026
8d00310
fix: wire kill switch to all agents — chat, crank, sentinel, herald (…
rz1989s Apr 9, 2026
7b8e4ba
fix: add requireOwner authorization middleware for admin routes (clos…
rz1989s Apr 9, 2026
2b9184f
fix: add graceful shutdown handler for SIGTERM/SIGINT (closes #98)
rz1989s Apr 9, 2026
518809d
fix: add wallet-scoping to confirmation endpoint (closes #95)
rz1989s Apr 9, 2026
014b39a
fix: pin JWT algorithm to HS256 and fix Bearer prefix parsing (closes…
rz1989s Apr 9, 2026
cc7dbaf
fix: add canMakeCall budget guard to write HERALD tools (closes #97)
rz1989s Apr 9, 2026
f148acc
fix: use JWT wallet as approver in herald approval endpoint (closes #…
rz1989s Apr 9, 2026
db174e1
fix: set EventBus maxListeners to prevent warning spam (closes #104)
rz1989s Apr 9, 2026
364612f
fix: cap conversation messages at 100 to prevent memory growth (close…
rz1989s Apr 9, 2026
423aaf5
fix: harden backend state management — nonce cap, JWT secret, system …
rz1989s Apr 9, 2026
127045c
fix: harden auth rate limiting, command length, and tool schemas (clo…
rz1989s Apr 9, 2026
e7a54ab
fix: improve frontend error handling, vault display, and SSE state (c…
rz1989s Apr 9, 2026
4b70cc1
fix: low-priority hardening — base58 guard, domain nonce, SSE IDs, X …
rz1989s Apr 9, 2026
da54368
fix: add isStealth type and useAuth error state (closes #123, closes …
rz1989s Apr 9, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@ coverage/
scripts/.colosseum-state.json
scripts/.sipher-agent-state.json
data/
!packages/**/src/data/
179 changes: 179 additions & 0 deletions app/designs/01-stream-view.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,179 @@
<!--
aesthetic_dna:
theme: "Cyber-Utility / Stealth Crypto"
visual_tension: "Stark contrast, zero-noise, highly dense typography-driven UI"
ui_paradigm: "Mobile-first single-column dataloop, fixed spatial headers/footers with scrolling meso-layer"
palette: "Obsidian Canvas (#0A0A0B), Dense Carbon (#141416) with High-Key Agent Spot Colors"
-->
<!DOCTYPE html>
<html lang="en" class="antialiased text-[#F5F5F5] bg-[#0A0A0B]">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no, viewport-fit=cover">
<title>Guardian Command | Sipher</title>
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&family=JetBrains+Mono:wght@400;500&display=swap" rel="stylesheet">
<script src="https://unpkg.com/@phosphor-icons/web"></script>
<script src="https://cdn.tailwindcss.com"></script>
<script>
tailwind.config = {
theme: {
extend: {
colors: {
app: { bg: '#0A0A0B', card: '#141416', border: '#1E1E22', text: '#F5F5F5', muted: '#71717A' },
agent: { sipher: '#10B981', herald: '#3B82F6', sentinel: '#F59E0B', courier: '#8B5CF6' }
},
fontFamily: { sans: ['Inter', 'system-ui', 'sans-serif'], mono: ['JetBrains Mono', 'monospace'] },
boxShadow: { 'cmd': '0 -4px 20px rgba(0,0,0,0.4)' }
}
}
}
</script>
<style>
body { overscroll-behavior-y: none; -webkit-font-smoothing: antialiased; }
.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }
.radius-exact { border-radius: 8px; }
</style>
</head>
<body class="flex justify-center w-full min-h-screen bg-black">
<main class="w-full max-w-[720px] bg-app-bg h-[100dvh] flex flex-col relative border-x border-[#1E1E22] overflow-hidden">
<header class="h-[56px] border-b border-app-border flex items-center justify-between px-4 shrink-0 bg-app-bg z-10 w-full">
<div class="flex items-center gap-2">
<i class="ph ph-shield-check text-agent-sipher text-lg"></i>
<span class="font-semibold text-[13px] tracking-widest uppercase text-app-text font-sans">Sipher</span>
</div>
<button class="flex items-center gap-2.5 bg-app-card border border-app-border px-3 py-1.5 radius-exact transition-colors hover:bg-[#1A1A1D]">
<div class="w-1.5 h-1.5 rounded-full bg-agent-sipher shadow-[0_0_0_2px_rgba(16,185,129,0.2)]"></div>
<span class="text-[12px] font-mono text-app-text">5k9Q...P2vX</span>
</button>
</header>
<div class="flex-1 overflow-y-auto no-scrollbar px-4 py-5 space-y-3 pb-6 relative z-0">
<div class="bg-app-card border border-app-border radius-exact p-3.5 flex flex-col gap-2">
<div class="flex justify-between items-center">
<div class="flex items-center gap-2">
<div class="w-1.5 h-1.5 rounded-full bg-agent-sipher"></div>
<span class="text-agent-sipher text-[11px] font-semibold tracking-widest uppercase">Sipher</span>
</div>
<span class="text-app-muted text-[11px]">2m ago</span>
</div>
<p class="text-app-text text-[14px] leading-snug">Deposited 2 SOL into vault.</p>
<div class="flex items-center gap-2 text-[12px]">
<span class="text-app-muted">TX:</span>
<span class="text-app-muted font-mono">4Hc3...5s5c</span>
</div>
<div class="mt-1">
<button class="inline-flex items-center justify-center border border-app-border bg-app-bg hover:bg-app-border transition-colors text-[11px] px-3 py-1.5 radius-exact font-medium text-app-text">View TX</button>
</div>
</div>
<div class="bg-app-card border border-app-border radius-exact p-3.5 flex flex-col gap-2">
<div class="flex justify-between items-center">
<div class="flex items-center gap-2">
<div class="w-1.5 h-1.5 rounded-full bg-agent-herald"></div>
<span class="text-agent-herald text-[11px] font-semibold tracking-widest uppercase">Herald</span>
</div>
<span class="text-app-muted text-[11px]">5m ago</span>
</div>
<p class="text-app-text text-[14px] leading-snug">Posted: "Your wallet is a diary. SIP makes it private."</p>
<div class="text-app-muted text-[12px]"><span>12 likes · 3 RTs</span></div>
<div class="mt-1">
<button class="inline-flex items-center gap-1.5 border border-app-border bg-app-bg hover:bg-app-border transition-colors text-[11px] px-3 py-1.5 radius-exact font-medium text-app-text"><i class="ph ph-x-logo"></i> View on X</button>
</div>
</div>
<div class="bg-app-card border-y border-r border-[#1E1E22] border-l-[3px] border-l-agent-sentinel radius-exact p-3.5 flex flex-col gap-2">
<div class="flex justify-between items-center">
<div class="flex items-center gap-2">
<div class="w-1.5 h-1.5 rounded-full bg-agent-sentinel"></div>
<span class="text-agent-sentinel text-[11px] font-semibold tracking-widest uppercase">Sentinel</span>
</div>
<span class="text-app-muted text-[11px]">12m ago</span>
</div>
<p class="text-app-text text-[14px] font-medium leading-snug tracking-wide">⚠ Unclaimed stealth payment: 1.5 SOL</p>
<div class="flex items-center gap-2 text-[12px]">
<span class="text-app-muted">Ephemeral key:</span>
<span class="text-agent-sentinel font-mono opacity-80">0x04def...789</span>
</div>
<div class="mt-1">
<button class="inline-flex items-center justify-center border border-app-border bg-app-bg hover:bg-[#1E1E22] hover:border-agent-sentinel/30 transition-colors text-[11px] px-3 py-1.5 radius-exact font-semibold text-agent-sentinel">Claim Now</button>
</div>
</div>
<div class="bg-app-card border border-app-border radius-exact p-3.5 flex flex-col gap-2">
<div class="flex justify-between items-center">
<div class="flex items-center gap-2">
<div class="w-1.5 h-1.5 rounded-full bg-agent-sipher"></div>
<span class="text-agent-sipher text-[11px] font-semibold tracking-widest uppercase">Sipher</span>
</div>
<span class="text-app-muted text-[11px]">15m ago</span>
</div>
<div class="flex items-center justify-between">
<p class="text-app-text text-[14px] leading-snug">Privacy score: 87/100</p>
<span class="text-app-muted text-[12px]">12% traceable</span>
</div>
<div class="w-full h-1 bg-[#1A1A1D] rounded-full overflow-hidden mt-1">
<div class="h-full bg-agent-sipher w-[87%]"></div>
</div>
</div>
<div class="bg-app-card border border-app-border radius-exact p-3.5 flex flex-col gap-2">
<div class="flex justify-between items-center">
<div class="flex items-center gap-2">
<div class="w-1.5 h-1.5 rounded-full bg-agent-courier"></div>
<span class="text-agent-courier text-[11px] font-semibold tracking-widest uppercase">Courier</span>
</div>
<span class="text-app-muted text-[11px]">20m ago</span>
</div>
<p class="text-app-text text-[14px] leading-snug flex items-center gap-2">Executed scheduled send: 0.5 SOL <i class="ph ph-arrow-right text-app-muted text-[12px]"></i> stealth</p>
<div class="flex items-center gap-2 text-[12px] mt-0.5">
<span class="text-app-muted">TX:</span>
<span class="text-app-muted font-mono">m5oJ...qVwv</span>
</div>
</div>
<div class="bg-app-card border border-app-border radius-exact p-3.5 flex flex-col gap-2">
<div class="flex justify-between items-center">
<div class="flex items-center gap-2">
<div class="w-1.5 h-1.5 rounded-full bg-agent-herald"></div>
<span class="text-agent-herald text-[11px] font-semibold tracking-widest uppercase">Herald</span>
</div>
<span class="text-app-muted text-[11px]">30m ago</span>
</div>
<p class="text-app-text text-[14px] leading-snug">Replied to @privacy_maxi on X</p>
<div class="bg-app-bg border border-[#1E1E22] radius-exact p-2 mt-1 relative">
<div class="absolute w-[2px] h-[calc(100%-16px)] bg-[#1E1E22] left-2.5 top-2"></div>
<p class="text-app-muted text-[12px] italic pl-3 relative pr-1">"Stealth addresses solve this completely. By generating ephemeral keys per transaction, the link between sender and receiver is severed on-chain."</p>
</div>
</div>
<div class="h-2"></div>
</div>
<div class="shrink-0 bg-[#0A0A0B] shadow-cmd relative z-20 border-t border-app-border pb-[env(safe-area-inset-bottom)]">
<div class="px-4 py-3">
<div class="bg-app-card border border-app-border radius-exact flex items-center px-3 py-2 cursor-text transition-colors hover:border-[#2C2C30]">
<div class="flex-1 flex items-center gap-2">
<i class="ph ph-terminal-window text-app-muted text-base"></i>
<span class="text-app-muted text-[13px]">Talk to SIPHER...</span>
</div>
<div class="border border-app-border bg-app-bg px-1.5 py-[1px] rounded text-[10px] text-app-muted font-mono font-medium tracking-wide">⌘K</div>
</div>
</div>
<nav class="flex w-full px-2 pb-1 border-t border-[#1E1E22]/50">
<button class="flex-1 flex flex-col items-center justify-center py-2.5 gap-1 text-app-text">
<i class="ph-fill ph-waves text-[20px]"></i>
<span class="text-[10px] font-medium tracking-wide">Stream</span>
</button>
<button class="flex-1 flex flex-col items-center justify-center py-2.5 gap-1 text-app-muted hover:text-[#CCC] transition-colors">
<i class="ph ph-vault text-[20px]"></i>
<span class="text-[10px] font-medium tracking-wide">Vault</span>
</button>
<button class="flex-1 flex flex-col items-center justify-center py-2.5 gap-1 text-app-muted hover:text-[#CCC] transition-colors relative">
<i class="ph ph-broadcast text-[20px]"></i>
<span class="text-[10px] font-medium tracking-wide uppercase">Herald</span>
<div class="absolute top-2 right-[25%] w-1.5 h-1.5 rounded-full bg-agent-herald"></div>
</button>
<button class="flex-1 flex flex-col items-center justify-center py-2.5 gap-1 text-app-muted hover:text-[#CCC] transition-colors">
<i class="ph ph-users-three text-[20px]"></i>
<span class="text-[10px] font-medium tracking-wide">Squad</span>
</button>
</nav>
</div>
</main>
</body>
</html>
Loading
Loading