@synap-core/workspace-templates 0.5.0 → 0.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/src/hr.yaml CHANGED
@@ -37,6 +37,9 @@ profiles:
37
37
  icon: user-round
38
38
  color: indigo
39
39
  description: "A person on the team — the core people record."
40
+ profileKind: role
41
+ applicableKinds:
42
+ - person
40
43
  properties:
41
44
  - slug: role-title
42
45
  label: Role
@@ -123,6 +126,9 @@ profiles:
123
126
  icon: user-plus
124
127
  color: cyan
125
128
  description: "A person moving through the hiring pipeline for a role."
129
+ profileKind: role
130
+ applicableKinds:
131
+ - person
126
132
  properties:
127
133
  - slug: stage
128
134
  label: Stage
package/src/index.ts CHANGED
@@ -36,6 +36,7 @@ export type {
36
36
  TemplateIntegration,
37
37
  TemplateAutomation,
38
38
  TemplateExtendsRef,
39
+ TemplateDependency,
39
40
  TemplateProfileEntityBentoTemplates,
40
41
  TemplateDefaultSource,
41
42
  TemplateSourceRole,
@@ -43,20 +44,20 @@ export type {
43
44
  TemplateOnboardingCollectTarget,
44
45
  TemplatePlaybook,
45
46
  TemplatePlaybookParam,
46
- } from './types.js';
47
+ } from "./types.js";
47
48
 
48
49
  export {
49
50
  WORKSPACE_TEMPLATES,
50
51
  getWorkspaceTemplate,
51
52
  listWorkspaceTemplates,
52
53
  listPublicTemplates,
53
- } from './templates.js';
54
+ } from "./templates.js";
54
55
 
55
- export type { WorkspaceTemplateSlug } from './templates.js';
56
+ export type { WorkspaceTemplateSlug } from "./templates.js";
56
57
 
