A complete, production-ready autonomous AI coding agent platform. 80+ server modules, 5+ LLM provider integrations, native IDE bridge, multi-user billing, full CI/CD. Delivered as full source code — no black boxes, no dependencies on external infrastructure.
Three-tier architecture: browser-based SPA frontend ↔ Node.js/Express backend ↔ local Bridge daemon on the user's machine.
┌─────────────────────────────────────────────────────────────────────┐
│ USER'S BROWSER (React SPA) │
│ Chat.tsx ~5,900 lines · NarratedMessage.tsx · ConnectorsPanel │
│ ThinkingGlassPanel · ChatInput · Sidebar · Admin Panel │
└───────────────────────────┬─────────────────────────────────────────┘
│ WebSocket + HTTPS
┌───────────────────────────▼─────────────────────────────────────────┐
│ SERVER (Node.js + Express) │
│ ts-node-dev · port 3500 · better-sqlite3 · Vercel AI SDK │
│ │
│ ┌──────────────────────────────────────────────────────────────┐ │
│ │ 80+ Server Modules (src/server/) │ │
│ │ ┌──────────┐ ┌──────────┐ ┌──────────┐ ┌─────────────────┐ │ │
│ │ │ Agent │ │ Session │ │ Power │ │ Prompt Factory │ │ │
│ │ │ Loop │ │ Manager │ │ Tools │ │ + Tiered System │ │ │
│ │ └──────────┘ └──────────┘ └──────────┘ └─────────────────┘ │ │
│ │ ┌──────────┐ ┌──────────┐ ┌──────────┐ ┌─────────────────┐ │ │
│ │ │ Billing │ │ Auth │ │ Bridge │ │ Connectors │ │ │
│ │ │ Engine │ │ JWT+OAuth│ │ Manager │ │ WhatsApp+Chrome │ │ │
│ │ └──────────┘ └──────────┘ └──────────┘ └─────────────────┘ │ │
│ └──────────────────────────────────────────────────────────────┘ │
└───────────────────────────┬─────────────────────────────────────────┘
│ WebSocket (ws://127.0.0.1:8765)
┌───────────────────────────▼─────────────────────────────────────────┐
│ BRIDGE DAEMON (Node.js) │
│ Installed on user's machine · stdio+WebSocket · File read/write │
│ Shell execution · Browser automation (Puppeteer) · ADB │
│ Downloads: ~8MB · 0 dependencies · Self-contained EXE on Windows │
└─────────────────────────────────────────────────────────────────────┘
Every dependency, every version, every architectural decision.
| Layer | Technology | Version | Purpose |
|---|---|---|---|
| Runtime | Node.js | ≥20.x | Server + Bridge execution |
| Language | TypeScript | 5.3+ | Full stack type safety |
| Backend Framework | Express | 4.x | REST API + middleware |
| Real-time | ws (WebSocket) | 8.x | Bidirectional streaming |
| Database | better-sqlite3 | 11.x | Embedded SQLite (WAL mode) |
| AI SDK | Vercel AI SDK | 5.x | streamText + tool calling |
| Frontend | React + Vite | 18 + 5.x | SPA with HMR |
| LLM Providers | Anthropic, Google, DeepSeek, Groq, OpenAI | Latest | Modular provider factory |
| Auth | JWT + bcrypt | — | Cookie-based + Bearer token |
| Billing | Custom engine | — | Atomic transactions, BYOK, outcome pricing |
| Dev Server | ts-node-dev | 2.x | Auto-restart on file change |
80+ modules averaging ~300 lines each.
Key modules:
session-manager.ts — 4,800 lines (agent loop)
ws-handler.ts — 2,800 lines (WebSocket router)
power-tools.ts — 1,000 lines (tool definitions)
prompt-factory.ts — ~320 lines (system prompt builder)
backup-orchestrator.ts — backup triggers
verification-gateway.ts — 5-layer verification
task-manager.ts — background task management
React 18 SPA with Vite build.
Key components:
Chat.tsx — 5,900 lines (main chat UI)
NarratedMessage.tsx — 1,500 lines (message rendering)
ChatInput.tsx — file upload, voice, terminal
TopBar.tsx — bridge status, balance, mode selector
AdminUserCards.tsx — 500 lines (ops inbox)
Sidebar — projects, apps, settings, usage
Standalone Node.js daemon (~800 lines).
Capabilities:
cmd-handler.ts — process spawning + streaming
fs-handler.ts — file read/write/list/delete
browser-handler.ts — Puppeteer automation
adb-handler.ts — Android control (USB/Wi-Fi, emulators)
desktop/ — computer use on Windows: screen reading (UI Automation + screenshot) and guarded mouse/keyboard input
record:* — relays Chrome skill recordings; project snapshots and file diffs for a recording
Self-contained EXE on Windows (pkg bundling).
0 runtime dependencies — ships standalone.
We leverage client-side speculation and "dead time" (typing pauses and project load times) to hide latency and eliminate round-trips without altering the core agent architecture.
Optimistic Rendering: The chat UI updates instantly upon pressing send.
Draft Auto-Save: localStorage saves user drafts on a 400ms debounce, keyed safely by project ID to prevent cross-bleed.
Instant @file Autocomplete: The file graph is eagerly fetched and cached to React state immediately upon project load, ensuring zero-wait autocomplete.
Pre-Warmed Connections: While the user types, the backend fires a tiny pre-flight request to the likely AI provider to open the TLS/HTTP2 connection ahead of time.
Eager System Prompts: buildProjectDigest and buildStaticSystemPrompt are pre-computed in the background the instant a project is opened, hiding the multi-second indexing cost.
Precomputed Forecasts: The token forecast is eagerly generated during the typing debounce, skipping the pre-run estimation delay.
Advisory Semantic Peek: During typing pauses the speculative cache checks SUNy’s own local semantic cache. When the same question was answered before, that answer is used and no model is called (Zero-Latency Hit).
Tier-Aware Loading State: The backend returns the predicted tier (e.g. simple vs complex) during typing, allowing the UI to instantly display context-aware loading states ("Thinking..." vs "Architecting...").
SQLite via better-sqlite3 with WAL mode. 26+ tables across 110+ schema migrations.
db-migrations.ts — 110+ numbered migrations. Each migration is idempotent (IF NOT EXISTS). WAL mode for concurrent reads. Foreign keys enabled via PRAGMA.
The core agent loop orchestrates 10 engine layers, each with clear single responsibility.
| Engine | File | Responsibility |
|---|---|---|
| Agent Loop | session-manager.ts | Orchestrates model calls, tool execution, retry logic, provider fallback chain |
| WebSocket Router | ws-handler.ts | Routes user/bridge messages, builds system prompt, handles billing, verification |
| Quote & Settlement Engine | task-quote.ts | Computes statistical P80 upfront quotes, loss ceiling caps and outcome settlements (never above the unguaranteed price), and signs cryptographic receipt chains |
| Skills System | skill-loader.ts | Loads 29 engineering & design disciplines from disk, dual-axis routing by phase and topic |
| Why Engine | why-engine.ts | Causal code memory: records why code exists (fix evidence from tool steps, protective comments) and guards deletions inside the file tools |
| User Skills | user-skills/ | Per-user and per-project skills: SKILL.md bundles, versions, review-before-activate drafts, run tracking and health, save-a-run traces, skill recordings (Chrome, SUNy commands, project file diffs, notes, pauses) with a free pre-model review (noise, inputs, gates, questions), test-before-save, zip import/export |
| Android Control | android/ | adb over USB/Wi-Fi via the Bridge: UI tree, touch and text, app management, build-install-run loop, crash-to-source mapping, device health, safety gate for destructive actions |
| Computer Use | desktop/ | Desktop apps on the user's Windows PC via the Bridge: element list from UI Automation plus a screenshot, click/type/key/scroll/focus/open, view-id rule (no action on a stale look), target check under the pointer, user-input pause, changed-detection, three-strikes loop guard, batched steps, typed passwords hidden from the UI. One long-running PowerShell helper per Bridge. PRO only; on by default (project switch to turn off; no-project chats ask once per chat); on-screen SUNy frame while active; gated by the ordinary permission policy |
| Prompt Factory | prompt-factory.ts | Assembles tiered system prompts from 15+ template sections |
| Power Tools | power-tools.ts | Defines 20+ tools (file, bash, web, ADB, precision edit, ask_question) |
| Model Router | agent.ts | Provider factory, key management, vision model resolution, BYOK support |
| Billing Engine | billing.ts | Atomic transactions, tier pricing, BYOK zero-cost, daily limits, refunds |
| Verification Gateway | verification-gateway.ts | 5-layer independent verification + adversarial re-verification after every task |
| Cross-Project Learning | cross-project-learning.ts | Patterns learned in one of the user’s own projects, offered in another — per account, never across accounts |
User Message → ws-handler.ts → classifyRequestTier()
→ Phase Planning & Statistical Quote Engine (if Guaranteed Task accepted)
→ runAgentLoop() → modelLoop (iterates providers):
1. streamText() → LLM generates text + tool calls (or Generative UI preview)
2. Auto-execute tools sequentially
3. Auto-retry on empty output (up to N times)
4. Provider fallback on failure (retaining working context across model switch)
5. Tier escalation on all providers exhausted
→ Verification Gateway (5 objective layers + adversarial re-verification)
→ Settlement & Billing (capped at quote / failed tasks never above the unguaranteed price / loss ceiling absorbed)
→ Append signed cryptographic receipt to immutable hash chain
→ stream_end → user sees verified result & receipt card
IDE-grade terminal sessions and perfectly safe file mutations.
power-tools.ts: shell_start, shell_run
SUNy spawns long-lived interactive terminals (PowerShell or Bash) that stay alive across multiple commands.
Run cd src and the next command stays in that directory.
Supports real-time streaming partial output on timeouts, and automatic interceptors for prompts (e.g. automatically answering "y" to "Are you sure?").
transaction-manager.ts: begin_transaction
Multi-file edits are now perfectly safe. SUNy automatically snapshots files before mutating them.
If an agent makes a mistake halfway through a complex refactor, a single rollback_transaction command puts every file changed inside the transaction back exactly as it was before the transaction began.
session-file-cache.ts: getOrReadFileIncremental
Zero-cost re-reads. When SUNy tries to read a file it already read, the Bridge performs a sub-millisecond stat check.
If the size and modified timestamp haven't changed, the file isn't downloaded again, saving huge amounts of LLM context tokens and latency.
Modular provider factory with automatic failover, prompt caching, and BYOK support.
agent.ts:buildLanguageModel() — switch-based factory:
Anthropic → createAnthropic() with prompt caching
DeepSeek → createDeepSeek() with auto prefix caching
Groq → createGroq() with Llama models
OpenAI → createOpenAI() for DALL-E + GPT
Gemini → createGoogleGenerativeAI() free tier
OpenRouter → createOpenAICompatible()
Custom endpoints → baseURL per provider
Two caching strategies:
Anthropic: cacheControl: { type: 'ephemeral' } on static system prompt prefix (~90% cost savings on cache hits).
DeepSeek: Automatic prefix caching — no markers needed.
One prompt per run: the system prompt and tool set are fixed before the first step and never change within a run, so every later step is a cache hit on everything but its own new output.
Three tiers via tiered-system-prompt.ts:
simple (~700 tokens) — role + behavioral laws + communication rules
medium (~3K tokens) — + capabilities + bridge + MCP + workflow
complex (~8K tokens) — + skill index + training + instincts + continuity
Classified by request-tier-classifier.ts (regex-based, sub-ms latency).
api_keys table: provider, mode, priority, model override.
Each mode has a fallback chain ordered by priority.
BYOK: Users can bring their own API keys. Billing engine detects BYOK keys and logs zero-cost usage.
Health checks: Background cron validates keys — deactivates invalid ones automatically.
The agent that performs the work cannot be the agent that evaluates the work. Independent verification gating billing.
Agent A (Builder) finishes
→ Gateway runs 5 independent layers:
L1: Build Check — tsc/eslint (0 errors required)
L2: Runtime Check — npm run dev (app starts)
L3: Smoke Test — the app's page loads with its real title and content
L4: Functional Test — npm test (tests pass)
L5: Agent B (Judge) — independent AI with CLEAN context
— never sees Agent A's reasoning
— only sees task + output
→ All PASS → bill user → signed receipt stored
→ Any FAIL → no charge → return for retry
A simulated UX reviewer with its own persona. Name a component (plus the page URL if your dev server runs) and Reen reads its code, looks at a live screenshot when reachable, and returns rated UX observations. One click hands them to SUNy to fix. Runs only when you ask — zero background token spend.
Every task generates a SHA-256 signed receipt recording all verification layer results, written to the verification_receipts table before the user ever sees the output.
Delegated AI work is sealed into chained, tamper-evident records carrying a cryptographic fingerprint of all file contents. You don't have to trust the AI's claims; you can mathematically verify them.
Billing is gated on verification. If the gateway returns FAIL, the atomic billing transaction is rolled back. User pays nothing.
Users can dispute charges. The system shows the signed receipt. Admins can review, refund, or reject via the operations inbox.
SUNy reads and explains compiled software, not just source — and builds from it. Hand her an APK, a shipped JavaScript bundle or a live website as your prototype: a native engine reads its screens, navigation, API surface, forms and strings, derives a build brief, and SUNy builds an original implementation with your name and branding. No Ghidra, no JADX, no toolchain to install: it ships in the core, and every finding comes with the evidence behind it.
analyze_file("build/app.apk")
→ Identified by magic bytes (extension ignored)
→ Android APK · 214 entries · AndroidManifest.xml, classes.dex, resources.arsc
→ Largest members listed (no decompression)
analyze_file("dist/bundle.js")
→ Minified JavaScript · webpack · ~1,840 modules
→ Frameworks: React, Axios
→ 23 endpoints, 11 route-like paths
→ 2 strings shaped like secrets — flagged by location, values never shown
analyze_file("bin/service")
→ ELF 64-bit executable (x86-64) · entry 0x401000
→ Links: libc.so.6, libssl.so.3 · 312 imported symbols
→ Every finding carries its evidence; the report states what it could NOT determine
From prototype to product. Point SUNy at an APK, a bundle or a URL. She extracts the screens, navigation, API calls, forms and features into a structured brief, then builds your own version of it — original code, your assets, your brand. What any agent guesses from a description, SUNy reads from the real thing.
Identifies by content, not extension. ELF, PE and Mach-O binaries; ZIP, JAR and APK archives — including the manifest and code tables inside an APK; JavaScript bundles; images and documents. Header parsing recovers architecture, linked libraries and imported symbols.
When the inventory is not enough. A built-in skill walks SUNy through standard command-line tools on your own PC: unpack an Electron app.asar, list a Go binary's modules, decompile an APK's code, turn WebAssembly into text, extract a PyInstaller executable. PowerShell on Windows, the shell on macOS and Linux; always on a copy, with any needed tool named before it is installed.
It reads bytes. It never runs the target and never unpacks it, so inspection cannot trigger the thing being inspected. Archive members are listed from the directory, not extracted.
Each finding records the bytes, offsets or counts behind it, and every report ends with what the pass could not determine. "No evidence of X" is never dressed up as "X is absent".
Flags strings shaped like API keys, tokens, JWTs and private keys by their location — so you can find a leaked credential in a shipped build. The values themselves are never printed.
For a shipped web app: detects minification, names the module system and frameworks, and extracts the endpoints and routes it talks to. Understand a front-end you have the source-map-less build of.
Built for software you own or are cleared to examine. SUNy inspects and explains; it does not defeat the protections around other people's software. You bring the authorization; SUNy brings the lens.
Multi-layer security: injection guard, CSP headers, credential vault, audit trail.
injection-guard.ts — scans every user message for prompt injection attempts before it reaches the agent loop. Block on high confidence.
credential-vault.ts — encrypted storage for connector credentials (WhatsApp, WordPress). AES-256-GCM with per-user keys.
operation-audit.ts — every bridge command logged with userId, timestamp, and result. Forensic traceability.
CSP headers blocking inline scripts. XSS prevention via sanitizer.ts. Secret registry prevents API key leakage in chat.
Per-user WebSocket rate limiter (60 msg/min). Per-user turn queue prevents concurrent requests. AbortController for cancellation.
Bridge runs on user's machine, not the VPS. All file operations go through Bridge — never touch VPS filesystem. Process sandboxing via spawn.
Complete dev workflow: concurrent Vite + ts-node-dev, SQLite-backed, Docker-ready.
npm run dev — concurrently starts Vite HMR (port 5173) + ts-node-dev backend (port 3500).
npm run build:renderer — production Vite build (1,530 modules, ~740KB JS).
Auto-restart on file changes via ts-node-dev --respawn.
Single-server deployment. nginx reverse proxy, WAL-mode SQLite (no Postgres needed).
Static frontend served from src/renderer/dist/.
Environment-specific config via .env.
Background cron: session cleanup, API key health checks, cache purging.
| Command | What it does |
|---|---|
npm run dev | Start development server (Vite + backend concurrently) |
npm run build:renderer | Production frontend build (Vite, ~10s) |
npm start | Production start (serves built frontend) |
ts-node-dev src/server/index.ts | Start backend only (auto-restart) |
1,044 source files audited by Opus — verified, clean, publish-ready.
Each server module has a single responsibility. Average module size ~300 lines.
No circular dependencies. Clear import hierarchy: index.ts → ws-handler.ts → session-manager.ts → engines.
Full TypeScript strict mode. Interfaces defined per module. Zod schemas for all API inputs. Vite build catches type errors.
Agent loop catches all provider errors with automatic fallback chain. WebSocket errors are isolated per-user. Bridge errors never crash the server.
SUNy's get_overview(), get_context(), and get_risk() tools return a file's context in one call: its functions and exports with line numbers, the files that import it (ES import or CommonJS require), its git risk from commits, reverts and emergency fixes, co-change partners, authors and a test-gap hint — plus a project overview of languages, size, entry points and hot spots. One round-trip instead of a chain of searches, reads and git commands.
Every bash command output is automatically distilled before the LLM reads it: errors move to the top, PASS lines collapse into a count, duplicate lines are removed, and long output is truncated with expandable [distill#] markers. The LLM can call distill_expand(ref) to see the full original output. Saves 60-90% tokens on test/grep/build output with zero information loss.
Progressive milestone billing via declare_checkpoint(). The agent declares checkpoints at natural task milestones (scaffold, logic, integration, final). Each is verified by automated tests — build check, unit tests, smoke tests. On pass, the user is billed incrementally for verified work. Failed checkpoints cost nothing. Maximum 4 per task. System-defined criteria prevent agent gaming.
SUNy responses collapse to a compact summary by default — showing preview text and stats (tools used, files changed, tokens, duration). Click to expand the full response. Choose in Settings: collapsed for long bubbles only (default), always expanded, or expand only the latest reply. Keeps conversations clean without losing detail.
Instead of blindly retrying tool failures, SUNy's Behavioral Law 9 routes by error type: rate limits wait and retry once then switch provider, timeouts double and retry, ENOENT searches for the file rather than guessing, permission errors report what needs access. After 3 consecutive different failures, SUNy stops and asks the user. Inspired by Claude Code's prompt architecture.
Two new behavioral laws embedded in SUNy's core prompt. LAW 10 — Check Before You Create: Before writing any new function/module, SUNy searches the existing codebase using grep_search, find_files, or get_context(). Existing code is reused; partial overlaps trigger refactoring of existing code instead of duplication. LAW 11 — Learn From User Corrections: Every user correction ("no, use X instead", "that already exists") is auto-detected by the WebSocket handler, stored as a behavioral rule with source user_correction, and injected into future prompts. User corrections become the highest-quality labeled examples in the system — automatically captured, no manual effort needed. Inspired by research on self-learning agents and the "vibe coding" architectural critique.
Every account gets its own vault: a random 256-bit data key and an X25519 key pair. The data key is stored only wrapped — by a key derived from the user’s password (scrypt) and by a key derived from a recovery code shown to the user once. The password itself is never stored (only its bcrypt hash), so nothing in the database opens the vault. At sign-in the vault is opened and a copy is wrapped for that browser with a random secret that lives only in an httpOnly cookie; the server keeps the wrapped copy, never the secret.
What is locked with the user’s own key (AES-256-GCM, user id bound into every value): chats and saved chats, tool inputs and outputs (what SUNy read and wrote in the user’s files), the work log, memories, learned rules and blueprint, task history, saved pages, snapshots, plans, goals, ratings, recipes, image prompts and server-side gallery images, session notes. Data written while the user is away (a page saved from Chrome) is sealed to their public key and opens at their next sign-in. Exact-match lookups use a keyed HMAC, and the full-text indexes that kept words readable are gone: search opens the user’s rows and ranks them in memory.
What uses the server key instead, because it must run while the user is away or be shared: scheduled agents, WhatsApp, team chats and voice notes, client tickets, automations, delegations, queued jobs, skills. What stays readable: account and billing data (username, plan, balance, usage with no content) and project names and folders. The server log records sizes and timings, never content.
Honest limits: while a user is signed in, their opened key is in the running server’s memory, so someone who changed the server’s code could capture what that user does from then on — nothing already stored can be read that way. Code a task reads is still sent to the AI model. After an admin password reset only the user’s recovery code unlocks their data; every such event is listed for the user in Settings → Security.
After 5 minutes of user inactivity, SUNy fires an async dream generation pass against the current session's message history. A dedicated LLM call (using the cheapest available model) distills the session into a structured DreamSummary JSON object: decisions_made[], facts_learned[], open_questions[], current_goal, danger_zones[]. Max 5 items per array, max 20 words each. The summary is stored in a new dream_summaries SQLite table (pruned to last 5 per user+project). On the next session, formatDreamContext() renders it as a <400-token system prompt prefix — giving SUNy instant memory of what happened. Directly remediates Failure Cluster #3 (long-horizon degradation) from arXiv:2607.05775. Inspired by nanobot's /dream architecture (HKUDS/nanobot, 45k ⭐). The dream timer is cancelled on any incoming user message via cancelDream().
Task memory, the answer cache and decision provenance run on an engine built into SUNy, with no outside service. Text becomes a 1,024-dimension vector from Unicode words and character trigrams (Arabic and English alike), stored next to everything else in SUNy’s SQLite database and searched with exact cosine similarity. No embeddings API, no vector database server, nothing downloaded, nothing sent anywhere, no cost per call.
What it powers: a risk note before a task that looks like earlier ones in the same project (“this was tricky before”); instant answers only to the same question asked again (near-identical vector and the same meaningful words, so “closures” never returns the answer about “promises”; personal questions are never cached); and trace_origin, which finds the change behind a behaviour and feeds project handovers.
Honest limit: it matches shared words and parts of words. A rewording with no word in common may be missed; an in-process model can replace the vectoriser later without changing anything that uses it. It replaced an earlier Voyage + Qdrant setup that depended on two outside services.
Behavioral Law 12 addresses arXiv:2607.05775 Failure Cluster #2 (planning and constraint-satisfaction failures). Before executing any multi-step plan, SUNy must: (1) enumerate all stated constraints (file must exist, API must be reachable, dependency must be installed), (2) verify each against current state using its tools (file_read, run_command, grep), (3) if all are satisfiable — proceed, (4) if any constraint is provably unresolvable — HALT, state which constraint is violated, propose an alternative plan, and ask the user. Examples: "Edit src/api/auth.ts" when that file doesn't exist → search for the real file first. "Use the useUser() hook" when that hook is absent from the codebase → clarify before writing. "Push to main" on a detached HEAD → fix git state first. The law explicitly cites the academic finding that "failures compound nonlinearly with task length" — a wrong assumption in step 1 cascades into errors in steps 2–5. Stop early, save work.
Extended LAW 6 — Trust but Verify at every step: after file edits, run tsc --noEmit. After starting a server, run curl health. On verification failure: quote the error, diagnose root cause, fix, then verify again. If verification fails 3 times, escalate to user. Graceful degradation: when a direct approach fails, SUNy pivots instead of giving up. Strict error parsing: quote exact stderr before proposing any fix — never skip diagnosis. Combined with environment awareness (OS, shell type, Node version) and async execution awareness for long-running commands.
SUNy pre-processes every user message before the LLM sees it — detecting 4 anti-patterns (vague tasks, missing success criteria, context-less continuations, overly short requests) and injecting clarifying structure. Zero tokens, zero LLM calls. Optional via enhance_prompts setting (default ON). Combined with shared project language: if your project has a CONTEXT.md file, SUNy injects it into every session so the agent uses your exact terminology.
Use file_write with temp: true and intermediate scripts route to .suny/temp/ — auto-deleted when the task finishes. No more test_suny33.py or check_env.bat cluttering your project root. The .suny/ directory is auto-gitignored. Configurable via cleanup_temp_files setting (default ON). Each project also has a 🧹 Clear temp files action that empties that project's .suny/temp only — never another project, never your code — and waits while a task is still running.
Connect your own dashboard to SUNy. A dedicated /ag-ui WebSocket endpoint streams the agent's live activity as AG-UI-style events (a stock AG-UI/CopilotKit client may need a small adapter) — RUN_STARTED, ordered TEXT_MESSAGE_CONTENT chunks (with sequenceId), TOOL_CALL_START/OUTPUT, STATE_SNAPSHOT, and RUN_FINISHED — with proper runId/messageId threading. The built-in SUNy UI stays untouched, and every connection is authenticated with your SUNy session token via Authorization: Bearer. Build your own live dashboard or embed SUNy's progress in your product.
Settings screens are where features go to hide. Say “switch the interface to Arabic”, “set this project’s default mode to Claude”, “turn off auto-approve” or “set the per-task budget to 500 credits”, and SUNy makes the change — after showing you a confirmation that names the setting, its current value and the new one. Nothing is written unless you accept, and what you approve applies immediately, with no reload.
An allowlist, not a passthrough. SUNy can only touch settings on a fixed, audited list; a key that is not on it cannot be written, whatever is asked for. That boundary exists because an agent reads untrusted text all day — READMEs, issues, web pages, saved captures. Without it, a single line buried in a repo could switch off your approval prompts.
Your request, not a document’s. SUNy will not change a setting because a file or a page told her to. She reports what the text asked for and leaves it alone. A confirmation dialog is no defence on its own: you cannot tell one raised because you asked from one raised because a document said so.
Opt out by voice; opt in deliberately. Memory, cross-device memory and cross-project learning can all be switched off just by asking. Switching them back on happens in Settings, where you can read what you are agreeing to first.
Money and keys are permanently out of scope. Balances, the Bot Wallet, top-ups, your plan, passwords, API keys and anything administrative can never be changed this way, by design.
A skill is a written engineering discipline the agent follows — a process, the excuses that lead people to skip it, the red flags that should stop the work, and a checklist that proves it was actually done. They are what make SUNy's output consistent instead of merely plausible.
Chosen on two axes at once. SUNy routes by the phase of the work (defining, planning, building, verifying, reviewing, shipping) and independently by the topic of the task — visual design, UI, API contracts, security, performance and cost, context size, browser work, tests, version control, documentation, simplification, migrations, CI. You never name a skill; the right ones are applied for you.
The library covers Test-Driven Development (red-green-refactor), Code Review (standards + spec fidelity), Debugging & Error Recovery (reproduce → minimize → hypothesize → fix), Security Hardening, Performance Optimization, API & Interface Design, Context Engineering, CI/CD Automation, Documentation & ADRs, Deprecation & Migration, Code Simplification, and Visual Design Restraint — the one that keeps an interface looking like a person designed it rather than a model generated it.
Free to inspect. Type /skills in any chat for the live list, or /skills <name> for one in detail. Both are read straight from disk with no AI call, so they cost nothing. Each skill is a plain skills/<name>/SKILL.md file in your own install — readable, auditable, and yours to extend. Users add their own on top (see Your Own Skills).
And it stays cheap. Your prompt carries a one-line index of the library, not the library. The skills that match your task are named up front; the full text of any other is fetched only if the task actually needs it. Each extra skill costs one short index line until it is needed.
Bypasses expensive grep loops and multi-file reads. SUNy finds functions, classes and components by name with the exact file and line, and adds matches by meaning from a hybrid HNSW + FTS5 index where one exists (it is built where SUNy can read the project directly, i.e. a local install). Fast and token-efficient.
ORBITS is SUNy's teams feature. An orbit is a team around one person's SUNy — the way planets sit around a sun: the owner's machine is the centre, every teammate's request passes through it, and when the owner is away the orbit stands still. (Nothing to do with Microsoft Teams.)
An orbit you cannot be pulled into, and cannot barge into. Every user has a public member code (SUNY-7K3Q-9ZP2). The owner adds a member's code; the member enters the orbit code; only when both halves exist is anyone in. The join screen states the orbit's billing strategy in plain words before the member accepts: owner pays (within daily caps the owner sets) or each pays (a teammate's request is charged to their own balance, and refused if it cannot cover it). Change the strategy later and every member must accept again.
Shared projects run where the code lives. The owner shares a project; teammates get a tab for it and ask SUNy as if it were theirs — but the request is a Team Turn: it runs on the owner's machine through the owner's Bridge, under a signed delegation grant that fences every tool call to that project's folder and to the member's capability (monitor = read-only, edit = read+write), never auto-executes, and sends anything needing approval to the owner alone. One request runs at a time per project; the rest are told they are next. The reply streams to the whole team through an allow-listed channel that scrubs paths and secrets, and the transcript lives on the server, so every device shows the same history.
Locks, pauses, caps. The owner's machine or app going offline locks the project tab until it is back; the owner can pause the orbit, mute or remove a member, stop sharing, or delete the orbit (transcripts kept 30 days). Usage shows Billed from orbits and Orbit spend by teammate, and each cost card says who paid.
Orbit chat built in: one plain chat tab per orbit — no SUNy composer in the way — with text, a basic emoji picker, reactions, replies, edit/delete within five minutes, typing and presence, file attachments up to 10 MB with image previews, and voice notes up to 60 seconds, all stored server-side and served only to members. A pill bar on its own line above the chat tabs (Home · Projects · Apps · Orbits · Shared) hides or shows whole categories without archiving anything.
A ⚡ Parallel Task (or /parallel) is one more agent working beside your chat on the same project, so you keep talking while it builds. Its edits land in the folder as it goes — there is nothing to merge — at most two run on one project. Keep them on different files: if two tasks do change the same one, SUNy tells you which. When it finishes, SUNy can tell you on WhatsApp.
A swarm (/swarm) is different: 2–4 specialised agents split one big feature — frontend, backend, tests, database — and build the parts at the same time inside the turn, after SUNy takes a restore point, so the whole swarm can be rolled back.
Full Arabic language support with right-to-left layout via a React Context-based I18nProvider wrapping the entire app. Language strings are stored in en.json / ar.json and loaded by key. Switching to Arabic sets document.documentElement.dir = 'rtl' and lang = 'ar' automatically — all UI components reflow without manual RTL handling. The choice persists in localStorage and syncs to the server via PATCH /api/settings with the ui_language field. Your entire team can work in their preferred language side by side.
Three-tier override chain: Project → User → Global (Admin). Each level can be set to tool-call (surgical edits via AI tools), diff (search/replace patch blocks for token efficiency), whole (full file rewrites), or architect (two-pass plan-then-execute for complex changes). Stored in app_settings as user_{id}_edit_format or user_{id}_project_{pid}_edit_format. The getEditFormat(userId, projectId) function in agent.ts resolves the chain at session start — project override wins, then user, then global. The sidebar shows a dropdown per project with an "Inherit user default" option so users can override selectively without affecting other projects.
Every project has its own panel in the sidebar — and every switch in it is wired end to end, scoped to that project only, and reports an error instead of failing silently.
.suny/rules.md in the project and applied to every message.Type / in the message box and SUNy lists every command with a one-line description — no memorising: /goal works autonomously until the goal is verified done, /plan proposes a plan before touching code, /review audits recent changes, /test runs and fixes the test suite, /image generates an image, /clear and /help are one keystroke away, /interview pins down requirements before any code, /web forces online research, /remember saves rules and preferences permanently, /swarm splits a big feature across 2–4 agents at once, /parallel runs a task beside your chat, and /battle compares models side by side for BYOK users. Inside a project, type @ to pick a file and attach its content to your message.
SUNy Junior, the quick-help chat (Ctrl+K), answers product questions from a verified knowledge base of SUNy's real features, pages and connectors, answers general questions normally, and hands anything that needs live data or real work to the main chat with one click — instead of inventing an answer.
When a parallel task finishes, SUNy sends a short note to your own WhatsApp chat if WhatsApp is connected.
When ALL providers and ALL tier escalations have failed at the outer agent loop's failure point in session-manager.ts, SUNy triggers a last-resort replan before giving up. A hasAttemptedReplan boolean guard ensures it only runs once per session. It emits suny:stage { stage: 'replanning' } so the UI shows "Analyzing and retrying...", strips the last failed assistant turn (tool calls + results) from the message list via a while-loop (pop() until role === 'user'), appends a fresh user message: "The previous approach failed. Please step back, analyze what went wrong, and try a completely different strategy.", then runs one more streamText call with the cleaned messages. If the replan succeeds, it returns without showing the upgrade suggestion. If it also fails, it falls through to suny:suggest_tier_upgrade as before. Zero additional LLM infrastructure — purely message list manipulation.
When a parallel agent finishes and merges successfully via merge-coordinator.ts, a non-blocking IIFE fires after the suny:parallel_merge_complete event. It looks up the user's connected WhatsApp credential from the connector registry via getCredentials(userId), and if a connected WhatsApp credential is found, calls executeConnectorCapability(userId, waCred.id, 'send_message', { message: taskSummary }) — silently caught on failure so the merge flow is never blocked. The agent can launch background refactoring tasks and walk away; the result arrives on their phone the moment it's ready. The WhatsApp link is made by WaCore, SUNy's own WhatsApp engine — QR-code sign-in, no browser tab, no Meta API key.
One QR code, and SUNy is on WhatsApp. WaCore links as an ordinary WhatsApp account, exactly the way WhatsApp Web does: no Meta developer app, no API key, no webhooks, no message templates, no per-message fee. Scan once from the APPS panel and the session survives restarts.
Address anyone the way you'd say it. "Message Sara the build is green" works — WaCore resolves a contact or chat by name from your synced contacts, so you never have to dig out a phone number. It also takes a plain number, an exact group id (so SUNy can post into a team group), or yourself, which is how a finished background task lands on your own phone. A local number without a country code is completed from the one you set on the connection; anything written in full, or with + or 00, is left exactly as you typed it.
It refuses to pretend. Before sending to a number, WaCore asks WhatsApp whether that number actually has an account, and stops with a clear message if it doesn't — rather than accepting a send that quietly goes nowhere. A successful send hands back WhatsApp's own message id as proof. Over-long messages are refused before they're sent, not truncated silently.
It protects the number it's using. Outgoing messages pass through a pacing queue (about one every two seconds, with jitter), a circuit breaker rests a connection that keeps failing instead of hammering it, and a lease stops two workers ever opening the same session twice — the mistake that gets numbers banned. Session keys are encrypted at rest in the credential vault.
What SUNy can do with it: send text, send an image, read a conversation, search contacts, list your recent chats, and list your groups — all from ordinary chat instructions.
Groups by name. "Post it in the Dev team group" is enough — WaCore records your group names when it connects and resolves them like contacts, with an exact name always beating a partial one, so Sara never goes to Sara's Book Club.
It behaves like a person. The account comes online, shows typing… before a message lands, and can mark a chat as read. That isn't decoration: a client that fires messages with no presence at all is exactly what gets a number flagged.
Prefer your own browser? WaCore also drives WhatsApp Web inside the Chrome you're already signed in to, through the SUNy Bridge and the SUNy for Chrome extension. Nothing to look up, nothing to paste.
Message your agent the way you'd message a colleague. Switch on inbound triggers and WhatsApp stops being an outbox: text "SUNy what changed in the shop repo today?" from the queue at the airport and the answer arrives in that same chat. No app to open, no laptop, no VPN.
Closed by default, on purpose. An inbound message is untrusted text that becomes an agent instruction, so this is the most carefully fenced feature in SUNy — and the fences cannot be switched off:
Anyone you do allow-list can spend your credits and see what SUNy can see. SUNy says so plainly on the setup screen rather than burying it.
The configuration is a sentence, not a form. Who should SUNy reply to on WhatsApp, and what should it say to each of them? Write it the way you'd tell a new assistant:
Rami: answer about his order and shipping, nothing else
+96170123456 -> invoices only, say I will call in the evening
ignore everyone else
Or skip the form entirely and just say it in SUNy's chat — "reply to Rami about his order and ignore everybody else" — and SUNy writes the rules down, reads them back to you, and tells you plainly that nobody else gets answered. Ask "who are you answering on WhatsApp?" any time to see the list. Names are matched against your own contacts, so you never need a phone number, and a change takes effect in seconds without reconnecting.
A customer asking "where is my order?" just gets an answer — a contact you wrote a rule for needs no trigger word. And the fences are the point:
This is an assistant answering for you under instructions you can read in one glance — not a chatbot pointed at your contact list.
GET /admin/usage/user-daily?days=N endpoint joins usage_log with users, groups by date(timestamp) and user_id, returning call count, input/output tokens, provider cost, and billed amount per user per day. Displayed in the Admin Reports page as a sortable table with Date, User, Calls, Tokens, and Cost columns. SUNy Replay (SessionReplayViewer.tsx) is wired into the same page — each Recent Calls row has a "Replay" button that opens a full session timeline with phase-colored segments (preparing, planning, executing, verifying), tool call inspection, and branching tools. The replay data comes from operation_log via GET /session/timeline which returns events grouped by phase with elapsed_ms timestamps. Admins can audit exactly what happened in any past session without digging through raw logs.
Previously, background tasks that prompted for input (interactive CLIs like npm init, create-react-app, or scripts asking y/N) would hang indefinitely — the agent had no way to respond. The manage_task tool now supports action send_input: the agent calls manage_task({ action: 'send_input', taskId, input }), which flows through power-tools.ts → task-manager.sendInputToTask() → local-executor.sendInputToProcess() → the local Bridge's cmd-handler.sendInput(processId, input), which writes directly to the background process's stdin stream. The bridge already had sendInput implemented (42 lines in cmd-handler.ts, handling process lookup, write, and error states) — only the server-side plumbing was missing. The task is validated as running and has a processId before forwarding; non-running tasks return a clear error message. Completes the task manager's capability set: list, status, kill, and now send_input.
The agent loop's step limit is no longer a static number. getStepLimit(resolvedMode, userMessage) in session-manager.ts dynamically classifies every request: simple creation tasks ("create a calculator") get 3 steps via detectSimpleCreationTask(), quick fixes get 3, chat messages get 2, general questions get 4, advanced mode coding tasks get 8, and Opus mode gets 8. A hard MAX_STEPS = 15 constant caps all loops regardless of classification. Combined with MAX_LINT_RETRIES = 3 and MAX_TEST_RETRIES = 5, this prevents runaway token burn while allowing complex tasks enough room. Previously, autoExecuteEnabled ? 999 : 25 meant auto-execute mode had effectively no limit — now all modes are capped consistently.
SUNy's Chrome connector covers navigate, click, type, press key, scroll, hover, wait, screenshot, evaluate and close, plus listing your open tabs. Everything is routed through the same proven Bridge daemon on your machine. The agent orchestrates deeply complex browser flows — hovering menus, scrolling dynamic feeds, dispatching exact keyboard events, managing tabs — and you choose, per connection, whether it drives your own Chrome (your logins, through the free SUNy for Chrome extension) or a background browser that needs no extension and is signed in to nothing.
The guardrail stack runs in both browsers. Loop detection halts when repeated actions stop changing the page, a retry budget caps attempts on a stubborn element, a per-domain pace limiter keeps requests civil, and a page-state detector recognises CAPTCHA, login walls, Cloudflare challenges and rate-limit pages — handing control back instead of fighting them. In your own Chrome those guards also persist between steps, so clicking the same dead button across four separate attempts is caught, not just four clicks in one batch. And when a guard stops the run it says which guard and what to do next, rather than reporting that nothing happened.
One thing is own-browser only, on purpose. In the window SUNy opens itself, a live on-screen overlay announces each click or keystroke before it happens and one click halts the agent — you are watching a window you did not open, so it narrates. In your Chrome it does not: you are already looking at your own tab, and a card on every keystroke is noise on top of your work. There, the handoff card below is the thing that interrupts you, and only for a step that is genuinely yours.
In the Chrome you are already signed in to. The cursor travels to a button along a curve and lands somewhere inside it — not on the exact pixel centre, every single time. The click is held down for a moment, the way a finger does. Text goes in one character at a time, with a real typing rhythm: a beat after a space, a longer one after a full stop, quicker on a repeated letter, the occasional pause mid-sentence. Arabic, emoji and accented text go in word by word, which is exactly what a keyboard with an input method produces.
This is about pages working, not about hiding. Autocomplete, search-as-you-type, phone-number formatters, password-strength meters and most modern form fields only react to real per-character typing — drop a whole string into a field in one go and it looks filled while the page never noticed. Menus that open on hover need a cursor that actually arrives. And after every click, keypress and page load SUNy waits for the page to stop changing before the next step, instead of acting on a page that is still re-drawing — which is the single most common reason an agent "clicks" and nothing happens.
A CAPTCHA. A two-factor approval. A terms-of-service checkbox. SUNy will not solve, tick or confirm any of them for you — and says so plainly if you ask it to. Those are your decisions, and on the first one it is also the fastest way to get an account banned.
Instead, a card appears in that tab naming exactly what is needed, with Continue and Stop SUNy. You do the step; SUNy picks up from wherever the page ended up — including when the step itself navigated somewhere else, which a sign-in approval usually does. If you walk away and never answer, SUNy reports that nobody answered. It never reports a step as done because it timed out.
Not at that screen? Do it here. The same card also appears in the chat. When SUNy is working in her own browser window — on a machine you are not sitting at — the card offers Do it here: the exact page she is stuck on streams into the chat panel, you tick the box or sign in there, press Continue, and the page is handed back. Nothing is solved for you; the step is just brought to where you are. (Desktop browsers for now.)
The code they emailed you is different. When a site says "enter the code we sent to your email", SUNy opens your own webmail — Gmail, Outlook, mail.com, Yahoo, GMX, Zoho and others — in that same signed-in Chrome, on your machine — finds the newest matching message, reads the code out of it, returns to the page and types it in. Only the code is used: the message is not stored, not displayed, and never sent to the model. Not signed in to your mail there? It asks you to sign in rather than guessing.
Signing in. On a login page SUNy tries the password Chrome already saved for you, then a login you saved in SUNy, then asks you once in a private box — tick Remember on this computer and it is the last time. It never stops silently on a sign-in page: if it cannot get in, a card asks you to.
Verifying. "We sent you a code" or "confirm your email": SUNy opens your own webmail in that Chrome, reads the code or opens the confirm link from the newest message, and carries on.
Paying. Before any Pay, Buy or Subscribe button SUNy shows you the shop, the amount, what it is for and the card, and pays only when you approve. In a project where you switched on Auto-Execute, Sandbox Bypass and Blind payment, it pays with your saved card without asking. Either way every payment is shown in the chat and logged, and a CVC, Windows Hello or bank OTP is still yours.
Your logins and cards stay on your PC. Saved logins and cards are kept encrypted on your own computer by the SUNy Bridge — never on SUNy's servers. SUNy sees only the site and the last four digits; the Bridge types the value into the field, even inside a payment provider's secure card box. A saved login is typed only on its own site, so a look-alike page gets nothing.
Connect a project to GitHub and push it once from your PC. From then on you can open SUNy on your phone and say "fix the typo on the pricing page": with the PC switched off, SUNy works on the GitHub copy of the project. She finds the files, reads them, makes the change and saves it as one clear commit. With Auto-Execute off she shows you the files first.
Nothing of yours runs on SUNy's servers: she works through GitHub itself, and if the branch moved while she worked she never overwrites it. She cannot run or test anything until the PC is back, so she keeps changes careful and tells you what to check.
Back at your desk, SUNy sees the commits your PC is missing and offers to pull them before she touches those files, or you press Pull to this PC in the GitHub window. Work on the PC that is not committed yet is never mixed in: she asks you to commit it first.
On a big build, most steps are legwork: run a command, read a file, click a button, check a background task. SUNy keeps its deepest thinking for planning, writing code and fixing errors, and hands the legwork to a faster engine — so the same job costs less and each click comes back sooner. Each step is billed as the engine that answered it.
Right-click any page in Chrome and choose Save this page to SUNy (or press Alt+Shift+S). SUNy writes a two- or three-line summary of it, so the Saved pages list says what each page is, not just where it came from.
Ask SUNy on any saved page to summarize it, pull out the key points, ask how it applies to the project you have open, or ask your own question. Or ask in any chat: "what did that pricing page I saved say about annual plans?"
Use it in a project. Save a library's API docs, a spec or an example, and file it into a project with one click. From then on SUNy knows it is there whenever she works on that project, and reads it in full when the task needs it, instead of working from memory.
Most browser agents are deaf. They click, something does not happen, and all they can report is that their own call returned. SUNy reads the browser's own console and network activity — so a failed step comes back with a cause: the page logged "Blocked by CSP", the POST to /api/orders returned 500, that request never resolved a hostname. The same evidence turns "it's broken" into a bug report with the stack trace already in it.
It keeps roughly the last two minutes of activity, so a bug that already happened is still explainable, and you can mark a point and ask only what happened after it. Ask for a summary, the console lines, or the requests.
Where that data lives matters more than the feature. The buffer is held on your machine, by the Bridge. Authorization headers, cookies, tokens and anything shaped like a key are stripped there, before a single line is eligible to leave your computer — and the summary is what reaches the model, not a log dump, so reading it costs next to nothing. The raw log is never stored on a server; only the summary SUNy asks for leaves your PC. There is no screen recording.
A skill that works perfectly when it runs and never gets reached for is a skill you do not have. Everyone measures the first thing. SUNy measures the second.
Put about twenty realistic prompts beside a skill — half that should reach it, half near-misses that share its words but need something else, because those are what test precision rather than enthusiasm. SUNy runs each one three times and reports a trigger rate, not a yes or no, since the same prompt can match on one run and miss on the next. The set is split into a train half and a validation half, proportionally and identically on every run, so a description cannot be quietly tuned to the exact phrasings you happened to test — and if the validation half scores far below the train half, SUNy says so and tells you the earlier description may have been the better one.
Then it tells you which way the description is wrong, because the fixes are opposite: prompts that should have matched and did not mean it is too narrow; prompts that matched and should not have mean it is too broad; both at once mean the description is pointing at the wrong thing and another round of tweaks will not help. It also names which path fired — the keyword table or the model reading the skill list — because those are fixed in different files.
And it is cheap on purpose. A trigger decision depends on the skill list and the prompt, and on nothing else, so SUNy asks the cheapest model that decision on its own rather than running sixty whole tasks to measure it. The keyword half costs nothing at all. The number of decisions is on screen before a single one is spent.
Point SUNy at any element and it answers with numbers and a verdict, not a description. Colour contrast computed against the real background — composited through every translucent layer above it — with a pass or fail against WCAG at the threshold that actually applies to that size and weight. The accessible name, and where it came from: a visible label and a title attribute are not the same quality of name, and it says which you have. Whether the webfont you asked for is the one rendering, or quietly fell back. How far an element overflows its container, and whether the parent is clipping it. Which sibling is 3px out of line — close enough that it reads as a mistake rather than a layout. And what breaks at phone, tablet and desktop widths.
Two things it will not do. It will not resize the window you are looking at to take those measurements — the per-width pass runs in SUNy's own background browser, and it tells you so instead of grabbing your screen. And when a value cannot be read, it reports that it could not read it. A confident wrong number is worse than no number.
SUNy is not only for developers. An empty chat asks one question, what do you do?, and shows ready jobs for a business owner, a website builder, a marketer or content creator, a developer, or someone who is just curious: a landing page, a price list, a website check, a report for a client, a month of posts. One click, and SUNy asks the two or three things it needs, then shows the result as a live page right in the chat.
Press Share link above the page and send it to a customer or a client. Anyone with the link can see it and nobody can find it without the link. The page is shown sealed: it cannot collect anything from a visitor or load anything from the internet, so it is a page to look at, not a working website. Stop sharing any time.
When you want SUNy to work on your real website and files, install the Bridge once. You do not need it to start.
Say "why is my page slow?" and SUNy records a performance trace and reads it with the browser's own insights: what made the main content late, split into server time, discovery, download and render; render-blocking files; third-party scripts; what shifted the layout. Say "test it on a phone with slow 3G" and it emulates the screen, a slower CPU and the network in its background browser, never in the window you are looking at.
It opens any request the page made with its headers and body, fakes an API response or blocks a URL to see how the page copes, shows the CSS rules that matched in cascade order with the file each came from, places a log line in the running page without editing your code, and compares memory snapshots before and after a repeated action to find a leak. Drag and drop, whole forms, pop-up dialogs and file uploads from your PC are covered too.
A Lighthouse audit runs on SUNy's server, so it works on public web addresses only. For localhost and pages behind your sign-in, SUNy checks element by element instead and says that is what it did. Included in every plan.
Monitor SUNy's asynchronous work (timers, builds, scrapes) in a sleek real-time drawer directly above your chat input. Track exactly what SUNy is running in the background without losing chat context. Plus, watch file changes live as SUNy edits your codebase with the new File Diff UI Card that provides exact line-by-line stats (+X, -Y) on every modification.
A massive optimization for token efficiency. SUNy dynamically detects simple or info-gathering tasks (like web searches or news retrieval) and drastically shrinks its context window. It automatically switches to a compact version of its behavioral laws and prunes heavy, unneeded tools (like record_design_decision) from the payload. This drops context size from ~18K tokens per call to under 6K — saving you massive API costs and drastically reducing TTFT (Time-To-First-Token) latency.
To completely mitigate malicious prompt injections, AI hallucinations, and sycophantic behavior, SUNy now features a hardened SQLite-backed Permission Policy Engine and a 4-Stage Integrity Engine. File execution, terminal commands, internet access, and autonomous component rendering can all be locked down. A local bridge daemon scans all shell executions against a signature-based denylist to instantly block OS-destructive commands, ensuring SUNy remains perfectly contained within your project workspace.
rm -rf, DROP TABLE, force push) according to your Auto-Execute / Sandbox settings — the warning is added to the answer, the answer itself is kept.SUNy is no longer just a Chat UI—it's a headless enterprise automation engine. The new /api/orchestrate/run and /api/orchestrate/stream REST endpoints allow you to trigger, monitor, and stream autonomous agent loops directly from your CI/CD pipelines, cron jobs, or IDE plugins without ever opening the browser.
SUNy builds long-term memory across sessions. A dedicated .suny/ directory automatically aggregates hard constraints (rules.md), durable architectural facts (brain.md), and project-scoped agent skills. Rules apply to every message (even short ones), the brain and skills are injected once per turn — no duplicated tokens — and a legacy .suny rules file is migrated to .suny/rules.md automatically.
Allows freelancers to seamlessly transfer a project to clients while maintaining complete provenance history, project rules, and an automatically LLM-generated Welcome Brief. This enterprise-grade feature ensures context isn’t lost during handoffs — an assistant that starts every session from nothing cannot hand a project over, because it was never holding one.
Multi-file changes are no longer a sequence of irrecoverable writes. The agent calls begin_transaction(), and SUNy's new transaction-manager.ts records a FileSnapshot (prior content, existence flag, directory flag) for every path touched by file_edit, file_write, or file_delete — before the mutation lands. The first snapshot for a path wins, so a file created then edited inside one transaction rolls back to "does not exist" via a single delete. commit_transaction() finalizes the batch; rollback_transaction() replays the snapshots in reverse through the Bridge (exec:write_file / exec:mkdir / exec:delete_file) and invalidates the session file cache and L3/L4 cache-engine entries so no stale read survives. Only one transaction is active per session (keyed by sessionId, falling back to userId), auto-swept after 30 minutes of inactivity. This is a documented, narrow exception to the "no module-level mutable state in the agent loop" rule — see ADR-0004 — justified because the begin/mutate/commit lifecycle spans separate LLM tool invocations. Rollback restores file content and recreates empty directories; deleted non-empty directory contents are not reconstructed (a documented content-level limitation).
Two token-efficiency upgrades land in the read path. Batch reads: a new read_files_batch() tool accepts 1–50 file specs in a single call, reading them sequentially and returning a delimited result — collapsing N model round-trips into one. Incremental reads: session-file-cache.ts gains getOrReadFileIncremental(), which stores each cached file's size + mtime baseline. On a cache hit it only issues a cheap exec:stat (a new alias wired into the Bridge's handleAction router next to the existing stat case) and compares size+mtime; if unchanged it returns the memoized content without a full read. The old read-then-memoize flow always paid the full bridge read even on cache hits — now unchanged files cost a single metadata round-trip instead of a full content transfer. file_read and read_files_batch share one readOneFile core (bridge read → incremental cache → server-side line slicing → AST symbol fallback for >500-line files), and read_files_batch is registered in the L4 read-only result cache and the diagnostic/read-only tool allowlists alongside file_read.
Blind string search-and-replace is dead. SUNy's new code-surgery.ts engine performs scope-aware, type-safe transformations powered directly by the TypeScript Compiler API — no new dependency, since typescript was already in the tree (AGENTS.md rule 6). The engine builds an in-memory ts.Program over the project's source files (recursive exec:list_dir, skipping node_modules/dist/build, capped at 3000 files / 1MB each) and exposes four surgical tools:
ast_rename_symbol — renames a variable, function, class, type, or interface across the entire project using the compiler's symbol resolution. Only references that actually bind to that symbol are rewritten, so a rename never corrupts unrelated strings, comments, or shadowed identifiers. Supports dryRun for a unified-diff preview.ast_find_references — project-wide reference search returning each file, line, column, and the enclosing context line for every usage of a symbol. A type-safe replacement for the grep-loop "who imports this" pattern.ast_extract_function — hoists a selected line range into a new function. The engine infers which identifiers are read (parameters) versus assigned (returned), synthesizes the new function's signature and call site, and places it adjacent to the source.ast_move_symbol — moves a top-level symbol from one file to another and rewires every import across the project, including splitting a multi-named import and emitting a fresh single-named import pointed at the new location.All file access is delegated through a SurgeryFs adapter that forwards reads/writes to the user's Bridge daemon — the engine never touches the server filesystem directly — and every write flows through the same snapshotBeforeWrite hook used by Atomic File Transactions, so a code-surgery edit is fully rollback-able. Edits also invalidate the session file cache so no stale read survives a transformation.
SUNy second-guesses itself before touching the repository. In Combined Mode (planner + executor), the moment a detailed plan leaves the architect model — and before the executor starts editing — a deterministic gate (substantial plan + non-trivial request) fires a forced-disagreement pass on the cheapest available model. That reviewer is instructed to argue against the plan: unverified codebase assumptions, dangerous or irreversible steps, ordering mistakes, missing error paths, and integration gaps the literal executor will hit. Material concerns are injected into the executor's context as a structured, advisory <preflight_review> note — it can never block or override the primary model, and the whole pass soft-fails to the original plan on any error, timeout, or unparseable response. Executor and planner stay in charge; a cheap model simply gets one chance to make the plan better before code changes land. Pure counterfactual self-interrogation, zero veto power.
Closes the safety gap between Auto-Execute and full autonomy. SUNy's permission engine always checkpoints destructive commands when Auto-Execute is OFF, but with Auto-Execute ON (and sandbox-bypass full autonomy OFF) wide-scope irreversible commands previously ran silently. Now bash and shell_run pass every command through isRiskyCommand() — rm -rf, git reset --hard, force pushes, database drops/truncates, recursive permission changes — and trigger exactly one explicit scope confirmation via the existing checkpoint UI in that grey zone. Calibrated friction: targeted commands stay frictionless, fully autonomous mode keeps its zero-questions promise, and when Auto-Execute is OFF the existing policy checkpoint still handles it (no double-asking). Declining the prompt returns an explicit ABORTED message so the agent reports the block and proposes a narrower alternative instead of guessing.
When SUNy does delegated work, every run is sealed into a tamper-evident record containing the exact request, file changes, and costs. Each record carries a cryptographic fingerprint of all file contents at completion, meaning "these files changed" is something you can recompute, not just a claim the AI makes. Records are cryptographically chained, so altering any past record mathematically breaks all subsequent records, turning quiet edits into an all-or-nothing rewrite. You keep your own receipt from the moment work is delivered, meaning delegated AI work stops being something you have to trust, and becomes something you can explicitly verify.
A request that is really three projects in one message ("monitor these sites, notify my browser, and email me") used to be built all at once: the model wrote everything in a single pass, exhausted its context half-way, and the verification gateway then judged a half-written whole as a single FAIL — after which every repair pass was spent untangling the lot. SUNy now plans first. One cheap model call splits the request into 2–6 ordered phases (phase-planner.ts), each a focused pass of roughly 10–25 tool steps: phase 1 is the smallest working core plus a test that proves it, each later phase adds exactly one capability on top of a working base, and the final phase is always end-to-end integration. The user sees the plan up front. Each phase is verified on its own by the 5-Layer Verification Gateway — which is explicitly told that later phases are intentionally absent, so a phase is never failed for work that is not due yet — and only a verified phase unlocks the next. A phase advance gets a fresh loop-detection guard and is counted as progress rather than against the repair budget, so a long job is not cut short by its own successful milestones. Requests that fit one pass are untouched: the planner returns nothing and the task runs exactly as before.
Every provider fails sometimes — a reset connection, a rate limit, a capacity spike. Previously the fallback chain handed the next model only the original request, so it started from zero: it never saw its predecessor's reasoning, the files it had read, or the test output it was reacting to, and on a long build it could re-choose a different stack and then "discover" an unexpected project in the folder — its own work from ninety seconds earlier. SUNy now carries the working context across the switch. Every finished step's transcript (assistant text, tool calls paired with their results) is recorded as it happens and handed to the next model, which is told it is taking over mid-task and must continue from the last completed step. Retrying the same model replays the native messages, so the conversation stays byte-identical and prompt-cacheable; switching to a different model renders the same history as a provider-neutral work log (▶ action / ◀ result), because native tool-call messages do not survive a provider change intact — tool-call id formats, reasoning parts and thought signatures all differ. A step that was still in flight when the provider died is deliberately excluded, so no side effect is replayed. The user sees one continuous answer and a single line naming the switch.
Advanced mode no longer uses one model for everything. Conversation is answered by a fast chat model; building and editing are routed to a reasoning model, decided per turn from the same predicate the capability filter uses, so the two decisions can never disagree about what kind of turn it is. Routes also gained pinModel, which fixes a silent bug in the fallback chain: because a provider is matched by name, two routes for the same provider resolved to the same key and the key's model override rewrote both, collapsing the second route into a duplicate of the first — the reasoning model was never actually reachable. Chat-only routes still honour the key override, so tuning the conversational model leaves the build model alone. Keys that just failed for a non-transient reason (rejected credentials, no balance, rate limit) are rested for a bounded cooldown instead of being retried on every attempt, and when a chain is exhausted the error states in plain language what each provider actually did.
Reading the web now escalates by cost instead of by guesswork, and the ladder is declared once in the system prompt and echoed in each tool's own description so it survives prompt trimming on small-context providers. (1) rss_fetch — a new tool that reads RSS 2.0, RSS 1.0 and Atom feeds and autodiscovers a site's feed from its HTML when given a plain page; a few kilobytes of structured items instead of a rendered page, which is the cheapest possible answer to "what's new on this site". (2) url_fetch — plain HTTP, converted to text, now with an automatic reader fallback: when a site blocks a plain request or returns a JavaScript-only shell, the page is re-extracted as clean text through a text-extraction reader rather than immediately starting a headless browser, which previously cost seconds of latency and thousands of tokens for what is ultimately an article. (3) smart_fetch for extracting specific data from a stubborn page. (4) the real browser, only when the task genuinely requires clicking, typing or signing in. Dead URLs still short-circuit to search rather than burning a round trip on a 404 body, and output is capped per call so one page cannot fill the context window.
Any URL SUNy fetches may have been chosen by a model rather than by the user, which makes every fetch path a potential server-side request forgery vector. Two were closed. First, URL validation now resolves the hostname before connecting and rejects every answer that is private, loopback or link-local — the previous check only inspected literal IP addresses, so localhost, internal cloud metadata hostnames and any domain whose DNS record points inward all passed it. Redirects are followed manually, at most five hops, with the same check re-run on every hop, so a public URL cannot redirect into the internal network. Validation fails closed: a name that cannot be resolved is a name that cannot be vouched for. Deliberate loopback remains available where it is a feature rather than an attack — the verification gateway's runtime layer must be able to load the user's own app on localhost to prove it runs. Second, media extraction no longer builds a shell command string from a URL; arguments are passed directly to the binary as an argument vector, so no amount of quoting or shell metacharacters in a URL can become a command.
Every AI agent treats a codebase as a snapshot: it can read what the code says, but not why it exists. So agents routinely delete "unused" code that is actually a guard, and re-introduce bugs that were already fixed. SUNy keeps a per-project causal memory that closes exactly this gap.
When a check fails (a test, a build, a command), SUNy edits the file the error named, and the task finishes green, the link is stored: "this code exists to fix that error" — anchored to the function, with the exact session and tool steps as evidence. Protective comments (HACK:, SECURITY:, "do not remove") are honored too. The whole pipeline is deterministic: zero model calls, zero credits, zero hallucinated reasons. This evidence — the agent's own verified fix history — is a signal no snapshot-based tool has.
Before a later edit deletes guarded code, the file tool itself refuses once and shows the recorded reasons with their evidence. SUNy then keeps the code, or repeats the edit deliberately — and you see a Why Engine notice after the turn naming what was deleted and the reason it had. It warns, it never hard-blocks — refactoring stays possible, silently dropping a fix does not. Reasons are per-account and per-project, size-capped, and self-cleaning: a reason only fires while the code it protects still exists.
Usage breaks a customer’s spending down by model, and SUNy’s own engine appears there as a single line — “SUNy engine” — never by model name or provider. Four anonymous rows with different costs would still describe the shape of the spend across the chain, so they are collapsed into one.
The exception is what the customer chose. The premium Claude models they selected themselves are listed by name, because there is nothing to withhold about a choice they made. That leaves the split that actually matters on a bill: the included engine versus premium Claude.
Token counts are not shown beside prices. A count next to a cost recovers the per-token rate, and from that the engine and the margin. Billing is in credits (1,000 credits = $1), which is pegged to money and reveals nothing else. The enforcement lives on the server: the model id, the provider name, the raw cost and the token counts never leave it, whichever transport asked.
“Could not open a browser” is not an error message, it is a shrug. When Chrome’s own debugging bar has been dismissed, the extension is paused — and SUNy now says exactly that: click the SUNy icon in Chrome’s toolbar and press “Let SUNy continue”. One click, named in the message, instead of a dead end. She also stops retrying, because every further attempt fails identically and each one costs the customer.
The same principle applies to waiting. The mini browser launches a real Chrome, and a cold start can take tens of seconds; the server now waits longer than the browser can legitimately take, and if it does run out of patience it says the panel may still appear rather than declaring a failure that has not happened. A product that calls slow things broken teaches people to distrust its errors.
Ask SUNy for a video and it plays in the message bubble. No browser window opens, the Bridge is not involved, the Chrome extension is not needed, and it costs nothing beyond the answer itself. For the one thing people most often want “shown” to them, the cheapest path is also the most reliable one — and the expensive path can fail for reasons that have nothing to do with the video.
Nothing loads until you press play. Before that the bubble holds a still and a title, so a message with videos in it never reaches out to the video host on its own. Playback runs through the privacy-preserving embed host where the provider offers one.
An allowlist, not a passthrough. YouTube, Vimeo, TikTok and direct .mp4 / .webm / .ogg / .mov / .m4v links, each with a strict id shape checked before anything is embedded — the player’s source URL is rebuilt from that id, never passed through from the text. Up to three players per message. A timestamp in the link (?t=90, 1m30s) starts it at that point. A video on any other site is given as a link, honestly described as opening on the site.
The link stays in the text as well. The player is in addition to it, not instead of it, so the page is always one click away.
A model's knowledge of a library is an average of every version ever written about it. You have one version installed, and it is written down exactly — in your lockfile. So before answering anything about a library's API, options or syntax, SUNy reads it: package-lock.json (v1–v3, preferring the top-level copy over a nested one), pnpm-lock.yaml, yarn.lock (classic and berry), poetry.lock, uv.lock, requirements.txt, Cargo.lock, composer.lock. In a monorepo it can read one workspace's lockfile rather than the root's.
A manifest is not an answer. package.json says "react": "^18.0.0". That is a range, and on your disk it resolved to one of 18.0.0 through 18.3.1 depending on when you installed. Treating the range as a version is how an assistant confidently describes an API you do not have.
When the version cannot be established, SUNy says so. It does not fall back to the newest documentation. That fallback is the same wrong answer the model would have given from memory, now carrying a citation that makes it harder to catch rather than easier. Documentation is fetched from registry endpoints keyed by name and version, and a repository link is only offered after the matching tag has been confirmed to exist.
When SUNy takes on a task with several steps, she shows her plan as a short checklist next to the conversation and strikes each step through as it is done. The step she is on is highlighted; a step that did not work is marked with the reason, never quietly ticked. A step is only ticked after SUNy actually did the work for it. A big job built in phases shows the phase on top, with a fresh checklist for each one.
The card disappears when the task ends, so the chat stays a conversation. On a narrow screen it folds into a small “Plan 3/6” bar above the message box. It is on by default and can be turned off in Settings.
Two chats never edit the same project at once — two tabs, or a teammate’s ORBITS request and your own chat. The second one waits, says so, and starts by itself as soon as the first finishes; Stop cancels it while it waits. Talk Only and plan turns change nothing and never wait. A teammate’s request that was queued behind your task is no longer lost: it runs when yours ends, and if it can never run the orbit chat says so at once.
Work that ran is paid for — and only that. A task you stop, that times out, or that fails part-way is charged for the work it actually did: not the whole task, and not nothing. A task stops by itself when its cost reaches what is left in your wallet instead of running on unpaid, and a task that ran partly on your own API key is charged only for SUNy’s part.
SUNy snapshots your project with git before it changes anything, and the timeline lets you return to any earlier state. The part that decides whether that is useful is the name: a list of restore points you cannot tell apart is not a safety net.
So each one is named after what the turn was about — “add an export button”, “swarm: build the export flow”, “before parallel work”, “before a quick edit” — rather than after your raw message, with pasted stack traces and appended instructions cut off mid-word. A message that carries no intent at all (“go”, “ok”) is filed by time instead, because twelve restore points all called “go” identify nothing.
Restoring never destroys anything: a dirty working tree is committed as a safety checkpoint first, and the state you just left stays in the list.
Every file SUNy writes, edits, deletes or creates on your PC is noted first, with a copy of how it was. In Rewind & Replay you take it back: one change, one whole request, or everything from a request onwards. It works inside projects and anywhere else on the PC SUNy is allowed to work.
A file you changed yourself afterwards is kept, and SUNy says so. A rewind can itself be put back. Files a command names or creates can be rewound too; files it changed without naming them are listed as “cannot be rewound”.
Honest limits: Rewind covers files on the PC. Sent messages, payments, website changes, pushes, deploys and clicks in a browser or a desktop program cannot be rewound, and the approval card for such a command says so. Files over 50 MB are not copied. The copies stay on your PC for 14 days (up to 2 GB) and are never uploaded. A PRO feature; it uses no credits. Needs SUNy Bridge 1.15.0 or newer.
The project sidebar has a Backups list: each backup with its time, its cause and its size, with Back up now, Restore and Delete. You can also ask SUNy to list, make or restore one. A restore always asks first, makes a safety copy of the current state, and does not touch .env, node_modules, .git or git-ignored files.
Automatic backups keep the last 10 by default. Backups you make yourself stay until you delete them. All of them live on your PC and are never uploaded.
Ask for a logo and SUNy designs real vector artwork. Under her reply you get a live brand board, usually with three different directions to switch between: every lockup, full colour, reversed and one colour, sizes down to a 16 px browser-tab icon, and mockups on a website header, a phone, a business card and a shop sign. The name is set in a real typeface and turned into outlines, Arabic included.
The board also shows checks that are measured: does the symbol survive at 16 px, does it work in one colour, is the contrast enough. Say “make B bolder” or “A with the green of C” and only that changes. Pick one and SUNy saves the whole package on your PC: SVG and PNG files, favicon, app icons, social images, colours and a brand sheet.
Honest limits: stronger modes draw better symbols. Each new board has a small fee; changes to it cost only normal usage. Saving the files needs the SUNy Bridge. SUNy does not check trademarks.
The most common way an AI coding tool lets you down is not a bug. It writes a function, tests it, reports "done", and nothing in your app ever calls it: the button does nothing, the number never changes. Every piece is correct and the pieces are not connected.
SUNy follows a feature from what starts it to what you get, and proves each handoff. On top of that habit there is a check that does not depend on her: the functions and web routes a task added are searched in your project when the work is verified, and anything that nothing uses is listed as built but not connected, with one pass for SUNy to connect it.
Honest limits: JavaScript and TypeScript for now. It checks that new code is used, not that it behaves correctly, and it skips what frameworks call by themselves (pages, route files, webhooks). It is a note on the result and never changes what you pay.
The costliest wrong answer is a confident one read from the wrong place: a default in the code instead of your real settings, the documentation instead of what is installed, the source instead of your live site. Before SUNy states a current value of your system, or says something is done or live, she reads it from where the real value lives, in that same request, and tells you in a few words how she knows.
When she could not check, she says so. And if a reply ever states such a value without anything having been read, a short note under it says it was not checked.
Many businesses only have their logo as a picture: a blurry PNG, a JPEG from a printer, a screenshot. Give it to SUNy and she traces it into clean vector shapes, shown on the board next to your original with how closely it matches. When the logo has a symbol and a name, she also rebuilds it with the name set in the closest built-in typeface, which she finds by measuring, so it can be respaced, recoloured or translated.
From there it is a full brand kit: colour versions, sizes down to 16 px, mockups, and the file package with favicon, app icons and social images.
Honest limits: clean files with flat colours trace best; gradients, shadows and glows are flattened, and a small or blurry picture gives a less exact result. SUNy says what she could not keep. A custom typeface she does not have stays as traced lettering. Tracing has a small fee, shown before it runs, and so does saving the file package.
For a business website SUNy starts from her own website kit: real pages, scroll motion, English and Arabic versions and a build script. A site check then loads the result and reports invisible sections, broken images, missing facts and a robots or sitemap file that does not answer, before SUNy says it is finished.
SUNy uses only the business facts you give her. Reviews, prices and policies she was not given are marked as missing, not invented. For a hero video she can search stock footage where stock search is set up (the clips are free to use; each search that finds clips costs a small search fee, about 2 cents); a generated video is paid, the price is shown first, and nothing is charged until you agree in a later message.
In your own Chrome SUNy can read a page the way a screen reader does — its buttons, links, fields and headings with their names — and find one by plain words (“the Save button”, “the email field”). That helps on custom components that ordinary page reading misses. The Chrome extension also reconnects by itself after a dropped link and repeats only the read-only step that was in flight.
Design, UX and web skills: eight written skills joined the built-in library (52 in total with the brand identity, check-the-source, trace-end-to-end and desktop-data-entry skills): design foundations, design directions, design systems, UX flows and states, UX writing, SEO and AI visibility, Arabic and right-to-left layout, and a React / Next.js / Tailwind playbook.
Screenshots as thumbnails: when SUNy works on your PC or phone, her screenshots sit in one row of small pictures; click one to enlarge it.
It remembers what does not work in a project: a command that fails twice for a simple reason (the program is not installed under that name, the shell refuses &&, there is no such package script) is noted and not tried again. The note removes itself when the command works.
File watching on network drives: where change events are unreliable (network shares, containers) the Bridge checks the folder every few seconds instead.
Demonstrate a task the way you already do it. Press Record a skill, work, press Finish. Four sources land on one timeline: your Chrome steps (through SUNy for Chrome, with password, card and one-time-code fields masked in the page), the commands you run in SUNy's terminal and the ones SUNy's own shell runs meanwhile (exit codes and trimmed, secret-scrubbed output), the project's files — a snapshot when you start and a comparison when you finish, so an edit made in VS Code or any other app is part of the skill — and notes you type on the recording bar. .env and key files are reported as changed but never read; build output and dependencies are skipped.
What it deliberately does not do: no microphone, no voice, no screen or video capture, no keyboard hook. A demonstration recorder that watches everything is a keylogger with a nicer name; this one reads three things it already has a right to read, and nothing else.
The bar stays out of the way. Timer, step count, Note, Pause (nothing done while paused is kept), Finish, Cancel — and Float, which pops the controls into a small always-on-top window so you can demonstrate in another app and still finish without hunting for the SUNy tab.
On Finish, before any model sees the recording, SUNy cleans it — paused moments, stray keys, double clicks, a field typed twice, a page opened and abandoned, a command that failed and was simply re-run — and works out the rest itself: the values that change next time (named after the field they were typed into, each one ask every run or always this value), a verification gate after every step with a visible result, and at most three questions about what a recording cannot explain: a specific item you picked, the longest pause before an action, a command that failed at the end. Plus one optional line of always / never rules. All free.
SUNy then writes the skill from the cleaned timeline and your answers: your explanations become conditions, your rules become rules, every kept gate becomes a check right after its step and a Verification section. The draft card keeps Save locked until one test run passes, reopens with the result when the run finishes, and lets you edit the SKILL.md in place — an edit asks for a fresh test. The server enforces the lock too.
Gotchas. When you correct SUNy about something one skill keeps getting wrong, that correction belongs in that skill — read when the skill runs — not in a global rule that fires on every message you ever send. /add-gotcha puts it there, free and without a model call. It refuses general advice on purpose: a gotchas list that fills with “handle errors properly” costs context every time the skill loads and teaches nothing, so a line has to name something real — a file, a field, a flag, a command, a status code, an exact value. Up to twelve per skill.
Proof that a skill helps. /skill-eval <name> --impact answers a few real tasks twice on the same model — with the skill and without it — and a judge compares each pair blind, twice with the order swapped, so a judge that simply prefers the first answer cannot fake a result. A skill that only repeats what the model already does shows up as “little difference”, and gets cut down to what the model does not know. It works on the built-in library too, which now covers end-to-end testing with Playwright and production containers.
The built-in library makes SUNy's engineering consistent; user skills make your work repeatable. A skill is a folder — SKILL.md (name, description, trigger words, inputs, steps) plus optional scripts/, templates/, references/ — that SUNy loads only when a request matches it.
Describe it: /create-skill starts a short interview and drafts the skill. Save a run: the Save as skill button under a finished task turns the tool steps SUNy actually executed — failed attempts marked, inputs detected — into a skill. Record a skill: do the task once; SUNy records your Chrome steps, the commands you run through SUNy, and what changed in the open project — then asks before it writes (below).
Every draft opens a review card with Save, Test (one live run of the draft), Edit and Discard. A skill made from a recording is locked until one test run passes — a recording is a messy demonstration, and only a replay proves the skill works. Nothing becomes active, and no skill changes, without the user's click. Imported .zip skills land in a Review queue with a static warning list for their scripts (network, deletion, process spawning, credentials, encoded payloads).
Each run is recorded with its outcome and failed tool calls. A skill that keeps failing is flagged Needs attention; /improve-skill builds a revision from the real failures and the inputs that worked, shown as a line diff with Accept / Reject. A daily health pass flags skills without spending a single model call.
SUNy also reads .agents/skills/ — the directory the open Agent Skills ecosystem installs into — so a skill anyone has published is live after npx skills add owner/repo, with no import step and no proprietary format. On a name clash the project’s own skill wins and the shadowed one is reported rather than silently ignored.
Skills are scoped per account (never shared between customers) or stored in the project under .suny/skills/, read through the Bridge so it works with the server on a VPS. Scripts execute on the user's machine from a hash-named cache; scripts from imported skills require approval on every run, pinned to the script hash. Full version history with one-click restore.
SUNy can operate desktop programs on the user's Windows PC through the Bridge (v1.13.0 or newer): it reads the window in front as a list of controls (Windows UI Automation, with classic controls recognised by their window class) together with a screenshot shown in the chat, then clicks, types, presses keys, scrolls, switches windows and opens programs. It is a PRO feature, on by default: in every project (a per-project switch in its own Project settings section, above Auto-Execute, turns it off) and in chats with no project open, where it follows the user's Auto-Execute setting (off: the first desktop action in a chat shows one approval card that covers the rest of that chat). When it is unavailable (not PRO, switched off, Bridge offline) SUNy knows the feature exists and says why instead of pretending. While she is in control the PC shows a SUNy-themed frame, a label and an orange copy of the arrow pointer under the real one, drawn by a separate click-through, no-focus, capture-excluded overlay process. It adds no permission mode of its own: Auto-Execute, Sandbox Bypass and Blind payment govern it like every other tool.
Every action is checked on the PC before it happens, and a refused action does nothing: stale view (each look returns a view id; an action must carry the latest one), window changed (another window came to the front), target mismatch (the thing under the point is not what SUNy named), and user input (the person touched the mouse or keyboard; after three such refusals SUNy pauses). Each result reports whether the window's picture changed; three identical actions with no change stop the attempt.
Speed. The Bridge keeps one PowerShell helper running (started on the first look, closed after 10 idle minutes; a helper that hangs is killed and replaced), reads controls with UI Automation caching (one cross-process call per control), and waits for the window to settle instead of a fixed pause. SUNy can send up to 8 actions as one steps call that runs back to back and stops at the first refusal or no-change, which saves a model round-trip per action.
Passwords. SUNy may type a password the user gave it into a password box. It is masked in the approval card, in the step shown in the chat and in the result; a password box's contents are never read into the control list. It does pass through the model's own tool call for that turn. Limits: Windows only; the screenshot is sent to the server on each look; programs running as administrator may not respond.
SUNy drives a real Android phone, tablet or emulator over USB or Wi-Fi through the Bridge, using the user's own Android SDK or Google's official platform-tools (downloaded once). It reads the screen as a tree of tappable elements, taps, types, scrolls and waits for the next screen; installs, launches and manages apps; and runs a single build → install → launch → watch loop for Gradle, Flutter, React Native and Capacitor projects. Java, Kotlin, native and ANR crashes come back mapped to the file and line in the project. Device health (battery, thermals, storage, patch age) and per-app performance (startup, memory, jank) are one call each. Wipes, flashing, removing system apps and disabling debugging always require explicit confirmation — even in full autonomy.
Agreeing on a design used to cost a round trip per idea: the model described a layout in prose, the user tried to picture it, asked for a different one, and paid for a whole turn to see it. SUNy now renders the design instead of describing it. A request to see a page, screen or set of options produces one fenced html block holding a complete self-contained document with 2–4 variants inside it, which the chat renders live in a sandboxed frame. The economics are the point: because every variant ships in the same page and the switch is performed by the page's own script, flipping between options costs nothing — no message, no model call, no credits. Three options cost what one costs, and the alternative (one option, then iterate) costs a full turn each round. The frame gained real review controls — phone 390 / tablet 768 / full width, a height toggle and full-screen expand — so "does it work on a phone" is answered by looking rather than by a verification layer after the fact, and a page that announces itself as a design preview opens already rendered rather than as a code block to expand. A Use this one control inside the page posts the chosen variant to the host, which validates it by shape, strips control characters and newlines, caps it at 60 characters and places it in the composer: untrusted frame content is treated as data, never as an instruction, and nothing is ever auto-sent. The contract itself lives in a skill pack (skills/generative-ui/SKILL.md) routed by topic, so it costs a single index line in the prompt until a task actually calls for it: no external fonts, CDNs or images (the frame is sealed — allow-scripts only, no same-origin, no forms, no navigation), no storage or network, fluid widths, real copy, and a hard rule that a preview is for deciding while the chosen variant is then written for real in the project's own framework.
Every autonomous AI coding platform charges for effort — raw tokens, wall-clock time, tool iterations — regardless of whether the software actually compiles, passes its tests, or functions. SUNy introduces Guaranteed Tasks: an outcome-based settlement contract backed by multi-layered verification and sealed with a tamper-evident cryptographic receipt chain. Status: fully built and running in shadow calibration; not yet offered to users until the calibration data supports it.
Before any guaranteed task executes, SUNy constructs a task bucket from the billing mode, the request tier, whether the task is a phased build, and which objective verification layers the project supports: mode:tier:phased:layers (e.g., advanced:complex:single:124), and queries historical runs in that bucket. A guarantee is eligible only if the bucket holds at least 8 real runs, the project supports at least 2 objective verification layers (syntax, type-check, unit tests, dev-server boot), and the user's balance covers the quote. The quote is calculated using nearest-rank P80 × 1.25. In shadow mode (ff_guarantee_shadow), would-be quotes are recorded alongside actual costs without moving money, giving administrators an empirical go/no-go calibration metric (target: ≥ 90% coverage).
SUNy prevents catastrophic agent runaway by enforcing an internal raw cost ceiling: P80(raw) × 1.25 × 1.5. When reached, execution terminates cleanly, with the overrun absorbed entirely by SUNy. Charges follow a deterministic outcome table:
min(normal price, quote). Under-runs pay less; overruns are capped and absorbed by SUNy.min(normal failed-task charge, quote × 0.20) — exactly what the same failure costs without a guarantee, or less.min(normal failed-task charge, quote × 0.20); the work beyond that is on SUNy.Because the verification gateway executes on the user's host via the local Bridge daemon and a failed outcome is billed at a reduced rate, the client side has an economic incentive to produce false failures. Any FAIL verdict therefore triggers one more full run of the objective layers before settlement; a flaky or staged failure has to reproduce twice to change the price. This raises the bar but does not make the client trustworthy, so per-user failure rates are also tracked and an abnormal rate suspends guarantees for that user pending review.
Every settled guarantee appends to an immutable per-user hash chain. Fields are canonicalized with fixed 6-decimal amounts and attested file hashes collected via Bridge. The record is hashed via SHA-256 (H_n = SHA-256(H_{n-1} || canonical_payload)) and signed using a domain-separated HMAC key (HMAC-SHA256(JWT_SECRET, 'suny-guarantee-receipts-v1')), so the receipt key is never the same key that signs sessions. Every field the hash covers is stored with the record, so any receipt can be re-verified from the database at any time. Pushing receiptHash to the user at settlement gives them a copy the server cannot later change: any rewrite of the history, even by the operator, produces a chain that no longer matches the hash the user already holds.