# lubusin/frappe-skills architecture

> Architecture diagram of the GitHub repository lubusin/frappe-skills, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-08-21). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/lubusin/frappe-skills
- Repository: https://github.com/lubusin/frappe-skills

## Overview

#### Purpose and Distribution
This repository is a framework-knowledge package for AI coding assistants working on Frappe. It is not a runnable Frappe application: its primary deliverable is structured Markdown skill instructions, installed through the Skills CLI or copied into an assistant’s skill directory. Repository-level orientation and installation are in `README.md`.

#### Routing and Task Intake
The task-selection layer directs an assistant from a user request to the appropriate specialized procedure. `router/SKILL.md` is the primary routing entry point; `project-triage/SKILL.md` establishes project type, installed Frappe apps, framework version, and available tooling before implementation-oriented skills are applied.

#### Core Frappe Development Guidance
The main backend-development domains are separated into focused skills:
- Application scaffolding, hooks, services, jobs, and integrations: `app-development/SKILL.md`
- Schema/model and lifecycle-controller work around Frappe DocTypes: `doctype-development/SKILL.md`
- REST/RPC endpoints, authentication, permissions, rate limits, and webhooks: `api-development/SKILL.md`
- Production-grade workflows, queues, SLAs, integrations, and authorization patterns: `enterprise-patterns/SKILL.md`

Each skill is a procedural front door, with detailed constraints moved to its local `references/` content.

#### UI, Data Presentation, and Document Output
A separate presentation layer covers Frappe Desk customization, external frontends, reports, forms, and rendered documents. Key boundaries are Desk-side JavaScript APIs (`desk-customization/SKILL.md`), Vue 3/Frappe UI frontend work (`frontend-development/SKILL.md`), reporting (`reports/SKILL.md`), and Jinja/print rendering (`printing-templates/SKILL.md`). Public data-capture workflows are handled independently in `web-forms/SKILL.md`.

#### Reference-Driven Execution Model
The control flow is: select skill → gather declared inputs → follow its procedure → consult topical references when needed → run the skill’s verification and handle documented failure modes. For example, API work expands from `api-development/SKILL.md` into `api-development/references/authentication.md`, `api-development/references/permissions.md`, and `api-development/references/webhooks.md`; DocType work similarly expands through `doctype-development/references/controllers.md` and `doctype-development/references/doctypes.md`.

#### Runtime and Infrastructure Boundaries
The guidance targets the Frappe ecosystem, including Python server-side code, Frappe Desk/browser JavaScript, Vue 3 via Frappe UI, and Jinja templating. Operational guidance is encapsulated in `frappe-manager/SKILL.md`, including Bench, Docker-based environments, command workflows, and SSL material under `frappe-manager/references/`. Testing guidance spans unit/integration/UI approaches in `testing/SKILL.md`.

#### Embedded Reference Implementation
The repository includes a compact illustrative Frappe app rather than production runtime code. `app-development/assets/mini-app-template/your_app/hooks.py` represents app integration points; `app-development/assets/mini-app-template/your_app/doctype/` demonstrates DocType assets and controllers; `app-development/assets/mini-app-template/your_app/services/sample_service.py` and `background_jobs/sample_job.py` show service and asynchronous-job boundaries. This template anchors the documented app architecture in concrete expected file layouts.