57
- export { toWorkspaceDefinition, toPackageDefinition } from './define.js';
58
+ export { toWorkspaceDefinition, toPackageDefinition } from "./define.js";
58
59
  export type {
59
60
  WorkspaceDefinitionInput,
60
61
  ToDefinitionResult,
61
62
  PackageDefinitionOutput,
62
- } from './define.js';
63
+ } from "./define.js";
@@ -0,0 +1,499 @@
1
+ # Internal Runbook workspace template — the company's OPERATING SYSTEM.
2
+ # The head-of-ops / chief-of-staff layer: how the business actually runs day to
3
+ # day — the documented procedures (SOPs), the recurring processes (workflows),
4
+ # the tool stack and vendors behind them, the metrics/SLAs that keep them
5
+ # honest, and the rituals/cadences that keep everyone aligned.
6
+ # Provider of the `runbook` domain. Validated against types.ts at build time.
7
+
8
+ meta:
9
+ slug: internal-runbook
10
+ name: Internal Runbook
11
+ description: The company's operating system — SOPs, workflows, vendors, tools, metrics, and rituals that keep the business running.
12
+ icon: settings-2
13
+ color: "#64748B"
14
+ tags: [operations, sops, vendors, workflows]
15
+ isPublic: true
16
+
17
+ workspace:
18
+ name: Internal Runbook
19
+ description: The operating layer of the company — documented procedures, recurring processes, the tool stack and vendors behind them, operational metrics, and the rituals that keep the team aligned.
20
+ proposalId: operations-v1
21
+ subtype: internal-runbook
22
+ visibility: members
23
+ workspaceType: operational
24
+ capabilities:
25
+ - operations.sops
26
+ - operations.vendors
27
+ - operations.workflows
28
+ sourceRoles:
29
+ runbook: provider
30
+
31
+ profiles:
32
+ - slug: sop
33
+ displayName: SOP
34
+ icon: book-open
35
+ color: "#64748B"
36
+ description: "A standard operating procedure or runbook — the documented, repeatable way to do a thing."
37
+ scope: WORKSPACE
38
+ properties:
39
+ - slug: category
40
+ label: Category
41
+ valueType: string
42
+ inputType: select
43
+ enumValues: [Onboarding, Finance, People, IT, Support, Sales, Legal, Facilities, Other]
44
+ - slug: sop-status
45
+ label: Status
46
+ valueType: string
47
+ inputType: select
48
+ enumValues: [Draft, Active, Needs Review, Deprecated]
49
+ constraints: { defaultValue: Draft }
50
+ - slug: owner
51
+ label: Owner
52
+ valueType: string
53
+ inputType: text
54
+ placeholder: Who owns this procedure?
55
+ - slug: trigger
56
+ label: When to run
57
+ valueType: string
58
+ inputType: textarea
59
+ placeholder: What situation triggers this procedure?
60
+ - slug: last-reviewed
61
+ label: Last Reviewed
62
+ valueType: date
63
+ inputType: date
64
+ - slug: steps
65
+ label: Steps
66
+ valueType: string
67
+ inputType: textarea
68
+ placeholder: The step-by-step procedure...
69
+
70
+ - slug: workflow
71
+ displayName: Workflow
72
+ icon: workflow
73
+ color: "#0EA5E9"
74
+ description: "A recurring business process — a repeatable flow with an owner, a cadence, and an input/output."
75
+ scope: WORKSPACE
76
+ properties:
77
+ - slug: workflow-status
78
+ label: Status
79
+ valueType: string
80
+ inputType: select
81
+ enumValues: [Backlog, Active, Blocked, Optimizing, Retired]
82
+ constraints: { defaultValue: Active }
83
+ - slug: frequency
84
+ label: Frequency
85
+ valueType: string
86
+ inputType: select
87
+ enumValues: [Ad-hoc, Daily, Weekly, Monthly, Quarterly]
88
+ - slug: owner
89
+ label: Owner
90
+ valueType: string
91
+ inputType: text
92
+ placeholder: Process owner
93
+ - slug: automation-level
94
+ label: Automation
95
+ valueType: string
96
+ inputType: select
97
+ enumValues: [Manual, Semi-automated, Automated]
98
+ - slug: input
99
+ label: Input
100
+ valueType: string
101
+ inputType: text
102
+ placeholder: What kicks it off?
103
+ - slug: output
104
+ label: Output
105
+ valueType: string
106
+ inputType: text
107
+ placeholder: What it produces
108
+
109
+ - slug: vendor
110
+ displayName: Vendor
111
+ icon: truck
112
+ color: "#8B5CF6"
113
+ description: "A supplier, contractor, or service provider the company pays and depends on."
114
+ scope: WORKSPACE
115
+ profileKind: role
116
+ applicableKinds:
117
+ - company
118
+ properties:
119
+ - slug: vendor-category
120
+ label: Category
121
+ valueType: string
122
+ inputType: select
123
+ enumValues: [Software, Service, Supplier, Contractor, Agency, Other]
124
+ - slug: vendor-status
125
+ label: Status
126
+ valueType: string
127
+ inputType: select
128
+ enumValues: [Active, Trial, Evaluating, Paused, Churned]
129
+ constraints: { defaultValue: Active }
130
+ - slug: owner
131
+ label: Owner
132
+ valueType: string
133
+ inputType: text
134
+ placeholder: Internal relationship owner
135
+ - slug: monthly-cost
136
+ label: "Monthly Cost (€)"
137
+ valueType: number
138
+ inputType: number
139
+ placeholder: "0"
140
+ - slug: renewal-date
141
+ label: Renewal Date
142
+ valueType: date
143
+ inputType: date
144
+ - slug: website
145
+ label: Website
146
+ valueType: string
147
+ inputType: url
148
+ placeholder: "https://..."
149
+ - slug: notes
150
+ label: Notes
151
+ valueType: string
152
+ inputType: textarea
153
+
154
+ - slug: tool
155
+ displayName: Tool
156
+ icon: wrench
157
+ color: "#F59E0B"
158
+ description: "A tool in the company stack — the software the team actually uses to get work done."
159
+ scope: WORKSPACE
160
+ properties:
161
+ - slug: tool-category
162
+ label: Category
163
+ valueType: string
164
+ inputType: select
165
+ enumValues: [Productivity, Comms, Finance, Sales, Marketing, Dev, Design, Data, HR, Other]
166
+ - slug: tool-status
167
+ label: Status
168
+ valueType: string
169
+ inputType: select
170
+ enumValues: [Active, Trial, Deprecated]
171
+ constraints: { defaultValue: Active }
172
+ - slug: owner
173
+ label: Owner
174
+ valueType: string
175
+ inputType: text
176
+ placeholder: Admin / owner
177
+ - slug: seats
178
+ label: Seats
179
+ valueType: number
180
+ inputType: number
181
+ placeholder: "0"
182
+ - slug: monthly-cost
183
+ label: "Monthly Cost (€)"
184
+ valueType: number
185
+ inputType: number
186
+ placeholder: "0"
187
+ - slug: url
188
+ label: URL
189
+ valueType: string
190
+ inputType: url
191
+ placeholder: "https://..."
192
+
193
+ - slug: process-metric
194
+ displayName: Metric
195
+ icon: gauge
196
+ color: "#10B981"
197
+ description: "An operational SLA or KPI — a number the team commits to and tracks against a target."
198
+ scope: WORKSPACE
199
+ properties:
200
+ - slug: metric-type
201
+ label: Type
202
+ valueType: string
203
+ inputType: select
204
+ enumValues: [SLA, KPI, Health]
205
+ - slug: metric-status
206
+ label: Status
207
+ valueType: string
208
+ inputType: select
209
+ enumValues: [On Track, At Risk, Off Track]
210
+ constraints: { defaultValue: On Track }
211
+ - slug: target
212
+ label: Target
213
+ valueType: string
214
+ inputType: text
215
+ placeholder: e.g. < 4h, > 95%
216
+ - slug: current
217
+ label: Current
218
+ valueType: string
219
+ inputType: text
220
+ placeholder: Latest reading
221
+ - slug: cadence
222
+ label: Cadence
223
+ valueType: string
224
+ inputType: select
225
+ enumValues: [Daily, Weekly, Monthly, Quarterly]
226
+ - slug: owner
227
+ label: Owner
228
+ valueType: string
229
+ inputType: text
230
+ placeholder: Who's accountable?
231
+
232
+ - slug: ritual
233
+ displayName: Ritual
234
+ icon: repeat
235
+ color: "#EC4899"
236
+ description: "A recurring meeting or cadence — standups, reviews, retros, planning — that keeps the team aligned."
237
+ scope: WORKSPACE
238
+ properties:
239
+ - slug: cadence
240
+ label: Cadence
241
+ valueType: string
242
+ inputType: select
243
+ enumValues: [Daily, Weekly, Biweekly, Monthly, Quarterly]
244
+ - slug: ritual-date
245
+ label: Next Occurrence
246
+ valueType: date
247
+ inputType: date
248
+ - slug: owner
249
+ label: Facilitator
250
+ valueType: string
251
+ inputType: text
252
+ placeholder: Who runs it?
253
+ - slug: attendees
254
+ label: Attendees
255
+ valueType: string
256
+ inputType: text
257
+ placeholder: Who attends?
258
+ - slug: duration-min
259
+ label: Duration (min)
260
+ valueType: number
261
+ inputType: number
262
+ placeholder: "30"
263
+ - slug: agenda
264
+ label: Agenda
265
+ valueType: string
266
+ inputType: textarea
267
+ placeholder: Standing agenda...
268
+
269
+ views:
270
+ - name: SOPs
271
+ slug: sops
272
+ type: table
273
+ scopeProfileSlug: sop
274
+ description: The documented procedures, by category and review status.
275
+ defaultView: true
276
+ config:
277
+ visibleColumns: [category, sop-status, owner, last-reviewed]
278
+ defaultSort: { field: last-reviewed, direction: asc }
279
+ - name: Workflows
280
+ slug: workflows
281
+ type: kanban
282
+ scopeProfileSlug: workflow
283
+ groupBy: workflow-status
284
+ description: Recurring processes on a board by status.
285
+ config:
286
+ groupByField: workflow-status
287
+ cardFields: [frequency, owner, automation-level]
288
+ - name: Vendors
289
+ slug: vendors
290
+ type: table
291
+ scopeProfileSlug: vendor
292
+ description: Suppliers and service providers, with cost, owner, and renewal.
293
+ config:
294
+ visibleColumns: [vendor-category, vendor-status, owner, monthly-cost, renewal-date]
295
+ defaultSort: { field: monthly-cost, direction: desc }
296
+ - name: Tool Stack
297
+ slug: tool-stack
298
+ type: table
299
+ scopeProfileSlug: tool
300
+ description: The software the team runs on.
301
+ config:
302
+ visibleColumns: [tool-category, tool-status, owner, seats, monthly-cost]
303
+ defaultSort: { field: monthly-cost, direction: desc }
304
+ - name: Metrics
305
+ slug: metrics
306
+ type: table
307
+ scopeProfileSlug: process-metric
308
+ description: Operational SLAs and KPIs against target.
309
+ config:
310
+ visibleColumns: [metric-type, metric-status, target, current, cadence, owner]
311
+ - name: Rituals
312
+ slug: rituals
313
+ type: calendar
314
+ scopeProfileSlug: ritual
315
+ description: Recurring meetings and cadences on a calendar.
316
+ config:
317
+ dateField: ritual-date
318
+ colorField: cadence
319
+
320
+ # Schema-level links — give the relation picker and graph domain-specific
321
+ # edges from day one, not just pod defaults.
322
+ entityLinks:
323
+ - sourceProfileSlug: sop
324
+ targetProfileSlug: workflow
325
+ type: documents
326
+ label: Documents
327
+ - sourceProfileSlug: workflow
328
+ targetProfileSlug: tool
329
+ type: uses
330
+ label: Uses
331
+ - sourceProfileSlug: tool
332
+ targetProfileSlug: vendor
333
+ type: provided_by
334
+ label: Provided by
335
+ - sourceProfileSlug: process-metric
336
+ targetProfileSlug: workflow
337
+ type: measures
338
+ label: Measures
339
+ - sourceProfileSlug: ritual
340
+ targetProfileSlug: workflow
341
+ type: reviews
342
+ label: Reviews
343
+
344
+ onboarding:
345
+ goal: Capture how the company actually runs — its core SOPs, its recurring workflows, the vendors and tools behind them, and the rituals that keep the team aligned — so the workspace mirrors the real operating system, not a generic template.
346
+ framing: >
347
+ THE OPERATOR: Act as a seasoned head of operations / chief of staff doing an
348
+ ops walkthrough. Be systems-minded and pragmatic — hunt for the procedures
349
+ that live only in someone's head, the processes that run every week, the
350
+ tools quietly draining budget, and the meetings that must happen. Refuse
351
+ vagueness: every workflow has an owner and a cadence, every SOP has a
352
+ trigger. Translate their answers into SOPs, workflows, vendors, tools, and
353
+ rituals.
354
+ expertise:
355
+ starters:
356
+ - >
357
+ Don't map the whole org or every process — start with the few recurring
358
+ processes that actually BREAK: the ones that cause fire drills, missed
359
+ handoffs, or "who was supposed to do that?" moments. Ask what went wrong last
360
+ month and reverse-engineer the workflow from the failure, not from an
361
+ idealized flowchart.
362
+ - >
363
+ SOP the highest-frequency × highest-pain work first. A daily task that hurts
364
+ every time beats a quarterly one that's annoying once. Propose that
365
+ prioritization out loud — "let's document the thing you do 50 times a month
366
+ before the thing you do twice a year" — instead of documenting alphabetically.
367
+ - >
368
+ Give every workflow a single named owner and a cadence before anything else.
369
+ Refuse "the team owns it" — that means no one does. If they can't name one
370
+ accountable person, that's the finding, and the workflow's real status is
371
+ "at risk", not "active".
372
+ blindSpots:
373
+ - >
374
+ A process nobody owns doesn't exist — it just hasn't failed publicly yet.
375
+ Hunt for the workflows that run on habit and goodwill with no owner; those
376
+ are the ones that collapse the week someone is on holiday.
377
+ - >
378
+ "It's all in my head" is a single point of failure, not a system. The most
379
+ dangerous SOPs are the undocumented ones the founder or one key person runs
380
+ from memory. Ask directly: what breaks if that person is out for two weeks? —
381
+ and document those first.
382
+ - >
383
+ Founders confuse activity with process. A recurring meeting or a busy Slack
384
+ channel isn't a workflow unless it has a defined input, a defined output, and
385
+ a trigger. If a "process" has no clear input→output, it's a habit; name it as
386
+ one and either give it structure or drop it.
387
+ bar: >
388
+ The workspace captures the handful of processes that actually run (and break)
389
+ the business — each with one accountable owner, a cadence, and a clear
390
+ input→output — the highest-frequency/highest-pain procedures are documented as
391
+ SOPs so they survive the owner leaving, and nothing critical lives only in one
392
+ person's head.
393
+ collect:
394
+ - profileSlug: sop
395
+ what: The core documented procedures / runbooks — the repeatable ways of doing key things.
396
+ cardinality: several
397
+ keyFields: [title, category, owner, sop-status]
398
+ - profileSlug: workflow
399
+ what: The recurring processes that run the business, each with an owner and a cadence.
400
+ cardinality: several
401
+ keyFields: [title, workflow-status, frequency, owner]
402
+ - profileSlug: vendor
403
+ what: The suppliers and service providers the company pays and depends on.
404
+ cardinality: few
405
+ keyFields: [title, vendor-category, monthly-cost, owner]
406
+ - profileSlug: tool
407
+ what: The main tools in the stack the team runs on.
408
+ cardinality: several
409
+ keyFields: [title, tool-category, owner, monthly-cost]
410
+ - profileSlug: ritual
411
+ what: The recurring meetings and cadences that keep the team aligned.
412
+ cardinality: few
413
+ keyFields: [title, cadence, owner]
414
+ openingQuestions:
415
+ - "What are the procedures that live only in someone's head today — the ones you'd need to write down if that person left?"
416
+ - "Which processes run on a fixed cadence — weekly, monthly — and who owns each?"
417
+ - "What tools and vendors is the company paying for, and who's the owner of each?"
418
+ doneWhen: A few core SOPs are documented with owners, the key recurring workflows exist with a cadence, the main vendors and tools are captured with cost, and the standing rituals are on the calendar.
419
+
420
+ app:
421
+ kind: stored
422
+ cellKey: entity-detail
423
+
424
+ layout:
425
+ defaultView: SOPs
426
+ defaultApp: null
427
+ pinnedApps: [dashboard, data, chat]
428
+ sidebarItems:
429
+ - kind: view
430
+ viewName: SOPs
431
+ label: SOPs
432
+ icon: book-open
433
+ - kind: view
434
+ viewName: Workflows
435
+ label: Workflows
436
+ icon: workflow
437
+ - kind: view
438
+ viewName: Vendors
439
+ label: Vendors
440
+ icon: truck
441
+ - kind: view
442
+ viewName: Tool Stack
443
+ label: Tool Stack
444
+ icon: wrench
445
+ - kind: view
446
+ viewName: Metrics
447
+ label: Metrics
448
+ icon: gauge
449
+ - kind: view
450
+ viewName: Rituals
451
+ label: Rituals
452
+ icon: repeat
453
+ - kind: app
454
+ appId: data
455
+ label: All Data
456
+ icon: database
457
+
458
+ bento:
459
+ viewName: Operations Command Center
460
+ blocks:
461
+ - kind: widget
462
+ widgetType: welcome-header
463
+ pos: { x: 0, y: 0, w: 12, h: 2 }
464
+ - kind: widget
465
+ widgetType: entity-count
466
+ pos: { x: 0, y: 2, w: 3, h: 2 }
467
+ config:
468
+ profileSlug: sop
469
+ label: SOPs
470
+ - kind: widget
471
+ widgetType: entity-count
472
+ pos: { x: 3, y: 2, w: 3, h: 2 }
473
+ config:
474
+ profileSlug: workflow
475
+ label: Workflows
476
+ - kind: widget
477
+ widgetType: entity-count
478
+ pos: { x: 6, y: 2, w: 3, h: 2 }
479
+ config:
480
+ profileSlug: vendor
481
+ label: Vendors
482
+ - kind: widget
483
+ widgetType: entity-count
484
+ pos: { x: 9, y: 2, w: 3, h: 2 }
485
+ config:
486
+ profileSlug: tool
487
+ label: Tools
488
+ - kind: view
489
+ viewName: Workflows
490
+ pos: { x: 0, y: 4, w: 8, h: 5 }
491
+ - kind: view
492
+ viewName: Metrics
493
+ pos: { x: 8, y: 4, w: 4, h: 5 }
494
+ - kind: view
495
+ viewName: SOPs
496
+ pos: { x: 0, y: 9, w: 6, h: 4 }
497
+ - kind: view
498
+ viewName: Vendors
499
+ pos: { x: 6, y: 9, w: 6, h: 4 }
package/src/legal.yaml CHANGED
@@ -67,7 +67,7 @@ profiles:
67
67
  valueType: string
