Skip to content
Agent Orchestration
Skill

/dia-source-analysis

Analyze / reverse-engineer the locally installed Dia Browser mac app (The Browser Company; bundle id company.thebrowser.dia; shares ArcCore with Arc). Inspect its app bundle, extract its Bun/TypeScript agent-server source from shipped source maps, fingerprint the runtime, read

From plugin
termio
79029 skills

Claude Code

$ npx -y skills add termio-sh/termio --skill dia-source-analysis --agent claude-code

SKILL.md

dia-source-analysis.SKILL.md
name: dia-source-analysis
description: "Analyze / reverse-engineer the locally installed Dia Browser mac app (The Browser Company; bundle id company.thebrowser.dia; shares ArcCore with Arc). Inspect its app bundle, extract its Bun/TypeScript agent-server source from shipped source maps, fingerprint the runtime, read native-Swift symbols, and map its AI-agent / sandbox / on-device-ML architecture. Invoke when the user wants to study how Dia works internally, extract Dia's agent code, or compare Dia's agent/terminal approach against termio. (User sometimes voice-types the name as 'DotBrowser' — same app.)"

Analyze Dia Browser source

Dia (`/Applications/Dia.app`, The Browser Company, `company.thebrowser.dia`) is a WebKit-based browser (~1.4 GB) that shares `ArcCore.framework` with Arc. termio uses it as a reference for how a shipping product **drives AI coding agents as sandboxed child processes** (Dia shells to the real Claude Code CLI under Seatbelt) and for its agent-server / IPC architecture. This skill captures how to dig into it and what's already known, so analysis doesn't start from scratch each time.

Golden rules

  • **Read-only, on the user's own machine, for research.** This is proprietary code shipped

to the user. Use it to *understand and learn*, never to copy/redistribute verbatim or ship lifted code. State this caveat when sharing recovered source.

  • **Verify before trusting old findings.** The "Established facts" below are version-stamped.

Dia auto-updates (Sparkle); bundle layout, file hashes, runtime versions, and even whether source maps ship can all change. Always re-read `info.json` + `CFBundleShortVersionString` first and treat mismatches as "re-derive from scratch."

  • **Two recoverability tiers:** the Bun/TS agent backend is near-fully recoverable (source

maps); the native Swift app is symbols/structure only (no real source).

Established facts (as of Dia 1.34.2 — RE-VERIFY)

Agent-server `info.json` (1.34.2): version 1.0.0, buildDate 2026-06-10, commit `47de9fbe6c4`, `claudeCodeVersion 2.1.131`. (Was 1.32.0 / commit `55d9d2e174b` / buildDate 2026-05-20.)

  • **⚠️ Source maps NO LONGER SHIP as of 1.34.2.** `extract-sourcemaps.py` returns "No .map

files found" — the Bun/TS agent-server backend is no longer recoverable as near-original TS (only logic compiled into the Mach-O remains). The native-Swift tier is unchanged: symbols + embedded source paths only. So "the big win" in §1 below is gone on current builds; keep the procedure for older installs / in case they return.

  • **Agent backend = Bun-compiled standalone Mach-O** (`agent-server`, `handler`) + **the real

Claude Code CLI** (`claude`, 206 MB, itself a Bun binary). No separate Node/Bun runtime is installed — each binary embeds Bun. They run as **child processes under Seatbelt sandbox** (`sandbox-exec -f agent.sb` / `agent-claude-code.sb`, params via `-D DATA_DIR=…`), talking to the native UI over SSE/IPC (`transport/sse.ts`, `ipc-gateway.ts`). Per-context workspace at `data/contexts/{contextId}` with resumable disk buffers (`session/buffer.ts`, JSONL). **This is the part most relevant to termio** — termio runs agents in real PTYs (`.exec`) instead, but the child-process-under-sandbox + resumable-buffer + IPC design is the directly comparable bit.

  • **Streaming smoothness** comes from native rendering + `session/update-batcher.ts`: deltas are

coalesced and flushed only on **≥256 B** OR **250 ms idle** OR completion — so the UI updates a few times/sec, not per token. The Bun agent-server is backend orchestration and does NOT touch UI perf.

  • **AI chat ("AssistantPanel") renders NATIVELY, not in a webview.** Markdown parsed by

