spine-framework-cortex 0.1.1
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/components/CortexSidebar.tsx +130 -0
- package/functions/custom_anonymous-sessions.ts +356 -0
- package/functions/custom_case_analysis.ts +507 -0
- package/functions/custom_community-escalation.ts +234 -0
- package/functions/custom_cortex-chunks.ts +52 -0
- package/functions/custom_cortex-handler.ts +35 -0
- package/functions/custom_funnel-scoring.ts +256 -0
- package/functions/custom_funnel-signal.ts +678 -0
- package/functions/custom_funnel-timers.ts +449 -0
- package/functions/custom_kb-chunker-test.ts +364 -0
- package/functions/custom_kb-chunker.ts +576 -0
- package/functions/custom_kb-embeddings.ts +481 -0
- package/functions/custom_kb-ingestion.ts +448 -0
- package/functions/custom_support-triage.ts +649 -0
- package/functions/custom_tag_management.ts +314 -0
- package/index.tsx +103 -0
- package/manifest.json +82 -0
- package/package.json +29 -0
- package/pages/CortexDashboard.tsx +97 -0
- package/pages/community/CommunityPage.tsx +159 -0
- package/pages/courses/CoursesPage.tsx +231 -0
- package/pages/crm/AccountDetailPage.tsx +393 -0
- package/pages/crm/AccountsPage.tsx +164 -0
- package/pages/crm/ActivityPage.tsx +82 -0
- package/pages/crm/ContactDetailPage.tsx +184 -0
- package/pages/crm/ContactsPage.tsx +87 -0
- package/pages/crm/DealDetailPage.tsx +191 -0
- package/pages/crm/DealsPage.tsx +169 -0
- package/pages/crm/HealthPage.tsx +109 -0
- package/pages/intelligence/IntelligencePage.tsx +314 -0
- package/pages/kb/KBEditorPage.tsx +328 -0
- package/pages/kb/KBIngestionPage.tsx +409 -0
- package/pages/kb/KBPage.tsx +258 -0
- package/pages/support/RedactionReview.tsx +562 -0
- package/pages/support/SupportPage.tsx +395 -0
- package/pages/support/TicketDetailPage.tsx +919 -0
- package/seed/accounts.json +9 -0
- package/seed/link-types.json +44 -0
- package/seed/triggers.json +80 -0
- package/seed/types.json +352 -0
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"slug": "account_opportunities",
|
|
4
|
+
"name": "Account Opportunities",
|
|
5
|
+
"description": "Links accounts to their opportunity queue entries",
|
|
6
|
+
"config": {
|
|
7
|
+
"cardinality": "many-to-many",
|
|
8
|
+
"source_type": "account",
|
|
9
|
+
"target_type": "item"
|
|
10
|
+
},
|
|
11
|
+
"is_active": true
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
"slug": "account_signals",
|
|
15
|
+
"name": "Account Signals",
|
|
16
|
+
"description": "Links accounts to their funnel signals",
|
|
17
|
+
"config": {
|
|
18
|
+
"cardinality": "many-to-many",
|
|
19
|
+
"source_type": "account",
|
|
20
|
+
"target_type": "item"
|
|
21
|
+
},
|
|
22
|
+
"is_active": true
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
"slug": "analyzed_by",
|
|
26
|
+
"name": "Analyzed By",
|
|
27
|
+
"description": "Ticket analyzed by case analysis",
|
|
28
|
+
"config": {
|
|
29
|
+
"forward_label": "analyzed by",
|
|
30
|
+
"reverse_label": "analysis of"
|
|
31
|
+
},
|
|
32
|
+
"is_active": true
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"slug": "tagged_with",
|
|
36
|
+
"name": "Tagged With",
|
|
37
|
+
"description": "Entity tagged with a specific tag",
|
|
38
|
+
"config": {
|
|
39
|
+
"forward_label": "tagged with",
|
|
40
|
+
"reverse_label": "applied to"
|
|
41
|
+
},
|
|
42
|
+
"is_active": true
|
|
43
|
+
}
|
|
44
|
+
]
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"name": "Case Resolution Analysis",
|
|
4
|
+
"description": "Automatically triggers case analysis when support tickets are resolved",
|
|
5
|
+
"trigger_type": "event_driven",
|
|
6
|
+
"event_type": "item_updated",
|
|
7
|
+
"config": {
|
|
8
|
+
"filters": [
|
|
9
|
+
{ "field": "status", "value": "resolved", "operator": "$eq" },
|
|
10
|
+
{ "field": "type_id", "value": "82320862-a99c-4a84-b7ed-c2832cf519cd", "operator": "$eq" }
|
|
11
|
+
],
|
|
12
|
+
"debounce_ms": 5000,
|
|
13
|
+
"entity_type": "items",
|
|
14
|
+
"retry_count": 3,
|
|
15
|
+
"retry_delay_ms": 1000
|
|
16
|
+
},
|
|
17
|
+
"ownership": "tenant",
|
|
18
|
+
"is_system": false,
|
|
19
|
+
"is_active": true
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
"name": "Funnel Signal Lead Scoring",
|
|
23
|
+
"description": "Processes funnel signals to update lead scores and lifecycle stages",
|
|
24
|
+
"trigger_type": "event",
|
|
25
|
+
"event_type": "item_created",
|
|
26
|
+
"config": {
|
|
27
|
+
"filters": {},
|
|
28
|
+
"type_slug": "funnel_signal",
|
|
29
|
+
"entity_type": "item"
|
|
30
|
+
},
|
|
31
|
+
"ownership": "tenant",
|
|
32
|
+
"is_system": false,
|
|
33
|
+
"is_active": true
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
"name": "Funnel: Aggregation",
|
|
37
|
+
"description": "Hourly dashboard metric aggregation",
|
|
38
|
+
"trigger_type": "cron",
|
|
39
|
+
"event_type": null,
|
|
40
|
+
"config": {
|
|
41
|
+
"function": "funnel-timers.aggregation",
|
|
42
|
+
"schedule": "0 * * * *",
|
|
43
|
+
"timezone": "UTC",
|
|
44
|
+
"description": "Hourly dashboard metric aggregation"
|
|
45
|
+
},
|
|
46
|
+
"ownership": "tenant",
|
|
47
|
+
"is_system": false,
|
|
48
|
+
"is_active": true
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"name": "Funnel: Score Decay",
|
|
52
|
+
"description": "Daily recalculation of account ratings for score decay",
|
|
53
|
+
"trigger_type": "cron",
|
|
54
|
+
"event_type": null,
|
|
55
|
+
"config": {
|
|
56
|
+
"function": "funnel-timers.scoreDecay",
|
|
57
|
+
"schedule": "59 23 * * *",
|
|
58
|
+
"timezone": "UTC",
|
|
59
|
+
"description": "Daily recalculation of account ratings for score decay"
|
|
60
|
+
},
|
|
61
|
+
"ownership": "tenant",
|
|
62
|
+
"is_system": false,
|
|
63
|
+
"is_active": true
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
"name": "Funnel: Session Cleanup",
|
|
67
|
+
"description": "Daily purge of expired anonymous sessions",
|
|
68
|
+
"trigger_type": "cron",
|
|
69
|
+
"event_type": null,
|
|
70
|
+
"config": {
|
|
71
|
+
"function": "funnel-timers.sessionCleanup",
|
|
72
|
+
"schedule": "0 2 * * *",
|
|
73
|
+
"timezone": "UTC",
|
|
74
|
+
"description": "Daily purge of expired anonymous sessions"
|
|
75
|
+
},
|
|
76
|
+
"ownership": "tenant",
|
|
77
|
+
"is_system": false,
|
|
78
|
+
"is_active": true
|
|
79
|
+
}
|
|
80
|
+
]
|
package/seed/types.json
ADDED
|
@@ -0,0 +1,352 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"kind": "item",
|
|
4
|
+
"slug": "case_analysis",
|
|
5
|
+
"name": "Case Analysis",
|
|
6
|
+
"description": "AI-generated case resolution analysis and insights",
|
|
7
|
+
"icon": "analysis",
|
|
8
|
+
"color": "#10B981",
|
|
9
|
+
"ownership": "tenant",
|
|
10
|
+
"is_active": true,
|
|
11
|
+
"design_schema": {
|
|
12
|
+
"fields": {
|
|
13
|
+
"ticket_id": { "type": "string", "label": "Original Ticket ID", "required": true },
|
|
14
|
+
"ai_agent_id": { "type": "string", "label": "AI Agent Used", "readonly": true },
|
|
15
|
+
"analysis_data": { "type": "json", "label": "Complete Analysis Data", "required": true },
|
|
16
|
+
"confidence_score": { "min": 0, "max": 1, "type": "number", "label": "AI Analysis Confidence" },
|
|
17
|
+
"analysis_timestamp": { "type": "timestamp", "label": "Analysis Timestamp", "readonly": true }
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"validation_schema": {}
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
"kind": "item",
|
|
24
|
+
"slug": "course",
|
|
25
|
+
"name": "Course",
|
|
26
|
+
"description": "Top-level course container",
|
|
27
|
+
"icon": "graduation-cap",
|
|
28
|
+
"color": "#6366f1",
|
|
29
|
+
"ownership": "tenant",
|
|
30
|
+
"is_active": true,
|
|
31
|
+
"design_schema": { "scope": "platform" },
|
|
32
|
+
"validation_schema": {}
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"kind": "item",
|
|
36
|
+
"slug": "course_chapter",
|
|
37
|
+
"name": "Course Chapter",
|
|
38
|
+
"description": "Chapter grouping lessons within a course",
|
|
39
|
+
"icon": "book-open",
|
|
40
|
+
"color": "#8b5cf6",
|
|
41
|
+
"ownership": "tenant",
|
|
42
|
+
"is_active": true,
|
|
43
|
+
"design_schema": { "scope": "platform" },
|
|
44
|
+
"validation_schema": {}
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
"kind": "item",
|
|
48
|
+
"slug": "csm_health",
|
|
49
|
+
"name": "CSM Health Record",
|
|
50
|
+
"description": "Customer success health: temperature, churn risk, adoption, NPS",
|
|
51
|
+
"icon": "heart-pulse",
|
|
52
|
+
"color": "#10B981",
|
|
53
|
+
"ownership": "tenant",
|
|
54
|
+
"is_active": true,
|
|
55
|
+
"design_schema": {
|
|
56
|
+
"scope": "account",
|
|
57
|
+
"fields": {
|
|
58
|
+
"title": { "label": "Title", "system": true, "required": true, "data_type": "text" },
|
|
59
|
+
"status": { "label": "Status", "system": true, "required": false, "data_type": "text" },
|
|
60
|
+
"is_active": { "label": "Active", "system": true, "required": true, "data_type": "boolean" },
|
|
61
|
+
"temperature": { "label": "Health Temperature", "system": false, "required": true, "data_type": "text" },
|
|
62
|
+
"nps_score": { "label": "NPS Score", "system": false, "required": false, "data_type": "number" },
|
|
63
|
+
"adoption_score": { "label": "Adoption Score", "system": false, "required": false, "data_type": "number" },
|
|
64
|
+
"churn_risk_score": { "label": "Churn Risk Score", "system": false, "required": false, "data_type": "number" },
|
|
65
|
+
"notes": { "label": "CSM Notes", "system": false, "required": false, "data_type": "textarea" },
|
|
66
|
+
"description": { "label": "Description", "system": true, "required": false, "data_type": "textarea" },
|
|
67
|
+
"created_at": { "label": "Created", "system": true, "readonly": true, "required": false, "data_type": "datetime" },
|
|
68
|
+
"updated_at": { "label": "Updated", "system": true, "readonly": true, "required": false, "data_type": "datetime" }
|
|
69
|
+
},
|
|
70
|
+
"record_permissions": { "system_admin": ["create", "read", "update", "delete"] }
|
|
71
|
+
},
|
|
72
|
+
"validation_schema": {}
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
"kind": "item",
|
|
76
|
+
"slug": "deal",
|
|
77
|
+
"name": "Deal",
|
|
78
|
+
"description": "Sales opportunity with stage, value, and close date",
|
|
79
|
+
"icon": "briefcase",
|
|
80
|
+
"color": "#3B82F6",
|
|
81
|
+
"ownership": "tenant",
|
|
82
|
+
"is_active": true,
|
|
83
|
+
"design_schema": {
|
|
84
|
+
"scope": "account",
|
|
85
|
+
"fields": {
|
|
86
|
+
"title": { "label": "Title", "system": true, "required": true, "data_type": "text" },
|
|
87
|
+
"status": { "label": "Status", "system": true, "required": false, "data_type": "text" },
|
|
88
|
+
"is_active": { "label": "Active", "system": true, "required": true, "data_type": "boolean" },
|
|
89
|
+
"stage": { "label": "Stage", "system": false, "required": true, "data_type": "text" },
|
|
90
|
+
"value": { "label": "Deal Value", "system": false, "required": false, "data_type": "number" },
|
|
91
|
+
"source": { "label": "Lead Source", "system": false, "required": false, "data_type": "text" },
|
|
92
|
+
"close_date": { "label": "Close Date", "system": false, "required": false, "data_type": "datetime" },
|
|
93
|
+
"probability": { "label": "Probability %", "system": false, "required": false, "data_type": "number" },
|
|
94
|
+
"description": { "label": "Description", "system": true, "required": false, "data_type": "textarea" },
|
|
95
|
+
"created_at": { "label": "Created", "system": true, "readonly": true, "required": false, "data_type": "datetime" },
|
|
96
|
+
"updated_at": { "label": "Updated", "system": true, "readonly": true, "required": false, "data_type": "datetime" }
|
|
97
|
+
},
|
|
98
|
+
"record_permissions": { "system_admin": ["create", "read", "update", "delete"] }
|
|
99
|
+
},
|
|
100
|
+
"validation_schema": {}
|
|
101
|
+
},
|
|
102
|
+
{
|
|
103
|
+
"kind": "item",
|
|
104
|
+
"slug": "kb_article",
|
|
105
|
+
"name": "Knowledge Base Article",
|
|
106
|
+
"description": "Help documentation and knowledge base article",
|
|
107
|
+
"icon": "book-open",
|
|
108
|
+
"color": "#0EA5E9",
|
|
109
|
+
"ownership": "system",
|
|
110
|
+
"is_active": true,
|
|
111
|
+
"design_schema": {
|
|
112
|
+
"scope": "platform",
|
|
113
|
+
"fields": {
|
|
114
|
+
"title": { "label": "Title", "system": true, "required": true, "data_type": "text", "validation": { "minLength": 1, "maxLength": 255 } },
|
|
115
|
+
"status": { "label": "Status", "system": true, "required": true, "data_type": "select", "options": [{"label":"Draft","value":"draft"},{"label":"Under Review","value":"review"},{"label":"Published","value":"published"},{"label":"Deprecated","value":"deprecated"},{"label":"Archived","value":"archived"},{"label":"Restricted Access","value":"restricted"}] },
|
|
116
|
+
"kb_type": { "label": "Knowledge Base Type", "required": true, "data_type": "select", "options": [{"label":"Article","value":"article"},{"label":"Care Guide","value":"care_guide"},{"label":"Process Guide","value":"process_guide"},{"label":"Code Chunk","value":"code_chunk"},{"label":"API Reference","value":"api_reference"},{"label":"Troubleshooting","value":"troubleshooting"},{"label":"FAQ","value":"faq"},{"label":"Policy","value":"policy"},{"label":"Tutorial","value":"tutorial"}] },
|
|
117
|
+
"description": { "label": "Description", "required": true, "data_type": "rich_text" },
|
|
118
|
+
"audience": { "label": "Audience", "required": false, "data_type": "multiselect", "options": [{"label":"End User","value":"end_user"},{"label":"Support Agent","value":"support_agent"},{"label":"Developer","value":"developer"},{"label":"Administrator","value":"admin"},{"label":"Manager","value":"manager"},{"label":"AI System","value":"ai_system"},{"label":"Internal Only","value":"internal_only"}] },
|
|
119
|
+
"category": { "label": "Category", "required": false, "data_type": "select", "options": [{"label":"Getting Started","value":"getting_started"},{"label":"User Guide","value":"user_guide"},{"label":"Technical","value":"technical"},{"label":"Billing","value":"billing"},{"label":"Security","value":"security"},{"label":"Integration","value":"integration"},{"label":"Troubleshooting","value":"troubleshooting"},{"label":"Reference","value":"reference"},{"label":"Best Practices","value":"best_practices"},{"label":"Policies","value":"policies"}] },
|
|
120
|
+
"priority": { "label": "Priority", "required": true, "data_type": "select", "options": [{"label":"Low","value":"low"},{"label":"Medium","value":"medium"},{"label":"High","value":"high"},{"label":"Critical","value":"critical"},{"label":"Emergency","value":"emergency"}] },
|
|
121
|
+
"security_level": { "label": "Security Level", "required": false, "data_type": "select", "options": [{"label":"Public","value":"public"},{"label":"Internal","value":"internal"},{"label":"Confidential","value":"confidential"},{"label":"Restricted","value":"restricted"}] },
|
|
122
|
+
"tags": { "label": "Tags", "required": false, "data_type": "json" },
|
|
123
|
+
"version": { "label": "Version", "required": false, "data_type": "text" },
|
|
124
|
+
"expires_at": { "label": "Expires At", "required": false, "data_type": "datetime" },
|
|
125
|
+
"last_reviewed_at": { "label": "Last Reviewed At", "required": false, "data_type": "datetime" },
|
|
126
|
+
"view_count": { "label": "View Count", "required": false, "data_type": "number", "validation": { "min": 0 } },
|
|
127
|
+
"helpful_count": { "label": "Helpful Votes", "required": false, "data_type": "number", "validation": { "min": 0 } },
|
|
128
|
+
"not_helpful_count": { "label": "Not Helpful Votes", "required": false, "data_type": "number", "validation": { "min": 0 } },
|
|
129
|
+
"related_articles": { "label": "Related Articles", "required": false, "data_type": "json" },
|
|
130
|
+
"source_info": { "label": "Source Info", "required": false, "data_type": "json" },
|
|
131
|
+
"care_metadata": { "label": "Care Metadata", "required": false, "data_type": "json" },
|
|
132
|
+
"code_metadata": { "label": "Code Metadata", "required": false, "data_type": "json" },
|
|
133
|
+
"process_metadata": { "label": "Process Metadata", "required": false, "data_type": "json" }
|
|
134
|
+
},
|
|
135
|
+
"record_permissions": { "guest": ["read"], "member": ["read"], "support": ["create", "read", "update"], "system-admin": ["create", "read", "update", "delete"] }
|
|
136
|
+
},
|
|
137
|
+
"validation_schema": {}
|
|
138
|
+
},
|
|
139
|
+
{
|
|
140
|
+
"kind": "item",
|
|
141
|
+
"slug": "marketing_touch",
|
|
142
|
+
"name": "Marketing Touch",
|
|
143
|
+
"description": "Marketing touchpoint: channel, campaign, content, conversion",
|
|
144
|
+
"icon": "megaphone",
|
|
145
|
+
"color": "#F59E0B",
|
|
146
|
+
"ownership": "tenant",
|
|
147
|
+
"is_active": true,
|
|
148
|
+
"design_schema": {
|
|
149
|
+
"scope": "account",
|
|
150
|
+
"fields": {
|
|
151
|
+
"title": { "label": "Title", "system": true, "required": true, "data_type": "text" },
|
|
152
|
+
"status": { "label": "Status", "system": true, "required": false, "data_type": "text" },
|
|
153
|
+
"is_active": { "label": "Active", "system": true, "required": true, "data_type": "boolean" },
|
|
154
|
+
"channel": { "label": "Channel", "system": false, "required": true, "data_type": "text" },
|
|
155
|
+
"campaign": { "label": "Campaign", "system": false, "required": false, "data_type": "text" },
|
|
156
|
+
"content": { "label": "Content/Asset", "system": false, "required": false, "data_type": "text" },
|
|
157
|
+
"converted": { "label": "Converted", "system": false, "required": false, "data_type": "boolean" },
|
|
158
|
+
"created_at": { "label": "Created", "system": true, "readonly": true, "required": false, "data_type": "datetime" },
|
|
159
|
+
"updated_at": { "label": "Updated", "system": true, "readonly": true, "required": false, "data_type": "datetime" }
|
|
160
|
+
},
|
|
161
|
+
"record_permissions": { "system_admin": ["create", "read", "update", "delete"] }
|
|
162
|
+
},
|
|
163
|
+
"validation_schema": {}
|
|
164
|
+
},
|
|
165
|
+
{
|
|
166
|
+
"kind": "item",
|
|
167
|
+
"slug": "note",
|
|
168
|
+
"name": "Note",
|
|
169
|
+
"description": "Internal account note",
|
|
170
|
+
"icon": "sticky-note",
|
|
171
|
+
"color": "#f59e0b",
|
|
172
|
+
"ownership": "tenant",
|
|
173
|
+
"is_active": true,
|
|
174
|
+
"design_schema": { "scope": "account" },
|
|
175
|
+
"validation_schema": {}
|
|
176
|
+
},
|
|
177
|
+
{
|
|
178
|
+
"kind": "item",
|
|
179
|
+
"slug": "site_visit",
|
|
180
|
+
"name": "Site Visit",
|
|
181
|
+
"description": "Website visit tracking event",
|
|
182
|
+
"icon": "eye",
|
|
183
|
+
"color": "#8B5CF6",
|
|
184
|
+
"ownership": "tenant",
|
|
185
|
+
"is_active": true,
|
|
186
|
+
"design_schema": {
|
|
187
|
+
"scope": "account",
|
|
188
|
+
"fields": {
|
|
189
|
+
"title": { "label": "Title", "system": true, "required": true, "data_type": "text" },
|
|
190
|
+
"status": { "label": "Status", "system": true, "required": false, "data_type": "text" },
|
|
191
|
+
"is_active": { "label": "Active", "system": true, "required": true, "data_type": "boolean" },
|
|
192
|
+
"url": { "label": "Page URL", "system": false, "required": true, "data_type": "text" },
|
|
193
|
+
"source": { "label": "Traffic Source", "system": false, "required": false, "data_type": "text" },
|
|
194
|
+
"referrer": { "label": "Referrer URL", "system": false, "required": false, "data_type": "text" },
|
|
195
|
+
"duration_seconds": { "label": "Duration (sec)", "system": false, "required": false, "data_type": "number" },
|
|
196
|
+
"utm_source": { "label": "UTM Source", "system": false, "required": false, "data_type": "text" },
|
|
197
|
+
"utm_medium": { "label": "UTM Medium", "system": false, "required": false, "data_type": "text" },
|
|
198
|
+
"utm_campaign": { "label": "UTM Campaign", "system": false, "required": false, "data_type": "text" },
|
|
199
|
+
"created_at": { "label": "Created", "system": true, "readonly": true, "required": false, "data_type": "datetime" }
|
|
200
|
+
},
|
|
201
|
+
"record_permissions": { "system_admin": ["create", "read", "update", "delete"] }
|
|
202
|
+
},
|
|
203
|
+
"validation_schema": {}
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
"kind": "item",
|
|
207
|
+
"slug": "support_queue",
|
|
208
|
+
"name": "Support Queue Entry",
|
|
209
|
+
"description": "Human-assignable support ticket from AI escalation",
|
|
210
|
+
"icon": "inbox",
|
|
211
|
+
"color": "#f59e0b",
|
|
212
|
+
"ownership": "tenant",
|
|
213
|
+
"is_active": true,
|
|
214
|
+
"design_schema": {
|
|
215
|
+
"fields": {
|
|
216
|
+
"ticket_id": { "type": "string", "label": "Source Ticket" },
|
|
217
|
+
"assigned_to": { "type": "string", "label": "Assignee" },
|
|
218
|
+
"sla_deadline": { "type": "timestamp", "label": "SLA Deadline" },
|
|
219
|
+
"priority_score": { "type": "number", "label": "Priority Score" },
|
|
220
|
+
"escalation_reason": { "type": "select", "label": "Escalation Reason", "options": ["low_confidence", "thumbs_down", "customer_request"] }
|
|
221
|
+
}
|
|
222
|
+
},
|
|
223
|
+
"validation_schema": {}
|
|
224
|
+
},
|
|
225
|
+
{
|
|
226
|
+
"kind": "item",
|
|
227
|
+
"slug": "tag",
|
|
228
|
+
"name": "Tag",
|
|
229
|
+
"description": "Reusable tags for categorization and analysis across entities",
|
|
230
|
+
"icon": "tag",
|
|
231
|
+
"color": "#8B5CF6",
|
|
232
|
+
"ownership": "tenant",
|
|
233
|
+
"is_active": true,
|
|
234
|
+
"design_schema": {
|
|
235
|
+
"fields": {
|
|
236
|
+
"name": { "type": "string", "label": "Tag Name", "required": true },
|
|
237
|
+
"slug": { "type": "string", "label": "Tag Slug", "required": true, "validation": { "pattern": "^[a-z0-9_-]+$" } },
|
|
238
|
+
"purpose": { "type": "text", "label": "Purpose Description" },
|
|
239
|
+
"category": { "type": "select", "label": "Category", "required": true, "options": ["bug_classification", "knowledge_value", "process_type", "sentiment"] },
|
|
240
|
+
"applicable_to": { "type": "array", "items": { "type": "string" }, "label": "Applicable To", "default": ["ticket"], "required": true },
|
|
241
|
+
"usage_count": { "type": "number", "label": "Usage Count", "default": 0, "readonly": true }
|
|
242
|
+
}
|
|
243
|
+
},
|
|
244
|
+
"validation_schema": {}
|
|
245
|
+
},
|
|
246
|
+
{
|
|
247
|
+
"kind": "item",
|
|
248
|
+
"slug": "anonymous_session",
|
|
249
|
+
"name": "Anonymous Session",
|
|
250
|
+
"description": "Pre-identification visitor session with locked first-touch attribution",
|
|
251
|
+
"icon": "user",
|
|
252
|
+
"color": "#8b5cf6",
|
|
253
|
+
"ownership": "system",
|
|
254
|
+
"is_active": true,
|
|
255
|
+
"design_schema": {
|
|
256
|
+
"scoring": {
|
|
257
|
+
"ratings": { "anonymous": { "rating": { "max": 5, "min": 1, "type": "integer" }, "raw_score": { "type": "float" }, "signal_count": { "type": "integer" }, "calculated_at": { "type": "timestamp" }, "best_signal_id": { "type": "uuid", "nullable": true } } },
|
|
258
|
+
"temperature": { "type": "enum", "options": ["cold", "warm", "hot"] },
|
|
259
|
+
"current_stage": { "type": "enum", "default": "anonymous", "options": ["anonymous"] }
|
|
260
|
+
},
|
|
261
|
+
"identity": { "anonymous_id": { "type": "uuid" } },
|
|
262
|
+
"lifecycle": { "created_at": { "type": "timestamp" }, "stitched_at": { "type": "timestamp", "nullable": true }, "last_activity_at": { "type": "timestamp" }, "stitched_to_person_id": { "type": "uuid", "nullable": true }, "stitched_to_account_id": { "type": "uuid", "nullable": true } },
|
|
263
|
+
"retention": { "purge_after": { "type": "timestamp" }, "retention_days": { "type": "integer", "default": 90 } },
|
|
264
|
+
"attribution": {
|
|
265
|
+
"first_touch": { "utm_medium": { "type": "string", "nullable": true }, "utm_source": { "type": "string", "nullable": true }, "occurred_at": { "type": "timestamp" }, "landing_page": { "type": "string" }, "referrer_url": { "type": "string" }, "utm_campaign": { "type": "string", "nullable": true }, "referrer_domain": { "type": "string" }, "referrer_category": { "type": "enum", "options": ["social", "search", "direct", "referral", "email", "ad"] }, "landing_page_category": { "type": "string", "nullable": true } },
|
|
266
|
+
"current_referrer": { "occurred_at": { "type": "timestamp", "nullable": true }, "referrer_url": { "type": "string", "nullable": true }, "referrer_domain": { "type": "string", "nullable": true } }
|
|
267
|
+
}
|
|
268
|
+
},
|
|
269
|
+
"validation_schema": {}
|
|
270
|
+
},
|
|
271
|
+
{
|
|
272
|
+
"kind": "item",
|
|
273
|
+
"slug": "funnel_signal",
|
|
274
|
+
"name": "Funnel Signal",
|
|
275
|
+
"description": "Individual prospect/customer activity with engagement scoring",
|
|
276
|
+
"icon": "activity",
|
|
277
|
+
"color": "#3b82f6",
|
|
278
|
+
"ownership": "system",
|
|
279
|
+
"is_active": true,
|
|
280
|
+
"design_schema": {
|
|
281
|
+
"action": { "action_type": { "type": "string" }, "action_value": { "enum": [1, 2, 5], "type": "integer" }, "action_description": { "type": "string", "nullable": true } },
|
|
282
|
+
"identity": { "person_id": { "type": "uuid", "nullable": true }, "account_id": { "type": "uuid", "nullable": true }, "session_id": { "type": "string", "nullable": true }, "anonymous_id": { "type": "uuid", "nullable": true } },
|
|
283
|
+
"processing": { "scored_at": { "type": "timestamp" }, "enriched_at": { "type": "timestamp" }, "received_at": { "type": "timestamp" }, "stitched_at": { "type": "timestamp", "nullable": true }, "stitched_to_account_id": { "type": "uuid", "nullable": true } },
|
|
284
|
+
"attribution": { "utm_medium": { "type": "string", "nullable": true }, "utm_source": { "type": "string", "nullable": true }, "utm_campaign": { "type": "string", "nullable": true }, "immediate_referrer": { "type": "string", "nullable": true }, "first_touch_landing_page": { "type": "string", "nullable": true }, "first_touch_referrer_url": { "type": "string", "nullable": true }, "first_touch_referrer_domain": { "type": "string", "nullable": true } },
|
|
285
|
+
"classification": { "stage": { "type": "enum", "options": ["anonymous", "identified", "installed"] }, "source": { "type": "enum", "options": ["mar", "int", "use", "manual"] } },
|
|
286
|
+
"scoring_components": {
|
|
287
|
+
"recency": { "window": { "type": "enum", "options": ["fresh", "cooling", "stale", "expired"] }, "divisor": { "enum": [1, 2, 5], "type": "integer" }, "age_days": { "type": "float" } },
|
|
288
|
+
"raw_score": { "rating": { "max": 5, "min": 1, "type": "integer" }, "calculated": { "type": "float" }, "max_possible": { "type": "float", "default": 25 } },
|
|
289
|
+
"engagement": { "type": { "enum": [1, 2, 5], "type": "integer" }, "context": { "type": "enum", "options": ["first_visit", "deep_session", "return_visit"] }, "session_depth": { "type": "integer" }, "prior_session_count": { "type": "integer", "nullable": true } }
|
|
290
|
+
}
|
|
291
|
+
},
|
|
292
|
+
"validation_schema": {}
|
|
293
|
+
},
|
|
294
|
+
{
|
|
295
|
+
"kind": "item",
|
|
296
|
+
"slug": "opportunity_queue",
|
|
297
|
+
"name": "Opportunity Queue Entry",
|
|
298
|
+
"description": "Manual review queue for high-engagement prospects",
|
|
299
|
+
"icon": "star",
|
|
300
|
+
"color": "#f59e0b",
|
|
301
|
+
"ownership": "system",
|
|
302
|
+
"is_active": true,
|
|
303
|
+
"design_schema": {
|
|
304
|
+
"notes": { "auto_reason": { "type": "string", "nullable": true }, "reviewer_notes": { "type": "string", "nullable": true } },
|
|
305
|
+
"review": { "status": { "type": "enum", "options": ["pending", "accepted", "rejected", "converted"] }, "reviewed_at": { "type": "timestamp", "nullable": true }, "reviewed_by": { "type": "uuid", "nullable": true }, "conversion_opportunity_id": { "type": "uuid", "nullable": true } },
|
|
306
|
+
"trigger": { "trigger_stage": { "type": "enum", "options": ["anonymous", "identified", "installed"] }, "trigger_rating": { "max": 5, "min": 1, "type": "integer" }, "trigger_reason": { "type": "string" }, "source_signal_id": { "type": "uuid" }, "trigger_raw_score": { "type": "float" } },
|
|
307
|
+
"identity": { "person_id": { "type": "uuid", "nullable": true }, "account_id": { "type": "uuid", "nullable": true } },
|
|
308
|
+
"recommendation": { "confidence": { "type": "enum", "options": ["low", "medium", "high"] }, "opportunity_type": { "type": "enum", "options": ["advanced_portal", "implementation", "support_plan", "managed_services", "expansion", "advocate"] }, "suggested_priority": { "max": 5, "min": 1, "type": "integer" } }
|
|
309
|
+
},
|
|
310
|
+
"validation_schema": {}
|
|
311
|
+
},
|
|
312
|
+
{
|
|
313
|
+
"kind": "item",
|
|
314
|
+
"slug": "funnel_aggregation",
|
|
315
|
+
"name": "Funnel Aggregation",
|
|
316
|
+
"description": "Pre-computed funnel metrics for dashboard performance",
|
|
317
|
+
"icon": "bar-chart-2",
|
|
318
|
+
"color": "#10b981",
|
|
319
|
+
"ownership": "system",
|
|
320
|
+
"is_active": true,
|
|
321
|
+
"design_schema": {
|
|
322
|
+
"metrics": { "queue_summary": { "type": "jsonb" }, "signal_volume": { "type": "jsonb" }, "top_referrers": { "type": "jsonb" }, "conversion_rates": { "type": "jsonb" }, "avg_time_in_stage": { "type": "jsonb" }, "stage_distribution": { "type": "jsonb" }, "temperature_distribution": { "type": "jsonb" } },
|
|
323
|
+
"identity": { "account_id": { "type": "uuid", "nullable": true }, "aggregation_scope": { "type": "enum", "options": ["system", "account"] } },
|
|
324
|
+
"metadata": { "ttl_hours": { "type": "integer", "default": 1 }, "period_end": { "type": "timestamp" }, "computed_at": { "type": "timestamp" }, "period_start": { "type": "timestamp" } }
|
|
325
|
+
},
|
|
326
|
+
"validation_schema": {}
|
|
327
|
+
},
|
|
328
|
+
{
|
|
329
|
+
"kind": "item",
|
|
330
|
+
"slug": "kb_tag",
|
|
331
|
+
"name": "Knowledge Base Tag",
|
|
332
|
+
"description": "Tag for categorizing and organizing knowledge base content",
|
|
333
|
+
"icon": "tag",
|
|
334
|
+
"color": "#8B5CF6",
|
|
335
|
+
"ownership": "tenant",
|
|
336
|
+
"is_active": true,
|
|
337
|
+
"design_schema": {
|
|
338
|
+
"scope": "platform",
|
|
339
|
+
"views": {
|
|
340
|
+
"default_list": { "type": "list", "label": "KB Tags", "fields": { "name": { "sortable": true, "display_type": "text" }, "color": { "sortable": false, "display_type": "color" }, "created_at": { "sortable": true, "display_type": "date" } }, "display": "table", "default_sort": { "field": "name", "direction": "asc" } },
|
|
341
|
+
"default_detail": { "type": "detail", "label": "KB Tag", "sections": [{ "title": "Tag Details", "fields": ["name", "description", "color"] }, { "title": "Metadata", "fields": ["created_at", "updated_at"] }] }
|
|
342
|
+
},
|
|
343
|
+
"fields": {
|
|
344
|
+
"name": { "label": "Tag Name", "required": true, "data_type": "text" },
|
|
345
|
+
"color": { "label": "Color", "default": "#8B5CF6", "data_type": "text" },
|
|
346
|
+
"description": { "label": "Description", "data_type": "text" }
|
|
347
|
+
},
|
|
348
|
+
"record_permissions": { "member": ["read"], "support": ["read", "create", "update"], "system_admin": ["create", "read", "update", "delete"] }
|
|
349
|
+
},
|
|
350
|
+
"validation_schema": {}
|
|
351
|
+
}
|
|
352
|
+
]
|