68
68
  inputType: textarea
69
69
 
70
- - slug: contract
70
+ - slug: legal-contract
71
71
  displayName: Contract
72
72
  icon: file-signature
73
73
  color: violet
@@ -292,7 +292,7 @@ views:
292
292
  - name: Contracts
293
293
  slug: contracts
294
294
  type: table
295
- scopeProfileSlug: contract
295
+ scopeProfileSlug: legal-contract
296
296
  description: Every agreement, its counterparty, status, and term.
297
297
  defaultView: true
298
298
  config:
@@ -300,7 +300,7 @@ views:
300
300
  - name: Renewals
301
301
  slug: renewals
302
302
  type: kanban
303
- scopeProfileSlug: contract
303
+ scopeProfileSlug: legal-contract
304
304
  groupBy: status
305
305
  description: Contracts by lifecycle stage — catch renewals and expirations before they bite.
306
306
  config:
@@ -339,7 +339,7 @@ views:
339
339
 
340
340
  # Schema-level relations — give the relation picker domain-specific links from day one.
341
341
  entityLinks:
342
- - sourceProfileSlug: contract
342
+ - sourceProfileSlug: legal-contract
343
343
  targetProfileSlug: legal-entity
344
344
  type: party_to
345
345
  label: Party to
@@ -356,7 +356,7 @@ entityLinks:
356
356
  type: governed_by
