@contractspec/example.learning-journey-ambient-coach 1.46.2 → 1.47.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.
@@ -1,5 +1,5 @@
1
1
  $ tsdown
2
- ℹ tsdown v0.18.4 powered by rolldown v1.0.0-beta.57
2
+ ℹ tsdown v0.19.0 powered by rolldown v1.0.0-beta.59
3
3
  ℹ config file: /home/runner/work/contractspec/contractspec/packages/examples/learning-journey-ambient-coach/tsdown.config.js
4
4
  ℹ entry: src/example.ts, src/index.ts, src/track.ts, src/docs/ambient-coach.docblock.ts, src/docs/index.ts
5
5
  ℹ target: esnext
@@ -8,18 +8,18 @@ $ tsdown
8
8
  ℹ Cleaning 16 files
9
9
  ℹ dist/track.js 1.63 kB │ gzip: 0.72 kB
10
10
  ℹ dist/docs/ambient-coach.docblock.js 1.27 kB │ gzip: 0.71 kB
11
- ℹ dist/example.js 0.91 kB │ gzip: 0.50 kB
11
+ ℹ dist/example.js 0.98 kB │ gzip: 0.53 kB
12
12
  ℹ dist/index.js 0.28 kB │ gzip: 0.14 kB
13
13
  ℹ dist/docs/index.js 0.04 kB │ gzip: 0.06 kB
14
- ℹ dist/track.js.map 2.83 kB │ gzip: 1.07 kB
14
+ ℹ dist/track.js.map 2.67 kB │ gzip: 1.06 kB
15
15
  ℹ dist/docs/ambient-coach.docblock.js.map 1.68 kB │ gzip: 0.88 kB
16
- ℹ dist/example.js.map 1.43 kB │ gzip: 0.71 kB
16
+ ℹ dist/example.js.map 1.41 kB │ gzip: 0.72 kB
17
17
  ℹ dist/track.d.ts.map 0.18 kB │ gzip: 0.15 kB
18
- ℹ dist/example.d.ts.map 0.12 kB │ gzip: 0.12 kB
18
+ ℹ dist/example.d.ts.map 0.14 kB │ gzip: 0.13 kB
19
19
  ℹ dist/track.d.ts 0.44 kB │ gzip: 0.21 kB
20
+ ℹ dist/example.d.ts 0.25 kB │ gzip: 0.17 kB
20
21
  ℹ dist/index.d.ts 0.23 kB │ gzip: 0.12 kB
21
- ℹ dist/example.d.ts 0.20 kB │ gzip: 0.16 kB
22
22
  ℹ dist/docs/ambient-coach.docblock.d.ts 0.01 kB │ gzip: 0.03 kB
23
23
  ℹ dist/docs/index.d.ts 0.01 kB │ gzip: 0.03 kB
24
- ℹ 15 files, total: 11.25 kB
25
- ✔ Build complete in 18521ms
24
+ ℹ 15 files, total: 11.21 kB
25
+ ✔ Build complete in 18846ms
@@ -1,7 +1,7 @@
1
1
  $ bun build:types && bun build:bundle
2
2
  $ tsc --noEmit
3
3
  $ tsdown
4
- ℹ tsdown v0.18.4 powered by rolldown v1.0.0-beta.57
4
+ ℹ tsdown v0.19.0 powered by rolldown v1.0.0-beta.59
5
5
  ℹ config file: /home/runner/work/contractspec/contractspec/packages/examples/learning-journey-ambient-coach/tsdown.config.js
6
6
  ℹ entry: src/example.ts, src/index.ts, src/track.ts, src/docs/ambient-coach.docblock.ts, src/docs/index.ts
7
7
  ℹ target: esnext
@@ -9,18 +9,18 @@ $ tsdown
9
9
  ℹ Build start
10
10
  ℹ dist/track.js 1.63 kB │ gzip: 0.72 kB
11
11
  ℹ dist/docs/ambient-coach.docblock.js 1.27 kB │ gzip: 0.71 kB
12
- ℹ dist/example.js 0.91 kB │ gzip: 0.50 kB
12
+ ℹ dist/example.js 0.98 kB │ gzip: 0.53 kB
13
13
  ℹ dist/index.js 0.28 kB │ gzip: 0.14 kB
14
14
  ℹ dist/docs/index.js 0.04 kB │ gzip: 0.06 kB
