Architecture of paperclipai/paperclip
paperclipai/paperclip is 13,867 source files holding 86,576 symbols across 15 modules, written mainly in TypeScript, JavaScript, Rust. The largest module is server, with 3,984 files, and 80 files are entry points into the dependency graph.
How paperclip fits together
The ui directory holds the React interface, which is built with Vite and tested with Vitest and Storybook. Requests from the UI and from the command line reach the server directory, whose services coordinate agent runs and record tasks, comments, runs and reported spend. The cli directory contains the command line tool, starting from cli/src/index.ts, and cli/src/commands/run.ts defines the run command. The server/src/services/native-runtime/native-session-executor.ts file handles native agent sessions on the server. The packages/paperclip-runner directory holds the native runner, and its src/live/runnerd-codex-transport.ts file implements a Codex transport for it. The tests directory contains the automated test suites for these parts.
Largest modules
- server: 3,984 files and 1,317,639 lines of code
- packages: 3,126 files and 689,809 lines of code
- ui: 3,047 files and 642,196 lines of code
- tests: 1,134 files and 169,178 lines of code
- scripts: 363 files and 59,272 lines of code
- cli: 173 files and 41,065 lines of code
- .agents: 61 files and 6,157 lines of code
- .github: 55 files and 5,907 lines of code
Languages
By file count: TypeScript 10,589 files, JavaScript 738 files, Rust 92 files, Shell 60 files, Python 32 files, Dockerfile 6 files.
Documentation
Repowise documents paperclip in 6,227 pages generated from the source, 45 of them written explanations of the repository and its modules. Module guides include:
- packages/adapter-utils/src: Adapter Runtime Sync
- packages/adapters: Adapters Packages (11)
- tools/agent-shim: Agent Runtime Guide
- ui/src/pages/apps: Application Pages and Plugins
- cli/src: CLI Client and Commands
More on paperclip: summary and FAQ, codebase overview, code health.
Related guide: Best dependency graph tools for monorepos