357
357
  label: Governed by
358
358
  - sourceProfileSlug: legal-matter
359
- targetProfileSlug: contract
359
+ targetProfileSlug: legal-contract
360
360
  type: concerns
361
361
  label: Concerns
362
362
 
@@ -416,7 +416,7 @@ onboarding:
416
416
  what: The company's legal entities and the jurisdictions they operate in.
417
417
  cardinality: few
418
418
  keyFields: [entityType, jurisdiction, status]
419
- - profileSlug: contract
419
+ - profileSlug: legal-contract
420
420
  what: The key live agreements — the ones with real obligations, value, or renewal dates.
421
421
  cardinality: several
422
422
  keyFields: [contractType, status, counterparty, renewalDate]
@@ -10,6 +10,21 @@ meta:
10
10
  tags: [marketing, crm, outreach, leads, campaigns]
11
11
  isPublic: true
12
12
 
13
+ # SSOT ordering guarantee — this template REFERENCES foundation's pod-wide
14
+ # shared `lead` role. The apply engine seeds a shared profile's pod-wide BASE
15
+ # property body from whichever template creates it FIRST, and adds a REUSING
16
+ # template's extra props as workspace OVERLAYS. Without this dependency,
17
+ # marketing-first would make the pod-wide `lead` base marketing's 10-prop body
18
+ # for EVERY workspace. Requiring foundation makes the resolver install it first
19
+ # (deps-first), so the base is always foundation's SSOT body (leadStage, notes)
20
+ # and marketing's extras stay per-workspace overlays. `require`, not `compose`:
21
+ # foundation is a real workspace, not an overlay.
22
+ dependencies:
23
+ - slug: foundation
24
+ kind: workspace
25
+ relation: require
26
+ reason: "Provides the pod-wide lead role vocabulary (leadStage) this workspace reuses."
27
+
13
28
  workspace:
14
29
  name: Marketing Campaign OS
15
30
  description: "Track leads, manage campaigns, and let AI help run your outreach. Contacts, pipeline, tasks, and AI briefings — all connected."
@@ -20,6 +35,8 @@ workspace:
20
35
  - marketing.contacts
21
36
  - marketing.leads
22
37
  sourceRoles:
38
+ brand: consumer
39
+ content: consumer
23
40
  marketing: provider
24
41
 
25
42
  profiles:
@@ -80,6 +97,9 @@ profiles:
80
97
  color: blue
81
98
  description: "A person in your marketing contact list."
82
99
  semanticSlug: marketing.contact
100
+ profileKind: role
101
+ applicableKinds:
102
+ - person
83
103
  properties:
84
104
  - slug: contact-email
85
105
  label: Email
@@ -117,19 +137,26 @@ profiles:
117
137
  valueType: string
118
138
  inputType: text
119
139
 
140
+ # `scope: shared` dedups to the ONE pod-wide `lead` profile seeded by
141
+ # foundation.yaml (SSOT for leadStage). Ordering is guaranteed by the
142
+ # `require: foundation` dependency above — foundation always installs first,
143
+ # so the pod-wide BASE body is always foundation's and the props below are
144
+ # always workspace OVERLAYS on top of it. That is the legitimate extension
145
+ # mechanism: EXTRA props are fine. What is NOT fine is REDECLARING a prop
146
+ # foundation already owns (e.g. `leadStage`) with a divergent enum/default —
147
+ # that is base drift, and the SSOT tripwire fails on it.
148
+ # (Standards reference inherited base props like `leadStage` directly.)
120
149
  - slug: lead
