business-as-code 0.2.1 → 2.0.2

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.
Files changed (190) hide show
  1. package/.turbo/turbo-build.log +5 -0
  2. package/CHANGELOG.md +17 -0
  3. package/IMPLEMENTATION.md +226 -0
  4. package/README.md +1133 -193
  5. package/dist/business.d.ts +62 -0
  6. package/dist/business.d.ts.map +1 -0
  7. package/dist/business.js +109 -0
  8. package/dist/business.js.map +1 -0
  9. package/dist/dollar.d.ts +60 -0
  10. package/dist/dollar.d.ts.map +1 -0
  11. package/dist/dollar.js +107 -0
  12. package/dist/dollar.js.map +1 -0
  13. package/dist/entities/assets.d.ts +21 -0
  14. package/dist/entities/assets.d.ts.map +1 -0
  15. package/dist/entities/assets.js +323 -0
  16. package/dist/entities/assets.js.map +1 -0
  17. package/dist/entities/business.d.ts +36 -0
  18. package/dist/entities/business.d.ts.map +1 -0
  19. package/dist/entities/business.js +370 -0
  20. package/dist/entities/business.js.map +1 -0
  21. package/dist/entities/communication.d.ts +21 -0
  22. package/dist/entities/communication.d.ts.map +1 -0
  23. package/dist/entities/communication.js +255 -0
  24. package/dist/entities/communication.js.map +1 -0
  25. package/dist/entities/customers.d.ts +58 -0
  26. package/dist/entities/customers.d.ts.map +1 -0
  27. package/dist/entities/customers.js +989 -0
  28. package/dist/entities/customers.js.map +1 -0
  29. package/dist/entities/financials.d.ts +59 -0
  30. package/dist/entities/financials.d.ts.map +1 -0
  31. package/dist/entities/financials.js +932 -0
  32. package/dist/entities/financials.js.map +1 -0
  33. package/dist/entities/goals.d.ts +58 -0
  34. package/dist/entities/goals.d.ts.map +1 -0
  35. package/dist/entities/goals.js +800 -0
  36. package/dist/entities/goals.js.map +1 -0
  37. package/dist/entities/index.d.ts +299 -0
  38. package/dist/entities/index.d.ts.map +1 -0
  39. package/dist/entities/index.js +198 -0
  40. package/dist/entities/index.js.map +1 -0
  41. package/dist/entities/legal.d.ts +21 -0
  42. package/dist/entities/legal.d.ts.map +1 -0
  43. package/dist/entities/legal.js +301 -0
  44. package/dist/entities/legal.js.map +1 -0
  45. package/dist/entities/market.d.ts +21 -0
  46. package/dist/entities/market.d.ts.map +1 -0
  47. package/dist/entities/market.js +301 -0
  48. package/dist/entities/market.js.map +1 -0
  49. package/dist/entities/marketing.d.ts +67 -0
  50. package/dist/entities/marketing.d.ts.map +1 -0
  51. package/dist/entities/marketing.js +1157 -0
  52. package/dist/entities/marketing.js.map +1 -0
  53. package/dist/entities/offerings.d.ts +51 -0
  54. package/dist/entities/offerings.d.ts.map +1 -0
  55. package/dist/entities/offerings.js +727 -0
  56. package/dist/entities/offerings.js.map +1 -0
  57. package/dist/entities/operations.d.ts +58 -0
  58. package/dist/entities/operations.d.ts.map +1 -0
  59. package/dist/entities/operations.js +787 -0
  60. package/dist/entities/operations.js.map +1 -0
  61. package/dist/entities/organization.d.ts +57 -0
  62. package/dist/entities/organization.d.ts.map +1 -0
  63. package/dist/entities/organization.js +807 -0
  64. package/dist/entities/organization.js.map +1 -0
  65. package/dist/entities/partnerships.d.ts +21 -0
  66. package/dist/entities/partnerships.d.ts.map +1 -0
  67. package/dist/entities/partnerships.js +300 -0
  68. package/dist/entities/partnerships.js.map +1 -0
  69. package/dist/entities/planning.d.ts +87 -0
  70. package/dist/entities/planning.d.ts.map +1 -0
  71. package/dist/entities/planning.js +271 -0
  72. package/dist/entities/planning.js.map +1 -0
  73. package/dist/entities/projects.d.ts +25 -0
  74. package/dist/entities/projects.d.ts.map +1 -0
  75. package/dist/entities/projects.js +349 -0
  76. package/dist/entities/projects.js.map +1 -0
  77. package/dist/entities/risk.d.ts +21 -0
  78. package/dist/entities/risk.d.ts.map +1 -0
  79. package/dist/entities/risk.js +293 -0
  80. package/dist/entities/risk.js.map +1 -0
  81. package/dist/entities/sales.d.ts +72 -0
  82. package/dist/entities/sales.d.ts.map +1 -0
  83. package/dist/entities/sales.js +1248 -0
  84. package/dist/entities/sales.js.map +1 -0
  85. package/dist/financials.d.ts +130 -0
  86. package/dist/financials.d.ts.map +1 -0
  87. package/dist/financials.js +297 -0
  88. package/dist/financials.js.map +1 -0
  89. package/dist/goals.d.ts +87 -0
  90. package/dist/goals.d.ts.map +1 -0
  91. package/dist/goals.js +215 -0
  92. package/dist/goals.js.map +1 -0
  93. package/dist/index.d.ts +97 -4
  94. package/dist/index.d.ts.map +1 -0
  95. package/dist/index.js +131 -1079
  96. package/dist/index.js.map +1 -1
  97. package/dist/kpis.d.ts +118 -0
  98. package/dist/kpis.d.ts.map +1 -0
  99. package/dist/kpis.js +232 -0
  100. package/dist/kpis.js.map +1 -0
  101. package/dist/metrics.d.ts +448 -0
  102. package/dist/metrics.d.ts.map +1 -0
  103. package/dist/metrics.js +325 -0
  104. package/dist/metrics.js.map +1 -0
  105. package/dist/okrs.d.ts +123 -0
  106. package/dist/okrs.d.ts.map +1 -0
  107. package/dist/okrs.js +269 -0
  108. package/dist/okrs.js.map +1 -0
  109. package/dist/organization.d.ts +585 -0
  110. package/dist/organization.d.ts.map +1 -0
  111. package/dist/organization.js +173 -0
  112. package/dist/organization.js.map +1 -0
  113. package/dist/process.d.ts +112 -0
  114. package/dist/process.d.ts.map +1 -0
  115. package/dist/process.js +241 -0
  116. package/dist/process.js.map +1 -0
  117. package/dist/product.d.ts +85 -0
  118. package/dist/product.d.ts.map +1 -0
  119. package/dist/product.js +145 -0
  120. package/dist/product.js.map +1 -0
  121. package/dist/queries.d.ts +304 -0
  122. package/dist/queries.d.ts.map +1 -0
  123. package/dist/queries.js +415 -0
  124. package/dist/queries.js.map +1 -0
  125. package/dist/roles.d.ts +340 -0
  126. package/dist/roles.d.ts.map +1 -0
  127. package/dist/roles.js +255 -0
  128. package/dist/roles.js.map +1 -0
  129. package/dist/service.d.ts +61 -0
  130. package/dist/service.d.ts.map +1 -0
  131. package/dist/service.js +140 -0
  132. package/dist/service.js.map +1 -0
  133. package/dist/types.d.ts +459 -0
  134. package/dist/types.d.ts.map +1 -0
  135. package/dist/types.js +5 -0
  136. package/dist/types.js.map +1 -0
  137. package/dist/vision.d.ts +38 -0
  138. package/dist/vision.d.ts.map +1 -0
  139. package/dist/vision.js +68 -0
  140. package/dist/vision.js.map +1 -0
  141. package/dist/workflow.d.ts +115 -0
  142. package/dist/workflow.d.ts.map +1 -0
  143. package/dist/workflow.js +247 -0
  144. package/dist/workflow.js.map +1 -0
  145. package/examples/basic-usage.ts +307 -0
  146. package/package.json +19 -60
  147. package/src/business.ts +121 -0
  148. package/src/dollar.ts +132 -0
  149. package/src/entities/assets.ts +332 -0
  150. package/src/entities/business.ts +406 -0
  151. package/src/entities/communication.ts +264 -0
  152. package/src/entities/customers.ts +1072 -0
  153. package/src/entities/financials.ts +1011 -0
  154. package/src/entities/goals.ts +871 -0
  155. package/src/entities/index.ts +383 -0
  156. package/src/entities/legal.ts +310 -0
  157. package/src/entities/market.ts +310 -0
  158. package/src/entities/marketing.ts +1249 -0
  159. package/src/entities/offerings.ts +789 -0
  160. package/src/entities/operations.ts +861 -0
  161. package/src/entities/organization.ts +876 -0
  162. package/src/entities/partnerships.ts +309 -0
  163. package/src/entities/planning.ts +307 -0
  164. package/src/entities/projects.ts +360 -0
  165. package/src/entities/risk.ts +302 -0
  166. package/src/entities/sales.ts +1352 -0
  167. package/src/financials.ts +352 -0
  168. package/src/goals.ts +250 -0
  169. package/src/index.test.ts +336 -0
  170. package/src/index.ts +530 -0
  171. package/src/kpis.ts +275 -0
  172. package/src/metrics.ts +825 -0
  173. package/src/okrs.ts +325 -0
  174. package/src/organization.ts +909 -0
  175. package/src/process.ts +272 -0
  176. package/src/product.ts +178 -0
  177. package/src/queries.ts +767 -0
  178. package/src/roles.ts +686 -0
  179. package/src/service.ts +164 -0
  180. package/src/types.ts +493 -0
  181. package/src/vision.ts +88 -0
  182. package/src/workflow.ts +280 -0
  183. package/tsconfig.json +9 -0
  184. package/dist/loaders/index.d.ts +0 -174
  185. package/dist/loaders/index.js +0 -366
  186. package/dist/loaders/index.js.map +0 -1
  187. package/dist/schema/index.d.ts +0 -146
  188. package/dist/schema/index.js +0 -716
  189. package/dist/schema/index.js.map +0 -1
  190. package/dist/types-CJ9eGS_C.d.ts +0 -86