Main entry points: [`router/SKILL.md`](https://github.com/lubusin/frappe-skills/blob/main/router/SKILL.md) (Skill router), [`app-development/SKILL.md`](https://github.com/lubusin/frappe-skills/blob/main/app-development/SKILL.md) (App development), [`project-triage/SKILL.md`](https://github.com/lubusin/frappe-skills/blob/main/project-triage/SKILL.md) (Project triage), [`doctype-development/SKILL.md`](https://github.com/lubusin/frappe-skills/blob/main/doctype-development/SKILL.md) (DocType development)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_intake["Task Intake"]
  node_router["Skill router<br/>routing skill<br/>[SKILL.md]"]
  node_triage["Project triage<br/>intake skill<br/>[SKILL.md]"]
end

subgraph group_development["Development Skills"]
  node_app_dev["App development<br/>backend skill<br/>[SKILL.md]"]
  node_doctype_dev["DocType development<br/>model skill<br/>[SKILL.md]"]
  node_api_dev["API development<br/>API skill<br/>[SKILL.md]"]
  node_enterprise["Enterprise patterns<br/>workflow skill<br/>[SKILL.md]"]
  node_api_refs["API references<br/>topical references<br/>[authentication.md]"]
  node_doctype_refs["DocType references<br/>topical references<br/>[controllers.md]"]
end

subgraph group_presentation["Presentation Skills"]
  node_desk["Desk customization<br/>UI skill<br/>[SKILL.md]"]
  node_frontend["Frontend development<br/>frontend skill<br/>[SKILL.md]"]
  node_reports["Reports<br/>reporting skill<br/>[SKILL.md]"]
  node_printing["Print templates<br/>rendering skill<br/>[SKILL.md]"]
  node_web_forms["Web forms<br/>public workflow skill<br/>[SKILL.md]"]
end

subgraph group_operations["Operations &amp; Quality"]
  node_manager["Frappe manager<br/>operations skill<br/>[SKILL.md]"]
  node_testing["Testing<br/>quality skill<br/>[SKILL.md]"]
end

subgraph group_template["Reference App Template"]
  node_template_hooks["App hooks<br/>template integration<br/>[hooks.py]"]
  node_template_doctype["DocType assets<br/>template model"]
  node_template_service["Sample service<br/>template service<br/>[sample_service.py]"]
  node_template_job["Sample background job<br/>template job<br/>[sample_job.py]"]
end

node_readme["Repository orientation<br/>distribution guide<br/>[README.md]"]

node_readme -->|"installs and starts with"| node_router
node_router -->|"triages implementation work"| node_triage
node_triage -->|"routes backend tasks"| node_app_dev
node_triage -->|"routes model tasks"| node_doctype_dev
node_triage -->|"routes API tasks"| node_api_dev
node_router -->|"routes UI tasks"| node_desk
node_router -->|"routes frontend tasks"| node_frontend
node_router -->|"routes reporting tasks"| node_reports
node_router -->|"routes document-output tasks"| node_printing
node_router -->|"routes public-form tasks"| node_web_forms
node_api_dev -.->|"consults"| node_api_refs
node_doctype_dev -.->|"consults"| node_doctype_refs
node_app_dev -.->|"anchors in example"| node_template_hooks
node_app_dev -.->|"anchors in example"| node_template_service
node_app_dev -.->|"anchors in example"| node_template_job
node_doctype_dev -.->|"anchors in example"| node_template_doctype
node_app_dev -.->|"extends with production patterns"| node_enterprise
node_manager -.->|"supports verification workflows"| node_testing
node_testing -.->|"verifies implementation"| node_app_dev

click node_readme "https://github.com/lubusin/frappe-skills/blob/main/README.md"
click node_router "https://github.com/lubusin/frappe-skills/blob/main/router/SKILL.md"
click node_triage "https://github.com/lubusin/frappe-skills/blob/main/project-triage/SKILL.md"
click node_app_dev "https://github.com/lubusin/frappe-skills/blob/main/app-development/SKILL.md"
click node_doctype_dev "https://github.com/lubusin/frappe-skills/blob/main/doctype-development/SKILL.md"
click node_api_dev "https://github.com/lubusin/frappe-skills/blob/main/api-development/SKILL.md"
click node_enterprise "https://github.com/lubusin/frappe-skills/blob/main/enterprise-patterns/SKILL.md"
click node_desk "https://github.com/lubusin/frappe-skills/blob/main/desk-customization/SKILL.md"
click node_frontend "https://github.com/lubusin/frappe-skills/blob/main/frontend-development/SKILL.md"
click node_reports "https://github.com/lubusin/frappe-skills/blob/main/reports/SKILL.md"
click node_printing "https://github.com/lubusin/frappe-skills/blob/main/printing-templates/SKILL.md"
click node_web_forms "https://github.com/lubusin/frappe-skills/blob/main/web-forms/SKILL.md"
click node_manager "https://github.com/lubusin/frappe-skills/blob/main/frappe-manager/SKILL.md"
click node_testing "https://github.com/lubusin/frappe-skills/blob/main/testing/SKILL.md"
click node_api_refs "https://github.com/lubusin/frappe-skills/blob/main/api-development/references/authentication.md"
click node_doctype_refs "https://github.com/lubusin/frappe-skills/blob/main/doctype-development/references/controllers.md"
click node_template_hooks "https://github.com/lubusin/frappe-skills/blob/main/app-development/assets/mini-app-template/your_app/hooks.py"
click node_template_service "https://github.com/lubusin/frappe-skills/blob/main/app-development/assets/mini-app-template/your_app/services/sample_service.py"
click node_template_job "https://github.com/lubusin/frappe-skills/blob/main/app-development/assets/mini-app-template/your_app/background_jobs/sample_job.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_router,node_triage toneBlue
class node_app_dev,node_doctype_dev,node_api_dev,node_enterprise,node_api_refs,node_doctype_refs toneAmber
class node_desk,node_frontend,node_reports,node_printing,node_web_forms toneMint
class node_manager,node_testing toneRose
class node_template_hooks,node_template_doctype,node_template_service,node_template_job toneIndigo
class node_readme toneNeutral
```

## Components

### Task Intake

- [Skill router](https://github.com/lubusin/frappe-skills/blob/main/router/SKILL.md): routing skill · Primary entry point for selecting a procedure. · `router/SKILL.md`
- [Project triage](https://github.com/lubusin/frappe-skills/blob/main/project-triage/SKILL.md): intake skill · Establishes project type, apps, Frappe version, and tooling. · `project-triage/SKILL.md`

### Development Skills

- [App development](https://github.com/lubusin/frappe-skills/blob/main/app-development/SKILL.md): backend skill · Covers scaffolding, hooks, services, jobs, and integrations. · `app-development/SKILL.md`
- [DocType development](https://github.com/lubusin/frappe-skills/blob/main/doctype-development/SKILL.md): model skill · Covers schema and lifecycle controllers. · `doctype-development/SKILL.md`
- [API development](https://github.com/lubusin/frappe-skills/blob/main/api-development/SKILL.md): API skill · Covers REST/RPC, auth, permissions, limits, and webhooks. · `api-development/SKILL.md`
- [Enterprise patterns](https://github.com/lubusin/frappe-skills/blob/main/enterprise-patterns/SKILL.md): workflow skill · Covers queues, SLAs, integrations, and authorization. · `enterprise-patterns/SKILL.md`
- [API references](https://github.com/lubusin/frappe-skills/blob/main/api-development/references/authentication.md): topical references · Authentication, permissions, and webhook constraints. · `api-development/references/authentication.md`
- [DocType references](https://github.com/lubusin/frappe-skills/blob/main/doctype-development/references/controllers.md): topical references · Controller and DocType implementation constraints. · `doctype-development/references/controllers.md`

### Presentation Skills

- [Desk customization](https://github.com/lubusin/frappe-skills/blob/main/desk-customization/SKILL.md): UI skill · Covers Desk-side JavaScript APIs. · `desk-customization/SKILL.md`
- [Frontend development](https://github.com/lubusin/frappe-skills/blob/main/frontend-development/SKILL.md): frontend skill · Covers Vue 3 and Frappe UI. · `frontend-development/SKILL.md`
- [Reports](https://github.com/lubusin/frappe-skills/blob/main/reports/SKILL.md): reporting skill · `reports/SKILL.md`
- [Print templates](https://github.com/lubusin/frappe-skills/blob/main/printing-templates/SKILL.md): rendering skill · Covers Jinja and print rendering. · `printing-templates/SKILL.md`
- [Web forms](https://github.com/lubusin/frappe-skills/blob/main/web-forms/SKILL.md): public workflow skill · Covers public data-capture workflows. · `web-forms/SKILL.md`

### Operations & Quality

- [Frappe manager](https://github.com/lubusin/frappe-skills/blob/main/frappe-manager/SKILL.md): operations skill · Covers Bench, Docker, commands, and SSL operations. · `frappe-manager/SKILL.md`
- [Testing](https://github.com/lubusin/frappe-skills/blob/main/testing/SKILL.md): quality skill · Covers unit, integration, and UI testing. · `testing/SKILL.md`

### Reference App Template

Illustrative Frappe app layout embedded with app-development guidance.

- [App hooks](https://github.com/lubusin/frappe-skills/blob/main/app-development/assets/mini-app-template/your_app/hooks.py): template integration · Concrete app integration points. · `app-development/assets/mini-app-template/your_app/hooks.py`
- **DocType assets**: template model · Example DocType assets and controllers.
- [Sample service](https://github.com/lubusin/frappe-skills/blob/main/app-development/assets/mini-app-template/your_app/services/sample_service.py): template service · Example service boundary. · `app-development/assets/mini-app-template/your_app/services/sample_service.py`
- [Sample background job](https://github.com/lubusin/frappe-skills/blob/main/app-development/assets/mini-app-template/your_app/background_jobs/sample_job.py): template job · Example asynchronous-job boundary. · `app-development/assets/mini-app-template/your_app/background_jobs/sample_job.py`

### Other components

- [Repository orientation](https://github.com/lubusin/frappe-skills/blob/main/README.md): distribution guide · Explains installation through Skills CLI or skill-directory copy. · `README.md`

## Connections

- Repository orientation → Skill router: installs and starts with
- Skill router → Project triage: triages implementation work
- Project triage → App development: routes backend tasks
- Project triage → DocType development: routes model tasks
- Project triage → API development: routes API tasks
- Skill router → Desk customization: routes UI tasks
- Skill router → Frontend development: routes frontend tasks
- Skill router → Reports: routes reporting tasks
- Skill router → Print templates: routes document-output tasks
- Skill router → Web forms: routes public-form tasks
- API development → API references: consults
- DocType development → DocType references: consults
- App development → App hooks: anchors in example
- App development → Sample service: anchors in example
- App development → Sample background job: anchors in example
- DocType development → DocType assets: anchors in example
- App development → Enterprise patterns: extends with production patterns
- Frappe manager → Testing: supports verification workflows
- Testing → App development: verifies implementation