`cmark` (swift-markdown), code highlighted by **Highlightr** (`CodeAttributedString` → NSAttributedString), math by **SwiftMath** (`MTMathListDisplay`, CoreText). UI is AppKit `NSViewController`s (source paths `Frameworks/BoostBrowser/Sources/AssistantPanel/*.swift`).

  • **The AI input is the native AppKit module `BoostCommandBar`** (`Frameworks/BoostBrowser/

Sources/BoostCommandBar/*`): a token/pill `TokenTextView` w/ `SkillPillTokenViewProvider`; Skills = `SkillsV3`; `@`-mentions (`AtMentionKeywords`: @Search/@Slack/@Gmail/@Notion) insert context/tool pills. On-device `cmd_t_router` (3-label intent) + `skills` classifier rank proactive suggestions.

  • **WKWebView (~45 refs) is for web pages + HTML "artifacts"** (reports/slides via

`report-kit`/`slide-kit`), NOT for chat bubbles.

  • **On-device ML** (`OnDeviceLoRAadaptors` bundle, 152 M): one shared **DistilBERT-base** encoder

(126 M, fp16) + three LoRA adapters + heads — `cmd_t_router` (input intent), `skills` (which skill to fire), `sensitive_content` (privacy gate). Run via MLX (`mlx-swift`).

Bundle map

| Path | Size | What | |---|---|---| | `Contents/Frameworks/ArcCore.framework` | ~548 M | browser engine core (WebKit + Arc) | | `Contents/Resources/agent-server-resources/dist` | ~371 M | Bun agent backend + bundled `claude` CLI (206 M) | | `Contents/Resources/OnDeviceLoRAadaptors_…bundle` | ~152 M | DistilBERT base + 3 LoRA classifiers | | `Contents/MacOS/Dia` | ~106 M | native Swift app binary (AssistantPanel etc.) | | `Contents/Frameworks/libAIInfra.dylib` | ~21 M | on-device classification (`LocalClassification`) | | `Contents/Resources/*.bundle` | — | Highlightr, SwiftMath, SwiftProtobuf, mlx-swift, swift-transformers, ARC/BoostBrowser feature bundles | | `dist/*.sb` | — | Seatbelt sandbox profiles |

Procedure

0. Identify version (always first)

/usr/libexec/PlistBuddy -c "Print :CFBundleShortVersionString" /Applications/Dia.app/Contents/Info.plist
cat "/Applications/Dia.app/Contents/Resources/agent-server-resources/dist/info.json"

1. Recover the agent-server source (the big win)

The `.js` bundles are compiled into the Mach-O binaries and NOT shipped, but `entrypoint.js.map` and `handler-entrypoint.js.map` ship with `sourcesContent`

Read more
@termio-sh
Ships withtermio

A terminal-first agentic development environment for agentic coding. Build for CLI/TUI agent. Runtime for Coding Agent, Tmux alternative

Stars on GitHub

Momentum

stars in total
790
Star history of termio-sh/termio on GitHub, a chart by star-history.com

Other skills on termio.

termio-device

termio-device

See and drive the sibling agent sessions running alongside you on this machine via the `termio session` CLI — list them and their…

@termio-sh@termio-shInstall Skill
termio

termio

See and drive the sibling agent sessions running alongside you in this Termio project via the `termio session` CLI — list and…

@termio-sh@termio-shInstall Skill
animation-vocabulary

animation-vocabulary

Reverse-lookup glossary that turns a vague description of a web animation or motion effect into its exact term ("the bouncy thing…

@termio-sh@termio-shInstall Skill
app-screenshot-debug

app-screenshot-debug

Drive the running termio app via AppleScript / System Events to reach a UI state (focus the window, click a sidebar project, a…

@termio-sh@termio-shInstall Skill
apple-design

apple-design

Apple's approach to interface design and fluid, physical motion, translated for the web. Use when building or reviewing…

@termio-sh@termio-shInstall Skill
asc

asc

Drive App Store Connect from the terminal with the `asc` CLI — TestFlight builds, groups, testers and What to Test notes; App…

@termio-sh@termio-shInstall Skill

More skills from other plugins.

1password

1password

Set up and use 1Password CLI for sign-in, desktop integration, and reading or injecting secrets.

openclaw4d395k
@steipete@steipeteInstall Skill
jira-tickets

jira-tickets

Read and update Jira tickets through Orca's saved Jira connections. Use when a task comes from Jira or the user asks for Jira…

orca2d128k
@stablyai@stablyaiInstall Skill
agentmail

agentmail

Use your assigned AgentMail inbox to read email tasks, explicitly send or reply, and check delivery. Provided automatically by…

paperclip3d114k
@paperclipai@paperclipaiInstall Skill
adr-create

adr-create

Create a new Architecture Decision Record with sequential numbering and AgentDB registration

@ruvnet@ruvnetInstall Skill

Questions about dia-source-analysis.

Which coding agents can use dia-source-analysis?
dia-source-analysis installs in Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode and Windsurf with the skills CLI, using each agent's flag shown on this page. Flowy's auto-invocation, which fires a skill when your prompt matches, runs in Claude Code only.