Skip to main content
Version: 0.4.0

Model what the organization does

Say what the organization does, whatever the systems: its domains, the function groups and functions inside them, and which systems carry each out. The guide grows one small model, a shop, a step at a time, and every step is a whole model that builds with no error or lint: type it into model/ in a repository kq init made, and check it with kq validate or in VS Code as you type. Every statement used here is described in full in Business functions.

Start with the ecosystem​

An ecosystem is the outermost boundary, usually a company, and everything sits inside one. The token in parentheses after its name is the organization's own abbreviation, which is optional. The shop's:

ecosystem shop "Shop" (SHOP)

Every later step writes inside its block. See Ecosystem.

Cut the domains​

Write a domain for each area the organization works in, with its function groups and functions inside it. Levels may be skipped but not reordered, and a domain holds either sub-domains or function groups and functions, never a mix. Your organization's own code goes in parentheses right after the name, such as APQC's hierarchy number. The shop sells and ships:

ecosystem shop "Shop" (SHOP) { domain selling "Selling" ("1") { function-group take-orders "Take orders" ("1.1") { function place-order "Place an order" ("1.1.1") function cancel-order "Cancel an order" ("1.1.2") } function-group pay "Take payments" ("1.2") } domain fulfilment "Fulfilment" ("2") { function ship-order "Ship an order" ("2.1") } }

Fulfilment skips a level: ship-order sits directly in its domain. A function group never sits in another. See Domain, function group, function.

Set the shared services apart​

enabler after a domain's name makes it an Enabler Domain: one that holds shared software components or shared infrastructure, such as identity, messaging or monitoring, that other domains lean on. Business capabilities never go in one. Add the shop's sign-in as one:

ecosystem shop "Shop" (SHOP) { domain selling "Selling" ("1") { function-group take-orders "Take orders" ("1.1") { function place-order "Place an order" ("1.1.1") function cancel-order "Cancel an order" ("1.1.2") } function-group pay "Take payments" ("1.2") } domain fulfilment "Fulfilment" ("2") { function ship-order "Ship an order" ("2.1") } domain identity-access "Identity" enabler { function-group sign-in "Sign people in" } }

Only a domain directly in an ecosystem can be an Enabler Domain, KQ025. See Enabler Domains.

Connect the systems to the functions​

A function is carried out by the components that realize it. realizes joins a component to a domain, function group or function in the same ecosystem. Add the storefront's components, each realizing what it does, and the two calls the order service makes:

ecosystem shop "Shop" (SHOP) { domain selling "Selling" ("1") { function-group take-orders "Take orders" ("1.1") { function place-order "Place an order" ("1.1.1") function cancel-order "Cancel an order" ("1.1.2") } function-group pay "Take payments" ("1.2") } domain fulfilment "Fulfilment" ("2") { function ship-order "Ship an order" ("2.1") } domain identity-access "Identity" enabler { function-group sign-in "Sign people in" } platform storefront "Storefront" { component order-service "Order Service" : backend component payments "Payments" : saas component warehouse "Warehouse" : backend component sign-in "Sign-in" : saas order-service -> payments/payments-api over http auth key order-service -> sign-in/token-api over http auth client-credentials order-service realizes selling/take-orders payments realizes selling/pay warehouse realizes fulfilment/ship-order sign-in realizes identity-access/sign-in } }

A component may realize a whole function group, as the order service does, or one function, as the warehouse does. See Realization, and Model the applications for the components and their calls.

See what you modeled​

A Domain's layered view answers what the Domain does and which components do it: its functions above, the components that realize them below, every box labeled with its code. Selling's, drawn from the last step:

The diagram in words

1 Selling · Layered application view

Ecosystem

  • Shop (Ecosystem)

Domains

  • 1 Selling (Domain)

Function Groups

  • 1.1 Take orders (Function Group)
  • 1.2 Take payments (Function Group)

Domain Components

  • Storefront (Platform)
    • Order Service (Backend)
    • Payments (SaaS)
      • payments-api (HTTP API)

Enablers

  • Shop (Ecosystem)
    • Identity (Enabler Domain)
      • Sign-in (SaaS)

Lines

  • Order Service → payments-api: connection, http · key
  • Order Service → Sign-in: connection, http · client-credentials

Sign-in realizes into an Enabler Domain, so it stands apart in a band of its own, Enablers, framed by Identity. In VS Code, the viewer draws it as you type. See Layered view.

Where next​

© 2026 Extenza Works. All rights reserved.