monorepo-architect
Skill129 starsChanged 13 days agoMITView on GitHub
Scalable monorepo architecture with Turborepo and pnpm workspaces / Arsitektur monorepo skalabel dengan Turborepo dan pnpm workspaces.
- Reads credentials
8 other projects use a version of this.
Adopted by
Most recently taken up by
- gromov0737/skillstheir own version, first seen Nov 29, 2026
- AtulPurohit/Antigravity-Awesome-Skillstheir own version, first seen Nov 29, 2026
- AtilaMedeiros/skillstheir own version, first seen Nov 16, 2026
- xfstudio/skillstheir own version, first seen Oct 13, 2026
- TheHiddenDeveloper/jarvis-skillstheir own version, first seen Aug 19, 2026
- 4gentic/obelustheir own version, first seen Apr 28, 2026
Other versions8 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 8
- xfstudio/skills★ 9same name
- 4gentic/obelus★ 8same name
- AtulPurohit/Antigravity-Awesome-Skills★ 6same name
- ai4brands-design/claude-skills★ 2same name
- gromov0737/skills★ 2same name
- AtilaMedeiros/skills★ 1same name
- lschGSL/claude_code_template★ 1same name
- TheHiddenDeveloper/jarvis-skills★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository372 other files it gives its agents.
- AGENTS.mdAGENTS.md
- rules/AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- .cursor/rules/vibes-plug-anti-slop.mdcCursor rule
- .cursor/rules/vibes-plug-backend.mdcCursor rule
- .cursor/rules/vibes-plug-core.mdcCursor rule
- .cursor/rules/vibes-plug-devops.mdcCursor rule
- .cursor/rules/vibes-plug-frontend.mdcCursor rule
- .cursor/rules/vibes-plug-mcp.mdcCursor rule
- .cursor/rules/vibes-plug-skills.mdcCursor rule
- .cursor/rules/vibes-plug-testing.mdcCursor rule
- llms-full.txtllms.txt
- llms.txtllms.txt
- showcase/llms-full.txtllms.txt
- showcase/llms.txtllms.txt
- a2a-agent-protocol-expertSkill
- accessibility-testing-expertSkill
- adaptive-model-cascadeSkill
- affective-computing-emotion-aiSkill
- agentic-coding-workflow-expertSkill
- agentic-m2m-settlementSkill
- agentic-memory-architectSkill
- agentic-micro-economy-architectSkill
- ai-code-review-autonomousSkill
- ai-llm-integration-expertSkill
- ai-media-generation-expertSkill
- ai-prompt-engineering-expertSkill
- ai-safety-governance-expertSkill
- angular-expertSkill
- anti-slopSkill
- api-design-expertSkill
- api-gateway-proxy-expertSkill
- app-analyzer-optimizerSkill
- apple-ecosystem-expertSkill
- app-promo-media-expertSkill
- astro-framework-expertSkill
- async-queue-temporal-expertSkill
- authentication-identity-expertSkill
- autonomous-api-drift-healerSkill
- autonomous-red-teamerSkill
- autonomous-tdd-debuggerSkill
- biome-linter-formatter-expertSkill
- blockchain-web3-expertSkill
- brainstormingSkill
- browser-automation-expertSkill
- browser-extension-mv3-proSkill
- bun-runtime-expertSkill
- chatbot-messaging-expertSkill
- ci-cd-devops-architectSkill
- cloudflare-workers-expertSkill
- cloud-hosting-expertSkill
- coderabbitSkill
- compliance-gdpr-privacy-expertSkill
- composable-mach-architectSkill
- computer-use-os-agent-expertSkill
- context-window-engineerSkill
- cron-scheduler-expertSkill
- database-orm-expertSkill
- data-pipeline-etl-expertSkill
- data-telemetry-expertSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
3 rules. 0 are common, 0 are distinctive, and 3 are very specific to this project.
0
Common
Most of the 7 edited versions we read keep these.
0
Distinctive
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 137
Use "exports" pointing to source files directly — Turborepo compiles them as part of the consuming app:
- Very specific: line 208
Mandatory Blue-Ocean Pairing: Always compose monorepo-architect with sbom-supply-chain-security-expert, self-healing-cloud-orchestrator, …
- Very specific: line 210
Pre-Disk Gate: Run vibes verify-gate and vibes skill auto-diff --json to inject <350-token slices and eliminate placeholder slop.
“Common” is measured: kept by at least 6 in 10 of the 7 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Monorepo Architect (Turborepo 2.x / Moon Edition)
English | Bahasa Indonesia
<a name="english"></a>
English
Orchestration & Integration
- Upstream & Project Topology:
zero-to-prod-orchestrator(Phase 2 project foundation),brainstorming,session-memory-manager. - AST & Codebase Intelligence:
living-codebase-ast-graph(cross-package dependency topology & DAG sorting),typescript-expert(composite projects & isolated declarations). - CI/CD & Deployment:
ci-cd-devops-architect(monorepo cache pipelines),github-actions-expert(matrix testing & sparse checkout),cloud-hosting-expert(multi-app deployments). - Shared Design & Components:
design-system-architect(sharedpackages/uitokens),senior-frontend/js-backend-expert(shared packages consumption),micro-frontend-architect(federated micro-apps),composable-mach-architect(composable multi-app packages),dependency-upgrade-migrator(monorepo-wide dependency upgrades).
Description
Expert guide for designing and managing scalable monorepos. Covers Turborepo 2.x (the 2026 standard for JS/TS monorepos), moon (polyglot task runner for teams mixing JS + Rust + Go), pnpm workspaces, shared package design, incremental builds, remote caching, and CI/CD pipeline optimization.
Trigger Conditions
- Managing a codebase with multiple apps and shared packages.
- Setting up a monorepo for a SaaS with separate
web,admin,api, andpackages. - Optimizing build and test times with remote caching.
- Sharing TypeScript types, UI components, or utility functions across apps.
- Migrating from a multi-repo setup to a monorepo.
Tool Selection Guide (2026)
| Tool | Best For | Language Agnostic |
| Turborepo 2.x | JS/TS monorepos (Next.js, Vite, Node) | ❌ (JS focused) |
| moon | Polyglot teams (JS + Go + Rust + Python) | ✅ |
| Nx | Enterprise, Angular/React, plugin ecosystem | ❌ (JS focused) |
| Bazel | Very large orgs, hermetic builds | ✅ |
Turborepo 2.x — Standard JS Monorepo
Repository Structure
my-saas/
├── apps/
│ ├── web/ # Next.js 16 main app
│ ├── admin/ # Next.js 16 super admin (subdomain)
│ └── api/ # Hono/Fastify backend
├── packages/
│ ├── ui/ # Shared Tailwind v4 components
│ ├── db/ # Drizzle ORM schema + queries
│ ├── auth/ # Auth utilities (session, JWT)
│ ├── email/ # Email templates (React Email)
│ └── tsconfig/ # Shared TypeScript configs
├── turbo.json
├── pnpm-workspace.yaml
└── package.jsonturbo.json (v2 Syntax)
{
"$schema": "https://turbo.build/schema.json",
"ui": "tui",
"tasks": {
"build": {
"dependsOn": ["^build"],
"inputs": ["$TURBO_DEFAULT$", ".env*"],
"outputs": [".next/**", "!.next/cache/**", "dist/**"]
},
"dev": {
"cache": false,
"persistent": true
},
"test": {
"dependsOn": ["^build"],
"inputs": ["src/**", "test/**", "vitest.config.*"]
},
"lint": {
"inputs": ["src/**", "*.config.*", ".eslintrc*"]
},
"typecheck": {
"dependsOn": ["^build"]
},
"db:generate": {
"cache": false
}
}
}pnpm-workspace.yaml
packages:
- "apps/*"
- "packages/*"Remote Caching (Vercel Remote Cache)
# Authenticate with Vercel Remote Cache
npx turbo login
npx turbo link
# Or self-hosted with Turborepo Remote Cache
TURBO_TEAM=my-team TURBO_TOKEN=xxx turbo buildShared UI Package (packages/ui)
// packages/ui/package.json
{
"name": "@myapp/ui",
"version": "0.0.0",
"private": true,
"exports": {
"./button": {
"import": "./src/button.tsx",
"types": "./src/button.tsx"
},
"./card": {
"import": "./src/card.tsx",
"types": "./src/card.tsx"
}
},
"peerDependencies": {
"react": "^19.0.0",
"react-dom": "^19.0.0"
}
}Internal Package Pattern (No Build Step)
Use "exports" pointing to source files directly — Turborepo compiles them as part of the consuming app:
// packages/db/package.json
{
"name": "@myapp/db",
"exports": {
".": {
"import": "./src/index.ts",
"types": "./src/index.ts"
}
},
"devDependencies": {
"drizzle-orm": "latest",
"drizzle-kit": "latest"
}
}moon — Polyglot Task Runner
For teams mixing JavaScript, Go, Rust, and Python in one repo:
# .moon/workspace.yml
projects:
- "apps/*"
- "packages/*"
- "services/*" # Go/Rust microservices
vcs:
manager: "git"
defaultBranch: "main"# apps/api/moon.yml (Go service)
language: "go"
type: "application"
tasks:
build:
command: "go build -o ./bin/api ./cmd/api"
inputs: ["src/**/*.go", "go.mod"]
outputs: ["bin/api"]
test:
command: "go test ./..."CI/CD Optimization
# .github/workflows/ci.yml
- name: Build & Test (Turborepo)
run: |
npx turbo run build test lint typecheck \
--filter="...[origin/main]" \ # Only changed packages
--cache-dir=".turbo"
env:
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
TURBO_TEAM: ${{ vars.TURBO_TEAM }}Hard Guardrails (Declarative Invariants)
- Directed Acyclic Package Dependency (DAG) Invariant: Monorepo workspace package graphs MUST form a strict DAG; circular dependencies between internal packages (
packages/ui$\leftrightarrow$packages/utils) are strictly prohibited. - Internal Package Source Export Pattern: Internal workspace packages MUST export TypeScript source files directly via the
"exports"field inpackage.jsonwithout requiring intermediate compilation build steps. - Explicit Task Dependency Graph (
turbo.json): Build, test, and typecheck tasks inturbo.jsonMUST explicitly declaredependsOn: ["^build"]and deterministicinputs/outputsto enable hermetic remote caching. - Strict Workspace Protocol Invariant: Cross-package internal dependencies in
package.jsonMUST enforce theworkspace:*orworkspace:^protocol to prevent accidental fetching of stale published npm registries.
Non-Functional Requirements (NFR)
- Remote Cache Hit Speed: Full monorepo cached build completion $\le 5\text{s}$.
- Incremental Local Build: Affected package build $\le 1\text{s}$.
- Hermetic CI Execution: 100% reproducible builds with verified cache inputs/outputs.
Blue-Ocean Synergy & Anti-Commodity Protocol
- Mandatory Blue-Ocean Pairing: Always compose
monorepo-architectwithsbom-supply-chain-security-expert,self-healing-cloud-orchestrator,zero-trust-secret-vault,adaptive-model-cascadeso commodity boilerplate is elevated into verified, self-healing production architecture. - Anti-Commodity Mandate: Go beyond basic Docker/CI YAML: mandate rootless distroless builds, CycloneDX SBOM attestation, zero-trust secret rotation, and self-healing telemetry loops.
- Pre-Disk Gate: Run
vibes verify-gateandvibes skill auto-diff --jsonto inject <350-token slices and eliminate placeholder slop.
Sovereign Execution, Token Efficiency & Invariants
| Dimension | Sovereign Mandate & Deterministic Contract |
| Frontier Model Cascade | High Fast / Medium / High (Gemini 4 Carbon, Gemini 4 Neon, Gemini 4 Hydrogen, Gemini 4 Argon, Claude Sonnet 5.5 High, Grok 4.7 High Fast) |
| Availability Fallback | Gemini 4 (Carbon/Hydrogen/Neon/Argon/Pro) -> Gemini 3.8 Flash; Claude Opus 5.5 -> Claude Opus 4.6 (Zero unhandled missing-model errors) |
| KV-Cache & Token Protocol | Pin static instructions & schemas at prompt prefix (kv-cache-prefix-optimizer); pass surgical CONTEXT_MAP.md slices (<250 tokens/call) during Swarm Fan-Out |
| SaaT CLI & MCP Dispatch | CLI: vibes skill exec monorepo-architect <audit|eval|verify|generate|blueprint> / MCP: vibes_skill_dispatch, vibes_ast_query, vibes_compile_cache, vibes_optimize_budget, vibes_verify_gate |
| NFR & Anti-Slop Invariants | P99 API Gateway Latency < 85ms, OpenAPI 3.1 / TypeSpec strict schema parity, RFC 9457 Problem Details error contracts, Idempotency-Key enforcement; 100% complete zero-placeholder output verified via node scripts/check-anti-slop.js --strict |
<a name="bahasa-indonesia"></a>
Bahasa Indonesia
Integrasi Orkestrasi
- Hulu & Topologi Proyek:
zero-to-prod-orchestrator(Pondasi proyek Fase 2),brainstorming,session-memory-manager. - AST & Inteligensi Basis Kode:
living-codebase-ast-graph(topologi dependensi lintas paket & DAG sorting),typescript-expert(composite project & isolated declarations). - CI/CD & Deployment:
ci-cd-devops-architect(pipeline cache monorepo),github-actions-expert(pengujian matriks & sparse checkout),cloud-hosting-expert(deployment multi-aplikasi). - Desain Bersama & Komponen:
design-system-architect(token sharedpackages/ui),senior-frontend/js-backend-expert(konsumsi paket bersama).
Deskripsi
Panduan ahli untuk merancang dan mengelola monorepo yang skalabel. Mencakup Turborepo 2.x (standar 2026 untuk monorepo JS/TS), moon (task runner poliglot untuk tim yang memadukan JS + Rust + Go), pnpm workspaces, desain shared package, incremental build, remote caching, dan optimasi pipeline CI/CD.
Kondisi Pemicu
- Mengelola codebase dengan banyak aplikasi dan shared package.
- Menyiapkan monorepo untuk SaaS dengan
web,admin,api, danpackagesterpisah. - Mengoptimalkan waktu build dan test dengan remote caching.
- Berbagi TypeScript types, komponen UI, atau utilitas antar aplikasi.
- Migrasi dari multi-repo ke monorepo.
Panduan Pemilihan Tool (2026)
- Turborepo 2.x: Standar untuk monorepo JS/TS — cepat, zero-config, remote cache bawaan.
- moon: Untuk tim poliglot yang memadukan JS, Go, Rust, Python dalam satu repo.
- Nx: Untuk enterprise dengan ekosistem plugin yang kaya.
Struktur Repositori
Pisahkan apps/ (aplikasi yang dapat di-deploy) dari packages/ (shared library internal):
apps/web— Next.js utamaapps/admin— Dashboard Super Admin (subdomain terpisah)apps/api— Backend APIpackages/ui— Komponen UI bersama (Tailwind v4)packages/db— Skema Drizzle ORM + querypackages/auth— Utilitas auth
Turborepo 2.x — Sintaksis Baru
Turborepo 2.x memperkenalkan TUI interaktif ("ui": "tui"), sintaksis tasks yang lebih ekspresif, dan caching yang lebih granular dengan inputs/outputs.
Pola Internal Package (Tanpa Build Step)
Arahkan exports langsung ke file sumber TypeScript — Turborepo mengkompilasi sebagai bagian dari aplikasi yang mengonsumsinya. Ini menghilangkan kebutuhan langkah build terpisah untuk setiap package.
moon — Task Runner Poliglot
Moon mendukung proyek dalam bahasa yang berbeda (Go, Rust, JS) dalam satu workspace, masing-masing dengan konfigurasi moon.yml-nya sendiri.
Optimasi CI/CD
Gunakan flag --filter="...[origin/main]" Turborepo untuk hanya membangun dan menguji package yang berubah sejak commit terakhir. Gunakan remote cache Vercel atau self-hosted untuk berbagi cache antar runner CI.
Hard Guardrails (Invarian Deklaratif)
- Invarian Dependensi Paket Directed Acyclic Graph (DAG): Graf dependensi paket monorepo WAJIB membentuk DAG tanpa siklus; dependensi melingkar antar paket internal (
packages/ui$\leftrightarrow$packages/utils) dilarang keras. - Pola Ekspor Sumber Internal Package: Paket internal workspace wajib mengekspor file sumber TypeScript langsung melalui kolom
"exports"dipackage.jsontanpa memerlukan build kompilasi perantara. - Graf Tugas Eksplisit (
turbo.json): Tugas build, test, dan lint dalamturbo.jsonwajib mendeklarasikandependsOn: ["^build"]sertainputs/outputsdeterministik untuk memastikan remote caching berjalan kedap (hermetic). - Protokol Workspace Ketat: Dependensi antar paket internal dalam
package.jsonwajib memberlakukan protokolworkspace:*atauworkspace:^guna mencegah pengambilan paket usang dari registry npm publik.
Non-Functional Requirements (NFR)
- Kecepatan Build Remote Cache: Penyelesaian build ber-cache seluruh monorepo $\le 5\text{s}$.
- Build Inkremental Lokal: Build paket yang terdampak $\le 1\text{s}$.
- Eksekusi CI Hermetis: 100% build dapat direproduksi dengan input/output cache terverifikasi.
Sinergi Blue-Ocean & Protokol Anti-Komoditas
- Pasangan Wajib Blue-Ocean: Selalu komposisikan
monorepo-architectbersamasbom-supply-chain-security-expert,self-healing-cloud-orchestrator,zero-trust-secret-vault,adaptive-model-cascadeagar boilerplate standar naik kelas menjadi arsitektur produksi terverifikasi dan self-healing. - Mandat Anti-Komoditas: Lampaui YAML Docker/CI standar: wajibkan build distroless non-root, atestasi CycloneDX SBOM, rotasi secret zero-trust, dan loop telemetri self-healing.
- Gerbang Pra-Disk: Jalankan
vibes verify-gatedanvibes skill auto-diff --jsonuntuk menyuntikkan slice <350 token serta mencegah placeholder slop.
Matriks Eksekusi Berdaulat, Efisiensi Token & Invarian
| Dimensi | Mandat Berdaulat & Kontrak Deterministik |
| Kaskade Model Frontier | High Fast / Medium / High (Gemini 4 Carbon, Gemini 4 Neon, Gemini 4 Hydrogen, Gemini 4 Argon, Claude Sonnet 5.5 High, Grok 4.7 High Fast) |
| Invarian Fallback Ketersediaan | Gemini 4 (Carbon/Hydrogen/Neon/Argon/Pro) -> Gemini 3.8 Flash; Claude Opus 5.5 -> Claude Opus 4.6 (Bebas gagal saat model belum tersedia/kuota penuh) |
| Protokol Hemat Token & KV-Cache | Kunci instruksi & skema statis di prefix awal (kv-cache-prefix-optimizer); kirim potongan CONTEXT_MAP.md (<250 token/panggilan) saat Fan-Out |
| Eksekusi SaaT CLI & MCP | CLI: vibes skill exec monorepo-architect <audit|eval|verify|generate|blueprint> / MCP: vibes_skill_dispatch, vibes_ast_query, vibes_compile_cache, vibes_optimize_budget, vibes_verify_gate |
| Invarian NFR & Anti-Slop | Latensi P99 API < 85ms, paritas skema ketat OpenAPI 3.1 / TypeSpec, kontrak error RFC 9457 Problem Details, penegakan Idempotency-Key; kode 100% tuntas tanpa placeholder diverifikasi melalui node scripts/check-anti-slop.js --strict |
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

