rhachet-roles-bhrain 0.2.0 → 0.3.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.
Files changed (130) hide show
  1. package/dist/.test/getContextOpenAI.js +1 -1
  2. package/dist/.test/getContextOpenAI.js.map +1 -1
  3. package/dist/domain.operations/review/compileReviewPrompt.d.ts +22 -0
  4. package/dist/domain.operations/review/compileReviewPrompt.js +95 -0
  5. package/dist/domain.operations/review/compileReviewPrompt.js.map +1 -0
  6. package/dist/domain.operations/review/enumFilesFromDiffs.d.ts +8 -0
  7. package/dist/domain.operations/review/enumFilesFromDiffs.js +74 -0
  8. package/dist/domain.operations/review/enumFilesFromDiffs.js.map +1 -0
  9. package/dist/domain.operations/review/enumFilesFromGlob.d.ts +8 -0
  10. package/dist/domain.operations/review/enumFilesFromGlob.js +31 -0
  11. package/dist/domain.operations/review/enumFilesFromGlob.js.map +1 -0
  12. package/dist/domain.operations/review/estimateTokenCount.d.ts +9 -0
  13. package/dist/domain.operations/review/estimateTokenCount.js +20 -0
  14. package/dist/domain.operations/review/estimateTokenCount.js.map +1 -0
  15. package/dist/domain.operations/review/formatReviewOutput.d.ts +14 -0
  16. package/dist/domain.operations/review/formatReviewOutput.js +42 -0
  17. package/dist/domain.operations/review/formatReviewOutput.js.map +1 -0
  18. package/dist/domain.operations/review/genTokenBreakdownMarkdown.d.ts +19 -0
  19. package/dist/domain.operations/review/genTokenBreakdownMarkdown.js +110 -0
  20. package/dist/domain.operations/review/genTokenBreakdownMarkdown.js.map +1 -0
  21. package/dist/domain.operations/review/genTokenBreakdownReport.d.ts +24 -0
  22. package/dist/domain.operations/review/genTokenBreakdownReport.js +64 -0
  23. package/dist/domain.operations/review/genTokenBreakdownReport.js.map +1 -0
  24. package/dist/domain.operations/review/invokeClaudeCode.d.ts +22 -0
  25. package/dist/domain.operations/review/invokeClaudeCode.js +92 -0
  26. package/dist/domain.operations/review/invokeClaudeCode.js.map +1 -0
  27. package/dist/domain.operations/review/writeInputArtifacts.d.ts +27 -0
  28. package/dist/domain.operations/review/writeInputArtifacts.js +50 -0
  29. package/dist/domain.operations/review/writeInputArtifacts.js.map +1 -0
  30. package/dist/domain.operations/review/writeOutputArtifacts.d.ts +12 -0
  31. package/dist/domain.operations/review/writeOutputArtifacts.js +46 -0
  32. package/dist/domain.operations/review/writeOutputArtifacts.js.map +1 -0
  33. package/dist/roles/getRoleRegistry.js +2 -1
  34. package/dist/roles/getRoleRegistry.js.map +1 -1
  35. package/dist/roles/getRoleRegistry.readme.js +6 -0
  36. package/dist/roles/getRoleRegistry.readme.js.map +1 -1
  37. package/dist/roles/reviewer/briefs/review.tactics.md +60 -0
  38. package/dist/roles/reviewer/getReviewerRole.d.ts +6 -0
  39. package/dist/roles/reviewer/getReviewerRole.js +80 -0
  40. package/dist/roles/reviewer/getReviewerRole.js.map +1 -0
  41. package/dist/roles/reviewer/skills/review/review.d.ts +57 -0
  42. package/dist/roles/reviewer/skills/review/review.js +445 -0
  43. package/dist/roles/reviewer/skills/review/review.js.map +1 -0
  44. package/dist/roles/reviewer/skills/review/review.sh +21 -0
  45. package/dist/roles/reviewer/skills/review/review.ts +575 -0
  46. package/dist/roles/thinker/getThinkerRole.js +1 -1
  47. package/dist/roles/thinker/getThinkerRole.js.map +1 -1
  48. package/dist/roles/thinker/skills/brief.articulate/.demo/article.vision.v2025_08_19..i1.via_chatgpt.md +47 -0
  49. package/dist/roles/thinker/skills/brief.articulate/.demo/article.vision.v2025_08_19.i2.via_rhachet.md +60 -0
  50. package/dist/roles/thinker/skills/brief.articulate/.demo/diverge.v2025_08_17.i1.md +62 -0
  51. package/dist/roles/thinker/skills/brief.articulate/.demo/diverge.v2025_08_17.i1.with_feedback.md +89 -0
  52. package/dist/roles/thinker/skills/brief.articulate/.demo/diverge.v2025_08_17.i2.md +47 -0
  53. package/dist/roles/thinker/skills/brief.articulate/.demo/joke.v2025_08_15.i1.md +44 -0
  54. package/dist/roles/thinker/skills/brief.articulate/.demo/joke.v2025_08_15.i2.md +63 -0
  55. package/dist/roles/thinker/skills/brief.articulate/.demo/joke.v2025_08_15.i3.md +51 -0
  56. package/dist/roles/thinker/skills/brief.articulate/.demo/user-journey.v2025_08_17.i1.md +62 -0
  57. package/dist/roles/thinker/skills/brief.articulate/.demo/user-journey.v2025_08_17.i2.md +49 -0
  58. package/dist/roles/thinker/skills/brief.articulate/.readme.md +0 -0
  59. package/dist/roles/thinker/skills/brief.articulate/stepArticulate.skill.js +1 -1
  60. package/dist/roles/thinker/skills/brief.articulate/stepArticulate.skill.js.map +1 -1
  61. package/dist/roles/thinker/skills/brief.articulate/stepArticulate.skill.ts +168 -0
  62. package/dist/roles/thinker/skills/brief.articulate/stepArticulate.ts +157 -0
  63. package/dist/roles/thinker/skills/brief.catalogize/.demo/joke.types.v2025_08_28.i1.md +93 -0
  64. package/dist/roles/thinker/skills/brief.catalogize/.demo/joke.types.v2025_08_28.i2.md +84 -0
  65. package/dist/roles/thinker/skills/brief.catalogize/.demo/joke.types.v2025_09_28.i1.no_focus_context.md +8 -0
  66. package/dist/roles/thinker/skills/brief.catalogize/.demo/joke.types.v2025_09_28.i2.md +54 -0
  67. package/dist/roles/thinker/skills/brief.catalogize/.demo/persona.usecases.v2025_08_28.i1.md +62 -0
  68. package/dist/roles/thinker/skills/brief.catalogize/.demo/persona.usecases.v2025_08_28.i2.md +64 -0
  69. package/dist/roles/thinker/skills/brief.catalogize/.readme.md +5 -0
  70. package/dist/roles/thinker/skills/brief.catalogize/stepCatalogize.skill.js +1 -1
  71. package/dist/roles/thinker/skills/brief.catalogize/stepCatalogize.skill.js.map +1 -1
  72. package/dist/roles/thinker/skills/brief.catalogize/stepCatalogize.skill.ts +173 -0
  73. package/dist/roles/thinker/skills/brief.catalogize/stepCatalogize.ts +132 -0
  74. package/dist/roles/thinker/skills/brief.demonstrate/.demo/user.journey.roadtrip.input.example.i4.md +3 -0
  75. package/dist/roles/thinker/skills/brief.demonstrate/.demo/user.journey.roadtrip.input.example.i5.md +3 -0
  76. package/dist/roles/thinker/skills/brief.demonstrate/.demo/user.journey.roadtrip.input.example.i6.md +3 -0
  77. package/dist/roles/thinker/skills/brief.demonstrate/.demo/user.journey.roadtrip.input.example.md +3 -0
  78. package/dist/roles/thinker/skills/brief.demonstrate/.demo/user.journey.roadtrip.v2025_08_27.i1.md +52 -0
  79. package/dist/roles/thinker/skills/brief.demonstrate/.demo/user.journey.roadtrip.v2025_08_27.i2.md +51 -0
  80. package/dist/roles/thinker/skills/brief.demonstrate/.demo/user.journey.roadtrip.v2025_08_27.i3.md +47 -0
  81. package/dist/roles/thinker/skills/brief.demonstrate/.demo/user.journey.roadtrip.v2025_08_27.i4.md +62 -0
  82. package/dist/roles/thinker/skills/brief.demonstrate/.demo/user.journey.roadtrip.v2025_08_27.i5.md +47 -0
  83. package/dist/roles/thinker/skills/brief.demonstrate/.demo/user.journey.roadtrip.v2025_08_27.i6.md +53 -0
  84. package/dist/roles/thinker/skills/brief.demonstrate/.readme +3 -0
  85. package/dist/roles/thinker/skills/brief.demonstrate/stepDemonstrate.skill.js +1 -1
  86. package/dist/roles/thinker/skills/brief.demonstrate/stepDemonstrate.skill.js.map +1 -1
  87. package/dist/roles/thinker/skills/brief.demonstrate/stepDemonstrate.skill.ts +190 -0
  88. package/dist/roles/thinker/skills/brief.demonstrate/stepDemonstrate.ts +164 -0
  89. package/dist/roles/thinker/skills/khue.cluster/.demo/user.journeys.input1.cluster.v2025_08_17.i1.md +72 -0
  90. package/dist/roles/thinker/skills/khue.cluster/.demo/user.journeys.input1.cluster.v2025_08_17.i2.md +53 -0
  91. package/dist/roles/thinker/skills/khue.cluster/.demo/user.journeys.input1.cluster.v2025_08_17.i3.which_objectives.md +58 -0
  92. package/dist/roles/thinker/skills/khue.cluster/.demo/user.journeys.input1.cluster.v2025_08_17.i5.which_personas.md +64 -0
  93. package/dist/roles/thinker/skills/khue.cluster/.demo/user.journeys.input2.cluster.v2025_08_17.i1.md +67 -0
  94. package/dist/roles/thinker/skills/khue.cluster/.demo/user.journeys.input2.cluster.v2025_08_17.i2.md +49 -0
  95. package/dist/roles/thinker/skills/khue.cluster/.demo/user.journeys.input2.cluster.v2025_08_17.i3.md +59 -0
  96. package/dist/roles/thinker/skills/khue.cluster/.readme.md +0 -0
  97. package/dist/roles/thinker/skills/khue.cluster/stepCluster.skill.js +1 -1
  98. package/dist/roles/thinker/skills/khue.cluster/stepCluster.skill.js.map +1 -1
  99. package/dist/roles/thinker/skills/khue.cluster/stepCluster.skill.ts +174 -0
  100. package/dist/roles/thinker/skills/khue.cluster/stepCluster.ts +150 -0
  101. package/dist/roles/thinker/skills/khue.decompose/.readme.md +9 -0
  102. package/dist/roles/thinker/skills/khue.diverge/.demo/joke.examples.v2025_08_17.i2.md +23 -0
  103. package/dist/roles/thinker/skills/khue.diverge/.demo/joke.examples.v2025_08_17.i3.md +23 -0
  104. package/dist/roles/thinker/skills/khue.diverge/.demo/joke.varieties.v2025_08_17.i1.md +23 -0
  105. package/dist/roles/thinker/skills/khue.diverge/.demo/userjourney.examples.v2025_08_17.i1.md +9 -0
  106. package/dist/roles/thinker/skills/khue.diverge/.demo/userjourney.examples.v2025_08_17.i2.md +9 -0
  107. package/dist/roles/thinker/skills/khue.diverge/.demo/userjourney.examples.v2025_08_17.i3.md +23 -0
  108. package/dist/roles/thinker/skills/khue.diverge/.demo/userjourney.examples.v2025_08_17.i4.folksy.md +9 -0
  109. package/dist/roles/thinker/skills/khue.diverge/.demo/userjourney.examples.v2025_08_17.i5.folksy.md +23 -0
  110. package/dist/roles/thinker/skills/khue.diverge/.readme.md +0 -0
  111. package/dist/roles/thinker/skills/khue.diverge/stepDiverge.skill.js +1 -1
  112. package/dist/roles/thinker/skills/khue.diverge/stepDiverge.skill.js.map +1 -1
  113. package/dist/roles/thinker/skills/khue.diverge/stepDiverge.skill.ts +149 -0
  114. package/dist/roles/thinker/skills/khue.diverge/stepDiverge.ts +151 -0
  115. package/dist/roles/thinker/skills/khue.encompose/.readme.md +7 -0
  116. package/dist/roles/thinker/skills/khue.instantiate/.readme.md +14 -0
  117. package/dist/roles/thinker/skills/khue.instantiate/stepInstantiate.skill.js +1 -1
  118. package/dist/roles/thinker/skills/khue.instantiate/stepInstantiate.skill.js.map +1 -1
  119. package/dist/roles/thinker/skills/khue.instantiate/stepInstantiate.skill.ts +190 -0
  120. package/dist/roles/thinker/skills/khue.instantiate/stepInstantiate.ts +132 -0
  121. package/dist/roles/thinker/skills/khue.triage/.demo/laughs.v2025_08_18.i1.md +29 -0
  122. package/dist/roles/thinker/skills/khue.triage/.demo/user.journeys.v2025_08_17.i1.md +86 -0
  123. package/dist/roles/thinker/skills/khue.triage/.demo/user.journeys.v2025_08_17.i2.md +68 -0
  124. package/dist/roles/thinker/skills/khue.triage/.readme.md +0 -0
  125. package/dist/roles/thinker/skills/khue.triage/stepTriage.skill.js +1 -1
  126. package/dist/roles/thinker/skills/khue.triage/stepTriage.skill.js.map +1 -1
  127. package/dist/roles/thinker/skills/khue.triage/stepTriage.skill.ts +174 -0
  128. package/dist/roles/thinker/skills/khue.triage/stepTriage.ts +153 -0
  129. package/package.json +7 -6
  130. package/readme.md +55 -0
