Spaces:
Sleeping
Sleeping
Commit History
-
Upload frontend/src/index.css with huggingface_hub
Verified signature343e8dc -
feat: instant demo mode, inline results after attack, 3-option launch modalβ
- Modal now has 3 options: Instant Demo (3s), Full Demo (7s), Live on HF Space - Instant mode compresses all battlefield timings 7x (3s total vs 21s full) - Typewriter skips animation in fast mode β shows payload immediately - After attack completes: InlineResults shows 5 stat chips + reward curve + bypass bars right on the attack page (no tab switch needed) - 'See all 5 plots' button links to Training Results tab - fast-badge indicator in section header when instant mode is active Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>3191547 -
feat: training results dashboard with stats cards, comparison table, and plotsβ
- 6 stat cards: GRPO steps, peak reward, PG2/FW bypass %, task success, training time - Baseline comparison table: handcrafted vs zero-shot vs InjectArena RL - All 5 training plots with titles, captions, and graceful loading state - PlotImg component handles loading/error states cleanly - Real numbers from 300-step A100 run and 24 evaluated traces Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>474639f -
feat: launch mode modal with demo vs live options and time estimateβ
- Clicking 'Launch Attack' now opens a modal with two options: 1. 'View Pre-Recorded Demo' β instant, replays real A100 trace 2. 'Run Live on HF Space' β calls /reset + /step API, shows time estimate based on selected steps Γ 21 s/step (real defense benchmark) - formatDuration() converts seconds to human-readable (seconds/minutes/hours) - Live mode shows pulsing status bar while API call is in flight - Falls back to demo result if API call fails (Space in replay mode) Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>d882fcd -
feat: battlefield visualization β attacker/firewalls/agent with live reward graphβ
- Full dark-theme UI rewrite with neon terminal aesthetic - Three-column battlefield: Attacker β beam β [PG2 | SecAlign | LlamaFirewall] β Agent - Animated payload beam with per-wall hit effects (green bypass / red blocked) - Walls show scan ray during scanning phase, BYPASSED/BLOCKED badges after - Live reward graph (SVG) replays 30 real training points from trainer_state.json during each attack; Y-axis 0.32-0.47 so the learning signal is visible - Typewriter effect shows real payload from committed trace files - Real agent output and blocked-at reason displayed on agent side - Result summary with per-layer verdict chips + insight text - Dashboard tab serves actual plot PNGs from /plots/ - Real bypass numbers embedded from 24 evaluated traces Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>ff4fe4a -
feat: real continuous GRPO reward curve + 5-plot dashboardβ
- data/trainer_state.json: 30 log entries from the actual 300-step GRPO run on Colab A100 (manually retrieved from Drive) - regenerate plots from real training data: - reward_curve.png: continuous mean-reward + Β±std band, 10-step granularity (replaces the previous discrete bypass-vs-step-count chart) - kl_loss_curve.png: KL divergence + policy loss on twin axes - completion_stats.png: mean length + clipped_ratio (the 100% cap signal) - Dashboard now shows 5 plots + a live-stats card with proper captions matching what each plot actually depicts Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>723a54a
-
feat: launch-mode modal (recorded vs live) + reframed success cardβ
- LaunchModeModal: clicking Launch Attack now opens a dialog asking whether to view the pre-recorded result (instant) or run live training on Colab (β18s/step estimate, links to colab_runner.ipynb) - Time estimator calibrated from real Colab measurement: 300 steps = 1.5 hrs - Modal also explains why live training isn't hosted on the Space (no GPU on free tier, blocking other users on paid) - ResultCard reframed: leads with classifier-bypass win, removes the SecAlign β row, demotes task-success to a 'next milestone' footnote - Retry path skips the modal (user already chose recorded once) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>32513fb -
feat: wire frontend to real API, ship plots, multi-stage Docker buildβ
Frontend (React + Vite) - Add to git (was untracked); .gitignore excludes node_modules/ and dist/ - App.jsx now calls real backend endpoints: - GET /api/attack-types β populates attack-type grid - GET /api/stats β drives hero badges (real numbers, no claims) - GET /api/highlight β hero animation payload preview - POST /api/attack β fetches the real trace JSON - timeline events from the trace drive the pipeline animation - outcome.broke_pg2 / broke_fw / task_succeeded / blocked_at drive the success / failure card (no more hardcoded "300 steps = success") - Plot dashboard now renders /plots/*.png from the FastAPI server (with a stats summary card backed by /api/stats) - vite.config.js: dev proxy to :7860 for /api, /plots, /health Backend - env/server.py: serves frontend/dist/ when present (StaticFiles with html=True for SPA + an /assets mount for Vite chunks); falls back to source dir or JSON index when the frontend hasn't been built Docker - Muβ¦5cceafb