15
- ℹ dist/track.js.map 2.83 kB │ gzip: 1.07 kB
15
+ ℹ dist/track.js.map 2.67 kB │ gzip: 1.06 kB
16
16
  ℹ dist/docs/ambient-coach.docblock.js.map 1.68 kB │ gzip: 0.88 kB
17
- ℹ dist/example.js.map 1.43 kB │ gzip: 0.71 kB
17
+ ℹ dist/example.js.map 1.41 kB │ gzip: 0.72 kB
18
18
  ℹ dist/track.d.ts.map 0.18 kB │ gzip: 0.15 kB
19
- ℹ dist/example.d.ts.map 0.12 kB │ gzip: 0.12 kB
19
+ ℹ dist/example.d.ts.map 0.14 kB │ gzip: 0.13 kB
20
20
  ℹ dist/track.d.ts 0.44 kB │ gzip: 0.21 kB
21
+ ℹ dist/example.d.ts 0.25 kB │ gzip: 0.17 kB
21
22
  ℹ dist/index.d.ts 0.23 kB │ gzip: 0.12 kB
22
- ℹ dist/example.d.ts 0.20 kB │ gzip: 0.16 kB
23
23
  ℹ dist/docs/ambient-coach.docblock.d.ts 0.01 kB │ gzip: 0.03 kB
24
24
  ℹ dist/docs/index.d.ts 0.01 kB │ gzip: 0.03 kB
25
- ℹ 15 files, total: 11.25 kB
26
- ✔ Build complete in 20833ms
25
+ ℹ 15 files, total: 11.21 kB
26
+ ✔ Build complete in 21839ms
package/CHANGELOG.md CHANGED
@@ -1,5 +1,27 @@
1
1
  # @contractspec/example.learning-journey-ambient-coach
2
2
 
3
+ ## 1.47.0
4
+
5
+ ### Minor Changes
6
+
7
+ - caf8701: feat: add cli vibe command to run workflow
8
+ - c69b849: feat: add api web services (mcp & website)
9
+ - 42b8d78: feat: add cli `contractspec vibe` workflow to simplify usage
10
+ - fd38e85: feat: auto-fix contractspec issues
11
+
12
+ ### Patch Changes
13
+
14
+ - e7ded36: feat: improve stability (adding ts-morph)
15
+ - c231a8b: test: improve workspace stability
16
+ - Updated dependencies [e7ded36]
17
+ - Updated dependencies [caf8701]
18
+ - Updated dependencies [c69b849]
19
+ - Updated dependencies [c231a8b]
20
+ - Updated dependencies [42b8d78]
21
+ - Updated dependencies [fd38e85]
22
+ - @contractspec/module.learning-journey@1.47.0
23
+ - @contractspec/lib.contracts@1.47.0
24
+
3
25
  ## 1.46.2
4
26
 
5
27
  ### Patch Changes
package/dist/example.d.ts CHANGED
@@ -1,7 +1,7 @@
1
- import { ExampleSpec } from "@contractspec/lib.contracts";
1
+ import * as _contractspec_lib_contracts0 from "@contractspec/lib.contracts";
2
2
 
3
3
  //#region src/example.d.ts
4
- declare const example: ExampleSpec;
4
+ declare const example: _contractspec_lib_contracts0.ExampleSpec;
5
5
  //#endregion
6
6
  export { example as default };
7
7
  //# sourceMappingURL=example.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"example.d.ts","names":[],"sources":["../src/example.ts"],"sourcesContent":[],"mappings":";;;cAEM,SAAS"}
1
+ {"version":3,"file":"example.d.ts","names":[],"sources":["../src/example.ts"],"sourcesContent":[],"mappings":";;;cAEM,SA0BJ,4BAAA,CA1BW"}
package/dist/example.js CHANGED
@@ -1,5 +1,7 @@
1
+ import { defineExample } from "@contractspec/lib.contracts";
2
+
1
3
  //#region src/example.ts
2
- const example = {
4
+ const example = defineExample({
3
5
  meta: {
4
6
  key: "learning-journey-ambient-coach",
5
7
  version: "1.0.0",
@@ -32,7 +34,7 @@ const example = {
32
34
  },
33
35
  mcp: { enabled: true }
34
36
  }
35
- };
37
+ });
36
38
  var example_default = example;
37
39
 
38
40
  //#endregion
