@ak--47/dungeon-master 1.0.0 → 1.2.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/README.md +7 -7
- package/dungeons/technical/ad-spend-schema.json +128 -0
- package/dungeons/technical/ad-spend.js +116 -0
- package/dungeons/technical/anonymous-users-schema.json +92 -0
- package/dungeons/technical/anonymous-users.js +102 -0
- package/dungeons/technical/array-of-object-lookup-schema.json +191 -0
- package/dungeons/{array-of-object-lookup.js → technical/array-of-object-lookup.js} +12 -5
- package/dungeons/technical/experiments-schema.json +203 -0
- package/dungeons/technical/experiments.js +168 -0
- package/dungeons/technical/foobar-schema.json +362 -0
- package/dungeons/{foobar.js → technical/foobar.js} +3 -3
- package/dungeons/technical/group-analytics-schema.json +241 -0
- package/dungeons/technical/group-analytics.js +151 -0
- package/dungeons/technical/mirror-strategies-schema.json +84 -0
- package/dungeons/technical/mirror-strategies.js +126 -0
- package/dungeons/technical/nested-objects-schema.json +145 -0
- package/dungeons/technical/nested-objects.js +207 -0
- package/dungeons/technical/retention-cadence-schema.json +37 -0
- package/dungeons/{retention-cadence.js → technical/retention-cadence.js} +2 -3
- package/dungeons/technical/sanity-schema.json +185 -0
- package/dungeons/{sanity.js → technical/sanity.js} +4 -2
- package/dungeons/technical/scale-test-schema.json +70 -0
- package/dungeons/technical/scale-test.js +90 -0
- package/dungeons/technical/scd-schema.json +467 -0
- package/dungeons/{scd.js → technical/scd.js} +20 -10
- package/dungeons/technical/simple-schema.json +362 -0
- package/dungeons/{simple.js → technical/simple.js} +7 -7
- package/dungeons/technical/simplest-schema.json +724 -0
- package/dungeons/{simplest.js → technical/simplest.js} +7 -7
- package/dungeons/technical/text-generation-schema.json +1062 -0
- package/dungeons/{text-generation.js → technical/text-generation.js} +24 -11
- package/dungeons/vertical/community-schema.json +579 -0
- package/dungeons/vertical/community.js +794 -0
- package/dungeons/vertical/devtools-schema.json +601 -0
- package/dungeons/vertical/devtools.js +843 -0
- package/dungeons/vertical/ecommerce-schema.json +604 -0
- package/dungeons/{ecommerce.js → vertical/ecommerce.js} +43 -5
- package/dungeons/vertical/education-schema.json +5686 -0
- package/dungeons/{education.js → vertical/education.js} +70 -39
- package/dungeons/vertical/fintech-schema.json +630 -0
- package/dungeons/{fintech.js → vertical/fintech.js} +107 -56
- package/dungeons/vertical/fitness-schema.json +530 -0
- package/dungeons/vertical/fitness.js +808 -0
- package/dungeons/vertical/food-delivery-schema.json +36728 -0
- package/dungeons/{food.js → vertical/food-delivery.js} +67 -26
- package/dungeons/vertical/gaming-schema.json +438 -0
- package/dungeons/{gaming.js → vertical/gaming.js} +29 -16
- package/dungeons/vertical/healthcare-schema.json +549 -0
- package/dungeons/vertical/healthcare.js +775 -0
- package/dungeons/vertical/insurance-application-schema.json +485 -0
- package/dungeons/{insurance-application.js → vertical/insurance-application.js} +41 -31
- package/dungeons/vertical/logistics-schema.json +574 -0
- package/dungeons/vertical/logistics.js +799 -0
- package/dungeons/vertical/marketplace-schema.json +533 -0
- package/dungeons/vertical/marketplace.js +850 -0
- package/dungeons/vertical/media-schema.json +4749 -0
- package/dungeons/{media.js → vertical/media.js} +103 -19
- package/dungeons/vertical/rpg-schema.json +2491 -0
- package/dungeons/{rpg.js → vertical/rpg.js} +87 -60
- package/dungeons/vertical/sass-schema.json +3128 -0
- package/dungeons/{sass.js → vertical/sass.js} +65 -26
- package/dungeons/vertical/social-schema.json +620 -0
- package/dungeons/{social.js → vertical/social.js} +76 -17
- package/dungeons/vertical/travel-schema.json +580 -0
- package/dungeons/vertical/travel.js +742 -0
- package/index.js +20 -16
- package/lib/core/config-validator.js +286 -1
- package/lib/core/context.js +16 -5
- package/lib/core/storage.js +2 -0
- package/lib/generators/adspend.js +3 -3
- package/lib/generators/events.js +141 -14
- package/lib/generators/funnels.js +67 -7
- package/lib/generators/text.js +2 -2
- package/lib/orchestrators/user-loop.js +444 -22
- package/lib/templates/soup-presets.js +2 -2
- package/lib/utils/utils.js +4 -5
- package/package.json +4 -3
- package/scripts/dungeon-to-json.mjs +163 -0
- package/scripts/extract-dungeon-schema.mjs +343 -0
- package/scripts/json-to-dungeon.mjs +200 -0
- package/scripts/run-dungeon.mjs +76 -0
- package/scripts/run-many.mjs +118 -0
- package/scripts/verify-runner.mjs +42 -0
- package/types.d.ts +316 -1
- package/dungeons/array-of-object-lookup-schema.json +0 -327
- package/dungeons/ecommerce-schema.json +0 -462
- package/dungeons/education-schema.json +0 -2409
- package/dungeons/fintech-schema.json +0 -14034
- package/dungeons/foobar-schema.json +0 -403
- package/dungeons/food-delivery-schema.json +0 -192
- package/dungeons/food-delivery.js +0 -602
- package/dungeons/food-schema.json +0 -1152
- package/dungeons/gaming-schema.json +0 -1270
- package/dungeons/insurance-application-schema.json +0 -204
- package/dungeons/media-schema.json +0 -906
- package/dungeons/retention-cadence-schema.json +0 -78
- package/dungeons/rpg-schema.json +0 -4526
- package/dungeons/sanity-schema.json +0 -255
- package/dungeons/sass-schema.json +0 -1291
- package/dungeons/scd-schema.json +0 -919
- package/dungeons/simple-schema.json +0 -608
- package/dungeons/simplest-schema.json +0 -1418
- package/dungeons/social-schema.json +0 -1118
- package/dungeons/text-generation-schema.json +0 -3096
|
@@ -0,0 +1,362 @@
|
|
|
1
|
+
{
|
|
2
|
+
"events": [
|
|
3
|
+
{
|
|
4
|
+
"event": "ad impression",
|
|
5
|
+
"weight": 15,
|
|
6
|
+
"properties": {
|
|
7
|
+
"partner": [
|
|
8
|
+
"google",
|
|
9
|
+
"facebook",
|
|
10
|
+
"twitter",
|
|
11
|
+
"linkedin",
|
|
12
|
+
"bing",
|
|
13
|
+
"taboola",
|
|
14
|
+
"outbrain",
|
|
15
|
+
"quora",
|
|
16
|
+
"pinterest"
|
|
17
|
+
]
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"event": "ad click",
|
|
22
|
+
"weight": 10,
|
|
23
|
+
"properties": {
|
|
24
|
+
"partner": [
|
|
25
|
+
"google",
|
|
26
|
+
"facebook",
|
|
27
|
+
"twitter",
|
|
28
|
+
"linkedin",
|
|
29
|
+
"bing",
|
|
30
|
+
"taboola",
|
|
31
|
+
"outbrain",
|
|
32
|
+
"quora",
|
|
33
|
+
"pinterest"
|
|
34
|
+
]
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
"event": "checkout",
|
|
39
|
+
"weight": 2,
|
|
40
|
+
"properties": {
|
|
41
|
+
"amount": {
|
|
42
|
+
"$range": [
|
|
43
|
+
104,
|
|
44
|
+
391
|
|
45
|
+
]
|
|
46
|
+
},
|
|
47
|
+
"currency": [
|
|
48
|
+
"USD",
|
|
49
|
+
"CAD",
|
|
50
|
+
"EUR",
|
|
51
|
+
"BTC",
|
|
52
|
+
"ETH",
|
|
53
|
+
"JPY"
|
|
54
|
+
],
|
|
55
|
+
"coupon": [
|
|
56
|
+
"none",
|
|
57
|
+
"10%OFF",
|
|
58
|
+
"20%OFF",
|
|
59
|
+
"30%OFF",
|
|
60
|
+
"40%OFF",
|
|
61
|
+
"50%OFF"
|
|
62
|
+
],
|
|
63
|
+
"numItems": {
|
|
64
|
+
"$range": [
|
|
65
|
+
2,
|
|
66
|
+
9
|
|
67
|
+
]
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
"event": "add to cart",
|
|
73
|
+
"weight": 4,
|
|
74
|
+
"properties": {
|
|
75
|
+
"amount": {
|
|
76
|
+
"$range": [
|
|
77
|
+
110,
|
|
78
|
+
395
|
|
79
|
+
]
|
|
80
|
+
},
|
|
81
|
+
"rating": {
|
|
82
|
+
"$range": [
|
|
83
|
+
1,
|
|
84
|
+
5
|
|
85
|
+
]
|
|
86
|
+
},
|
|
87
|
+
"reviews": {
|
|
88
|
+
"$range": [
|
|
89
|
+
1,
|
|
90
|
+
35
|
|
91
|
+
]
|
|
92
|
+
},
|
|
93
|
+
"isFeaturedItem": [
|
|
94
|
+
true,
|
|
95
|
+
false
|
|
96
|
+
],
|
|
97
|
+
"itemCategory": [
|
|
98
|
+
"Beauty",
|
|
99
|
+
"Outdoors",
|
|
100
|
+
"Toys",
|
|
101
|
+
"Pet",
|
|
102
|
+
"Books",
|
|
103
|
+
"Health"
|
|
104
|
+
],
|
|
105
|
+
"dateItemListed": {
|
|
106
|
+
"$type": "string"
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
},
|
|
110
|
+
{
|
|
111
|
+
"event": "page view",
|
|
112
|
+
"weight": 10,
|
|
113
|
+
"properties": {
|
|
114
|
+
"page": [
|
|
115
|
+
"/",
|
|
116
|
+
"/help",
|
|
117
|
+
"/account",
|
|
118
|
+
"/watch",
|
|
119
|
+
"/listen",
|
|
120
|
+
"/product",
|
|
121
|
+
"/people",
|
|
122
|
+
"/peace"
|
|
123
|
+
],
|
|
124
|
+
"utm_source": [
|
|
125
|
+
"$organic",
|
|
126
|
+
"google",
|
|
127
|
+
"facebook",
|
|
128
|
+
"twitter",
|
|
129
|
+
"linkedin"
|
|
130
|
+
]
|
|
131
|
+
}
|
|
132
|
+
},
|
|
133
|
+
{
|
|
134
|
+
"event": "watch video",
|
|
135
|
+
"weight": 8,
|
|
136
|
+
"properties": {
|
|
137
|
+
"videoCategory": [
|
|
138
|
+
"news",
|
|
139
|
+
"gaming",
|
|
140
|
+
"inspirational",
|
|
141
|
+
"DIY",
|
|
142
|
+
"sports"
|
|
143
|
+
],
|
|
144
|
+
"isFeaturedItem": [
|
|
145
|
+
true,
|
|
146
|
+
false
|
|
147
|
+
],
|
|
148
|
+
"watchTimeSec": {
|
|
149
|
+
"$range": [
|
|
150
|
+
131,
|
|
151
|
+
467
|
|
152
|
+
]
|
|
153
|
+
},
|
|
154
|
+
"quality": [
|
|
155
|
+
"2160p",
|
|
156
|
+
"1440p",
|
|
157
|
+
"1080p",
|
|
158
|
+
"720p",
|
|
159
|
+
"480p",
|
|
160
|
+
"360p",
|
|
161
|
+
"240p"
|
|
162
|
+
],
|
|
163
|
+
"format": [
|
|
164
|
+
"mp4",
|
|
165
|
+
"avi",
|
|
166
|
+
"mov",
|
|
167
|
+
"mpg"
|
|
168
|
+
],
|
|
169
|
+
"uploader_id": {
|
|
170
|
+
"$type": "string"
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
},
|
|
174
|
+
{
|
|
175
|
+
"event": "view item",
|
|
176
|
+
"weight": 8,
|
|
177
|
+
"properties": {
|
|
178
|
+
"isFeaturedItem": [
|
|
179
|
+
true,
|
|
180
|
+
false
|
|
181
|
+
],
|
|
182
|
+
"itemCategory": [
|
|
183
|
+
"Automotive",
|
|
184
|
+
"Appliances",
|
|
185
|
+
"Baby",
|
|
186
|
+
"Kids",
|
|
187
|
+
"Sports",
|
|
188
|
+
"Beauty",
|
|
189
|
+
"Music"
|
|
190
|
+
],
|
|
191
|
+
"dateItemListed": {
|
|
192
|
+
"$type": "string"
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
},
|
|
196
|
+
{
|
|
197
|
+
"event": "save item",
|
|
198
|
+
"weight": 5,
|
|
199
|
+
"properties": {
|
|
200
|
+
"isFeaturedItem": [
|
|
201
|
+
true,
|
|
202
|
+
false
|
|
203
|
+
],
|
|
204
|
+
"itemCategory": [
|
|
205
|
+
"Computers",
|
|
206
|
+
"Books",
|
|
207
|
+
"Electronics",
|
|
208
|
+
"Sports",
|
|
209
|
+
"Beauty",
|
|
210
|
+
"Games",
|
|
211
|
+
"Food"
|
|
212
|
+
],
|
|
213
|
+
"dateItemListed": {
|
|
214
|
+
"$type": "string"
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
},
|
|
218
|
+
{
|
|
219
|
+
"event": "sign up",
|
|
220
|
+
"isFirstEvent": true,
|
|
221
|
+
"properties": {
|
|
222
|
+
"signupMethod": [
|
|
223
|
+
"email",
|
|
224
|
+
"google",
|
|
225
|
+
"facebook",
|
|
226
|
+
"twitter",
|
|
227
|
+
"linkedin",
|
|
228
|
+
"github"
|
|
229
|
+
],
|
|
230
|
+
"referral": [
|
|
231
|
+
"none",
|
|
232
|
+
"friend",
|
|
233
|
+
"ad"
|
|
234
|
+
]
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
],
|
|
238
|
+
"funnels": [
|
|
239
|
+
{
|
|
240
|
+
"sequence": [
|
|
241
|
+
"page view",
|
|
242
|
+
"view item",
|
|
243
|
+
"save item",
|
|
244
|
+
"page view",
|
|
245
|
+
"sign up"
|
|
246
|
+
],
|
|
247
|
+
"name": "Signup Flow",
|
|
248
|
+
"isFirstFunnel": true,
|
|
249
|
+
"conversionRate": 50,
|
|
250
|
+
"timeToConvert": 2,
|
|
251
|
+
"order": "first-and-last-fixed",
|
|
252
|
+
"experiment": true
|
|
253
|
+
}
|
|
254
|
+
],
|
|
255
|
+
"superProps": {
|
|
256
|
+
"theme": [
|
|
257
|
+
"light",
|
|
258
|
+
"dark",
|
|
259
|
+
"custom"
|
|
260
|
+
]
|
|
261
|
+
},
|
|
262
|
+
"userProps": {
|
|
263
|
+
"title": {
|
|
264
|
+
"$type": "string"
|
|
265
|
+
},
|
|
266
|
+
"luckyNumber": {
|
|
267
|
+
"$range": [
|
|
268
|
+
114,
|
|
269
|
+
333
|
|
270
|
+
]
|
|
271
|
+
},
|
|
272
|
+
"spiritAnimal": [
|
|
273
|
+
"duck",
|
|
274
|
+
"dog",
|
|
275
|
+
"otter",
|
|
276
|
+
"penguin",
|
|
277
|
+
"cat",
|
|
278
|
+
"elephant",
|
|
279
|
+
"lion",
|
|
280
|
+
"cheetah",
|
|
281
|
+
"giraffe",
|
|
282
|
+
"zebra",
|
|
283
|
+
"rhino",
|
|
284
|
+
"hippo",
|
|
285
|
+
"whale",
|
|
286
|
+
"dolphin",
|
|
287
|
+
"shark",
|
|
288
|
+
"octopus",
|
|
289
|
+
"squid",
|
|
290
|
+
"jellyfish",
|
|
291
|
+
"starfish",
|
|
292
|
+
"seahorse",
|
|
293
|
+
"crab",
|
|
294
|
+
"lobster",
|
|
295
|
+
"shrimp",
|
|
296
|
+
"clam",
|
|
297
|
+
"snail",
|
|
298
|
+
"slug",
|
|
299
|
+
"butterfly",
|
|
300
|
+
"moth",
|
|
301
|
+
"bee",
|
|
302
|
+
"wasp",
|
|
303
|
+
"ant",
|
|
304
|
+
"beetle",
|
|
305
|
+
"ladybug",
|
|
306
|
+
"caterpillar",
|
|
307
|
+
"centipede",
|
|
308
|
+
"millipede",
|
|
309
|
+
"scorpion",
|
|
310
|
+
"spider",
|
|
311
|
+
"tarantula",
|
|
312
|
+
"tick",
|
|
313
|
+
"mite",
|
|
314
|
+
"mosquito",
|
|
315
|
+
"fly",
|
|
316
|
+
"dragonfly",
|
|
317
|
+
"damselfly",
|
|
318
|
+
"grasshopper",
|
|
319
|
+
"cricket",
|
|
320
|
+
"locust",
|
|
321
|
+
"mantis",
|
|
322
|
+
"cockroach",
|
|
323
|
+
"termite",
|
|
324
|
+
"praying mantis",
|
|
325
|
+
"walking stick",
|
|
326
|
+
"stick bug",
|
|
327
|
+
"leaf insect",
|
|
328
|
+
"lacewing",
|
|
329
|
+
"aphid",
|
|
330
|
+
"cicada",
|
|
331
|
+
"thrips",
|
|
332
|
+
"psyllid",
|
|
333
|
+
"scale insect",
|
|
334
|
+
"whitefly",
|
|
335
|
+
"mealybug",
|
|
336
|
+
"planthopper",
|
|
337
|
+
"leafhopper",
|
|
338
|
+
"treehopper",
|
|
339
|
+
"flea",
|
|
340
|
+
"louse",
|
|
341
|
+
"bedbug",
|
|
342
|
+
"flea beetle",
|
|
343
|
+
"weevil",
|
|
344
|
+
"longhorn beetle",
|
|
345
|
+
"leaf beetle",
|
|
346
|
+
"tiger beetle",
|
|
347
|
+
"ground beetle",
|
|
348
|
+
"lady beetle",
|
|
349
|
+
"firefly",
|
|
350
|
+
"click beetle",
|
|
351
|
+
"rove beetle",
|
|
352
|
+
"scarab beetle",
|
|
353
|
+
"dung beetle",
|
|
354
|
+
"stag beetle",
|
|
355
|
+
"rhinoceros beetle",
|
|
356
|
+
"hercules beetle",
|
|
357
|
+
"goliath beetle",
|
|
358
|
+
"jewel beetle",
|
|
359
|
+
"tortoise beetle"
|
|
360
|
+
]
|
|
361
|
+
}
|
|
362
|
+
}
|
|
@@ -4,8 +4,9 @@ import dayjs from "dayjs";
|
|
|
4
4
|
import utc from "dayjs/plugin/utc.js";
|
|
5
5
|
dayjs.extend(utc);
|
|
6
6
|
import { uid, comma } from 'ak-tools';
|
|
7
|
-
import { pickAWinner, weighNumRange, date, integer, weighChoices } from "
|
|
7
|
+
import { pickAWinner, weighNumRange, date, integer, weighChoices } from "../../lib/utils/utils.js";
|
|
8
8
|
|
|
9
|
+
/** @typedef {import("../../types").Dungeon} Config */
|
|
9
10
|
const itemCategories = ["Books", "Movies", "Music", "Games", "Electronics", "Computers", "Smart Home", "Home", "Garden", "Pet", "Beauty", "Health", "Toys", "Kids", "Baby", "Handmade", "Sports", "Outdoors", "Automotive", "Industrial", "Entertainment", "Art", "Food", "Appliances", "Office", "Wedding", "Software"];
|
|
10
11
|
|
|
11
12
|
const videoCategories = ["funny", "educational", "inspirational", "music", "news", "sports", "cooking", "DIY", "travel", "gaming"];
|
|
@@ -57,7 +58,7 @@ const videoCategories = ["funny", "educational", "inspirational", "music", "news
|
|
|
57
58
|
* Expected: low-quality cohort volume thins out after midpoint
|
|
58
59
|
*/
|
|
59
60
|
|
|
60
|
-
/** @type {import('
|
|
61
|
+
/** @type {import('../../types').Dungeon} */
|
|
61
62
|
const config = {
|
|
62
63
|
token: "",
|
|
63
64
|
seed: "simple is best",
|
|
@@ -78,7 +79,6 @@ const config = {
|
|
|
78
79
|
isAnonymous: false,
|
|
79
80
|
alsoInferFunnels: true,
|
|
80
81
|
concurrency: 1,
|
|
81
|
-
batchSize: 2_500_000,
|
|
82
82
|
|
|
83
83
|
|
|
84
84
|
events: [
|
|
@@ -123,8 +123,8 @@ const config = {
|
|
|
123
123
|
event: "page view",
|
|
124
124
|
weight: 10,
|
|
125
125
|
properties: {
|
|
126
|
-
page:
|
|
127
|
-
utm_source:
|
|
126
|
+
page: ["/", "/", "/help", "/account", "/watch", "/listen", "/product", "/people", "/peace"],
|
|
127
|
+
utm_source: ["$organic", "$organic", "$organic", "$organic", "google", "google", "google", "facebook", "facebook", "twitter", "linkedin"],
|
|
128
128
|
}
|
|
129
129
|
},
|
|
130
130
|
{
|
|
@@ -184,7 +184,7 @@ const config = {
|
|
|
184
184
|
|
|
185
185
|
],
|
|
186
186
|
superProps: {
|
|
187
|
-
theme:
|
|
187
|
+
theme: ["light", "dark", "custom", "light", "dark"],
|
|
188
188
|
},
|
|
189
189
|
/*
|
|
190
190
|
user properties work the same as event properties
|
|
@@ -193,7 +193,7 @@ const config = {
|
|
|
193
193
|
userProps: {
|
|
194
194
|
title: chance.profession.bind(chance),
|
|
195
195
|
luckyNumber: weighNumRange(42, 420, .3),
|
|
196
|
-
spiritAnimal:
|
|
196
|
+
spiritAnimal: ["duck", "dog", "otter", "penguin", "cat", "elephant", "lion", "cheetah", "giraffe", "zebra", "rhino", "hippo", "whale", "dolphin", "shark", "octopus", "squid", "jellyfish", "starfish", "seahorse", "crab", "lobster", "shrimp", "clam", "snail", "slug", "butterfly", "moth", "bee", "wasp", "ant", "beetle", "ladybug", "caterpillar", "centipede", "millipede", "scorpion", "spider", "tarantula", "tick", "mite", "mosquito", "fly", "dragonfly", "damselfly", "grasshopper", "cricket", "locust", "mantis", "cockroach", "termite", "praying mantis", "walking stick", "stick bug", "leaf insect", "lacewing", "aphid", "cicada", "thrips", "psyllid", "scale insect", "whitefly", "mealybug", "planthopper", "leafhopper", "treehopper", "flea", "louse", "bedbug", "flea beetle", "weevil", "longhorn beetle", "leaf beetle", "tiger beetle", "ground beetle", "lady beetle", "firefly", "click beetle", "rove beetle", "scarab beetle", "dung beetle", "stag beetle", "rhinoceros beetle", "hercules beetle", "goliath beetle", "jewel beetle", "tortoise beetle"]
|
|
197
197
|
},
|
|
198
198
|
scdProps: {},
|
|
199
199
|
mirrorProps: {},
|