121
150
  displayName: Lead
122
151
  icon: user-plus
123
152
  color: green
124
153
  description: "A potential customer or partner contact in your pipeline"
125
154
  semanticSlug: marketing.lead
155
+ scope: shared
156
+ profileKind: role
157
+ applicableKinds:
158
+ - person
126
159
  properties:
127
- - slug: lead-stage
128
- label: Stage
129
- valueType: string
130
- inputType: select
131
- enumValues: [new, contacted, interested, qualified, demo, proposal, converted, lost]
132
- constraints: { defaultValue: new }
133
160
  - slug: lead-source
134
161
  label: Source
135
162
  valueType: string
@@ -164,7 +191,7 @@ profiles:
164
191
  label: Last Contacted
165
192
  valueType: date
166
193
  inputType: date
167
- - slug: lead-notes
194
+ - slug: notes
168
195
  label: Notes
169
196
  valueType: string
170
197
  inputType: textarea
@@ -190,7 +217,7 @@ views:
190
217
  slug: lead-pipeline
191
218
  type: kanban
192
219
  scopeProfileSlug: lead
193
- groupBy: lead-stage
220
+ groupBy: leadStage
194
221
  description: "Lead pipeline kanban by stage."
195
222
 
196
223
  onboarding:
@@ -249,7 +276,7 @@ onboarding:
249
276
  - profileSlug: lead
250
277
  what: A few representative leads already in motion, placed at their true pipeline stage.
251
278
  cardinality: several
252
- keyFields: [lead-stage, lead-source, lead-company]
279
+ keyFields: [leadStage, lead-source, lead-company]
253
280
  - profileSlug: contact
254
281
  what: Key marketing contacts — the people already on the list and how they got there.
255
282
  cardinality: few