Repo Map
The Shokunin Platform is organized as a monorepo. This page is a reference map to help contributors find where to make changes.Top-Level Structure
Directory Reference
app/
Next.js 15 App Router. Route groups organize the application:
Key entry point:
/docs route is at app/(platform)/docs/page.tsx.
components/
Reusable React components organized by concern:
Key entry point: Platform navigation is in
components/platform/sidebar-nav.tsx.
domains/
Domain-driven data access layer. Each domain encapsulates Firestore read/write logic for a specific business entity. This separates business logic from UI components.
Pattern: Each domain exports custom hooks (e.g.,
useWorkshop, useAgents) that consume repositories and manage React state. Hooks receive tenantId and projectId from a parent context.
hooks/
Global custom React hooks shared across the app (not tied to a specific domain):
lib/
Utility functions and shared logic:
packages/
Internal shared packages. These are TypeScript modules used across the monorepo.
plugins/
OpenCode agent plugins that extend the AI coding agent’s capabilities:
Key entry point:
plugins/agent/README.md explains how to install and use the Shokunin agent plugin.
apps/
Micro-frontend applications:
infrastructure/
Local backend service configurations (see also docker-compose.yml at the root):
terraform/
GCP infrastructure as code. Provisions all cloud resources for the Shokunin Platform:
platform/environments/dev-shared/— VPC, Artifact Registry, GKE Autopilot, GKE Gateway, Workshop Provisionerplatform/environments/staging/andproduction/— full Beads stack (Dolt VM, Filestore, Cloud Run)platform/environments/dev/— per-developer Firestore database and Secret Manager accessplatform/modules/— reusable single-purpose modulesterraform/tenants/— per-tenant GKE namespace, HTTPRoutes, Workshop workloadterraform/config/— environment and tenant.tfvarsconfiguration files
terraform/README.md for the conceptual infrastructure diagram and GCP component list.