@@ -0,0 +1,62 @@
1
+ # 🧩 .brief: `<diverge>`
2
+
3
+ ## .what
4
+
5
+ `<diverge>` is a semantic motion primitive designed to explore and identify the maximum variance within a given concept space. It aims to uncover a diverse spectrum of instances or expressions based on the core concept, pushing the boundaries to reveal the widest possible range of variations.
6
+
7
+ ---
8
+
9
+ ## 🎯 purpose
10
+
11
+ - uncover the broadest set of variations or instances from a starting concept
12
+ - facilitate the discovery of novel, unexpected, or edge-case examples
13
+ - challenge assumptions by expanding the visible scope of a concept
14
+
15
+ ---
16
+
17
+ ## ⚙️ process
18
+
19
+ 1. **anchor to the core concept**
20
+ - define the central idea or category you are diversifying
21
+ - ensure a clear understanding of its basic boundaries
22
+
23
+ 2. **explore variance axes**
24
+ - identify possible axes of variation (e.g., color, shape, function)
25
+ - consider both obvious and non-obvious differentiation criteria
26
+
27
+ 3. **generate variations**
28
+ - systematically list distinct and contrasting examples within the concept
29
+ - prioritize breadth over precision at this stage
30
+
31
+ 4. **evaluate diversity**
32
+ - assess whether the variations span the intended breadth and highlight differences
33
+ - refine any clustering or flattening of variance points that reduce visibility
34
+
35
+ ---
36
+
37
+ ## 🌿 example: `<diverge>` applied to `colors`
38
+
39
+ Identify diverse colors exemplifying maximum variance:
40
+ - red
41
+ - green
42
+ - tangerine
43
+ - scarlet
44
+ - ivory
45
+
46
+ Each selected color exemplifies unique attributes within the color spectrum, showcasing distinct hues, tints, and tones. This variance reveals the extensive diversity possible within a seemingly simple category.
47
+
48
+ ---
49
+
50
+ ## 📐 when to use
51
+
52
+ - when seeking inspiration or brainstorming new possibilities
53
+ - when needing to identify extremes or edge cases of a concept
54
+ - when preparing for strategic decisions requiring a panoramic understanding of option space
55
+
56
+ ---
57
+
58
+ ## 💡 notes
59
+
60
+ - `<diverge>` differs from clustering or focusing as it intentionally avoids centralization or narrowing
61
+ - it complements processes that require a broad exploration phase prior to narrowing
62
+ - can be paired with other primitives like `<contrast>` or `<compare>` for deeper analysis of the generated variations
@@ -0,0 +1,89 @@
1
+ # 🧩 .brief: `<diverge>`
2
+
3
+ ## .what
4
+
5
+ `<diverge>` is a semantic motion primitive designed to explore and identify the maximum variance within a given concept space. It aims to uncover a diverse spectrum of instances or expressions based on the core concept, pushing the boundaries to reveal the widest possible range of variations.
6
+
7
+ ---
8
+
9
+ ## 🎯 purpose
10
+
11
+ - uncover the broadest set of variations or instances from a starting concept
12
+ - facilitate the discovery of novel, unexpected, or edge-case examples
13
+ - challenge assumptions by expanding the visible scope of a concept
14
+
15
+ ---
16
+
17
+ ## ⚙️ process
18
+
19
+ 1. **anchor to the core concept**
20
+ - define the central idea or category you are diversifying
21
+ - ensure a clear understanding of its basic boundaries
22
+
23
+ 2. **explore variance axes**
24
+ - identify possible axes of variation (e.g., color, shape, function)
25
+ - consider both obvious and non-obvious differentiation criteria
26
+
27
+ 3. **generate variations**
28
+ - systematically list distinct and contrasting examples within the concept
29
+ - prioritize breadth over precision at this stage
30
+
31
+ 4. **evaluate diversity**
32
+ - assess whether the variations span the intended breadth and highlight differences
33
+ - refine any clustering or flattening of variance points that reduce visibility
34
+
35
+ ---
36
+
37
+ ## 🌿 examples
38
+
39
+ ### Application to `colors`
40
+ Identify diverse colors exemplifying maximum variance:
41
+ - red
42
+ - green
43
+ - tangerine
44
+ - scarlet
45
+ - ivory
46
+ - cobalt
47
+ - magenta
48
+
49
+ Each selected color exemplifies unique attributes within the color spectrum, showcasing distinct hues, tints, and tones. This variance reveals the extensive diversity possible within a seemingly simple category.
50
+
51
+ ### Application to `modes of transport`
52
+ Identify a wide array of transportation modes:
53
+ - bicycle
54
+ - skateboard
55
+ - electric car
56
+ - sailboat
57
+ - helicopter
58
+ - hovercraft
59
+ - high-speed train
60
+
61
+ These examples represent different speeds, energy sources, and terrains, illustrating the diverse possibilities in transportation.
62
+
63
+ ### Application to `cuisines`
64
+ Explore the vast diversity in culinary traditions:
65
+ - Italian
66
+ - Japanese
67
+ - Mexican
68
+ - Ethiopian
69
+ - Indian
70
+ - Thai
71
+ - Moroccan
72
+
73
+ Each cuisine brings unique flavors, ingredients, and cultural significance, enriching the global culinary palette.
74
+
75
+ ---
76
+
77
+ ## 📐 when to use
78
+
79
+ - when seeking inspiration or brainstorming new possibilities
80
+ - when needing to identify extremes or edge cases of a concept
81
+ - when preparing for strategic decisions requiring a panoramic understanding of option space
82
+
83
+ ---
84
+
85
+ ## 💡 notes
86
+
87
+ - `<diverge>` differs from clustering or focusing as it intentionally avoids centralization or narrowing
88
+ - it complements processes that require a broad exploration phase prior to narrowing
89
+ - can be paired with other primitives like `<contrast>` or `<compare>` for deeper analysis of the generated variations
@@ -0,0 +1,47 @@
1
+ # 🧩 .brief: `<diverge>`
2
+
3
+ ## .what
4
+ **`<diverge>`** is a semantic motion primitive focused on exploring the breadth of a given concept by identifying its most varied instances. It operates by systematically uncovering diverse elements or variations within the same conceptual category, highlighting the range of possibilities that exist.
5
+
6
+ ---
7
+
8
+ ## 🎯 purpose
9
+ - to map out and understand the **full spectrum of a concept**
10
+ - to enrich the concept by identifying and articulating its **maximum variance instances**
11
+ - to facilitate creative thinking and ideation by exposing **all possible angles**
12
+
13
+ ---
14
+
15
+ ## 🗺 method
16
+ 1. **identify the core concept**
17
+ - determine the central idea or category you wish to explore
18
+ - e.g., `colors`, `solutions`, `approaches`
19
+
20
+ 2. **expand into variants**
21
+ - list out as many distinct and varied instances as possible
22
+ - focus on range and contrast, covering different attributes, usages, or contexts
23
+
24
+ 3. **categorize variance**
25
+ - consider organizing instances by subcategories or dimensions of variance
26
+ - e.g., for colors: hue, tone, saturation
27
+
28
+ 4. **integrate divergent discovery**
29
+ - apply findings to broaden perspectives or inform decisions in related activities
30
+ - e.g., using the diverse color palette to design inclusive artwork
31
+
32
+ ---
33
+
34
+ ## 🔍 examples
35
+ - `<diverge>[colors]` results in a range:
36
+ - `red`, `green`, `tangerine`, `scarlet`, `ivory`
37
+ - `<diverge>[cooking methods]` could produce:
38
+ - `baking`, `grilling`, `steaming`, `frying`, `poaching`
39
+ - `<diverge>[musical genres]` may uncover:
40
+ - `jazz`, `classical`, `hip-hop`, `electronic`, `folk`
41
+
42
+ ---
43
+
44
+ ## 💡 notes
45
+ - `<diverge>` is about **breadth over depth**, emphasizing range rather than detail
46
+ - useful in ideation sessions, diversification strategies, and exploratory research
47
+ - pairs well with `<converge>` to then refine or select from the expanded set of instances
@@ -0,0 +1,44 @@
1
+ # 🧩 .brief: `joke`
2
+
3
+ ## .what
4
+ a **joke** is a form of communication designed to elicit laughter or amusement. it often involves a play on words, a twist in meaning, or a surprising punchline that challenges expectations. jokes can be spoken, written, or performed, and are a universal element of humor across cultures.
5
+
6
+ ## .etymology
7
+ the word "joke" originates from the latin word "jocus," meaning jest or joke. its use in english can be traced back to the 17th century, initially indicating a jest or something done to amuse.
8
+
9
+ ## .examples
10
+
11
+ - **verbal joke**: "why don't scientists trust atoms? because they make up everything."
12
+ - **knock-knock joke**:
13
+ - "knock, knock."
14
+ - "who's there?"
15
+ - "lettuce."
16
+ - "lettuce who?"
17
+ - "lettuce in, it's cold out here!"
18
+ - **physical comedy**: charlie chaplin's slapstick routines, where physical movements and exaggerated actions lead to humorous outcomes.
19
+
20
+ ## .why
21
+ jokes serve as a social tool for bonding, relieving tension, and expressing creative thinking. they can highlight shared knowledge or cultural references, reinforcing group identity.
22
+
23
+ ## .how
24
+ a joke typically comprises a setup and a punchline. the **setup** establishes context, creating expectations. the **punchline** delivers an unexpected twist or resolution, inducing laughter by subverting those expectations.
25
+
26
+ ## .where
27
+ jokes are prevalent in various settings, from casual conversations to professional comedy acts. they feature in media, classrooms, workplaces, and social gatherings, adapting to context and audience.
28
+
29
+ ## .when
30
+ jokes are relevant at times where light-heartedness or relief from tension is desired, or when making a point more engaging and memorable. certain contexts, such as funerals or serious meetings, may render jokes inappropriate.
31
+
32
+ ## .who
33
+ anyone can tell a joke, but effective delivery often requires a sense of timing, audience awareness, and creativity. professional comedians use jokes as their craft, while ordinary people use them to enliven interactions.
34
+
35
+ ## .attributes
36
+ - **brevity:** efficient delivery is key, often with minimal words.
37
+ - **timing:** the effectiveness of a joke highly depends on when it's told.
38
+ - **surprise:** jokes rely on unexpected conclusions or twists.
39
+ - **universality:** though culturally nuanced, the basic structure of jokes is global.
40
+
41
+ ## .relations
42
+ - **anecdote:** a short, amusing story often containing elements of a joke.
43
+ - **satire:** uses humor, irony, or exaggeration, often to criticize.
44
+ - **riddle:** poses a question requiring creative thought for a humorous or clever answer.
@@ -0,0 +1,63 @@
1
+ # 🧩 .brief: `joke`
2
+
3
+ ## .what
4
+ A **joke** is a form of communication intended to provoke laughter or amusement. This typically involves a comedic twist, element of surprise, or play on words. Jokes are a ubiquitous part of human interaction and transcend cultural barriers, often shedding light on social norms, shared experiences, or human folly.
5
+
6
+ ---
7
+
8
+ ## 🔍 etymology
9
+ The term **"joke"** derives from the Latin word *"jocus"*, meaning jest or play. The use of "joke" in the comedic sense became prevalent in the English language in the 17th century, reflecting the evolution of humor as a structured form of entertainment and expression.
10
+
11
+ ---
12
+
13
+ ## 🎯 purpose
14
+ - to entertain and amuse
15
+ - to express wit and creativity
16
+ - to build social connections and foster group cohesion
17
+ - to provide relief from tension or stress
18
+
19
+ ---
20
+
21
+ ## 🔧 how it works
22
+ Jokes function through various comedic mechanisms, including:
23
+ - **Incongruity**: presenting an unexpected or absurd outcome
24
+ - **Exaggeration**: amplifying truth for humorous effect
25
+ - **Wordplay**: utilizing homophones, puns, and multiple meanings
26
+ - **Timing**: expertly pacing the punchline for maximum effect
27
+
28
+ ---
29
+
30
+ ## 🧩 examples
31
+ 1. **Classic**: "Why did the chicken cross the road? To get to the other side."
32
+ - **Mechanism**: Incongruity; subverts expectation of a complex answer with simplicity.
33
+
34
+ 2. **Wordplay**: "I told my wife she was drawing her eyebrows too high. She looked surprised."
35
+ - **Mechanism**: Play on the dual meaning of "surprised."
36
+
37
+ 3. **One-liner**: "I have a split personality," said Tom, being Frank.
38
+ - **Mechanism**: Pun; relies on the humor of name wordplay and idiomatic phrases.
39
+
40
+ ---
41
+
42
+ ## 🎨 cultural references
43
+ Jokes can take many forms across cultures, from stand-up routines and comedic skits to riddles and visual gags. They often reflect societal norms and values, serving as a mirror to the intricacies of human life.
44
+
45
+ ---
46
+
47
+ ## 🎭 real-world implications
48
+ Beyond humor, jokes play a role in:
49
+ - **Psychological resilience**: offering coping mechanisms during challenging times
50
+ - **Cultural exchange**: bridging gaps between languages and traditions
51
+ - **Social critique**: providing commentary on political or societal issues
52
+
53
+ ---
54
+
55
+ ## 📘 related terms
56
+ - **Pun**: A joke exploiting different meanings of a word or similar words
57
+ - **Satire**: Humor, irony, or ridicule used to criticize or mock
58
+ - **Gag**: A specific joke or comedic sequence
59
+
60
+ ---
61
+
62
+ ## 🧠 insights
63
+ Jokes elucidate the human need to find lightness in life. While they serve as simple entertainment, their implications extend into psychological, social, and cultural realms, demonstrating their significant and multifaceted value.
@@ -0,0 +1,51 @@
1
+ # 🧩 .brief: `joke`
2
+
3
+ ## .what
4
+ a **joke** is a form of expression, often verbal, intended to provoke laughter or amusement. it typically involves a setup and a punchline or twist that creates humor through a play on words, situations, or expectations.
5
+
6
+ ---
7
+
8
+ ## .etymology
9
+ the word "joke" originates from the latin "jocus," meaning jest or play. it entered middle english through old french as "jouer," evolving into the modern term "joke."
10
+
11
+ ---
12
+
13
+ ## .definition
14
+ - a **joke** is a narrative or phrase crafted to elicit laughter by exploiting incongruities in language, logic, or irony.
15
+ - jokes can be cultural artifacts, reflecting societal norms, insights, and taboos.
16
+
17
+ ---
18
+
19
+ ## .types
20
+ 1. **knock-knock jokes**: involve a call-and-response format, often playful or pun-based.
21
+ 2. **one-liners**: concise, single-sentence jokes focusing on wordplay or surprise.
22
+ 3. **anecdotal jokes**: short narratives ending in a humorous twist.
23
+ 4. **practical jokes**: physical or situational gags designed to surprise or irritate for comedic effect.
24
+
25
+ ---
26
+
27
+ ## .examples
28
+ - **knock-knock joke**: "knock, knock." "who’s there?" "lettuce." "lettuce who?" "lettuce in, it’s cold out here!"
29
+ - **one-liner**: "i told my wife she was drawing her eyebrows too high. she looked surprised."
30
+ - **anecdotal joke**: "why don’t scientists trust atoms? because they make up everything."
31
+
32
+ ---
33
+
34
+ ## .purpose & effects
35
+ - jokes often serve to break tension, share cultural insights, or provide social commentary.
36
+ - humor is a social adhesive, fostering community bonds through shared laughter.
37
+
38
+ ---
39
+
40
+ ## .psychology & anthropology
41
+ studies suggest that humor evolved as a cognitive function to enhance group cohesion and social learning. jokes can reveal power dynamics and social norms within cultures.
42
+
43
+ ---
44
+
45
+ ## .narrative arc
46
+ a joke typically follows a simple arc: setup (establish context) → punchline (introduce humor twist).
47
+
48
+ ---
49
+
50
+ ## .insights & cultural value
51
+ while jokes might appear frivolous, they carry cultural and linguistic insights, revealing societal values and collective human experience. they differ across cultures, reflecting unique linguistic structures and societal taboos.
@@ -0,0 +1,62 @@
1
+ # 🧩 .brief: `user journey`
2
+
3
+ ## .what
4
+ A **user journey** is the series of experiences a user goes through to accomplish a specific goal within a product or service. It maps out the end-to-end experience from the user’s perspective, capturing interactions, emotions, and environments throughout the process.
5
+
6
+ ---
7
+
8
+ ## 🎯 purpose
9
+ - **Improve user experience**: Identifies pain points and opportunities for enhancement.
10
+ - **Guide design decisions**: Provides a user-centered framework for creating or refining touchpoints.
11
+ - **Communicate user needs**: Helps stakeholders understand the user’s perspective and priorities.
12
+
13
+ ---
14
+
15
+ ## 🛠 components
16
+ - **Personas**: Representations of different user archetypes.
17
+ - **Scenarios**: Contexts in which the journey unfolds.
18
+ - **Touchpoints**: Key moments of interaction between the user and the product/service.
19
+ - **Emotions**: User feelings at different stages.
20
+ - **Pain Points**: Challenges or frustrations encountered by the user.
21
+ - **Goals**: Desired outcomes the user aims to achieve.
22
+
23
+ ---
24
+
25
+ ## 🌀 stages
26
+ 1. **Discovery**: User learns about the product or service.
27
+ 2. **Consideration**: User evaluates options or gathers information.
28
+ 3. **Purchase/Decision**: User commits to a product or service.
29
+ 4. **Onboarding**: User starts using the product/service.
30
+ 5. **Usage**: Regular interaction with the product/service.
31
+ 6. **Support**: Seeks help or resolution to issues.
32
+ 7. **Feedback**: Shares experience or leaves a review.
33
+
34
+ ---
35
+
36
+ ## 🌐 context
37
+ A user journey occurs across multiple channels and platforms, including websites, mobile apps, customer support, and physical locations. It is essential for businesses aiming for omnichannel consistency to maintain seamless transitions and coherent messaging across all touchpoints.
38
+
39
+ ---
40
+
41
+ ## 🎨 examples
42
+ - **Online shopping**: From discovering a product on social media, navigating through the website, purchasing, and finally receiving the product.
43
+ - **Healthcare service**: Scheduling an appointment, receiving care, and follow-up communications.
44
+
45
+ ---
46
+
47
+ ## 📈 benefits
48
+ - Reduces friction and improves satisfaction by addressing user needs at each stage.
49
+ - Informs cross-functional teams (e.g., marketing, design, development) to align their efforts with user-focused goals.
50
+ - Facilitates continuous improvement through ongoing assessment and refinement of the user experience.
51
+
52
+ ---
53
+
54
+ ## 📚 when to use
55
+ - During the design phase of a new product or service.
56
+ - When changes are made to existing services seeking to improve user experience.
57
+ - To understand and solve specific user experience challenges.
58
+
59
+ ---
60
+
61
+ ## 🔄 evolution
62
+ As user expectations and technologies evolve, so must user journeys. They should be reviewed and updated regularly to reflect actual user behavior and preferences effectively.
@@ -0,0 +1,49 @@
1
+ # 🧩 .brief: `user journey`
2
+
3
+ ## .what
4
+ a **user journey** is a narrative or framework that maps out the interactions an individual has with a product or service over time. it focuses on capturing the complete user experience from initial contact to final engagement, highlighting the touchpoints and channels encountered along the way.
5
+
6
+ ---
7
+ ## 🎯 purpose
8
+ - to understand and enhance the user experience
9
+ - to identify pain points and opportunities for improvement
10
+ - to align organizational goals with user needs and expectations
11
+
12
+ ---
13
+ ## 🛠️ components
14
+ - **personas**: fictional characters representing user types
15
+ - **touchpoints**: instances of interaction between user and service
16
+ - **emotional journey**: a map of user emotions throughout the process
17
+ - **channels**: platforms and mediums used during the interaction
18
+ - **goals**: user objectives and desired outcomes
19
+
20
+ ---
21
+ ## 🗺️ structure
22
+ 1. **awareness**: how the user first learns about the product or service
23
+ 2. **consideration**: exploration of options and seeking further information
24
+ 3. **purchase/decision**: the point of transaction or commitment
25
+ 4. **retention**: user's continued use and experience with the service
26
+ 5. **advocacy**: user's likelihood to recommend the product or service to others
27
+
28
+ ---
29
+ ## 💡 examples
30
+ - a customer's journey from learning about a new smartphone through an online ad, visiting a store to try it out, purchasing it online, and finally using and recommending it to friends.
31
+ - a traveler's interactions from booking a flight, entering the airport, experiencing the flight, arriving at the destination, and sharing their trip online.
32
+
33
+ ---
34
+ ## 🔄 variations
35
+ - **self-service journeys**: focused on users navigating services themselves without direct support (e.g., online shopping)
36
+ - **in-person journeys**: primarily conducted in physical locations (e.g., dining at a restaurant)
37
+ - **digital-first journeys**: interactions primarily occur through digital platforms (e.g., using a mobile banking app)
38
+
39
+ ---
40
+ ## 🎯 why it matters
41
+ - facilitates a user-centered design approach
42
+ - helps in identifying user pain points to optimize conversion rates
43
+ - aids in creating seamless and cohesive experiences across different channels
44
+
45
+ ---
46
+ ## 📈 benefits
47
+ - improved user satisfaction and loyalty
48
+ - increased efficiency in product or service design
49
+ - stronger alignment of product offerings with user expectations
@@ -104,7 +104,7 @@ exports.SKILL_ARTICULATE = (0, rhachet_1.genRoleSkill)({
104
104
  lookup: {
105
105
  apiKeyOpenai: {
106
106
  source: 'process.env',
107
- envar: 'PREP_OPENAI_KEY',
107
+ envar: 'OPENAI_API_KEY',
108
108
  desc: 'the openai key to use',
109
109
  type: 'string',
110
110
  },
@@ -1 +1 @@
1
- {"version":3,"file":"stepArticulate.skill.js","sourceRoot":"","sources":["../../../../../src/roles/thinker/skills/brief.articulate/stepArticulate.skill.ts"],"names":[],"mappings":";;;AAAA,qCAA4E;AAC5E,+DAA6E;AAE7E,sEAAmE;AACnE,kEAA+D;AAC/D,yFAAsF;AACtF,gGAA6F;AAE7F,qDAAkD;AAErC,QAAA,gBAAgB,GAAG,IAAA,sBAAY,EAAC;IAC3C,IAAI,EAAE,YAAY;IAClB,KAAK,EAAE,+BAAc;IACrB,OAAO,EAAE;QACP,MAAM,EAAE;YACN,MAAM,EAAE;gBACN,MAAM,EAAE,cAAc;gBACtB,IAAI,EAAE,GAAG;gBACT,IAAI,EAAE,kCAAkC;gBACxC,IAAI,EAAE,QAAQ;aACf;YACD,IAAI,EAAE;gBACJ,MAAM,EAAE,cAAc;gBACtB,IAAI,EAAE,GAAG;gBACT,IAAI,EAAE,wDAAwD;gBAC9D,IAAI,EAAE,SAAS;aAChB;YACD,UAAU,EAAE;gBACV,MAAM,EAAE,cAAc;gBACtB,IAAI,EAAE,GAAG;gBACT,IAAI,EAAE,wDAAwD;gBAC9D,IAAI,EAAE,SAAS;aAChB;YACD,MAAM,EAAE;gBACN,MAAM,EAAE,cAAc;gBACtB,IAAI,EAAE,GAAG;gBACT,IAAI,EAAE,oDAAoD;gBAC1D,IAAI,EAAE,SAAS;aACh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d,GAAG,EAAE;4BACH,mBAAmB,EAAE,SAAS,CAAC,IAAI;4BACnC,mBAAmB,EAAE,SAAS,CAAC,IAAI;4BACnC,QAAQ,EAAE,SAAS,CAAC,QAAQ;4BAC5B,SAAS,EAAE,SAAS,CAAC,SAAS;yBAC/B;wBACD,IAAI,EAAE,SAAS,CAAC,UAAU;qBAC3B;iBACF,CAAC;gBACF,OAAO,EAAE,MAAM,IAAA,sBAAY,EAAC;oBAC1B,IAAI,EAAE,SAAS;oBACf,KAAK,EAAE;wBACL,GAAG,EAAE;4BACH,eAAe,EAAE,SAAS,CAAC,eAAe,CAAC;4BAC3C,eAAe,EAAE,SAAS,CAAC,eAAe,CAAC;yBAC5C;wBACD,MAAM,EAAE,SAAS,CAAC,MAAM;qBACzB;iBACF,CAAC;aACH,CAAC;QACJ,CAAC;KACF;IACD,OAAO,EAAE;QACP,MAAM,EAAE;YACN,YAAY,EAAE;gBACZ,MAAM,EAAE,aAAa;gBACrB,KAAK,EAAE,iBAAiB;gBACxB,IAAI,EAAE,uBAAuB;gBAC7B,IAAI,EAAE,QAAQ;aACf;SACF;QACD,MAAM,EAAE,CAAC,KAAK,EAAqC,EAAE,CACnD,OAAO,KAAK,CAAC,YAAY,KAAK,QAAQ;QACxC,WAAW,EAAE,GAAG,EAAE;YAChB,OAAO;gBACL,GAAG,IAAA,mCAAgB,GAAE;gBACrB,GAAG,IAAA,uCAAkB,GAAE;gBACvB,GAAG,IAAA,+BAAqB,EAAC;oBACvB,MAAM,EAAE,IAAA,6CAAqB,EAAC,EAAE,GAAG,EAAE,OAAO,CAAC,GAAG,EAAE,EAAE,CAAC,EAAE,wBAAwB;iBAChF,CAAC;aACH,CAAC;QACJ,CAAC;KACF;IACD,MAAM,EAAE,EAAE;CACX,CAAC,CAAC"}
1
+ {"version":3,"file":"stepArticulate.skill.js","sourceRoot":"","sources":["../../../../../src/roles/thinker/skills/brief.articulate/stepArticulate.skill.ts"],"names":[],"mappings":";;;AAAA,qCAA4E;AA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;KACF;IACD,OAAO,EAAE;QACP,MAAM,EAAE;YACN,YAAY,EAAE;gBACZ,MAAM,EAAE,aAAa;gBACrB,KAAK,EAAE,gBAAgB;gBACvB,IAAI,EAAE,uBAAuB;gBAC7B,IAAI,EAAE,QAAQ;aACf;SACF;QACD,MAAM,EAAE,CAAC,KAAK,EAAqC,EAAE,CACnD,OAAO,KAAK,CAAC,YAAY,KAAK,QAAQ;QACxC,WAAW,EAAE,GAAG,EAAE;YAChB,OAAO;gBACL,GAAG,IAAA,mCAAgB,GAAE;gBACrB,GAAG,IAAA,uCAAkB,GAAE;gBACvB,GAAG,IAAA,+BAAqB,EAAC;oBACvB,MAAM,EAAE,IAAA,6CAAqB,EAAC,EAAE,GAAG,EAAE,OAAO,CAAC,GAAG,EAAE,EAAE,CAAC,EAAE,wBAAwB;iBAChF,CAAC;aACH,CAAC;QACJ,CAAC;KACF;IACD,MAAM,EAAE,EAAE;CACX,CAAC,CAAC"}
@@ -0,0 +1,168 @@
1
+ import { enrollThread, genContextStitchTrail, genRoleSkill } from 'rhachet';
2
+ import { genArtifactGitFile, getArtifactObsDir } from 'rhachet-artifact-git';
3
+
4
+ import { genContextLogTrail } from '@src/.test/genContextLogTrail';
5
+ import { getContextOpenAI } from '@src/.test/getContextOpenAI';
6
+ import { setSkillOutputSrc } from '@src/domain.operations/artifact/setSkillOutputSrc';
7
+ import { genStitchStreamToDisk } from '@src/domain.operations/context/genStitchStreamToDisk';
8
+
9
+ import { loopArticulate } from './stepArticulate';
10
+
11
+ export const SKILL_ARTICULATE = genRoleSkill({
12
+ slug: 'articulate',
13
+ route: loopArticulate,
14
+ threads: {
15
+ lookup: {
16
+ output: {
17
+ source: 'process.argv',
18
+ char: 'o',
19
+ desc: 'the output file to write against',
20
+ type: 'string',
21
+ },
22
+ goal: {
23
+ source: 'process.argv',
24
+ char: 'g',
25
+ desc: 'the goal to use; if not specified, assumes ask is goal',
26
+ type: '?string',
27
+ },
28
+ references: {
29
+ source: 'process.argv',
30
+ char: 'f',
31
+ desc: 'reference files to to use, if any; delimit with commas',
32
+ type: '?string',
33
+ },
34
+ briefs: {
35
+ source: 'process.argv',
36
+ char: 'b',
37
+ desc: 'brief files to to use, if any; delimit with commas',
38
+ type: '?string',
39
+ },
40
+ templates: {
41
+ source: 'process.argv',
42
+ char: 'z', // todo: support undefined
43
+ desc: 'template files to to use, if any; delimit with commas',
44
+ type: '?string',
45
+ },
46
+ },
47
+ assess: (
48
+ input,
49
+ ): input is {
50
+ output: string;
51
+ goal: string;
52
+ references: string;
53
+ briefs: string;
54
+ templates?: string;
55
+ ask: string;
56
+ } => typeof input.output === 'string',
57
+ instantiate: async (input: {
58
+ output: string;
59
+ goal: string;
60
+ references: string;
61
+ briefs: string;
62
+ templates?: string;
63
+ ask: string;
64
+ }) => {
65
+ const obsDir = getArtifactObsDir({ uri: input.output });
66
+ const artifacts = {
67
+ goal: await (async () => {
68
+ if (input.goal)
69
+ return genArtifactGitFile(
70
+ { uri: input.goal },
71
+ { access: 'readonly' },
72
+ );
73
+
74
+ const art = genArtifactGitFile(
75
+ { uri: obsDir + '.goal.md' },
76
+ { versions: true },
77
+ );
78
+ await art.set({ content: input.ask });
79
+ return art;
80
+ })(),
81
+ feedback: genArtifactGitFile(
82
+ { uri: obsDir + '.feedback.md' },
83
+ { versions: true },
84
+ ),
85
+ 'focus.context': genArtifactGitFile(
86
+ { uri: obsDir + '.focus.context.md' },
87
+ { versions: true },
88
+ ),
89
+ 'focus.concept': genArtifactGitFile(
90
+ { uri: input.output },
91
+ { versions: true },
92
+ ),
93
+ references:
94
+ input.references
95
+ ?.split(',')
96
+ .filter((uri) => !!uri)
97
+ .map((reference) =>
98
+ genArtifactGitFile({ uri: reference }, { access: 'readonly' }),
99
+ ) ?? [],
100
+ briefs:
101
+ input.briefs
102
+ ?.split(',')
103
+ .filter((uri) => !!uri)
104
+ .map((brief) =>
105
+ genArtifactGitFile({ uri: brief }, { access: 'readonly' }),
106
+ ) ?? [],
107
+ templates:
108
+ input.templates
109
+ ?.split(',')
110
+ .filter((uri) => !!uri)
111
+ .map((template) =>
112
+ genArtifactGitFile({ uri: template }, { access: 'readonly' }),
113
+ ) ?? [],
114
+ };
115
+
116
+ // add an src file for historic record
117
+ await setSkillOutputSrc({ skillUri: 'bhrain.articulate', opts: input }); // todo: get skillUri from context
118
+
119
+ return {
120
+ caller: await enrollThread({
121
+ role: 'caller',
122
+ stash: {
123
+ ask: input.ask,
124
+ art: {
125
+ 'foci.goal.concept': artifacts.goal,
126
+ 'foci.goal.context': artifacts.goal,
127
+ feedback: artifacts.feedback,
128
+ templates: artifacts.templates,
129
+ },
130
+ refs: artifacts.references,
131
+ },
132
+ }),
133
+ thinker: await enrollThread({
134
+ role: 'thinker',
135
+ stash: {
136
+ art: {
137
+ 'focus.context': artifacts['focus.context'],
138
+ 'focus.concept': artifacts['focus.concept'],
139
+ },
140
+ briefs: artifacts.briefs,
141
+ },
142
+ }),
143
+ };
144
+ },
145
+ },
146
+ context: {
147
+ lookup: {
148
+ apiKeyOpenai: {
149
+ source: 'process.env',
150
+ envar: 'OPENAI_API_KEY',
151
+ desc: 'the openai key to use',
152
+ type: 'string',
153
+ },
154
+ },
155
+ assess: (input): input is { apiKeyOpenai: string } =>
156
+ typeof input.apiKeyOpenai === 'string',
157
+ instantiate: () => {
158
+ return {
159
+ ...getContextOpenAI(),
160
+ ...genContextLogTrail(),
161
+ ...genContextStitchTrail({
162
+ stream: genStitchStreamToDisk({ dir: process.cwd() }), // stream events to disk
163
+ }),
164
+ };
165
+ },
166
+ },
167
+ readme: '',
168
+ });