Releases: harshitthek/paint-code-rl
Releases · harshitthek/paint-code-rl
Release list
v0.2.0: Multi-Signal Visual RL, Dual-GPU Saturation & Interactive Cyclic Training
What's Changed in v0.2.0
🎨 Multi-Signal Verifiable Visual Reward Matrix
-
5-Tier Hierarchical Scoring Engine: Evaluates generated generative art with linear weighted composite signals:
- Compile Gate (0.10): Categorizes outcomes (SUCCESS, PARSE_ERROR, RUNTIME_ERROR, NO_CANVAS, TIMEOUT).
- Prompt Alignment CLIP (0.35): Zero-cost ViT-B/32 multimodal semantic cosine similarity.
-
Visual Richness (0.25): Edge variance (
$\nabla^2 I$ ), color entropy, palette spread, and anti-barcode anisotropy. - Brush Utilization (0.15): Validates authentic natural media brush primitives with anti-cheat protections.
- Global Aesthetic (0.15): Compositional harmony and color richness scoring.
- Explainable Diagnostic Scorecards: Real-time critique explaining why generated artwork passed or failed.
⚡ Dual-GPU Saturation & --max Mode
- Dual-GPU Distributed Training: Auto-probes multiple GPUs (e.g. Kaggle 2x Tesla T4), distributing policy generation and CLIP evaluation across ranks with NCCL gradient synchronization.
-
Hardware Optimizer: Dynamically configures
PYTORCH_CUDA_ALLOC_CONF="expandable_segments:True", TF32 tensor cores, and CuDNN benchmarking. -
Per-Rank VRAM Scaling: Batch sizes (
$G=4 \rightarrow 6/8$ ) and token budgets scale to available single-device VRAM.
🔄 Interactive Cyclic Continuous Training
-
Human-in-the-Loop Cycles: Train in discrete, inspectable cycles (
--steps-per-cycle 25). -
Dynamic Temperature Annealing: Smooth exponential decay from
$T=0.85$ (creative exploration) down to$T=0.55$ (stable convergence). -
Live HTML Dashboard: Auto-refreshing visual dashboard (
artifacts/dashboard.html) with interactive loss/temperature charts and rendered artwork galleries.
🛡️ Headless WebGL Sandbox Hardening
- Concurrent Batch Renderer: High-throughput Puppeteer daemon (
POST /render_batch) with in-memory base64 streaming. - Lexical Sandbox & Token Balancing: JavaScript tokenizer balances nested delimiters while ignoring delimiters in strings, regex literals, and comments.
- Source Exfiltration Protection: Interception blocks outbound HTTP requests and local filesystem exfiltration (
server.js). - Token-Authenticated Shutdown: Direct container invocation enforces fail-fast token authentication.
🚀 Hub Models & Cloud Workflows
- Hugging Face Model: Pretrained LoRA weights published at
HarshittheK/paint-code-rl-lora. - Kaggle GPU Notebook: 1-click cloud driver at
notebooks/kaggle_paint_rl.ipynb. - Publishing Utility: CLI tool
scripts/upload_model.pyfor automated publishing to Hugging Face and Kaggle Models viakagglehub.
🧪 Verification & Test Coverage
- 148 / 148 Tests Passing (100% Green):
107Python Unit, Integration, Hardening & Telemetry Tests (pytest)10Node.js Sandbox Security Smoke Tests (npm test)10WebGL / p5.brush Visual Corpus Tests (node test_corpus.js)21WebGL Adversarial Stress Tests (node test_adversarial_corpus.js)0Secrets Found (python scripts/tools/secret_scan.py)