@@ -0,0 +1,370 @@
1
+ /**
2
+ * Business Entity Types (Nouns)
3
+ *
4
+ * Core business entities: Business, Vision, Mission, Values.
5
+ *
6
+ * @packageDocumentation
7
+ */
8
+ // =============================================================================
9
+ // Business
10
+ // =============================================================================
11
+ /**
12
+ * Business entity
13
+ *
14
+ * Represents a company, startup, or business unit.
15
+ */
16
+ export const Business = {
17
+ singular: 'business',
18
+ plural: 'businesses',
19
+ description: 'A company, startup, or business unit',
20
+ properties: {
21
+ // Identity
22
+ name: {
23
+ type: 'string',
24
+ description: 'Business name',
25
+ },
26
+ legalName: {
27
+ type: 'string',
28
+ optional: true,
29
+ description: 'Legal entity name',
30
+ },
31
+ slug: {
32
+ type: 'string',
33
+ optional: true,
34
+ description: 'URL-friendly identifier',
35
+ },
36
+ // Type
37
+ type: {
38
+ type: 'string',
39
+ optional: true,
40
+ description: 'Business type',
41
+ examples: ['startup', 'smb', 'enterprise', 'agency', 'nonprofit', 'government'],
42
+ },
43
+ stage: {
44
+ type: 'string',
45
+ optional: true,
46
+ description: 'Business stage',
47
+ examples: ['idea', 'pre-seed', 'seed', 'series-a', 'series-b', 'growth', 'mature'],
48
+ },
49
+ industry: {
50
+ type: 'string',
51
+ optional: true,
52
+ description: 'Industry or sector',
53
+ },
54
+ // Purpose
55
+ mission: {
56
+ type: 'string',
57
+ optional: true,
58
+ description: 'Mission statement',
59
+ },
60
+ vision: {
61
+ type: 'string',
62
+ optional: true,
63
+ description: 'Vision statement',
64
+ },
65
+ values: {
66
+ type: 'string',
67
+ array: true,
68
+ optional: true,
69
+ description: 'Core values',
70
+ },
71
+ tagline: {
72
+ type: 'string',
73
+ optional: true,
74
+ description: 'Business tagline or slogan',
75
+ },
76
+ // Market
77
+ targetMarket: {
78
+ type: 'string',
79
+ optional: true,
80
+ description: 'Target market description',
81
+ },
82
+ customerSegments: {
83
+ type: 'string',
84
+ array: true,
85
+ optional: true,
86
+ description: 'Customer segments',
87
+ },
88
+ // Location
89
+ headquarters: {
90
+ type: 'string',
91
+ optional: true,
92
+ description: 'Headquarters location',
93
+ },
94
+ locations: {
95
+ type: 'string',
96
+ array: true,
97
+ optional: true,
98
+ description: 'Office locations',
99
+ },
100
+ timezone: {
101
+ type: 'string',
102
+ optional: true,
103
+ description: 'Primary timezone',
104
+ },
105
+ // Size & Scale
106
+ teamSize: {
107
+ type: 'number',
108
+ optional: true,
109
+ description: 'Number of team members',
110
+ },
111
+ headcount: {
112
+ type: 'number',
113
+ optional: true,
114
+ description: 'Total headcount including contractors',
115
+ },
116
+ // Dates
117
+ foundedAt: {
118
+ type: 'date',
119
+ optional: true,
120
+ description: 'Founding date',
121
+ },
122
+ incorporatedAt: {
123
+ type: 'date',
124
+ optional: true,
125
+ description: 'Incorporation date',
126
+ },
127
+ // Contact
128
+ website: {
129
+ type: 'url',
130
+ optional: true,
131
+ description: 'Business website',
132
+ },
133
+ email: {
134
+ type: 'string',
135
+ optional: true,
136
+ description: 'Contact email',
137
+ },
138
+ phone: {
139
+ type: 'string',
140
+ optional: true,
141
+ description: 'Contact phone',
142
+ },
143
+ // Status
144
+ status: {
145
+ type: 'string',
146
+ optional: true,
147
+ description: 'Business status',
148
+ examples: ['active', 'inactive', 'acquired', 'closed'],
149
+ },
150
+ },
151
+ relationships: {
152
+ organization: {
153
+ type: 'Organization',
154
+ description: 'Organizational structure',
155
+ },
156
+ products: {
157
+ type: 'Product[]',
158
+ description: 'Product offerings',
159
+ },
160
+ services: {
161
+ type: 'Service[]',
162
+ description: 'Service offerings',
163
+ },
164
+ goals: {
165
+ type: 'Goal[]',
166
+ description: 'Business goals',
167
+ },
168
+ okrs: {
169
+ type: 'OKR[]',
170
+ description: 'Objectives and key results',
171
+ },
172
+ kpis: {
173
+ type: 'KPI[]',
174
+ description: 'Key performance indicators',
175
+ },
176
+ financials: {
177
+ type: 'FinancialPeriod[]',
178
+ description: 'Financial records',
179
+ },
180
+ },
181
+ actions: [
182
+ 'create',
183
+ 'update',
184
+ 'launch',
185
+ 'pivot',
186
+ 'scale',
187
+ 'acquire',
188
+ 'merge',
189
+ 'close',
190
+ 'archive',
191
+ ],
192
+ events: [
193
+ 'created',
194
+ 'updated',
195
+ 'launched',
196
+ 'pivoted',
197
+ 'scaled',
198
+ 'acquired',
199
+ 'merged',
200
+ 'closed',
201
+ 'archived',
202
+ ],
203
+ };
204
+ // =============================================================================
205
+ // Vision
206
+ // =============================================================================
207
+ /**
208
+ * Vision entity
209
+ *
210
+ * Represents a long-term vision statement with success indicators.
211
+ */
212
+ export const Vision = {
213
+ singular: 'vision',
214
+ plural: 'visions',
215
+ description: 'A long-term vision statement with success indicators',
216
+ properties: {
217
+ // Content
218
+ statement: {
219
+ type: 'string',
220
+ description: 'Vision statement',
221
+ },
222
+ description: {
223
+ type: 'string',
224
+ optional: true,
225
+ description: 'Expanded description',
226
+ },
227
+ // Timeframe
228
+ timeframe: {
229
+ type: 'string',
230
+ optional: true,
231
+ description: 'Target timeframe (e.g., "5 years", "2030")',
232
+ },
233
+ targetDate: {
234
+ type: 'date',
235
+ optional: true,
236
+ description: 'Target achievement date',
237
+ },
238
+ // Success
239
+ successIndicators: {
240
+ type: 'string',
241
+ array: true,
242
+ optional: true,
243
+ description: 'Indicators of success',
244
+ },
245
+ // Status
246
+ status: {
247
+ type: 'string',
248
+ optional: true,
249
+ description: 'Vision status',
250
+ examples: ['draft', 'active', 'achieved', 'revised', 'abandoned'],
251
+ },
252
+ progress: {
253
+ type: 'number',
254
+ optional: true,
255
+ description: 'Progress percentage (0-100)',
256
+ },
257
+ },
258
+ relationships: {
259
+ business: {
260
+ type: 'Business',
261
+ description: 'Parent business',
262
+ },
263
+ goals: {
264
+ type: 'Goal[]',
265
+ description: 'Supporting goals',
266
+ },
267
+ },
268
+ actions: [
269
+ 'create',
270
+ 'update',
271
+ 'activate',
272
+ 'revise',
273
+ 'achieve',
274
+ 'abandon',
275
+ 'archive',
276
+ ],
277
+ events: [
278
+ 'created',
279
+ 'updated',
280
+ 'activated',
281
+ 'revised',
282
+ 'achieved',
283
+ 'abandoned',
284
+ 'archived',
285
+ ],
286
+ };
287
+ // =============================================================================
288
+ // Value
289
+ // =============================================================================
290
+ /**
291
+ * Value entity
292
+ *
293
+ * Represents a core organizational value.
294
+ */
295
+ export const Value = {
296
+ singular: 'value',
297
+ plural: 'values',
298
+ description: 'A core organizational value',
299
+ properties: {
300
+ // Identity
301
+ name: {
302
+ type: 'string',
303
+ description: 'Value name',
304
+ },
305
+ description: {
306
+ type: 'string',
307
+ optional: true,
308
+ description: 'Value description',
309
+ },
310
+ // Behaviors
311
+ behaviors: {
312
+ type: 'string',
313
+ array: true,
314
+ optional: true,
315
+ description: 'Example behaviors demonstrating this value',
316
+ },
317
+ antiPatterns: {
318
+ type: 'string',
319
+ array: true,
320
+ optional: true,
321
+ description: 'Behaviors that violate this value',
322
+ },
323
+ // Priority
324
+ priority: {
325
+ type: 'number',
326
+ optional: true,
327
+ description: 'Priority order',
328
+ },
329
+ // Status
330
+ status: {
331
+ type: 'string',
332
+ optional: true,
333
+ description: 'Value status',
334
+ examples: ['active', 'deprecated'],
335
+ },
336
+ },
337
+ relationships: {
338
+ business: {
339
+ type: 'Business',
340
+ description: 'Parent business',
341
+ },
342
+ },
343
+ actions: [
344
+ 'create',
345
+ 'update',
346
+ 'prioritize',
347
+ 'deprecate',
348
+ 'archive',
349
+ ],
350
+ events: [
351
+ 'created',
352
+ 'updated',
353
+ 'prioritized',
354
+ 'deprecated',
355
+ 'archived',
356
+ ],
357
+ };
358
+ // =============================================================================
359
+ // Exports
360
+ // =============================================================================
361
+ export const BusinessEntities = {
362
+ Business,
363
+ Vision,
364
+ Value,
365
+ };
366
+ export const BusinessCategories = {
367
+ core: ['Business'],
368
+ purpose: ['Vision', 'Value'],
369
+ };
370
+ //# sourceMappingURL=business.js.map
@@ -0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AW;QACX,SAAS;KACV;IAED,MAAM,EAAE;QACN,SAAS;QACT,SAAS;QACT,aAAa;QACb,YAAY;QACZ,UAAU;KACX;CACF,CAAA;AAED,gFAAgF;AAChF,UAAU;AACV,gFAAgF;AAEhF,MAAM,CAAC,MAAM,gBAAgB,GAAG;IAC9B,QAAQ;IACR,MAAM;IACN,KAAK;CACN,CAAA;AAED,MAAM,CAAC,MAAM,kBAAkB,GAAG;IAChC,IAAI,EAAE,CAAC,UAAU,CAAC;IAClB,OAAO,EAAE,CAAC,QAAQ,EAAE,OAAO,CAAC;CACpB,CAAA"}
@@ -0,0 +1,21 @@
1
+ import type { Noun } from 'ai-database';
2
+ /**
3
+ * Communication & Collaboration Entities
4
+ * Meeting, Decision, ActionItem, Announcement, Feedback, Discussion
5
+ */
6
+ export declare const Meeting: Noun;
7
+ export declare const Decision: Noun;
8
+ export declare const ActionItem: Noun;
9
+ export declare const Announcement: Noun;
10
+ export declare const Feedback: Noun;
11
+ export declare const Discussion: Noun;
12
+ export declare const CommunicationEntities: {
13
+ Meeting: Noun;
14
+ Decision: Noun;
15
+ ActionItem: Noun;
16
+ Announcement: Noun;
17
+ Feedback: Noun;
18
+ Discussion: Noun;
19
+ };
20
+ export default CommunicationEntities;
21
+ //# sourceMappingURL=communication.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"communication.d.ts","sourceRoot":"","sources":["../../src/entities/communication.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,aAAa,CAAA;AAEvC;;;GAGG;AAEH,eAAO,MAAM,OAAO,EAAE,IA6CrB,CAAA;AAED,eAAO,MAAM,QAAQ,EAAE,IA2CtB,CAAA;AAED,eAAO,MAAM,UAAU,EAAE,IAmCxB,CAAA;AAED,eAAO,MAAM,YAAY,EAAE,IAiC1B,CAAA;AAED,eAAO,MAAM,QAAQ,EAAE,IAyCtB,CAAA;AAED,eAAO,MAAM,UAAU,EAAE,IAqCxB,CAAA;AAGD,eAAO,MAAM,qBAAqB;;;;;;;CAOjC,CAAA;AAED,eAAe,qBAAqB,CAAA"}
@@ -0,0 +1,255 @@
1
+ /**
2
+ * Communication & Collaboration Entities
3
+ * Meeting, Decision, ActionItem, Announcement, Feedback, Discussion
4
+ */
5
+ export const Meeting = {
6
+ singular: 'meeting',
7
+ plural: 'meetings',
8
+ description: 'A scheduled meeting or event',
9
+ properties: {
10
+ name: { type: 'string', description: 'Meeting name' },
11
+ description: { type: 'string', description: 'Meeting description' },
12
+ type: { type: 'string', description: 'Type of meeting', examples: ['one-on-one', 'team', 'all-hands', 'standup', 'planning', 'review', 'retrospective', 'interview', 'client', 'board', 'workshop', 'training'] },
13
+ status: { type: 'string', description: 'Meeting status', examples: ['scheduled', 'confirmed', 'in-progress', 'completed', 'cancelled', 'rescheduled', 'no-show'] },
14
+ recurring: { type: 'boolean', description: 'Is recurring meeting' },
15
+ recurrencePattern: { type: 'string', description: 'Recurrence pattern', examples: ['daily', 'weekly', 'biweekly', 'monthly', 'quarterly'], optional: true },
16
+ startTime: { type: 'date', description: 'Start date and time' },
17
+ endTime: { type: 'date', description: 'End date and time' },
18
+ duration: { type: 'number', description: 'Duration in minutes' },
19
+ timezone: { type: 'string', description: 'Meeting timezone' },
20
+ location: { type: 'string', description: 'Physical location', optional: true },
21
+ virtualLink: { type: 'string', description: 'Virtual meeting link', optional: true },
22
+ platform: { type: 'string', description: 'Meeting platform', examples: ['zoom', 'teams', 'meet', 'webex', 'in-person', 'hybrid'] },
23
+ organizer: { type: 'string', description: 'Meeting organizer' },
24
+ attendees: { type: 'string[]', description: 'Attendees list' },
25
+ requiredAttendees: { type: 'string[]', description: 'Required attendees' },
26
+ optionalAttendees: { type: 'string[]', description: 'Optional attendees' },
27
+ actualAttendees: { type: 'string[]', description: 'Actual attendees' },
28
+ agenda: { type: 'string[]', description: 'Meeting agenda items' },
29
+ objectives: { type: 'string[]', description: 'Meeting objectives' },
30
+ notes: { type: 'string', description: 'Meeting notes', optional: true },
31
+ notesUrl: { type: 'string', description: 'Notes document URL', optional: true },
32
+ recordingUrl: { type: 'string', description: 'Recording URL', optional: true },
33
+ transcriptUrl: { type: 'string', description: 'Transcript URL', optional: true },
34
+ calendarEventId: { type: 'string', description: 'Calendar event ID', optional: true },
35
+ reminderMinutes: { type: 'number', description: 'Reminder before meeting (minutes)' },
36
+ tags: { type: 'string[]', description: 'Meeting tags' },
37
+ metadata: { type: 'object', description: 'Additional metadata', optional: true },
38
+ },
39
+ relationships: {
40
+ decisions: { type: 'decision[]', description: 'Decisions made', backref: 'meeting' },
41
+ actionItems: { type: 'actionItem[]', description: 'Action items', backref: 'meeting' },
42
+ project: { type: 'project', description: 'Related project', backref: 'meetings' },
43
+ deal: { type: 'deal', description: 'Related deal', backref: 'meetings' },
44
+ customer: { type: 'customer', description: 'Related customer', backref: 'meetings' },
45
+ series: { type: 'meeting', description: 'Parent series', backref: 'instances' },
46
+ instances: { type: 'meeting[]', description: 'Series instances', backref: 'series' },
47
+ },
48
+ actions: ['create', 'update', 'schedule', 'reschedule', 'cancel', 'start', 'end', 'summarize', 'record'],
49
+ events: ['created', 'updated', 'scheduled', 'rescheduled', 'cancelled', 'started', 'ended', 'summarized', 'recorded'],
50
+ };
51
+ export const Decision = {
52
+ singular: 'decision',
53
+ plural: 'decisions',
54
+ description: 'A documented business decision',
55
+ properties: {
56
+ name: { type: 'string', description: 'Decision title' },
57
+ description: { type: 'string', description: 'Decision description' },
58
+ type: { type: 'string', description: 'Type of decision', examples: ['strategic', 'tactical', 'operational', 'technical', 'policy', 'resource', 'budget', 'hiring', 'process'] },
59
+ status: { type: 'string', description: 'Decision status', examples: ['proposed', 'under-review', 'approved', 'rejected', 'deferred', 'superseded', 'implemented'] },
60
+ outcome: { type: 'string', description: 'Decision outcome' },
61
+ rationale: { type: 'string', description: 'Decision rationale' },
62
+ alternatives: { type: 'string[]', description: 'Alternatives considered' },
63
+ impact: { type: 'string', description: 'Impact assessment' },
64
+ risks: { type: 'string[]', description: 'Associated risks' },
65
+ benefits: { type: 'string[]', description: 'Expected benefits' },
66
+ constraints: { type: 'string[]', description: 'Constraints considered' },
67
+ stakeholders: { type: 'string[]', description: 'Stakeholders consulted' },
68
+ decisionMaker: { type: 'string', description: 'Decision maker' },
69
+ approvers: { type: 'string[]', description: 'Required approvers' },
70
+ proposedBy: { type: 'string', description: 'Proposed by' },
71
+ proposedDate: { type: 'date', description: 'Date proposed' },
72
+ decidedDate: { type: 'date', description: 'Date decided' },
73
+ implementationDate: { type: 'date', description: 'Target implementation date', optional: true },
74
+ reviewDate: { type: 'date', description: 'Review date', optional: true },
75
+ expirationDate: { type: 'date', description: 'Decision expiration', optional: true },
76
+ documentUrl: { type: 'string', description: 'Decision document URL' },
77
+ category: { type: 'string', description: 'Decision category' },
78
+ priority: { type: 'string', description: 'Decision priority', examples: ['critical', 'high', 'medium', 'low'] },
79
+ reversible: { type: 'boolean', description: 'Is reversible' },
80
+ notes: { type: 'string', description: 'Additional notes', optional: true },
81
+ tags: { type: 'string[]', description: 'Decision tags' },
82
+ metadata: { type: 'object', description: 'Additional metadata', optional: true },
83
+ },
84
+ relationships: {
85
+ meeting: { type: 'meeting', description: 'Decision meeting', backref: 'decisions' },
86
+ actionItems: { type: 'actionItem[]', description: 'Follow-up actions', backref: 'decision' },
87
+ project: { type: 'project', description: 'Related project', backref: 'decisions' },
88
+ supersedes: { type: 'decision', description: 'Previous decision', backref: 'supersededBy' },
89
+ supersededBy: { type: 'decision', description: 'Superseding decision', backref: 'supersedes' },
90
+ relatedDecisions: { type: 'decision[]', description: 'Related decisions', backref: 'relatedDecisions' },
91
+ },
92
+ actions: ['create', 'update', 'propose', 'review', 'approve', 'reject', 'defer', 'implement', 'supersede', 'archive'],
93
+ events: ['created', 'updated', 'proposed', 'reviewed', 'approved', 'rejected', 'deferred', 'implemented', 'superseded', 'archived'],
94
+ };
95
+ export const ActionItem = {
96
+ singular: 'actionItem',
97
+ plural: 'actionItems',
98
+ description: 'An action item or follow-up task',
99
+ properties: {
100
+ name: { type: 'string', description: 'Action item title' },
101
+ description: { type: 'string', description: 'Action item description' },
102
+ status: { type: 'string', description: 'Action item status', examples: ['pending', 'in-progress', 'completed', 'cancelled', 'blocked', 'deferred'] },
103
+ priority: { type: 'string', description: 'Priority level', examples: ['critical', 'high', 'medium', 'low'] },
104
+ source: { type: 'string', description: 'Source of action item', examples: ['meeting', 'email', 'decision', 'review', 'audit', 'incident'] },
105
+ assignee: { type: 'string', description: 'Assigned person' },
106
+ assignedBy: { type: 'string', description: 'Assigned by' },
107
+ collaborators: { type: 'string[]', description: 'Collaborators' },
108
+ dueDate: { type: 'date', description: 'Due date' },
109
+ completedDate: { type: 'date', description: 'Completion date', optional: true },
110
+ createdDate: { type: 'date', description: 'Creation date' },
111
+ context: { type: 'string', description: 'Context or background' },
112
+ outcome: { type: 'string', description: 'Expected outcome' },
113
+ actualOutcome: { type: 'string', description: 'Actual outcome', optional: true },
114
+ blockers: { type: 'string[]', description: 'Current blockers' },
115
+ progress: { type: 'number', description: 'Progress percentage' },
116
+ notes: { type: 'string', description: 'Additional notes', optional: true },
117
+ tags: { type: 'string[]', description: 'Action item tags' },
118
+ metadata: { type: 'object', description: 'Additional metadata', optional: true },
119
+ },
120
+ relationships: {
121
+ meeting: { type: 'meeting', description: 'Source meeting', backref: 'actionItems' },
122
+ decision: { type: 'decision', description: 'Related decision', backref: 'actionItems' },
123
+ task: { type: 'task', description: 'Linked task', backref: 'actionItem' },
124
+ project: { type: 'project', description: 'Related project', backref: 'actionItems' },
125
+ dependencies: { type: 'actionItem[]', description: 'Dependencies', backref: 'dependents' },
126
+ dependents: { type: 'actionItem[]', description: 'Dependent items', backref: 'dependencies' },
127
+ },
128
+ actions: ['create', 'update', 'assign', 'reassign', 'start', 'complete', 'cancel', 'defer', 'escalate'],
129
+ events: ['created', 'updated', 'assigned', 'reassigned', 'started', 'completed', 'cancelled', 'deferred', 'escalated'],
130
+ };
131
+ export const Announcement = {
132
+ singular: 'announcement',
133
+ plural: 'announcements',
134
+ description: 'A company-wide or team announcement',
135
+ properties: {
136
+ title: { type: 'string', description: 'Announcement title' },
137
+ content: { type: 'string', description: 'Announcement content' },
138
+ summary: { type: 'string', description: 'Brief summary' },
139
+ type: { type: 'string', description: 'Type of announcement', examples: ['general', 'product', 'company', 'HR', 'policy', 'event', 'milestone', 'emergency', 'recognition'] },
140
+ status: { type: 'string', description: 'Announcement status', examples: ['draft', 'scheduled', 'published', 'archived', 'recalled'] },
141
+ priority: { type: 'string', description: 'Priority level', examples: ['urgent', 'high', 'normal', 'low'] },
142
+ audience: { type: 'string[]', description: 'Target audience', examples: ['all', 'engineering', 'sales', 'leadership', 'specific-team'] },
143
+ channels: { type: 'string[]', description: 'Distribution channels', examples: ['email', 'slack', 'intranet', 'all-hands', 'newsletter'] },
144
+ author: { type: 'string', description: 'Author' },
145
+ approver: { type: 'string', description: 'Approver', optional: true },
146
+ publishDate: { type: 'date', description: 'Publish date' },
147
+ expirationDate: { type: 'date', description: 'Expiration date', optional: true },
148
+ acknowledgmentRequired: { type: 'boolean', description: 'Requires acknowledgment' },
149
+ acknowledgmentCount: { type: 'number', description: 'Acknowledgment count' },
150
+ viewCount: { type: 'number', description: 'View count' },
151
+ attachments: { type: 'string[]', description: 'Attachment URLs' },
152
+ featured: { type: 'boolean', description: 'Is featured/pinned' },
153
+ comments: { type: 'boolean', description: 'Comments enabled' },
154
+ notes: { type: 'string', description: 'Internal notes', optional: true },
155
+ tags: { type: 'string[]', description: 'Announcement tags' },
156
+ metadata: { type: 'object', description: 'Additional metadata', optional: true },
157
+ },
158
+ relationships: {
159
+ department: { type: 'department', description: 'Source department', backref: 'announcements' },
160
+ relatedAnnouncements: { type: 'announcement[]', description: 'Related announcements', backref: 'relatedAnnouncements' },
161
+ },
162
+ actions: ['create', 'update', 'draft', 'schedule', 'publish', 'recall', 'archive', 'acknowledge', 'feature'],
163
+ events: ['created', 'updated', 'drafted', 'scheduled', 'published', 'recalled', 'archived', 'acknowledged', 'featured'],
164
+ };
165
+ export const Feedback = {
166
+ singular: 'feedback',
167
+ plural: 'feedbacks',
168
+ description: 'Feedback from customers, employees, or stakeholders',
169
+ properties: {
170
+ title: { type: 'string', description: 'Feedback title' },
171
+ content: { type: 'string', description: 'Feedback content' },
172
+ type: { type: 'string', description: 'Type of feedback', examples: ['feature-request', 'bug-report', 'complaint', 'praise', 'suggestion', 'review', 'survey-response', 'NPS'] },
173
+ source: { type: 'string', description: 'Feedback source', examples: ['customer', 'employee', 'partner', 'support', 'sales', 'survey', 'social', 'review-site'] },
174
+ status: { type: 'string', description: 'Feedback status', examples: ['new', 'acknowledged', 'under-review', 'in-progress', 'resolved', 'declined', 'archived'] },
175
+ sentiment: { type: 'string', description: 'Sentiment analysis', examples: ['positive', 'neutral', 'negative', 'mixed'] },
176
+ rating: { type: 'number', description: 'Rating score (1-5 or 1-10)' },
177
+ npsScore: { type: 'number', description: 'NPS score (-100 to 100)', optional: true },
178
+ category: { type: 'string', description: 'Feedback category', examples: ['product', 'service', 'support', 'pricing', 'UX', 'performance', 'documentation'] },
179
+ priority: { type: 'string', description: 'Priority level', examples: ['critical', 'high', 'medium', 'low'] },
180
+ submitter: { type: 'string', description: 'Feedback submitter' },
181
+ submitterEmail: { type: 'string', description: 'Submitter email', optional: true },
182
+ submitterType: { type: 'string', description: 'Submitter type', examples: ['customer', 'prospect', 'employee', 'partner', 'anonymous'] },
183
+ submittedDate: { type: 'date', description: 'Submission date' },
184
+ assignee: { type: 'string', description: 'Assigned handler' },
185
+ response: { type: 'string', description: 'Response to feedback', optional: true },
186
+ responseDate: { type: 'date', description: 'Response date', optional: true },
187
+ resolvedDate: { type: 'date', description: 'Resolution date', optional: true },
188
+ productArea: { type: 'string', description: 'Related product area' },
189
+ feature: { type: 'string', description: 'Related feature', optional: true },
190
+ channel: { type: 'string', description: 'Submission channel' },
191
+ publicUrl: { type: 'string', description: 'Public URL if applicable', optional: true },
192
+ votes: { type: 'number', description: 'Vote count (for public feedback)' },
193
+ notes: { type: 'string', description: 'Internal notes', optional: true },
194
+ tags: { type: 'string[]', description: 'Feedback tags' },
195
+ metadata: { type: 'object', description: 'Additional metadata', optional: true },
196
+ },
197
+ relationships: {
198
+ customer: { type: 'customer', description: 'Related customer', backref: 'feedback' },
199
+ product: { type: 'product', description: 'Related product', backref: 'feedback' },
200
+ feature: { type: 'feature', description: 'Related feature', backref: 'feedback' },
201
+ task: { type: 'task', description: 'Created task', backref: 'feedback' },
202
+ relatedFeedback: { type: 'feedback[]', description: 'Related feedback', backref: 'relatedFeedback' },
203
+ },
204
+ actions: ['create', 'update', 'acknowledge', 'assign', 'respond', 'resolve', 'decline', 'archive', 'merge', 'upvote'],
205
+ events: ['created', 'updated', 'acknowledged', 'assigned', 'responded', 'resolved', 'declined', 'archived', 'merged', 'upvoted'],
206
+ };
207
+ export const Discussion = {
208
+ singular: 'discussion',
209
+ plural: 'discussions',
210
+ description: 'A threaded discussion or conversation',
211
+ properties: {
212
+ title: { type: 'string', description: 'Discussion title' },
213
+ content: { type: 'string', description: 'Initial post content' },
214
+ type: { type: 'string', description: 'Type of discussion', examples: ['question', 'proposal', 'brainstorm', 'announcement', 'decision', 'RFC', 'retrospective'] },
215
+ status: { type: 'string', description: 'Discussion status', examples: ['open', 'active', 'resolved', 'closed', 'locked', 'archived'] },
216
+ category: { type: 'string', description: 'Discussion category' },
217
+ author: { type: 'string', description: 'Discussion author' },
218
+ participants: { type: 'string[]', description: 'Participants' },
219
+ mentions: { type: 'string[]', description: 'Mentioned users' },
220
+ replyCount: { type: 'number', description: 'Number of replies' },
221
+ viewCount: { type: 'number', description: 'View count' },
222
+ lastReplyDate: { type: 'date', description: 'Last reply date' },
223
+ lastReplyBy: { type: 'string', description: 'Last reply by' },
224
+ pinned: { type: 'boolean', description: 'Is pinned' },
225
+ locked: { type: 'boolean', description: 'Is locked' },
226
+ resolved: { type: 'boolean', description: 'Is resolved' },
227
+ resolvedBy: { type: 'string', description: 'Resolved by', optional: true },
228
+ resolvedDate: { type: 'date', description: 'Resolution date', optional: true },
229
+ visibility: { type: 'string', description: 'Visibility', examples: ['public', 'team', 'private', 'confidential'] },
230
+ createdDate: { type: 'date', description: 'Creation date' },
231
+ notes: { type: 'string', description: 'Internal notes', optional: true },
232
+ tags: { type: 'string[]', description: 'Discussion tags' },
233
+ metadata: { type: 'object', description: 'Additional metadata', optional: true },
234
+ },
235
+ relationships: {
236
+ project: { type: 'project', description: 'Related project', backref: 'discussions' },
237
+ team: { type: 'team', description: 'Related team', backref: 'discussions' },
238
+ decision: { type: 'decision', description: 'Related decision', backref: 'discussions' },
239
+ parentDiscussion: { type: 'discussion', description: 'Parent discussion', backref: 'replies' },
240
+ replies: { type: 'discussion[]', description: 'Replies', backref: 'parentDiscussion' },
241
+ },
242
+ actions: ['create', 'update', 'reply', 'resolve', 'close', 'reopen', 'pin', 'unpin', 'lock', 'unlock', 'archive'],
243
+ events: ['created', 'updated', 'replied', 'resolved', 'closed', 'reopened', 'pinned', 'unpinned', 'locked', 'unlocked', 'archived'],
244
+ };
245
+ // Export all communication entities
246
+ export const CommunicationEntities = {
247
+ Meeting,
248
+ Decision,
249
+ ActionItem,
250
+ Announcement,
251
+ Feedback,
252
+ Discussion,
253
+ };
254
+ export default CommunicationEntities;
255
+ //# sourceMappingURL=communication.js.map