@contractspec/example.learning-journey-duo-drills 1.57.0 → 1.59.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/.turbo/turbo-build.log +31 -30
- package/.turbo/turbo-prebuild.log +1 -0
- package/CHANGELOG.md +25 -0
- package/dist/browser/docs/duo-drills.docblock.js +30 -0
- package/dist/browser/docs/index.js +30 -0
- package/dist/browser/example.js +32 -0
- package/dist/browser/index.js +123 -0
- package/dist/browser/track.js +62 -0
- package/dist/docs/duo-drills.docblock.d.ts +2 -1
- package/dist/docs/duo-drills.docblock.d.ts.map +1 -0
- package/dist/docs/duo-drills.docblock.js +18 -23
- package/dist/docs/index.d.ts +2 -1
- package/dist/docs/index.d.ts.map +1 -0
- package/dist/docs/index.js +31 -1
- package/dist/example.d.ts +2 -6
- package/dist/example.d.ts.map +1 -1
- package/dist/example.js +31 -40
- package/dist/index.d.ts +4 -3
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +123 -4
- package/dist/node/docs/duo-drills.docblock.js +30 -0
- package/dist/node/docs/index.js +30 -0
- package/dist/node/example.js +32 -0
- package/dist/node/index.js +123 -0
- package/dist/node/track.js +62 -0
- package/dist/track.d.ts +3 -7
- package/dist/track.d.ts.map +1 -1
- package/dist/track.js +62 -65
- package/dist/track.test.d.ts +2 -0
- package/dist/track.test.d.ts.map +1 -0
- package/package.json +61 -24
- package/tsdown.config.js +1 -2
- package/.turbo/turbo-build$colon$bundle.log +0 -30
- package/dist/docs/duo-drills.docblock.js.map +0 -1
- package/dist/example.js.map +0 -1
- package/dist/track.js.map +0 -1
- package/tsconfig.tsbuildinfo +0 -1
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,31 +1,32 @@
|
|
|
1
|
-
$ bun
|
|
2
|
-
$
|
|
3
|
-
$
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
[34mℹ[39m target: [34mesnext[39m
|
|
8
|
-
[34mℹ[39m tsconfig: [34mtsconfig.json[39m
|
|
9
|
-
[34mℹ[39m Build start
|
|
10
|
-
[34mℹ[39m [2mdist/[22m[1mtrack.js[22m [2m1.71 kB[22m [2m│ gzip: 0.74 kB[22m
|
|
11
|
-
[34mℹ[39m [2mdist/[22m[1mdocs/duo-drills.docblock.js[22m [2m1.43 kB[22m [2m│ gzip: 0.79 kB[22m
|
|
12
|
-
[34mℹ[39m [2mdist/[22m[1mexample.js[22m [2m0.95 kB[22m [2m│ gzip: 0.53 kB[22m
|
|
13
|
-
[34mℹ[39m [2mdist/[22m[1mindex.js[22m [2m0.19 kB[22m [2m│ gzip: 0.12 kB[22m
|
|
14
|
-
[34mℹ[39m [2mdist/[22m[1mdocs/index.js[22m [2m0.04 kB[22m [2m│ gzip: 0.06 kB[22m
|
|
15
|
-
[34mℹ[39m [2mdist/[22mtrack.js.map [2m2.73 kB[22m [2m│ gzip: 1.08 kB[22m
|
|
16
|
-
[34mℹ[39m [2mdist/[22mdocs/duo-drills.docblock.js.map [2m1.84 kB[22m [2m│ gzip: 0.97 kB[22m
|
|
17
|
-
[34mℹ[39m [2mdist/[22mexample.js.map [2m1.42 kB[22m [2m│ gzip: 0.73 kB[22m
|
|
18
|
-
[34mℹ[39m [2mdist/[22mtrack.d.ts.map [2m0.14 kB[22m [2m│ gzip: 0.13 kB[22m
|
|
19
|
-
[34mℹ[39m [2mdist/[22mexample.d.ts.map [2m0.13 kB[22m [2m│ gzip: 0.13 kB[22m
|
|
20
|
-
[34mℹ[39m [2mdist/[22m[32m[1mtrack.d.ts[22m[39m [2m0.34 kB[22m [2m│ gzip: 0.20 kB[22m
|
|
21
|
-
[34mℹ[39m [2mdist/[22m[32m[1mexample.d.ts[22m[39m [2m0.25 kB[22m [2m│ gzip: 0.17 kB[22m
|
|
22
|
-
[34mℹ[39m [2mdist/[22m[32m[1mindex.d.ts[22m[39m [2m0.16 kB[22m [2m│ gzip: 0.10 kB[22m
|
|
23
|
-
[34mℹ[39m [2mdist/[22m[32m[1mdocs/duo-drills.docblock.d.ts[22m[39m [2m0.01 kB[22m [2m│ gzip: 0.03 kB[22m
|
|
24
|
-
[34mℹ[39m [2mdist/[22m[32m[1mdocs/index.d.ts[22m[39m [2m0.01 kB[22m [2m│ gzip: 0.03 kB[22m
|
|
25
|
-
[34mℹ[39m 15 files, total: 11.36 kB
|
|
26
|
-
[33m[PLUGIN_TIMINGS] Warning:[0m Your build spent significant time in plugins. Here is a breakdown:
|
|
27
|
-
- rolldown-plugin-dts:generate (59%)
|
|
28
|
-
- tsdown:external (40%)
|
|
29
|
-
See https://rolldown.rs/options/checks#plugintimings for more details.
|
|
1
|
+
$ contractspec-bun-build prebuild
|
|
2
|
+
$ bun run prebuild && bun run build:bundle && bun run build:types
|
|
3
|
+
$ contractspec-bun-build prebuild
|
|
4
|
+
$ contractspec-bun-build transpile
|
|
5
|
+
[contractspec-bun-build] transpile target=bun root=src entries=5
|
|
6
|
+
Bundled 5 modules in 24ms
|
|
30
7
|
|
|
31
|
-
|
|
8
|
+
docs/duo-drills.docblock.js 1.45 KB (entry point)
|
|
9
|
+
./index.js 4.18 KB (entry point)
|
|
10
|
+
docs/index.js 1.45 KB (entry point)
|
|
11
|
+
./example.js 0.96 KB (entry point)
|
|
12
|
+
./track.js 1.80 KB (entry point)
|
|
13
|
+
|
|
14
|
+
[contractspec-bun-build] transpile target=node root=src entries=5
|
|
15
|
+
Bundled 5 modules in 19ms
|
|
16
|
+
|
|
17
|
+
docs/duo-drills.docblock.js 1.43 KB (entry point)
|
|
18
|
+
./index.js 4.15 KB (entry point)
|
|
19
|
+
docs/index.js 1.43 KB (entry point)
|
|
20
|
+
./example.js 0.95 KB (entry point)
|
|
21
|
+
./track.js 1.79 KB (entry point)
|
|
22
|
+
|
|
23
|
+
[contractspec-bun-build] transpile target=browser root=src entries=5
|
|
24
|
+
Bundled 5 modules in 23ms
|
|
25
|
+
|
|
26
|
+
docs/duo-drills.docblock.js 1.43 KB (entry point)
|
|
27
|
+
./index.js 4.15 KB (entry point)
|
|
28
|
+
docs/index.js 1.43 KB (entry point)
|
|
29
|
+
./example.js 0.95 KB (entry point)
|
|
30
|
+
./track.js 1.79 KB (entry point)
|
|
31
|
+
|
|
32
|
+
$ contractspec-bun-build types
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
$ contractspec-bun-build prebuild
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,30 @@
|
|
|
1
1
|
# @contractspec/example.learning-journey-duo-drills
|
|
2
2
|
|
|
3
|
+
## 1.59.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 1a0cf44: fix: publishConfig not supported by bun
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- Updated dependencies [1a0cf44]
|
|
12
|
+
- @contractspec/module.learning-journey@1.59.0
|
|
13
|
+
- @contractspec/lib.contracts@1.59.0
|
|
14
|
+
|
|
15
|
+
## 1.58.0
|
|
16
|
+
|
|
17
|
+
### Minor Changes
|
|
18
|
+
|
|
19
|
+
- d1f0fd0: chore: Migrate non-app package builds from tsdown to shared Bun tooling, add `@contractspec/tool.bun`, and standardize `prebuild`/`build`/`typecheck` with platform-aware exports and `tsc` declaration emission into `dist`.
|
|
20
|
+
|
|
21
|
+
### Patch Changes
|
|
22
|
+
|
|
23
|
+
- Updated dependencies [d1f0fd0]
|
|
24
|
+
- Updated dependencies [4355a9e]
|
|
25
|
+
- @contractspec/module.learning-journey@1.58.0
|
|
26
|
+
- @contractspec/lib.contracts@1.58.0
|
|
27
|
+
|
|
3
28
|
## 1.57.0
|
|
4
29
|
|
|
5
30
|
### Minor Changes
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
// src/docs/duo-drills.docblock.ts
|
|
2
|
+
import { registerDocBlocks } from "@contractspec/lib.contracts/docs";
|
|
3
|
+
var duoDrillsDocBlocks = [
|
|
4
|
+
{
|
|
5
|
+
id: "docs.learning-journey.duo-drills",
|
|
6
|
+
title: "Learning Journey — Duo Drills",
|
|
7
|
+
summary: "Short drill/SRS example with XP and streak hooks for language, finance, or ContractSpec concept drills.",
|
|
8
|
+
kind: "reference",
|
|
9
|
+
visibility: "public",
|
|
10
|
+
route: "/docs/learning-journey/duo-drills",
|
|
11
|
+
tags: ["learning", "drills", "srs", "xp"],
|
|
12
|
+
body: `## Track
|
|
13
|
+
- **Key**: \`drills_language_basics\`
|
|
14
|
+
- **Persona**: learner running quick drills (language/finance/spec concepts)
|
|
15
|
+
- **Goal**: complete first session, maintain high-accuracy sessions, master cards in the first skill
|
|
16
|
+
|
|
17
|
+
## Steps & Conditions
|
|
18
|
+
1) \`complete_first_session\` → event \`drill.session.completed\`
|
|
19
|
+
2) \`reach_accuracy_threshold\` → count 3 sessions with payload \`accuracyBucket: "high"\` (within default window)
|
|
20
|
+
3) \`unlock_new_skill\` → SRS mastery: \`drill.card.mastered\` events with \`mastery >= 0.8\`, count 5 cards
|
|
21
|
+
|
|
22
|
+
XP: 20 + 30 + 40. Streak: daily session completion can be used to drive streak rewards.
|
|
23
|
+
|
|
24
|
+
## Wiring
|
|
25
|
+
- Tracks export from \`@contractspec/example.learning-journey-duo-drills/track\`.
|
|
26
|
+
- Use registry helper \`recordEvent\` to advance steps from drill/session events.
|
|
27
|
+
- SRS mastery events should include payload: \`{ skillId, mastery }\`.`
|
|
28
|
+
}
|
|
29
|
+
];
|
|
30
|
+
registerDocBlocks(duoDrillsDocBlocks);
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
// src/docs/duo-drills.docblock.ts
|
|
2
|
+
import { registerDocBlocks } from "@contractspec/lib.contracts/docs";
|
|
3
|
+
var duoDrillsDocBlocks = [
|
|
4
|
+
{
|
|
5
|
+
id: "docs.learning-journey.duo-drills",
|
|
6
|
+
title: "Learning Journey — Duo Drills",
|
|
7
|
+
summary: "Short drill/SRS example with XP and streak hooks for language, finance, or ContractSpec concept drills.",
|
|
8
|
+
kind: "reference",
|
|
9
|
+
visibility: "public",
|
|
10
|
+
route: "/docs/learning-journey/duo-drills",
|
|
11
|
+
tags: ["learning", "drills", "srs", "xp"],
|
|
12
|
+
body: `## Track
|
|
13
|
+
- **Key**: \`drills_language_basics\`
|
|
14
|
+
- **Persona**: learner running quick drills (language/finance/spec concepts)
|
|
15
|
+
- **Goal**: complete first session, maintain high-accuracy sessions, master cards in the first skill
|
|
16
|
+
|
|
17
|
+
## Steps & Conditions
|
|
18
|
+
1) \`complete_first_session\` → event \`drill.session.completed\`
|
|
19
|
+
2) \`reach_accuracy_threshold\` → count 3 sessions with payload \`accuracyBucket: "high"\` (within default window)
|
|
20
|
+
3) \`unlock_new_skill\` → SRS mastery: \`drill.card.mastered\` events with \`mastery >= 0.8\`, count 5 cards
|
|
21
|
+
|
|
22
|
+
XP: 20 + 30 + 40. Streak: daily session completion can be used to drive streak rewards.
|
|
23
|
+
|
|
24
|
+
## Wiring
|
|
25
|
+
- Tracks export from \`@contractspec/example.learning-journey-duo-drills/track\`.
|
|
26
|
+
- Use registry helper \`recordEvent\` to advance steps from drill/session events.
|
|
27
|
+
- SRS mastery events should include payload: \`{ skillId, mastery }\`.`
|
|
28
|
+
}
|
|
29
|
+
];
|
|
30
|
+
registerDocBlocks(duoDrillsDocBlocks);
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
// src/example.ts
|
|
2
|
+
import { defineExample } from "@contractspec/lib.contracts";
|
|
3
|
+
var example = defineExample({
|
|
4
|
+
meta: {
|
|
5
|
+
key: "learning-journey-duo-drills",
|
|
6
|
+
version: "1.0.0",
|
|
7
|
+
title: "Learning Journey — Duo Drills",
|
|
8
|
+
description: "Short drill/SRS example with XP and streak hooks for language, finance, or ContractSpec concept drills.",
|
|
9
|
+
kind: "template",
|
|
10
|
+
visibility: "public",
|
|
11
|
+
stability: "experimental",
|
|
12
|
+
owners: ["@platform.core"],
|
|
13
|
+
tags: ["learning", "drills", "srs", "xp"]
|
|
14
|
+
},
|
|
15
|
+
docs: {
|
|
16
|
+
rootDocId: "docs.learning-journey.duo-drills"
|
|
17
|
+
},
|
|
18
|
+
entrypoints: {
|
|
19
|
+
packageName: "@contractspec/example.learning-journey-duo-drills",
|
|
20
|
+
docs: "./docs"
|
|
21
|
+
},
|
|
22
|
+
surfaces: {
|
|
23
|
+
templates: true,
|
|
24
|
+
sandbox: { enabled: true, modes: ["playground", "markdown"] },
|
|
25
|
+
studio: { enabled: true, installable: true },
|
|
26
|
+
mcp: { enabled: true }
|
|
27
|
+
}
|
|
28
|
+
});
|
|
29
|
+
var example_default = example;
|
|
30
|
+
export {
|
|
31
|
+
example_default as default
|
|
32
|
+
};
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
// src/docs/duo-drills.docblock.ts
|
|
2
|
+
import { registerDocBlocks } from "@contractspec/lib.contracts/docs";
|
|
3
|
+
var duoDrillsDocBlocks = [
|
|
4
|
+
{
|
|
5
|
+
id: "docs.learning-journey.duo-drills",
|
|
6
|
+
title: "Learning Journey — Duo Drills",
|
|
7
|
+
summary: "Short drill/SRS example with XP and streak hooks for language, finance, or ContractSpec concept drills.",
|
|
8
|
+
kind: "reference",
|
|
9
|
+
visibility: "public",
|
|
10
|
+
route: "/docs/learning-journey/duo-drills",
|
|
11
|
+
tags: ["learning", "drills", "srs", "xp"],
|
|
12
|
+
body: `## Track
|
|
13
|
+
- **Key**: \`drills_language_basics\`
|
|
14
|
+
- **Persona**: learner running quick drills (language/finance/spec concepts)
|
|
15
|
+
- **Goal**: complete first session, maintain high-accuracy sessions, master cards in the first skill
|
|
16
|
+
|
|
17
|
+
## Steps & Conditions
|
|
18
|
+
1) \`complete_first_session\` → event \`drill.session.completed\`
|
|
19
|
+
2) \`reach_accuracy_threshold\` → count 3 sessions with payload \`accuracyBucket: "high"\` (within default window)
|
|
20
|
+
3) \`unlock_new_skill\` → SRS mastery: \`drill.card.mastered\` events with \`mastery >= 0.8\`, count 5 cards
|
|
21
|
+
|
|
22
|
+
XP: 20 + 30 + 40. Streak: daily session completion can be used to drive streak rewards.
|
|
23
|
+
|
|
24
|
+
## Wiring
|
|
25
|
+
- Tracks export from \`@contractspec/example.learning-journey-duo-drills/track\`.
|
|
26
|
+
- Use registry helper \`recordEvent\` to advance steps from drill/session events.
|
|
27
|
+
- SRS mastery events should include payload: \`{ skillId, mastery }\`.`
|
|
28
|
+
}
|
|
29
|
+
];
|
|
30
|
+
registerDocBlocks(duoDrillsDocBlocks);
|
|
31
|
+
// src/example.ts
|
|
32
|
+
import { defineExample } from "@contractspec/lib.contracts";
|
|
33
|
+
var example = defineExample({
|
|
34
|
+
meta: {
|
|
35
|
+
key: "learning-journey-duo-drills",
|
|
36
|
+
version: "1.0.0",
|
|
37
|
+
title: "Learning Journey — Duo Drills",
|
|
38
|
+
description: "Short drill/SRS example with XP and streak hooks for language, finance, or ContractSpec concept drills.",
|
|
39
|
+
kind: "template",
|
|
40
|
+
visibility: "public",
|
|
41
|
+
stability: "experimental",
|
|
42
|
+
owners: ["@platform.core"],
|
|
43
|
+
tags: ["learning", "drills", "srs", "xp"]
|
|
44
|
+
},
|
|
45
|
+
docs: {
|
|
46
|
+
rootDocId: "docs.learning-journey.duo-drills"
|
|
47
|
+
},
|
|
48
|
+
entrypoints: {
|
|
49
|
+
packageName: "@contractspec/example.learning-journey-duo-drills",
|
|
50
|
+
docs: "./docs"
|
|
51
|
+
},
|
|
52
|
+
surfaces: {
|
|
53
|
+
templates: true,
|
|
54
|
+
sandbox: { enabled: true, modes: ["playground", "markdown"] },
|
|
55
|
+
studio: { enabled: true, installable: true },
|
|
56
|
+
mcp: { enabled: true }
|
|
57
|
+
}
|
|
58
|
+
});
|
|
59
|
+
var example_default = example;
|
|
60
|
+
|
|
61
|
+
// src/track.ts
|
|
62
|
+
var drillsLanguageBasicsTrack = {
|
|
63
|
+
id: "drills_language_basics",
|
|
64
|
+
name: "Language Basics Drills",
|
|
65
|
+
description: "Short SRS-driven drills to master a first skill, modeled after Duolingo-style sessions.",
|
|
66
|
+
targetUserSegment: "learner",
|
|
67
|
+
targetRole: "individual",
|
|
68
|
+
totalXp: 50,
|
|
69
|
+
completionRewards: { xpBonus: 25 },
|
|
70
|
+
steps: [
|
|
71
|
+
{
|
|
72
|
+
id: "complete_first_session",
|
|
73
|
+
title: "Complete first drill session",
|
|
74
|
+
description: "Finish a drill session to get started.",
|
|
75
|
+
order: 1,
|
|
76
|
+
completion: {
|
|
77
|
+
kind: "event",
|
|
78
|
+
eventName: "drill.session.completed"
|
|
79
|
+
},
|
|
80
|
+
xpReward: 20,
|
|
81
|
+
metadata: { surface: "drills" }
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
id: "reach_accuracy_threshold",
|
|
85
|
+
title: "Hit high accuracy in sessions",
|
|
86
|
+
description: "Achieve three high-accuracy sessions to build confidence.",
|
|
87
|
+
order: 2,
|
|
88
|
+
completion: {
|
|
89
|
+
kind: "count",
|
|
90
|
+
eventName: "drill.session.completed",
|
|
91
|
+
atLeast: 3,
|
|
92
|
+
payloadFilter: { accuracyBucket: "high" }
|
|
93
|
+
},
|
|
94
|
+
xpReward: 30,
|
|
95
|
+
metadata: { metric: "accuracy", target: ">=85%" }
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
id: "unlock_new_skill",
|
|
99
|
+
title: "Master core cards in first skill",
|
|
100
|
+
description: "Reach mastery on at least five cards in the first skill to unlock the next one.",
|
|
101
|
+
order: 3,
|
|
102
|
+
completion: {
|
|
103
|
+
kind: "srs_mastery",
|
|
104
|
+
eventName: "drill.card.mastered",
|
|
105
|
+
minimumMastery: 0.8,
|
|
106
|
+
requiredCount: 5,
|
|
107
|
+
skillIdField: "skillId",
|
|
108
|
+
masteryField: "mastery",
|
|
109
|
+
payloadFilter: { skillId: "language_basics" }
|
|
110
|
+
},
|
|
111
|
+
xpReward: 40,
|
|
112
|
+
metadata: { surface: "srs", skill: "language_basics" }
|
|
113
|
+
}
|
|
114
|
+
]
|
|
115
|
+
};
|
|
116
|
+
var drillTracks = [
|
|
117
|
+
drillsLanguageBasicsTrack
|
|
118
|
+
];
|
|
119
|
+
export {
|
|
120
|
+
example_default as example,
|
|
121
|
+
drillsLanguageBasicsTrack,
|
|
122
|
+
drillTracks
|
|
123
|
+
};
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
// src/track.ts
|
|
2
|
+
var drillsLanguageBasicsTrack = {
|
|
3
|
+
id: "drills_language_basics",
|
|
4
|
+
name: "Language Basics Drills",
|
|
5
|
+
description: "Short SRS-driven drills to master a first skill, modeled after Duolingo-style sessions.",
|
|
6
|
+
targetUserSegment: "learner",
|
|
7
|
+
targetRole: "individual",
|
|
8
|
+
totalXp: 50,
|
|
9
|
+
completionRewards: { xpBonus: 25 },
|
|
10
|
+
steps: [
|
|
11
|
+
{
|
|
12
|
+
id: "complete_first_session",
|
|
13
|
+
title: "Complete first drill session",
|
|
14
|
+
description: "Finish a drill session to get started.",
|
|
15
|
+
order: 1,
|
|
16
|
+
completion: {
|
|
17
|
+
kind: "event",
|
|
18
|
+
eventName: "drill.session.completed"
|
|
19
|
+
},
|
|
20
|
+
xpReward: 20,
|
|
21
|
+
metadata: { surface: "drills" }
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
id: "reach_accuracy_threshold",
|
|
25
|
+
title: "Hit high accuracy in sessions",
|
|
26
|
+
description: "Achieve three high-accuracy sessions to build confidence.",
|
|
27
|
+
order: 2,
|
|
28
|
+
completion: {
|
|
29
|
+
kind: "count",
|
|
30
|
+
eventName: "drill.session.completed",
|
|
31
|
+
atLeast: 3,
|
|
32
|
+
payloadFilter: { accuracyBucket: "high" }
|
|
33
|
+
},
|
|
34
|
+
xpReward: 30,
|
|
35
|
+
metadata: { metric: "accuracy", target: ">=85%" }
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
id: "unlock_new_skill",
|
|
39
|
+
title: "Master core cards in first skill",
|
|
40
|
+
description: "Reach mastery on at least five cards in the first skill to unlock the next one.",
|
|
41
|
+
order: 3,
|
|
42
|
+
completion: {
|
|
43
|
+
kind: "srs_mastery",
|
|
44
|
+
eventName: "drill.card.mastered",
|
|
45
|
+
minimumMastery: 0.8,
|
|
46
|
+
requiredCount: 5,
|
|
47
|
+
skillIdField: "skillId",
|
|
48
|
+
masteryField: "mastery",
|
|
49
|
+
payloadFilter: { skillId: "language_basics" }
|
|
50
|
+
},
|
|
51
|
+
xpReward: 40,
|
|
52
|
+
metadata: { surface: "srs", skill: "language_basics" }
|
|
53
|
+
}
|
|
54
|
+
]
|
|
55
|
+
};
|
|
56
|
+
var drillTracks = [
|
|
57
|
+
drillsLanguageBasicsTrack
|
|
58
|
+
];
|
|
59
|
+
export {
|
|
60
|
+
drillsLanguageBasicsTrack,
|
|
61
|
+
drillTracks
|
|
62
|
+
};
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export {};
|
|
2
|
+
//# sourceMappingURL=duo-drills.docblock.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"duo-drills.docblock.d.ts","sourceRoot":"","sources":["../../src/docs/duo-drills.docblock.ts"],"names":[],"mappings":""}
|
|
@@ -1,28 +1,24 @@
|
|
|
1
|
+
// @bun
|
|
2
|
+
// src/docs/duo-drills.docblock.ts
|
|
1
3
|
import { registerDocBlocks } from "@contractspec/lib.contracts/docs";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
"learning",
|
|
13
|
-
"drills",
|
|
14
|
-
"srs",
|
|
15
|
-
"xp"
|
|
16
|
-
],
|
|
17
|
-
body: `## Track
|
|
4
|
+
var duoDrillsDocBlocks = [
|
|
5
|
+
{
|
|
6
|
+
id: "docs.learning-journey.duo-drills",
|
|
7
|
+
title: "Learning Journey \u2014 Duo Drills",
|
|
8
|
+
summary: "Short drill/SRS example with XP and streak hooks for language, finance, or ContractSpec concept drills.",
|
|
9
|
+
kind: "reference",
|
|
10
|
+
visibility: "public",
|
|
11
|
+
route: "/docs/learning-journey/duo-drills",
|
|
12
|
+
tags: ["learning", "drills", "srs", "xp"],
|
|
13
|
+
body: `## Track
|
|
18
14
|
- **Key**: \`drills_language_basics\`
|
|
19
15
|
- **Persona**: learner running quick drills (language/finance/spec concepts)
|
|
20
16
|
- **Goal**: complete first session, maintain high-accuracy sessions, master cards in the first skill
|
|
21
17
|
|
|
22
18
|
## Steps & Conditions
|
|
23
|
-
1) \`complete_first_session\`
|
|
24
|
-
2) \`reach_accuracy_threshold\`
|
|
25
|
-
3) \`unlock_new_skill\`
|
|
19
|
+
1) \`complete_first_session\` \u2192 event \`drill.session.completed\`
|
|
20
|
+
2) \`reach_accuracy_threshold\` \u2192 count 3 sessions with payload \`accuracyBucket: "high"\` (within default window)
|
|
21
|
+
3) \`unlock_new_skill\` \u2192 SRS mastery: \`drill.card.mastered\` events with \`mastery >= 0.8\`, count 5 cards
|
|
26
22
|
|
|
27
23
|
XP: 20 + 30 + 40. Streak: daily session completion can be used to drive streak rewards.
|
|
28
24
|
|
|
@@ -30,7 +26,6 @@ XP: 20 + 30 + 40. Streak: daily session completion can be used to drive streak r
|
|
|
30
26
|
- Tracks export from \`@contractspec/example.learning-journey-duo-drills/track\`.
|
|
31
27
|
- Use registry helper \`recordEvent\` to advance steps from drill/session events.
|
|
32
28
|
- SRS mastery events should include payload: \`{ skillId, mastery }\`.`
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
//# sourceMappingURL=duo-drills.docblock.js.map
|
|
29
|
+
}
|
|
30
|
+
];
|
|
31
|
+
registerDocBlocks(duoDrillsDocBlocks);
|
package/dist/docs/index.d.ts
CHANGED
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
import './duo-drills.docblock';
|
|
2
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/docs/index.ts"],"names":[],"mappings":"AAAA,OAAO,uBAAuB,CAAC"}
|
package/dist/docs/index.js
CHANGED
|
@@ -1 +1,31 @@
|
|
|
1
|
-
|
|
1
|
+
// @bun
|
|
2
|
+
// src/docs/duo-drills.docblock.ts
|
|
3
|
+
import { registerDocBlocks } from "@contractspec/lib.contracts/docs";
|
|
4
|
+
var duoDrillsDocBlocks = [
|
|
5
|
+
{
|
|
6
|
+
id: "docs.learning-journey.duo-drills",
|
|
7
|
+
title: "Learning Journey \u2014 Duo Drills",
|
|
8
|
+
summary: "Short drill/SRS example with XP and streak hooks for language, finance, or ContractSpec concept drills.",
|
|
9
|
+
kind: "reference",
|
|
10
|
+
visibility: "public",
|
|
11
|
+
route: "/docs/learning-journey/duo-drills",
|
|
12
|
+
tags: ["learning", "drills", "srs", "xp"],
|
|
13
|
+
body: `## Track
|
|
14
|
+
- **Key**: \`drills_language_basics\`
|
|
15
|
+
- **Persona**: learner running quick drills (language/finance/spec concepts)
|
|
16
|
+
- **Goal**: complete first session, maintain high-accuracy sessions, master cards in the first skill
|
|
17
|
+
|
|
18
|
+
## Steps & Conditions
|
|
19
|
+
1) \`complete_first_session\` \u2192 event \`drill.session.completed\`
|
|
20
|
+
2) \`reach_accuracy_threshold\` \u2192 count 3 sessions with payload \`accuracyBucket: "high"\` (within default window)
|
|
21
|
+
3) \`unlock_new_skill\` \u2192 SRS mastery: \`drill.card.mastered\` events with \`mastery >= 0.8\`, count 5 cards
|
|
22
|
+
|
|
23
|
+
XP: 20 + 30 + 40. Streak: daily session completion can be used to drive streak rewards.
|
|
24
|
+
|
|
25
|
+
## Wiring
|
|
26
|
+
- Tracks export from \`@contractspec/example.learning-journey-duo-drills/track\`.
|
|
27
|
+
- Use registry helper \`recordEvent\` to advance steps from drill/session events.
|
|
28
|
+
- SRS mastery events should include payload: \`{ skillId, mastery }\`.`
|
|
29
|
+
}
|
|
30
|
+
];
|
|
31
|
+
registerDocBlocks(duoDrillsDocBlocks);
|
package/dist/example.d.ts
CHANGED
|
@@ -1,7 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
//#region src/example.d.ts
|
|
4
|
-
declare const example: _contractspec_lib_contracts0.ExampleSpec;
|
|
5
|
-
//#endregion
|
|
6
|
-
export { example as default };
|
|
1
|
+
declare const example: import("@contractspec/lib.contracts").ExampleSpec;
|
|
2
|
+
export default example;
|
|
7
3
|
//# sourceMappingURL=example.d.ts.map
|
package/dist/example.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"example.d.ts","
|
|
1
|
+
{"version":3,"file":"example.d.ts","sourceRoot":"","sources":["../src/example.ts"],"names":[],"mappings":"AAEA,QAAA,MAAM,OAAO,mDA0BX,CAAC;AAEH,eAAe,OAAO,CAAC"}
|
package/dist/example.js
CHANGED
|
@@ -1,42 +1,33 @@
|
|
|
1
|
+
// @bun
|
|
2
|
+
// src/example.ts
|
|
1
3
|
import { defineExample } from "@contractspec/lib.contracts";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
templates: true,
|
|
28
|
-
sandbox: {
|
|
29
|
-
enabled: true,
|
|
30
|
-
modes: ["playground", "markdown"]
|
|
31
|
-
},
|
|
32
|
-
studio: {
|
|
33
|
-
enabled: true,
|
|
34
|
-
installable: true
|
|
35
|
-
},
|
|
36
|
-
mcp: { enabled: true }
|
|
37
|
-
}
|
|
4
|
+
var example = defineExample({
|
|
5
|
+
meta: {
|
|
6
|
+
key: "learning-journey-duo-drills",
|
|
7
|
+
version: "1.0.0",
|
|
8
|
+
title: "Learning Journey \u2014 Duo Drills",
|
|
9
|
+
description: "Short drill/SRS example with XP and streak hooks for language, finance, or ContractSpec concept drills.",
|
|
10
|
+
kind: "template",
|
|
11
|
+
visibility: "public",
|
|
12
|
+
stability: "experimental",
|
|
13
|
+
owners: ["@platform.core"],
|
|
14
|
+
tags: ["learning", "drills", "srs", "xp"]
|
|
15
|
+
},
|
|
16
|
+
docs: {
|
|
17
|
+
rootDocId: "docs.learning-journey.duo-drills"
|
|
18
|
+
},
|
|
19
|
+
entrypoints: {
|
|
20
|
+
packageName: "@contractspec/example.learning-journey-duo-drills",
|
|
21
|
+
docs: "./docs"
|
|
22
|
+
},
|
|
23
|
+
surfaces: {
|
|
24
|
+
templates: true,
|
|
25
|
+
sandbox: { enabled: true, modes: ["playground", "markdown"] },
|
|
26
|
+
studio: { enabled: true, installable: true },
|
|
27
|
+
mcp: { enabled: true }
|
|
28
|
+
}
|
|
38
29
|
});
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
30
|
+
var example_default = example;
|
|
31
|
+
export {
|
|
32
|
+
example_default as default
|
|
33
|
+
};
|
package/dist/index.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
export * from './track';
|
|
2
|
+
export { default as example } from './example';
|
|
3
|
+
import './docs';
|
|
4
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,OAAO,EAAE,OAAO,IAAI,OAAO,EAAE,MAAM,WAAW,CAAC;AAC/C,OAAO,QAAQ,CAAC"}
|