@@ -1 +1 @@
1
- {"version":3,"file":"example.js","names":["example: ExampleSpec"],"sources":["../src/example.ts"],"sourcesContent":["import type { ExampleSpec } from '@contractspec/lib.contracts';\n\nconst example: ExampleSpec = {\n meta: {\n key: 'learning-journey-ambient-coach',\n version: '1.0.0',\n title: 'Learning Journey — Ambient Coach',\n description:\n 'Ambient coaching pattern: lightweight nudges driven by context and recent progress.',\n kind: 'template',\n visibility: 'public',\n stability: 'experimental',\n owners: ['@platform.core'],\n tags: ['learning', 'coaching', 'ambient'],\n },\n docs: {\n rootDocId: 'docs.learning-journey.ambient-coach',\n },\n entrypoints: {\n packageName: '@contractspec/example.learning-journey-ambient-coach',\n docs: './docs',\n },\n surfaces: {\n templates: true,\n sandbox: { enabled: true, modes: ['playground', 'markdown'] },\n studio: { enabled: true, installable: true },\n mcp: { enabled: true },\n },\n};\n\nexport default example;\n"],"mappings":";AAEA,MAAMA,UAAuB;CAC3B,MAAM;EACJ,KAAK;EACL,SAAS;EACT,OAAO;EACP,aACE;EACF,MAAM;EACN,YAAY;EACZ,WAAW;EACX,QAAQ,CAAC,iBAAiB;EAC1B,MAAM;GAAC;GAAY;GAAY;GAAU;EAC1C;CACD,MAAM,EACJ,WAAW,uCACZ;CACD,aAAa;EACX,aAAa;EACb,MAAM;EACP;CACD,UAAU;EACR,WAAW;EACX,SAAS;GAAE,SAAS;GAAM,OAAO,CAAC,cAAc,WAAW;GAAE;EAC7D,QAAQ;GAAE,SAAS;GAAM,aAAa;GAAM;EAC5C,KAAK,EAAE,SAAS,MAAM;EACvB;CACF;AAED,sBAAe"}
1
+ {"version":3,"file":"example.js","names":[],"sources":["../src/example.ts"],"sourcesContent":["import { defineExample } from '@contractspec/lib.contracts';\n\nconst example = defineExample({\n meta: {\n key: 'learning-journey-ambient-coach',\n version: '1.0.0',\n title: 'Learning Journey — Ambient Coach',\n description:\n 'Ambient coaching pattern: lightweight nudges driven by context and recent progress.',\n kind: 'template',\n visibility: 'public',\n stability: 'experimental',\n owners: ['@platform.core'],\n tags: ['learning', 'coaching', 'ambient'],\n },\n docs: {\n rootDocId: 'docs.learning-journey.ambient-coach',\n },\n entrypoints: {\n packageName: '@contractspec/example.learning-journey-ambient-coach',\n docs: './docs',\n },\n surfaces: {\n templates: true,\n sandbox: { enabled: true, modes: ['playground', 'markdown'] },\n studio: { enabled: true, installable: true },\n mcp: { enabled: true },\n },\n});\n\nexport default example;\n"],"mappings":";;;AAEA,MAAM,UAAU,cAAc;CAC5B,MAAM;EACJ,KAAK;EACL,SAAS;EACT,OAAO;EACP,aACE;EACF,MAAM;EACN,YAAY;EACZ,WAAW;EACX,QAAQ,CAAC,iBAAiB;EAC1B,MAAM;GAAC;GAAY;GAAY;GAAU;EAC1C;CACD,MAAM,EACJ,WAAW,uCACZ;CACD,aAAa;EACX,aAAa;EACb,MAAM;EACP;CACD,UAAU;EACR,WAAW;EACX,SAAS;GAAE,SAAS;GAAM,OAAO,CAAC,cAAc,WAAW;GAAE;EAC7D,QAAQ;GAAE,SAAS;GAAM,aAAa;GAAM;EAC5C,KAAK,EAAE,SAAS,MAAM;EACvB;CACF,CAAC;AAEF,sBAAe"}
package/dist/track.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"track.js","names":["moneyAmbientCoachTrack: LearningJourneyTrackSpec","colivingAmbientCoachTrack: LearningJourneyTrackSpec","ambientCoachTracks: LearningJourneyTrackSpec[]"],"sources":["../src/track.ts"],"sourcesContent":["import type { LearningJourneyTrackSpec } from '@contractspec/module.learning-journey/track-spec';\n\nconst makeTipStep = (\n id: string,\n tipId: string,\n description: string\n): LearningJourneyTrackSpec['steps'][number] => ({\n id,\n title: `Resolve tip: ${tipId}`,\n description,\n completion: {\n kind: 'event',\n eventName: 'coach.tip.follow_up_action_taken',\n payloadFilter: { tipId },\n },\n xpReward: 20,\n metadata: { tipId },\n});\n\nexport const moneyAmbientCoachTrack: LearningJourneyTrackSpec = {\n id: 'money_ambient_coach',\n name: 'Ambient Coach — Money',\n description:\n 'Subtle coaching for money patterns (cash buffer, goals, saving rhythm).',\n targetUserSegment: 'money_user',\n totalXp: 60,\n steps: [\n makeTipStep(\n 'cash_buffer_too_high',\n 'cash_buffer_too_high',\n 'Suggest sweeping excess cash into goals.'\n ),\n makeTipStep(\n 'no_savings_goal',\n 'no_savings_goal',\n 'Prompt setting a first savings goal.'\n ),\n makeTipStep(\n 'irregular_savings',\n 'irregular_savings',\n 'Recommend recurring saves after irregular deposits.'\n ),\n ],\n};\n\nexport const colivingAmbientCoachTrack: LearningJourneyTrackSpec = {\n id: 'coliving_ambient_coach',\n name: 'Ambient Coach — Coliving',\n description: 'Contextual tips for healthy coliving habits.',\n targetUserSegment: 'coliving',\n totalXp: 60,\n steps: [\n makeTipStep(\n 'noise_late_evening',\n 'noise_late_evening',\n 'Suggest updating quiet hours to reduce evening noise.'\n ),\n makeTipStep(\n 'guest_frequency_high',\n 'guest_frequency_high',\n 'Set guest frequency expectations for the house.'\n ),\n makeTipStep(\n 'shared_space_conflicts',\n 'shared_space_conflicts',\n 'Offer a shared-space checklist to reduce conflicts.'\n ),\n ],\n};\n\nexport const ambientCoachTracks: LearningJourneyTrackSpec[] = [\n moneyAmbientCoachTrack,\n colivingAmbientCoachTrack,\n];\n"],"mappings":";AAEA,MAAM,eACJ,IACA,OACA,iBAC+C;CAC/C;CACA,OAAO,gBAAgB;CACvB;CACA,YAAY;EACV,MAAM;EACN,WAAW;EACX,eAAe,EAAE,OAAO;EACzB;CACD,UAAU;CACV,UAAU,EAAE,OAAO;CACpB;AAED,MAAaA,yBAAmD;CAC9D,IAAI;CACJ,MAAM;CACN,aACE;CACF,mBAAmB;CACnB,SAAS;CACT,OAAO;EACL,YACE,wBACA,wBACA,2CACD;EACD,YACE,mBACA,mBACA,uCACD;EACD,YACE,qBACA,qBACA,sDACD;EACF;CACF;AAED,MAAaC,4BAAsD;CACjE,IAAI;CACJ,MAAM;CACN,aAAa;CACb,mBAAmB;CACnB,SAAS;CACT,OAAO;EACL,YACE,sBACA,sBACA,wDACD;EACD,YACE,wBACA,wBACA,kDACD;EACD,YACE,0BACA,0BACA,sDACD;EACF;CACF;AAED,MAAaC,qBAAiD,CAC5D,wBACA,0BACD"}
1
+ {"version":3,"file":"track.js","names":[],"sources":["../src/track.ts"],"sourcesContent":["import type { LearningJourneyTrackSpec } from '@contractspec/module.learning-journey/track-spec';\n\nconst makeTipStep = (\n id: string,\n tipId: string,\n description: string\n): LearningJourneyTrackSpec['steps'][number] => ({\n id,\n title: `Resolve tip: ${tipId}`,\n description,\n completion: {\n kind: 'event',\n eventName: 'coach.tip.follow_up_action_taken',\n payloadFilter: { tipId },\n },\n xpReward: 20,\n metadata: { tipId },\n});\n\nexport const moneyAmbientCoachTrack: LearningJourneyTrackSpec = {\n id: 'money_ambient_coach',\n name: 'Ambient Coach — Money',\n description:\n 'Subtle coaching for money patterns (cash buffer, goals, saving rhythm).',\n targetUserSegment: 'money_user',\n totalXp: 60,\n steps: [\n makeTipStep(\n 'cash_buffer_too_high',\n 'cash_buffer_too_high',\n 'Suggest sweeping excess cash into goals.'\n ),\n makeTipStep(\n 'no_savings_goal',\n 'no_savings_goal',\n 'Prompt setting a first savings goal.'\n ),\n makeTipStep(\n 'irregular_savings',\n 'irregular_savings',\n 'Recommend recurring saves after irregular deposits.'\n ),\n ],\n};\n\nexport const colivingAmbientCoachTrack: LearningJourneyTrackSpec = {\n id: 'coliving_ambient_coach',\n name: 'Ambient Coach — Coliving',\n description: 'Contextual tips for healthy coliving habits.',\n targetUserSegment: 'coliving',\n totalXp: 60,\n steps: [\n makeTipStep(\n 'noise_late_evening',\n 'noise_late_evening',\n 'Suggest updating quiet hours to reduce evening noise.'\n ),\n makeTipStep(\n 'guest_frequency_high',\n 'guest_frequency_high',\n 'Set guest frequency expectations for the house.'\n ),\n makeTipStep(\n 'shared_space_conflicts',\n 'shared_space_conflicts',\n 'Offer a shared-space checklist to reduce conflicts.'\n ),\n ],\n};\n\nexport const ambientCoachTracks: LearningJourneyTrackSpec[] = [\n moneyAmbientCoachTrack,\n colivingAmbientCoachTrack,\n];\n"],"mappings":";AAEA,MAAM,eACJ,IACA,OACA,iBAC+C;CAC/C;CACA,OAAO,gBAAgB;CACvB;CACA,YAAY;EACV,MAAM;EACN,WAAW;EACX,eAAe,EAAE,OAAO;EACzB;CACD,UAAU;CACV,UAAU,EAAE,OAAO;CACpB;AAED,MAAa,yBAAmD;CAC9D,IAAI;CACJ,MAAM;CACN,aACE;CACF,mBAAmB;CACnB,SAAS;CACT,OAAO;EACL,YACE,wBACA,wBACA,2CACD;EACD,YACE,mBACA,mBACA,uCACD;EACD,YACE,qBACA,qBACA,sDACD;EACF;CACF;AAED,MAAa,4BAAsD;CACjE,IAAI;CACJ,MAAM;CACN,aAAa;CACb,mBAAmB;CACnB,SAAS;CACT,OAAO;EACL,YACE,sBACA,sBACA,wDACD;EACD,YACE,wBACA,wBACA,kDACD;EACD,YACE,0BACA,0BACA,sDACD;EACF;CACF;AAED,MAAa,qBAAiD,CAC5D,wBACA,0BACD"}
package/package.json CHANGED
@@ -1,9 +1,8 @@
1
1
  {
2
2
  "name": "@contractspec/example.learning-journey-ambient-coach",
3
- "version": "1.46.2",
3
+ "version": "1.47.0",
4
4
  "description": "Ambient coach learning journey example with contextual tips and follow-up actions.",
5
5
  "type": "module",
6
- "main": "./dist/index.js",
7
6
  "types": "./dist/index.d.ts",
8
7
  "exports": {
9
8
  ".": "./dist/index.js",
@@ -27,16 +26,15 @@
27
26
  "test": "bun test"
28
27
  },
29
28
  "dependencies": {
30
- "@contractspec/module.learning-journey": "1.46.2",
31
- "@contractspec/lib.contracts": "1.46.2"
29
+ "@contractspec/module.learning-journey": "1.47.0",
30
+ "@contractspec/lib.contracts": "1.47.0"
32
31
  },
33
32
  "devDependencies": {
34
- "@contractspec/tool.tsdown": "1.46.2",
35
- "@contractspec/tool.typescript": "1.46.2",
36
- "tsdown": "^0.18.3",
33
+ "@contractspec/tool.tsdown": "1.47.0",
34
+ "@contractspec/tool.typescript": "1.47.0",
35
+ "tsdown": "^0.19.0",
37
36
  "typescript": "^5.9.3"
38
37
  },
39
- "module": "./dist/index.js",
40
38
  "publishConfig": {
41
39
  "exports": {
42
40
  ".": "./dist/index.js",
package/src/example.ts CHANGED
@@ -1,6 +1,6 @@
1
- import type { ExampleSpec } from '@contractspec/lib.contracts';
1
+ import { defineExample } from '@contractspec/lib.contracts';
2
2
 
3
- const example: ExampleSpec = {
3
+ const example = defineExample({
4
4
  meta: {
5
5
  key: 'learning-journey-ambient-coach',
6
6
  version: '1.0.0',
@@ -26,6 +26,6 @@ const example: ExampleSpec = {
26
26
  studio: { enabled: true, installable: true },
27
27
  mcp: { enabled: true },
28
28
  },
29
- };
29
+ });
30
30
 
31
31
  export default example;