make-mp-data 2.1.11 → 3.0.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/README.md +31 -0
- package/dungeons/adspend.js +2 -2
- package/dungeons/ai-chat-analytics-ed.js +3 -2
- package/dungeons/anon.js +2 -2
- package/dungeons/array-of-object-loopup.js +181 -0
- package/dungeons/benchmark-heavy.js +241 -0
- package/dungeons/benchmark-light.js +141 -0
- package/dungeons/big.js +9 -8
- package/dungeons/business.js +2 -1
- package/dungeons/clinch-agi.js +632 -0
- package/dungeons/complex.js +3 -2
- package/dungeons/copilot.js +383 -0
- package/dungeons/ecommerce-store.js +0 -0
- package/dungeons/experiments.js +5 -4
- package/dungeons/foobar.js +1 -1
- package/dungeons/funnels.js +2 -2
- package/dungeons/gaming.js +3 -2
- package/dungeons/harness/harness-education.js +988 -0
- package/dungeons/harness/harness-fintech.js +976 -0
- package/dungeons/harness/harness-food.js +985 -0
- package/dungeons/harness/harness-gaming.js +1178 -0
- package/dungeons/harness/harness-media.js +961 -0
- package/dungeons/harness/harness-sass.js +923 -0
- package/dungeons/harness/harness-social.js +928 -0
- package/dungeons/kurby.js +211 -0
- package/dungeons/media.js +5 -4
- package/dungeons/mil.js +4 -3
- package/dungeons/mirror.js +2 -2
- package/dungeons/money2020-ed.js +8 -7
- package/dungeons/sanity.js +3 -2
- package/dungeons/scd.js +3 -2
- package/dungeons/simple.js +30 -15
- package/dungeons/strict-event-test.js +30 -0
- package/dungeons/student-teacher.js +3 -2
- package/dungeons/text-generation.js +84 -85
- package/dungeons/too-big-events.js +166 -0
- package/dungeons/uday-schema.json +220 -0
- package/dungeons/userAgent.js +4 -3
- package/index.js +41 -54
- package/lib/core/config-validator.js +122 -7
- package/lib/core/context.js +7 -14
- package/lib/core/storage.js +57 -25
- package/lib/generators/adspend.js +12 -12
- package/lib/generators/events.js +6 -5
- package/lib/generators/funnels.js +32 -10
- package/lib/generators/product-lookup.js +262 -0
- package/lib/generators/product-names.js +195 -0
- package/lib/generators/profiles.js +3 -3
- package/lib/generators/scd.js +13 -3
- package/lib/generators/text.js +17 -4
- package/lib/orchestrators/mixpanel-sender.js +244 -204
- package/lib/orchestrators/user-loop.js +54 -16
- package/lib/templates/funnels-instructions.txt +272 -0
- package/lib/templates/hook-examples.json +187 -0
- package/lib/templates/hooks-instructions.txt +295 -8
- package/lib/templates/phrases.js +473 -16
- package/lib/templates/refine-instructions.txt +485 -0
- package/lib/templates/schema-instructions.txt +239 -109
- package/lib/templates/schema.d.ts +173 -0
- package/lib/templates/verbose-schema.js +140 -206
- package/lib/utils/ai.js +853 -77
- package/lib/utils/chart.js +210 -0
- package/lib/utils/function-registry.js +285 -0
- package/lib/utils/json-evaluator.js +172 -0
- package/lib/utils/logger.js +38 -0
- package/lib/utils/mixpanel.js +101 -0
- package/lib/utils/project.js +3 -2
- package/lib/utils/utils.js +41 -4
- package/package.json +15 -21
- package/types.d.ts +15 -5
- package/lib/generators/text-bak-old.js +0 -1121
- package/lib/orchestrators/worker-manager.js +0 -203
- package/lib/templates/phrases-bak.js +0 -925
- package/lib/templates/prompt (old).txt +0 -98
- package/lib/templates/scratch-dungeon-template.js +0 -116
- package/lib/templates/textQuickTest.js +0 -172
package/dungeons/big.js
CHANGED
|
@@ -1,34 +1,35 @@
|
|
|
1
1
|
import Chance from 'chance';
|
|
2
2
|
import dayjs from 'dayjs';
|
|
3
|
-
import utc from 'dayjs/plugin/utc';
|
|
3
|
+
import utc from 'dayjs/plugin/utc.js';
|
|
4
4
|
import { uid, comma, makeName } from 'ak-tools';
|
|
5
|
-
import { pickAWinner, weighNumRange, integer, date, choose } from
|
|
5
|
+
import { pickAWinner, weighNumRange, integer, date, choose } from "../lib/utils/utils.js";
|
|
6
6
|
|
|
7
7
|
const seed = "lets go big";
|
|
8
8
|
const chance = new Chance();
|
|
9
9
|
dayjs.extend(utc);
|
|
10
10
|
|
|
11
11
|
|
|
12
|
-
const eventsPerQuarter =
|
|
13
|
-
const numQuarters =
|
|
14
|
-
const parallelism = 5000;
|
|
15
|
-
const totalEvents = Math.floor((eventsPerQuarter * numQuarters)
|
|
12
|
+
const eventsPerQuarter = 10_000_000 // 50M
|
|
13
|
+
const numQuarters = 4; // 12 months
|
|
14
|
+
// const parallelism = 5000;
|
|
15
|
+
const totalEvents = Math.floor((eventsPerQuarter * numQuarters));
|
|
16
16
|
const eventPerUser = 500;
|
|
17
17
|
const totalUsers = Math.floor(totalEvents / eventPerUser);
|
|
18
18
|
const totalDays = (numQuarters * 90) + 10;
|
|
19
19
|
|
|
20
20
|
/** @type {import('../types').Dungeon} */
|
|
21
21
|
const config = {
|
|
22
|
-
token: "",
|
|
22
|
+
// token: process.env.MASTER_PROJECT_TOKEN || "",
|
|
23
23
|
seed: seed,
|
|
24
24
|
numDays: totalDays,
|
|
25
25
|
numEvents: totalEvents,
|
|
26
26
|
numUsers: totalUsers,
|
|
27
|
+
strictEventCount: true,
|
|
27
28
|
format: 'json', //csv or json
|
|
28
29
|
region: "US",
|
|
29
30
|
hasAnonIds: false, //if true, anonymousIds are created for each user
|
|
30
31
|
hasSessionIds: false, //if true, hasSessionIds are created for each user
|
|
31
|
-
hasLocation:
|
|
32
|
+
hasLocation: false,
|
|
32
33
|
hasAndroidDevices: false,
|
|
33
34
|
alsoInferFunnels: false,
|
|
34
35
|
batchSize: 2_000_000,
|
package/dungeons/business.js
CHANGED
|
@@ -22,7 +22,7 @@ const USERS = EVENTS / 100
|
|
|
22
22
|
|
|
23
23
|
/** @type {import('../types.js').Dungeon} */
|
|
24
24
|
const config = {
|
|
25
|
-
token: "",
|
|
25
|
+
token: process.env.MASTER_PROJECT_TOKEN || "",
|
|
26
26
|
seed: "it's business time...",
|
|
27
27
|
numDays: 90, //how many days worth of data
|
|
28
28
|
numEvents: EVENTS, //how many events
|
|
@@ -41,6 +41,7 @@ const config = {
|
|
|
41
41
|
hasAdSpend: true,
|
|
42
42
|
|
|
43
43
|
hasAvatar: false,
|
|
44
|
+
makeChart: true,
|
|
44
45
|
|
|
45
46
|
batchSize: 500_000,
|
|
46
47
|
concurrency: 500,
|