@litfamily/litgravity 0.1.1 → 0.1.3

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 (251) hide show
  1. package/CHANGELOG.md +46 -0
  2. package/README.md +19 -3
  3. package/README_ko-KR.md +19 -3
  4. package/TRADEMARK.md +12 -0
  5. package/package.json +3 -2
  6. package/plugin/hooks/lib/lanes.mjs +65 -0
  7. package/plugin/hooks/lib/liveness.mjs +81 -0
  8. package/plugin/hooks/lib/motion.mjs +34 -5
  9. package/plugin/hooks/lib/reentry.mjs +7 -0
  10. package/plugin/hooks/lib/rewind/brief.mjs +364 -0
  11. package/plugin/hooks/lib/rewind/collect.mjs +359 -0
  12. package/plugin/hooks/lib/rewind/gauge.mjs +55 -0
  13. package/plugin/hooks/lib/rewind/next-step.mjs +77 -0
  14. package/plugin/hooks/lib/rewind/redact.mjs +60 -0
  15. package/plugin/hooks/lib/rewind/transcripts.mjs +214 -0
  16. package/plugin/hooks/lib/routes.mjs +79 -5
  17. package/plugin/hooks/lib/workflow-stack.mjs +213 -0
  18. package/plugin/hooks/post-tool-use.mjs +39 -1
  19. package/plugin/hooks/pre-invocation.mjs +93 -2
  20. package/plugin/hooks/session-start.mjs +26 -3
  21. package/plugin/hooks/stop.mjs +55 -6
  22. package/plugin/hud/looks.mjs +29 -0
  23. package/plugin/hud/render.mjs +277 -12
  24. package/plugin/plugin.json +1 -1
  25. package/plugin/skills/frontend-ui-ux/SKILL.md +12 -1
  26. package/plugin/skills/frontend-ui-ux/kit/components.css +417 -0
  27. package/plugin/skills/frontend-ui-ux/kit/fonts.json +22 -0
  28. package/plugin/skills/frontend-ui-ux/kit/layouts/landing.html +164 -0
  29. package/plugin/skills/frontend-ui-ux/kit/layouts/settings.html +114 -0
  30. package/plugin/skills/frontend-ui-ux/kit/layouts/workspace.html +115 -0
  31. package/plugin/skills/frontend-ui-ux/kit/styles/computational-brutalism.json +227 -0
  32. package/plugin/skills/frontend-ui-ux/kit/styles/field-notes.json +205 -0
  33. package/plugin/skills/frontend-ui-ux/kit/styles/graphite.json +200 -0
  34. package/plugin/skills/frontend-ui-ux/kit/styles/meadow.json +199 -0
  35. package/plugin/skills/frontend-ui-ux/kit/styles/neo-brutalism.json +222 -0
  36. package/plugin/skills/frontend-ui-ux/kit/ui.js +226 -0
  37. package/plugin/skills/frontend-ui-ux/references/house-styles.md +234 -0
  38. package/plugin/skills/frontend-ui-ux/scripts/design-lock.mjs +400 -0
  39. package/plugin/skills/frontend-ui-ux/scripts/interface-probe-lock.mjs +196 -0
  40. package/plugin/skills/frontend-ui-ux/scripts/interface-probe-page.mjs +30 -9
  41. package/plugin/skills/frontend-ui-ux/scripts/interface-probe-rules.mjs +20 -8
  42. package/plugin/skills/frontend-ui-ux/scripts/interface-probe.mjs +42 -9
  43. package/plugin/skills/frontend-ui-ux/scripts/pixel-art.mjs +60 -0
  44. package/plugin/skills/lit-adhd/SKILL.md +160 -0
  45. package/plugin/skills/lit-adhd/references/card-examples.md +107 -0
  46. package/plugin/skills/lit-adhd/references/status-taxonomy.md +34 -0
  47. package/plugin/skills/lit-adhd/scripts/rewind.mjs +5 -0
  48. package/plugin/skills/lit-diagram-drawer/SKILL.md +5 -3
  49. package/plugin/skills/lit-diagram-drawer/references/drawing-rules.md +1 -1
  50. package/plugin/skills/lit-diagram-drawer/references/style-guide.md +21 -12
  51. package/plugin/skills/lit-diagram-drawer/references/type-architecture.md +3 -3
  52. package/plugin/skills/lit-diagram-drawer/references/type-dependency.md +1 -1
  53. package/plugin/skills/lit-diagram-drawer/references/type-tree.md +3 -3
  54. package/plugin/skills/lit-diagram-drawer/references/type-wardley.md +1 -1
  55. package/plugin/skills/lit-diagram-drawer/scripts/diagram-craft-rules.mjs +1 -2
  56. package/plugin/skills/lit-diagram-drawer/scripts/visual-quality.mjs +1 -2
  57. package/plugin/skills/lit-docx/SKILL.md +3 -3
  58. package/plugin/skills/lit-handoff/SKILL.md +1 -0
  59. package/plugin/skills/lit-hijack/SKILL.md +263 -0
  60. package/plugin/skills/lit-hijack/references/capture-and-provenance.md +100 -0
  61. package/plugin/skills/lit-hijack/references/clean-room-build.md +75 -0
  62. package/plugin/skills/lit-hijack/references/distil-and-licence.md +67 -0
  63. package/plugin/skills/lit-hijack/references/gap-and-port-design.md +100 -0
  64. package/plugin/skills/lit-hijack/references/parity-and-report.md +85 -0
  65. package/plugin/skills/lit-hijack/scripts/hijack.mjs +953 -0
  66. package/plugin/skills/lit-plan/SKILL.md +3 -2
  67. package/plugin/skills/lit-plan/references/plan-contract.md +12 -1
  68. package/plugin/skills/lit-plan/scripts/check-plan.mjs +39 -3
  69. package/plugin/skills/lit-plan/templates/plan.md +3 -0
  70. package/plugin/skills/lit-pptx/SKILL.md +8 -8
  71. package/plugin/skills/lit-pptx/fonts/jetbrains-mono/JetBrainsMono-Bold.ttf +0 -0
  72. package/plugin/skills/lit-pptx/fonts/jetbrains-mono/JetBrainsMono-Regular.ttf +0 -0
  73. package/plugin/skills/lit-pptx/fonts/jetbrains-mono/OFL.txt +93 -0
  74. package/plugin/skills/lit-pptx/fonts/provenance.json +32 -1
  75. package/plugin/skills/lit-pptx/references/agents/analyst.md +34 -56
  76. package/plugin/skills/lit-pptx/references/agents/antithesis.md +49 -67
  77. package/plugin/skills/lit-pptx/references/agents/architect.md +38 -51
  78. package/plugin/skills/lit-pptx/references/agents/critic.md +25 -41
  79. package/plugin/skills/lit-pptx/references/agents/synthesizer.md +37 -46
  80. package/plugin/skills/lit-pptx/references/agents/thesis.md +29 -49
  81. package/plugin/skills/lit-pptx/references/anti-slop-checklist.md +119 -145
  82. package/plugin/skills/lit-pptx/references/authoring-guide.md +187 -278
  83. package/plugin/skills/lit-pptx/references/consensus-protocol.md +99 -97
  84. package/plugin/skills/lit-pptx/references/data-display-cookbook.md +36 -137
  85. package/plugin/skills/lit-pptx/references/density-and-fill.md +147 -216
  86. package/plugin/skills/lit-pptx/references/design-system-azure.md +56 -85
  87. package/plugin/skills/lit-pptx/references/direction-step.md +134 -176
  88. package/plugin/skills/lit-pptx/references/examples/01-pitch-signal-ko.md +114 -115
  89. package/plugin/skills/lit-pptx/references/examples/02-pitch-studio-ko.md +66 -66
  90. package/plugin/skills/lit-pptx/references/examples/03-business-review-ledger-ko.md +63 -63
  91. package/plugin/skills/lit-pptx/references/examples/04-business-review-night-en.md +96 -96
  92. package/plugin/skills/lit-pptx/references/examples/05-research-talk-paper-en.md +81 -81
  93. package/plugin/skills/lit-pptx/references/examples/06-lecture-chalk-ko.md +103 -103
  94. package/plugin/skills/lit-pptx/references/examples/07-data-review-night-en.md +100 -98
  95. package/plugin/skills/lit-pptx/references/examples/08-image-led-atlas-ko.md +76 -76
  96. package/plugin/skills/lit-pptx/references/examples/09-briefing-gazette-ko.md +96 -96
  97. package/plugin/skills/lit-pptx/references/examples/10-status-update-ledger-ko.md +80 -80
  98. package/plugin/skills/lit-pptx/references/examples/11-portfolio-studio-en.md +72 -72
  99. package/plugin/skills/lit-pptx/references/examples/12-research-tutorial-chalk-en.md +95 -95
  100. package/plugin/skills/lit-pptx/references/examples/13-engineering-review-computational-brutalism-ko.md +173 -0
  101. package/plugin/skills/lit-pptx/references/examples/14-launch-pitch-neo-brutalism-ko.md +154 -0
  102. package/plugin/skills/lit-pptx/references/examples/15-design-lecture-bauhaus-ko.md +139 -0
  103. package/plugin/skills/lit-pptx/references/examples/16-community-programme-riso-ko.md +158 -0
  104. package/plugin/skills/lit-pptx/references/examples/17-public-data-briefing-newsroom-ko.md +179 -0
  105. package/plugin/skills/lit-pptx/references/interview-protocol.md +83 -102
  106. package/plugin/skills/lit-pptx/references/layout-families.md +161 -265
  107. package/plugin/skills/lit-pptx/references/stages/autopilot.md +30 -70
  108. package/plugin/skills/lit-pptx/references/stages/interview.md +36 -68
  109. package/plugin/skills/lit-pptx/references/stages/plan.md +26 -67
  110. package/plugin/skills/lit-pptx/references/title-treatments.md +93 -145
  111. package/plugin/skills/lit-pptx/references/tonalities/atlas.md +95 -108
  112. package/plugin/skills/lit-pptx/references/tonalities/bauhaus.md +140 -0
  113. package/plugin/skills/lit-pptx/references/tonalities/chalk.md +107 -122
  114. package/plugin/skills/lit-pptx/references/tonalities/computational-brutalism.md +150 -0
  115. package/plugin/skills/lit-pptx/references/tonalities/gazette.md +87 -111
  116. package/plugin/skills/lit-pptx/references/tonalities/ledger.md +96 -125
  117. package/plugin/skills/lit-pptx/references/tonalities/neo-brutalism.md +161 -0
  118. package/plugin/skills/lit-pptx/references/tonalities/newsroom.md +144 -0
  119. package/plugin/skills/lit-pptx/references/tonalities/night.md +104 -131
  120. package/plugin/skills/lit-pptx/references/tonalities/paper.md +114 -130
  121. package/plugin/skills/lit-pptx/references/tonalities/riso.md +137 -0
  122. package/plugin/skills/lit-pptx/references/tonalities/signal.md +96 -103
  123. package/plugin/skills/lit-pptx/references/tonalities/studio.md +81 -112
  124. package/plugin/skills/lit-pptx/scripts/compile-deck.js +4 -6
  125. package/plugin/skills/lit-pptx/scripts/craft_extras.py +135 -91
  126. package/plugin/skills/lit-pptx/scripts/deck_craft.py +1 -1
  127. package/plugin/skills/lit-pptx/scripts/embed_fonts.py +13 -1
  128. package/plugin/skills/lit-pptx/scripts/layout_inventory.py +1 -1
  129. package/plugin/skills/lit-pptx/scripts/learn_template.py +1 -1
  130. package/plugin/skills/lit-pptx/scripts/lib/grid-resolver.js +101 -110
  131. package/plugin/skills/lit-pptx/scripts/lib/layout-resolver.js +9 -15
  132. package/plugin/skills/lit-pptx/scripts/lib/render-pack.js +370 -563
  133. package/plugin/skills/lit-pptx/scripts/lib/slide-grid.js +104 -0
  134. package/plugin/skills/lit-pptx/scripts/lib/template-registry.js +57 -6
  135. package/plugin/skills/lit-pptx/scripts/qa_deck.py +6 -6
  136. package/plugin/skills/lit-pptx/scripts/render_pages.py +31 -0
  137. package/plugin/skills/lit-pptx/scripts/validate_pptx.py +1 -1
  138. package/plugin/skills/lit-pptx/specs/markdown-slide-spec-v1.md +167 -191
  139. package/plugin/skills/lit-pptx/specs/markdown-slide-spec-v2.md +117 -166
  140. package/plugin/skills/lit-pptx/specs/template-enrollment-contract.md +307 -330
  141. package/plugin/skills/lit-pptx/templates/tonalities/atlas/pack.yaml +1 -1
  142. package/plugin/skills/lit-pptx/templates/tonalities/bauhaus/pack.yaml +98 -0
  143. package/plugin/skills/lit-pptx/templates/tonalities/chalk/pack.yaml +1 -1
  144. package/plugin/skills/lit-pptx/templates/tonalities/computational-brutalism/pack.yaml +99 -0
  145. package/plugin/skills/lit-pptx/templates/tonalities/gazette/pack.yaml +1 -1
  146. package/plugin/skills/lit-pptx/templates/tonalities/ledger/pack.yaml +1 -1
  147. package/plugin/skills/lit-pptx/templates/tonalities/neo-brutalism/pack.yaml +107 -0
  148. package/plugin/skills/lit-pptx/templates/tonalities/newsroom/pack.yaml +99 -0
  149. package/plugin/skills/lit-pptx/templates/tonalities/night/pack.yaml +1 -1
  150. package/plugin/skills/lit-pptx/templates/tonalities/paper/pack.yaml +1 -1
  151. package/plugin/skills/lit-pptx/templates/tonalities/riso/pack.yaml +99 -0
  152. package/plugin/skills/lit-pptx/templates/tonalities/signal/pack.yaml +2 -2
  153. package/plugin/skills/lit-pptx/templates/tonalities/studio/pack.yaml +1 -1
  154. package/plugin/skills/lit-schematic/SKILL.md +114 -0
  155. package/plugin/skills/lit-schematic/examples/iso-heat-exchanger/build.mjs +38 -0
  156. package/plugin/skills/lit-schematic/examples/iso-heat-exchanger/scene.mjs +133 -0
  157. package/plugin/skills/lit-schematic/examples/journal-adsorption-rig/build.mjs +87 -0
  158. package/plugin/skills/lit-schematic/examples/pid-dosing-skid/build.mjs +85 -0
  159. package/plugin/skills/lit-schematic/references/cutaway-outputs.md +70 -0
  160. package/plugin/skills/lit-schematic/references/isometric-craft.md +101 -0
  161. package/plugin/skills/lit-schematic/references/journal-figures.md +72 -0
  162. package/plugin/skills/lit-schematic/references/kit-api.md +134 -0
  163. package/plugin/skills/lit-schematic/references/pfd-and-layout.md +53 -0
  164. package/plugin/skills/lit-schematic/references/pid-drafting.md +103 -0
  165. package/plugin/skills/lit-schematic/references/pid-symbols.md +163 -0
  166. package/plugin/skills/lit-schematic/references/verification.md +100 -0
  167. package/plugin/skills/lit-schematic/scripts/doctor.mjs +57 -0
  168. package/plugin/skills/lit-schematic/scripts/lib/figure.mjs +81 -0
  169. package/plugin/skills/lit-schematic/scripts/lib/fonts.mjs +27 -0
  170. package/plugin/skills/lit-schematic/scripts/lib/geom.mjs +113 -0
  171. package/plugin/skills/lit-schematic/scripts/lib/interactive.mjs +292 -0
  172. package/plugin/skills/lit-schematic/scripts/lib/isa.mjs +115 -0
  173. package/plugin/skills/lit-schematic/scripts/lib/iso.mjs +719 -0
  174. package/plugin/skills/lit-schematic/scripts/lib/legend-sheet.mjs +162 -0
  175. package/plugin/skills/lit-schematic/scripts/lib/pid.mjs +937 -0
  176. package/plugin/skills/lit-schematic/scripts/lib/png.mjs +132 -0
  177. package/plugin/skills/lit-schematic/scripts/lib/qa-core.mjs +658 -0
  178. package/plugin/skills/lit-schematic/scripts/lib/route.mjs +218 -0
  179. package/plugin/skills/lit-schematic/scripts/lib/sheet.mjs +890 -0
  180. package/plugin/skills/lit-schematic/scripts/lib/svg.mjs +82 -0
  181. package/plugin/skills/lit-schematic/scripts/lib/theme.mjs +115 -0
  182. package/plugin/skills/lit-schematic/scripts/motion.mjs +129 -0
  183. package/plugin/skills/lit-schematic/scripts/qa.mjs +92 -0
  184. package/plugin/skills/lit-schematic/scripts/render.mjs +233 -0
  185. package/plugin/skills/lit-schematic/scripts/scaffold.mjs +60 -0
  186. package/plugin/skills/lit-scientific-visualization/SKILL.md +17 -6
  187. package/plugin/skills/lit-typographic-motion/SKILL.md +58 -48
  188. package/plugin/skills/lit-typographic-motion/engine/THIRD_PARTY_NOTICES +13 -2
  189. package/plugin/skills/lit-typographic-motion/engine/blender/runner.py +218 -0
  190. package/plugin/skills/lit-typographic-motion/engine/core/presets.mjs +1 -1
  191. package/plugin/skills/lit-typographic-motion/engine/node/analysis.mjs +65 -1
  192. package/plugin/skills/lit-typographic-motion/engine/node/assets.mjs +298 -0
  193. package/plugin/skills/lit-typographic-motion/engine/node/blender.mjs +143 -0
  194. package/plugin/skills/lit-typographic-motion/engine/node/board.mjs +136 -0
  195. package/plugin/skills/lit-typographic-motion/engine/node/brief.mjs +7 -1
  196. package/plugin/skills/lit-typographic-motion/engine/node/chrome.mjs +9 -12
  197. package/plugin/skills/lit-typographic-motion/engine/node/cover-assets.mjs +5 -3
  198. package/plugin/skills/lit-typographic-motion/engine/node/cover-capture.mjs +7 -6
  199. package/plugin/skills/lit-typographic-motion/engine/node/cover-treatment.mjs +37 -4
  200. package/plugin/skills/lit-typographic-motion/engine/node/cover.mjs +19 -8
  201. package/plugin/skills/lit-typographic-motion/engine/node/done.mjs +45 -6
  202. package/plugin/skills/lit-typographic-motion/engine/node/frame-worker.mjs +7 -5
  203. package/plugin/skills/lit-typographic-motion/engine/node/gallery.mjs +121 -0
  204. package/plugin/skills/lit-typographic-motion/engine/node/host.mjs +34 -0
  205. package/plugin/skills/lit-typographic-motion/engine/node/house.mjs +44 -0
  206. package/plugin/skills/lit-typographic-motion/engine/node/look.mjs +34 -20
  207. package/plugin/skills/lit-typographic-motion/engine/node/pipeline.mjs +19 -9
  208. package/plugin/skills/lit-typographic-motion/engine/node/scaffold.mjs +210 -0
  209. package/plugin/skills/lit-typographic-motion/engine/node/score.mjs +639 -0
  210. package/plugin/skills/lit-typographic-motion/engine/node/sound-cli.mjs +21 -4
  211. package/plugin/skills/lit-typographic-motion/engine/node/sound.mjs +127 -29
  212. package/plugin/skills/lit-typographic-motion/engine/node/stage-capture.mjs +7 -6
  213. package/plugin/skills/lit-typographic-motion/engine/node/stage-gate.mjs +59 -5
  214. package/plugin/skills/lit-typographic-motion/engine/node/stage-qa.mjs +141 -9
  215. package/plugin/skills/lit-typographic-motion/engine/node/stage-serve.mjs +28 -5
  216. package/plugin/skills/lit-typographic-motion/engine/node/stage.mjs +82 -14
  217. package/plugin/skills/lit-typographic-motion/engine/node/styles.mjs +213 -0
  218. package/plugin/skills/lit-typographic-motion/engine/node/treatment.mjs +311 -10
  219. package/plugin/skills/lit-typographic-motion/engine/stage/cover-init.js +14 -2
  220. package/plugin/skills/lit-typographic-motion/engine/stage/init.js +11 -1
  221. package/plugin/skills/lit-typographic-motion/engine/stage/qa.js +6 -1
  222. package/plugin/skills/lit-typographic-motion/engine/stage/stage-kit.js +83 -0
  223. package/plugin/skills/lit-typographic-motion/engine/vendor/three/LICENSE +21 -0
  224. package/plugin/skills/lit-typographic-motion/engine/vendor/three/addons/environments/RoomEnvironment.js +144 -0
  225. package/plugin/skills/lit-typographic-motion/engine/vendor/three/addons/geometries/RoundedBoxGeometry.js +155 -0
  226. package/plugin/skills/lit-typographic-motion/engine/vendor/three/three.module.js +54571 -0
  227. package/plugin/skills/lit-typographic-motion/recipes/hero-3d/expected.json +69 -0
  228. package/plugin/skills/lit-typographic-motion/recipes/hero-3d/index.html +139 -0
  229. package/plugin/skills/lit-typographic-motion/recipes/orbit-loop/expected.json +6 -4
  230. package/plugin/skills/lit-typographic-motion/recipes/painted-light/expected.json +4 -2
  231. package/plugin/skills/lit-typographic-motion/recipes/weight-tide/expected.json +7 -5
  232. package/plugin/skills/lit-typographic-motion/references/cover.md +394 -443
  233. package/plugin/skills/lit-typographic-motion/references/craft-loop.md +57 -87
  234. package/plugin/skills/lit-typographic-motion/references/depth.md +122 -0
  235. package/plugin/skills/lit-typographic-motion/references/look.md +94 -129
  236. package/plugin/skills/lit-typographic-motion/references/runtime.md +58 -91
  237. package/plugin/skills/lit-typographic-motion/references/sound.md +130 -99
  238. package/plugin/skills/lit-typographic-motion/references/stage.md +190 -215
  239. package/plugin/skills/lit-typographic-motion/references/studio.md +245 -0
  240. package/plugin/skills/lit-typographic-motion/references/style-bibles.md +108 -97
  241. package/plugin/skills/lit-typographic-motion/references/treatment.md +191 -143
  242. package/plugin/skills/lit-typographic-motion/scripts/motion-doctor.mjs +17 -5
  243. package/plugin/skills/lit-typographic-motion/scripts/motion.mjs +47 -7
  244. package/plugin/skills/lit-typographic-motion/styles/paper.json +41 -0
  245. package/plugin/skills/lit-typographic-motion/styles/swiss-signal.json +41 -0
  246. package/plugin/skills/lit-typographic-motion/styles/terminalcore.json +42 -0
  247. package/plugin/skills/lit-typographic-motion/styles/tidal.json +41 -0
  248. package/plugin/skills/litresearch/SKILL.md +1 -0
  249. package/plugin/skills/readme-studio/SKILL.md +2 -0
  250. package/plugin/skills/review-work/SKILL.md +1 -1
  251. package/plugin/skills/start-work/SKILL.md +2 -2
package/CHANGELOG.md CHANGED
@@ -1,5 +1,51 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.1.3 — 2026-10-28
4
+
5
+ Plans:
6
+
7
+ - After `lit plan` saves a plan, type `go` in the same conversation within 30 minutes and start-work picks it up.
8
+ - If a plan's tasks touch a folder outside the project, the plan asks for a `Scope roots: <path> (<actions>)` line before it is saved, and the plan checker points at any path that line does not cover. The line is a reminder, not a lock.
9
+
10
+ Status line:
11
+
12
+ - Each conversation keeps a small record of whether it is running, idle or ended. The status line uses it to show the other conversations in the same workspace as one count, such as `+2 running · 1 idle`, and shows a start-work that just finished as done for a minute.
13
+
14
+ lit-adhd:
15
+
16
+ - The brief now opens with three lines: what is done, what is happening now, and what comes next. It also lists idle and finished conversations, reads plans before transcripts, says how many plan files it skipped, and, when nothing else suggests a next step, uses the `## Next` item of this folder's HANDOFF file. The box is a plain code fence.
17
+
18
+ Project:
19
+
20
+ - `TRADEMARK.md` explains how the LitGravity and LitFamily names and logos may be used. The code stays MIT.
21
+
22
+ ## 0.1.2 — 2026-10-27
23
+
24
+ New skills (42 in all):
25
+
26
+ - `lit-adhd` (also `lit-rewind`) tells you where your recent agy conversations stand: what each asked, did and waits on, how far the plans and goals have come, and one next step. Type `go`, `ㄱㄱ` or `진행` within 30 minutes and it starts that step. The brief is drawn in code, works in Korean and English, and masks credentials, environment values, one-time codes and terminal control sequences before anything is shortened.
27
+ - `lit-hijack` ports the know-how in someone else's published work into your own skill or system, clean-room: captures with provenance, a licence check, an overlap check that also covers Hangul, nine phase checks, a separate implementer, and a build brief that holds no source text.
28
+ - `lit-schematic` draws P&IDs, PFDs, equipment layouts, journal apparatus figures and isometric cutaways from a full symbol library, routes the lines, and checks the drawing with a QA gate and a look at the render.
29
+
30
+ Workflow:
31
+
32
+ - Routes can nest. `lit brainstorm` in the middle of `lit-loop` pauses the loop instead of ending it, and `lit continue` resumes it where it stopped. `lit approve` and `lit deny` record a start-work decision.
33
+ - The status line shows paused routes and running lanes, turns rainbow on every way into lit-adhd, and has three new looks: YOUR TURN in amber with the reason when a turn ends waiting on you, the five review-work lanes with their verdicts as each one reports, and a short DONE mark when a plan or goal finishes.
34
+
35
+ Making things:
36
+
37
+ - Diagrams, schematics, figures and films now come out rich by default; ask for minimal when you want it.
38
+ - `lit-pptx` adds five tonalities (computational brutalism, neo-brutalism, bauhaus, riso, newsroom), a shared slide grid and JetBrains Mono, and renders decks in their embedded fonts.
39
+ - `frontend-ui-ux` adds five house styles, a design lock that keeps a project on its chosen style, a small component kit, layout starters and new probe rules.
40
+ - Films get a house style, a shot grid, a starting page, a storyboard round before the full render, a story and protagonist, a three.js route for 3D (with Blender when it is installed), a layered score, and new checks for overlapping text, empty frames and dead air.
41
+ - The design skills ask you to pick a theme first, with the recommended one on top, unless you already named one or said to choose.
42
+ - The READMEs gain a "What you can make" gallery of real outputs.
43
+
44
+ Safety:
45
+
46
+ - `lit-hijack` captures and film asset downloads reach only public `https` hosts, on every redirect, connect to the address that was checked, and stop reading once a body passes its size cap.
47
+ - `lit-hijack` refuses a repository path that leaves the clone.
48
+
3
49
  ## 0.1.1 — 2026-10-26
4
50
 
5
51
  - The README studio's HyperFrames and Remotion cover templates pin newer `hono` and `fast-uri` in their lockfiles, picking up upstream fixes. A fresh template setup installs these versions.
package/README.md CHANGED
@@ -12,7 +12,7 @@
12
12
  <a href="https://github.com/wjgoarxiv/litgravity/stargazers"><img src="https://img.shields.io/github/stars/wjgoarxiv/litgravity?style=flat" alt="GitHub stars" /></a>
13
13
  </p>
14
14
 
15
- <p align="center"><a href="#install"><img src="./docs/assets/readme/icon-book.svg" width="16" alt="" /> Install</a> &nbsp; <a href="#demo"><img src="./docs/assets/readme/icon-play.svg" width="16" alt="" /> Demo</a> &nbsp; <a href="#safety-and-uninstall"><img src="./docs/assets/readme/icon-shield.svg" width="16" alt="" /> Safety</a> &nbsp; <a href="#quick-start">Quick start</a> &nbsp; <a href="#what-you-get">What you get</a> &nbsp; <a href="#what-agy-limits-today">agy limits</a> &nbsp; <a href="./README_ko-KR.md">한국어</a></p>
15
+ <p align="center"><a href="#install"><img src="./docs/assets/readme/icon-book.svg" width="16" alt="" /> Install</a> &nbsp; <a href="#demo"><img src="./docs/assets/readme/icon-play.svg" width="16" alt="" /> Demo</a> &nbsp; <a href="#safety-and-uninstall"><img src="./docs/assets/readme/icon-shield.svg" width="16" alt="" /> Safety</a> &nbsp; <a href="#quick-start">Quick start</a> &nbsp; <a href="#what-you-can-make">What you can make</a> &nbsp; <a href="#what-you-get">What you get</a> &nbsp; <a href="#what-agy-limits-today">agy limits</a> &nbsp; <a href="./README_ko-KR.md">한국어</a></p>
16
16
 
17
17
  ## Demo
18
18
 
@@ -20,6 +20,18 @@ What ignition looks like, captured from the real hook and status line on this Ma
20
20
 
21
21
  <!-- demo-gif --><p align="center"><img src="./docs/assets/litgravity/demo-ignition.webp" width="960" alt="Terminal capture. The prompt reads lit add a --shout flag that prints the greeting in capitals, with a test. The hook answers with the LIT mark and LIT IGNITED · lit-loop, names the lit-loop skill file to read first, and notes that tool events go to the conversation ledger. Below, the status line shows the model, the context gauge at 42 percent, the lit-loop chip with its clock, and the PIN through RECORD map with PIN lit." /></p>
22
22
 
23
+ ## What you can make
24
+
25
+ Each picture is a real output made on this Mac. The `lit-adhd` brief was drawn by its collector over three real agy conversations; the others were made by each skill's own engine from the skill's worked example, the same engine agy calls when you ask in a conversation.
26
+
27
+ | Picture | Skill | What it shows |
28
+ |---|---|---|
29
+ | <img src="./docs/assets/litgravity/showcase/deck-themes.webp" width="480" alt="The same Korean deck about a logistics platform in four tonalities: a dark night cover with an amber year, a navy cover with four KPI figures, a cobalt cover on cream, and a teal cover; below each, the matching chart slide with a native bar chart of monthly shipments, two bullet takeaways and a data table." /> | `lit-pptx` | One deck in four of its tonalities. Charts and KPI rows stay native and editable, Pretendard is embedded, and each deck passed the gate for overflow, contrast and empty slides. |
30
+ | <img src="./docs/assets/litgravity/showcase/pid-dosing-skid.webp" width="480" alt="P&amp;ID of a sodium hypochlorite dosing skid on a framed sheet: a storage tank TK-101 with level transmitter and alarm, duty and standby metering pumps P-101A and P-101B behind filters and check valves, a relief valve PSV-101 back to the tank, a flow loop FE-101, FT-101 and FIC-101 signalling the pump, a legend, notes and a title block." /> | `lit-schematic` | A P&amp;ID with ISA-5.1 tags, line numbers, a legend and a title block. Its checker passed: no text on a line, no line through a symbol, no loose end. |
31
+ | <img src="./docs/assets/litgravity/showcase/schematics.webp" width="480" alt="Two drawings side by side: an isometric cutaway of a shell-and-tube heat exchanger with copper tube bundle, baffles and saddle supports, each part labelled; and a journal-style two-panel figure of an adsorption rig, panel a a flow diagram with gas cylinders, mass flow controllers, an oven column and a mass spectrometer, panel b the column itself with adsorbent bed and thermocouples." /> | `lit-schematic` | The same skill drawing equipment as an isometric cutaway and as a two-panel figure for a paper. |
32
+ | <img src="./docs/assets/litgravity/showcase/motion-film.webp" width="480" alt="Four frames of a 12-second film in one dark house style: a ring drawing on beside the Korean line 작게 시작해서 끝까지, a bar chart beside One clock for every frame, a line through points beside 한 화면에 한 가지 생각, and a grid of teal and amber tiles over Same house, every film." /> | `lit-typographic-motion` | Four frames of a 12-second film from a one-line Korean request. The skill wrote a treatment first, rendered it frame by frame with a sound bed, and its gate checked flashes, legibility and the loop. |
33
+ | <img src="./docs/assets/litgravity/showcase/adhd-brief-en.webp" width="480" alt="The lit adhd brief in a dark chat pane: a headline counting three sessions, two active cards for a P&amp;ID and a landing page with what each wrote and its next step, a table row for an ended deck session, a roadmap line, and a box with the recommended next step." /> | `lit-adhd` | Type `lit adhd` after a scattered day: one brief of what you asked, what got written, what is still running and one real next step. |
34
+
23
35
  ## Why LitGravity
24
36
 
25
37
  agy starts fast: you type a line and it gets to work. The trouble shows up later. A long conversation fills its context, the next one begins without what the last one learned, and "done" often means the model said so. You end up re-explaining where you were and checking by hand what really works.
@@ -97,15 +109,17 @@ When the terminal narrows, the extras give way first and the route and the conte
97
109
  [LIT] | GF3.8 | ctx [#--] 42%/1049k | [LIT] . lit-loop 2:20 | [PIN] = RED . - GREEN . - VERIFY . - REVIEW . - RECORD .
98
110
  ```
99
111
 
112
+ Some moments change the look of the row. While `lit adhd` (or `lit-rewind`, the skill typed whole or after `/`, or the skill the model loads by itself) is the route, every cell turns its own colour of a slow rainbow. When the turn ends on a question, a typed approval, a BLOCKED report or a goal that needs a decision, the row turns amber and reads `⚠ YOUR TURN · <why>` until you type. During `lit review work` the five lanes (goal, qa, quality, security, context) appear as each reports, in its own colour with its verdict mark and a count such as `2/5`. A plan or goal finished during the route shows `✦ DONE ✦` for twenty seconds. Other conversations in the same workspace appear as one count, `+2 running · 1 idle` (shortened to `+3 others` when the row is tight), read from the small liveness record each conversation's hooks keep; a start-work that just finished counts as done for a minute. agy repaints the line when it chooses, so every look is static, and `NO_COLOR` keeps the labels in plain text.
113
+
100
114
  ## What you get
101
115
 
102
- **39 skills**, each a dense agy skill read on demand, with the references, scripts, templates and engines it needs inside its own folder. agy loads only the first 24,000 bytes of a `SKILL.md`, so the long material sits in the skill's `references/` folder and the skill names the file to open.
116
+ **42 skills**, each a dense agy skill read on demand, with the references, scripts, templates and engines it needs inside its own folder. agy loads only the first 24,000 bytes of a `SKILL.md`, so the long material sits in the skill's `references/` folder and the skill names the file to open.
103
117
 
104
118
  A lit turn runs the same routine through these parts. A bigger change gets a written plan first, the work is built row by row with tests under a goal record that outlives one conversation, a second look reviews it before anything merges, research shows its sources, documents and prose read clean, and the turn ends with a handoff the next conversation reads:
105
119
 
106
120
  | Part | Contents | Role |
107
121
  |---|---|---|
108
- | 39 skills | Dense agy skills with their references, scripts and engines | Plan, build, check, research, write, hand off |
122
+ | 42 skills | Dense agy skills with their references, scripts and engines | Plan, build, check, research, write, hand off |
109
123
  | 11 agents | Child agents agy starts under their type names | Plan, execute, verify, review, Korean prose |
110
124
  | 6 hooks | Run at session start, each turn, each tool call, and the stop gate | Route `lit`, hold unfinished turns, ledger every tool |
111
125
 
@@ -186,3 +200,5 @@ The seven armored machines on the cover are those seven packages, and LitGravity
186
200
  ## License
187
201
 
188
202
  MIT. See [LICENSE](./LICENSE).
203
+
204
+ The LitGravity and LitFamily names and logos are covered by the [trademark policy](./TRADEMARK.md).
package/README_ko-KR.md CHANGED
@@ -12,7 +12,7 @@
12
12
  <a href="https://github.com/wjgoarxiv/litgravity/stargazers"><img src="https://img.shields.io/github/stars/wjgoarxiv/litgravity?style=flat" alt="GitHub 스타" /></a>
13
13
  </p>
14
14
 
15
- <p align="center"><a href="#설치"><img src="./docs/assets/readme/icon-book.svg" width="16" alt="" /> 설치</a> &nbsp; <a href="#데모"><img src="./docs/assets/readme/icon-play.svg" width="16" alt="" /> 데모</a> &nbsp; <a href="#안전과-제거"><img src="./docs/assets/readme/icon-shield.svg" width="16" alt="" /> 안전</a> &nbsp; <a href="#빠른-시작">빠른 시작</a> &nbsp; <a href="#들어-있는-것">들어 있는 것</a> &nbsp; <a href="#지금-agy가-막아-두는-것">agy의 한계</a> &nbsp; <a href="./README.md">English</a></p>
15
+ <p align="center"><a href="#설치"><img src="./docs/assets/readme/icon-book.svg" width="16" alt="" /> 설치</a> &nbsp; <a href="#데모"><img src="./docs/assets/readme/icon-play.svg" width="16" alt="" /> 데모</a> &nbsp; <a href="#안전과-제거"><img src="./docs/assets/readme/icon-shield.svg" width="16" alt="" /> 안전</a> &nbsp; <a href="#빠른-시작">빠른 시작</a> &nbsp; <a href="#만들-수-있는-것">만들 수 있는 것</a> &nbsp; <a href="#들어-있는-것">들어 있는 것</a> &nbsp; <a href="#지금-agy가-막아-두는-것">agy의 한계</a> &nbsp; <a href="./README.md">English</a></p>
16
16
 
17
17
  ## 데모
18
18
 
@@ -20,6 +20,18 @@
20
20
 
21
21
  <!-- demo-gif --><p align="center"><img src="./docs/assets/litgravity/demo-ignition.webp" width="960" alt="터미널 갈무리. 프롬프트는 lit add a --shout flag that prints the greeting in capitals, with a test. 훅은 LIT 표시와 LIT IGNITED · lit-loop로 답하고, 먼저 읽을 lit-loop 스킬 파일을 알리고, 도구 기록이 대화 ledger에 남는다고 안내합니다. 아래 상태 표시줄에는 모델, 42퍼센트 컨텍스트 게이지, 시계가 달린 lit-loop 칩, PIN이 켜진 PIN부터 RECORD까지의 지도가 보입니다." /></p>
22
22
 
23
+ ## 만들 수 있는 것
24
+
25
+ 아래 그림은 모두 이 Mac에서 나온 실제 결과물입니다. `lit-adhd` 브리프는 실제 agy 대화 세 개를 수집기가 읽어 그렸고, 나머지는 각 스킬의 예제를 그 스킬의 엔진이 만든 것입니다. 대화에서 요청할 때 agy가 부르는 엔진과 같습니다.
26
+
27
+ | 그림 | 스킬 | 보여 주는 것 |
28
+ |---|---|---|
29
+ | <img src="./docs/assets/litgravity/showcase/deck-themes.webp" width="480" alt="물류 플랫폼을 다룬 같은 한국어 덱을 네 가지 톤으로 그린 그림. 호박색 연도가 있는 어두운 표지, KPI 네 개가 있는 남색 표지, 크림 바탕의 코발트 표지, 청록 표지가 있고, 각 표지 아래에 월별 화물 막대 차트와 요점 두 줄, 데이터 표가 있는 차트 슬라이드가 있습니다." /> | `lit-pptx` | 한 덱을 네 가지 톤으로 만든 모습입니다. 차트와 KPI 줄은 편집할 수 있는 원본 그대로이고, Pretendard가 들어 있으며, 넘침·대비·빈 슬라이드 검사를 통과했습니다. |
30
+ | <img src="./docs/assets/litgravity/showcase/pid-dosing-skid.webp" width="480" alt="차아염소산나트륨 주입 스키드의 P&amp;ID. 레벨 전송기와 경보가 달린 저장 탱크 TK-101, 필터와 체크 밸브 뒤의 주·예비 정량 펌프 P-101A와 P-101B, 탱크로 돌아가는 안전 밸브 PSV-101, 펌프로 신호를 보내는 FE-101·FT-101·FIC-101 유량 루프, 범례, 노트, 표제란이 있습니다." /> | `lit-schematic` | ISA-5.1 태그, 라인 번호, 범례, 표제란을 갖춘 P&amp;ID입니다. 선 위 글자, 기호를 지나는 선, 끊긴 선이 없다는 검사를 통과했습니다. |
31
+ | <img src="./docs/assets/litgravity/showcase/schematics.webp" width="480" alt="두 그림. 구리 튜브 다발과 배플, 새들 받침이 보이는 셸앤튜브 열교환기 등각 절단도에 부품 이름이 달려 있고, 옆에는 논문용 두 패널 흡착 장치 그림이 있습니다. a는 가스 실린더, 질량 유량 조절기, 오븐 안의 컬럼, 질량 분석기의 흐름도, b는 흡착층과 열전대가 있는 컬럼입니다." /> | `lit-schematic` | 같은 스킬이 장치를 등각 절단도로, 그리고 논문용 두 패널 그림으로 그린 예입니다. |
32
+ | <img src="./docs/assets/litgravity/showcase/motion-film.webp" width="480" alt="어두운 한 가지 스타일로 된 12초 영상의 네 장면. 작게 시작해서 끝까지 옆에 그려지는 고리, One clock for every frame 옆의 막대 차트, 한 화면에 한 가지 생각 옆의 점을 잇는 선, Same house, every film 위의 청록과 호박색 타일." /> | `lit-typographic-motion` | 한 줄짜리 한국어 요청으로 만든 12초 영상의 네 장면입니다. 스킬이 먼저 트리트먼트를 쓰고, 사운드와 함께 한 프레임씩 렌더링한 뒤, 깜빡임·가독성·루프 검사를 거쳤습니다. |
33
+ | <img src="./docs/assets/litgravity/showcase/adhd-brief-ko.webp" width="480" alt="어두운 대화 창에 뜬 lit adhd 브리프. 세션 세 개를 세는 제목, P&amp;ID와 랜딩 페이지를 만들던 진행 중 카드 두 장과 각각 쓴 파일, 다음 단계, 끝난 덱 세션 한 줄짜리 표, 로드맵 한 줄, 추천 다음 단계 상자가 있습니다." /> | `lit-adhd` | 정신없던 하루 끝에 `lit adhd`를 입력하면 요청한 것, 쓴 것, 아직 돌고 있는 것, 실제로 할 수 있는 다음 단계 하나를 한 장으로 보여 줍니다. |
34
+
23
35
  ## 왜 LitGravity인가
24
36
 
25
37
  agy는 시작이 빠릅니다. 한 줄 적으면 바로 일을 시작합니다. 문제는 그다음에 옵니다. 대화가 길어지면 컨텍스트가 차고, 다음 대화는 지난 대화가 알던 것을 모른 채 시작합니다. "끝났다"는 말도 모델이 그렇게 말했다는 뜻일 때가 많습니다. 결국 어디까지 했는지 다시 설명하고, 무엇이 실제로 돌아가는지 손으로 확인하게 됩니다.
@@ -97,15 +109,17 @@ Google Antigravity CLI용 LitFamily 플러그인인 LitGravity를 설치해 줘.
97
109
  [LIT] | GF3.8 | ctx [#--] 42%/1049k | [LIT] . lit-loop 2:20 | [PIN] = RED . - GREEN . - VERIFY . - REVIEW . - RECORD .
98
110
  ```
99
111
 
112
+ 몇몇 순간에는 줄의 모양이 바뀝니다. `lit adhd`가 경로일 때는 칸마다 색이 다른 느린 무지개가 됩니다. `lit-rewind`로 부르든, 스킬 이름을 그대로 치거나 `/` 뒤에 치든, 모델이 스스로 스킬을 불러오든 똑같습니다. 턴이 질문, 승인 요청, BLOCKED 보고로 끝나거나 목표가 결정을 기다리면, 줄이 호박색이 되고 다시 입력할 때까지 `⚠ YOUR TURN · <이유>`를 띄웁니다. `lit review work`가 도는 동안에는 다섯 레인(goal, qa, quality, security, context)이 보고하는 대로 레인마다 제 색과 판정 표시를 달고 나타나며, `2/5` 같은 수도 함께 보입니다. 경로가 도는 사이 계획이나 목표가 끝나면 `✦ DONE ✦`이 20초 동안 뜹니다. agy는 줄을 다시 그리는 때를 스스로 정하므로 모든 모양은 멈춰 있는 그림이고, `NO_COLOR`에서도 표시 글자는 평문으로 남습니다.
113
+
100
114
  ## 들어 있는 것
101
115
 
102
116
  모든 lit 턴은 같은 순서를 따릅니다. 큰 변경은 첫 편집 전에 계획으로 적습니다. 작업은 그 계획에 맞춰 테스트와 실제 화면 확인으로 검증합니다. 합치기 전에는 두 번째 눈이 검토합니다. 조사는 출처를 밝히고, 문서와 글은 깔끔하게 읽히며, 턴은 다음 대화가 읽을 인계 메모로 끝납니다. 아래 스킬, 에이전트, 훅, 엔진은 그 순서의 부품으로, 필요할 때 읽습니다.
103
117
 
104
- **스킬 39개.** 각 스킬은 필요할 때 읽는 agy 스킬로, 필요한 참고 문서, 스크립트, 템플릿, 엔진을 자기 폴더 안에 갖고 있습니다. agy는 `SKILL.md`의 앞 24,000바이트만 불러오므로 긴 내용은 스킬의 `references/` 폴더에 두고, 스킬이 열 파일을 알려 줍니다.
118
+ **스킬 42개.** 각 스킬은 필요할 때 읽는 agy 스킬로, 필요한 참고 문서, 스크립트, 템플릿, 엔진을 자기 폴더 안에 갖고 있습니다. agy는 `SKILL.md`의 앞 24,000바이트만 불러오므로 긴 내용은 스킬의 `references/` 폴더에 두고, 스킬이 열 파일을 알려 줍니다.
105
119
 
106
120
  | 부분 | 내용 | 역할 |
107
121
  |---|---|---|
108
- | 스킬 39개 | 참고 문서, 스크립트, 엔진을 담은 agy 스킬 | 계획, 구현, 확인, 조사, 작성, 인계 |
122
+ | 스킬 42개 | 참고 문서, 스크립트, 엔진을 담은 agy 스킬 | 계획, 구현, 확인, 조사, 작성, 인계 |
109
123
  | 에이전트 11개 | agy가 타입 이름으로 시작하는 하위 에이전트 | 계획, 실행, 검증, 검토, 한국어 글 |
110
124
  | 훅 6개 | 세션 시작, 매 턴, 매 도구 호출, 종료 게이트에서 실행 | `lit` 라우팅, 미완 턴 붙잡기, 도구 ledger 기록 |
111
125
 
@@ -186,3 +200,5 @@ LitGravity는 LitFamily 패키지 일곱 개 중 하나입니다. 각 패키지
186
200
  ## 라이선스
187
201
 
188
202
  MIT. [LICENSE](./LICENSE)를 보세요.
203
+
204
+ LitGravity와 LitFamily 이름과 로고는 [상표 정책](./TRADEMARK.md)을 따릅니다.
package/TRADEMARK.md ADDED
@@ -0,0 +1,12 @@
1
+ # Trademark policy
2
+
3
+ The code in this repository is free to use under the MIT License (see `LICENSE`). The names **LitGravity**
4
+ and **LitFamily**, and the logos and mascot art, are not part of that license.
5
+
6
+ - You can fork, change and share the code under MIT.
7
+ - If you publish a changed version, give it a different name and logo, and do not suggest that the
8
+ LitGravity maintainers made or endorse it.
9
+ - You can say in plain text that your project is "based on LitGravity" or "a fork of LitGravity".
10
+ - Unchanged copies, such as mirrors and package caches, may keep the name.
11
+
12
+ Questions: open an issue at https://github.com/wjgoarxiv/litgravity/issues.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@litfamily/litgravity",
3
- "version": "0.1.1",
3
+ "version": "0.1.3",
4
4
  "description": "Installer for LitGravity: skills, hooks and agents that help Google's Antigravity CLI (agy) plan, build, check and hand off work.",
5
5
  "keywords": [
6
6
  "antigravity",
@@ -35,7 +35,8 @@
35
35
  "README.md",
36
36
  "README_ko-KR.md",
37
37
  "CHANGELOG.md",
38
- "LICENSE"
38
+ "LICENSE",
39
+ "TRADEMARK.md"
39
40
  ],
40
41
  "publishConfig": {
41
42
  "access": "public"
@@ -0,0 +1,65 @@
1
+ // Lane state: tracks child agents spawned via invoke_subagent, read by the status line.
2
+ // State is a small JSON file next to the stack file. Lanes start on PostToolUse of invoke_subagent
3
+ // and end on PostToolUse when the subagent's tool call completes (error field present or a later
4
+ // invoke_subagent with the same TypeName). The file is capped and stale lanes (>1h) are dropped.
5
+
6
+ import { closeSync, constants, fstatSync, lstatSync, mkdirSync, openSync, readSync, renameSync, writeFileSync } from 'node:fs';
7
+ import { dirname } from 'node:path';
8
+ import { sessionPath } from './common.mjs';
9
+
10
+ const MAX_LANES = 10;
11
+ const MAX_FILE_BYTES = 16 * 1024;
12
+ const STALE_MS = 60 * 60 * 1000;
13
+
14
+ export const laneFilePath = (cwd, conversationId, env = process.env) => {
15
+ const base = sessionPath(cwd, conversationId, env);
16
+ if (!base) return null;
17
+ return base.replace(/\.json$/, '.lanes.json');
18
+ };
19
+
20
+ export const readLanes = (cwd, conversationId, env = process.env, now = Date.now()) => {
21
+ let fd;
22
+ try {
23
+ const path = laneFilePath(cwd, conversationId, env);
24
+ if (!path || !lstatSync(path).isFile()) return [];
25
+ fd = openSync(path, constants.O_RDONLY | (constants.O_NOFOLLOW ?? 0));
26
+ const { size } = fstatSync(fd);
27
+ if (size > MAX_FILE_BYTES) return [];
28
+ const buffer = Buffer.alloc(size);
29
+ readSync(fd, buffer, 0, size, 0);
30
+ const parsed = JSON.parse(buffer.toString('utf8'));
31
+ if (!Array.isArray(parsed)) return [];
32
+ return parsed.filter((l) => l && now - Date.parse(l.at) <= STALE_MS).slice(0, MAX_LANES);
33
+ } catch {
34
+ return [];
35
+ } finally {
36
+ if (fd !== undefined) closeSync(fd);
37
+ }
38
+ };
39
+
40
+ export const writeLanes = (cwd, conversationId, lanes, env = process.env) => {
41
+ const path = laneFilePath(cwd, conversationId, env);
42
+ if (!path) return;
43
+ mkdirSync(dirname(path), { recursive: true });
44
+ const staging = `${path}.${process.pid}.tmp`;
45
+ writeFileSync(staging, `${JSON.stringify(lanes.slice(0, MAX_LANES))}\n`, { flag: 'w' });
46
+ renameSync(staging, path);
47
+ };
48
+
49
+ // Called from PostToolUse when invoke_subagent is seen. Records or updates the lane.
50
+ export const recordLane = (cwd, conversationId, payload, env = process.env) => {
51
+ const name = payload.toolCall?.args?.TypeName ?? payload.toolCall?.args?.type_name ?? 'agent';
52
+ const now = Date.now();
53
+ const lanes = readLanes(cwd, conversationId, env, now);
54
+ const existing = lanes.findIndex((l) => l.name === name && l.status === 'active');
55
+ if (payload.error) {
56
+ if (existing !== -1) { lanes[existing].status = 'done'; lanes[existing].at = new Date(now).toISOString(); }
57
+ } else if (existing === -1) {
58
+ lanes.push({ name: String(name).slice(0, 60), status: 'active', steps: 0, at: new Date(now).toISOString() });
59
+ } else {
60
+ lanes[existing].steps = (lanes[existing].steps ?? 0) + 1;
61
+ lanes[existing].at = new Date(now).toISOString();
62
+ }
63
+ writeLanes(cwd, conversationId, lanes, env);
64
+ return lanes;
65
+ };
@@ -0,0 +1,81 @@
1
+ // Liveness: one small record per conversation beside its route state, `<id>.live.json`, read by the status line's
2
+ // other-session chip and the lit-adhd collector. PostToolUse writes `alive` and an unheld Stop writes `idle`, for every
3
+ // conversation, lit route or not. agy fires no session-end event, so `ended` is never written: a record left alone past
4
+ // its staleness limit reads as ended. The same state is rewritten at most once per throttle window; a change of state is
5
+ // written at once.
6
+
7
+ import { closeSync, constants, fstatSync, lstatSync, mkdirSync, openSync, readSync, readdirSync, renameSync, writeFileSync } from 'node:fs';
8
+ import { dirname, join } from 'node:path';
9
+ import { sessionPath } from './common.mjs';
10
+
11
+ export const LIVE_THROTTLE_MS = 30_000;
12
+ // An alive record that goes quiet this long belongs to a session that stopped without a Stop event.
13
+ export const ALIVE_STALE_MS = 10 * 60_000;
14
+ // An idle session waits on its user; after this long it is taken as closed.
15
+ export const IDLE_STALE_MS = 2 * 60 * 60_000;
16
+ const MAX_FILE_BYTES = 4096;
17
+ const PANE = /^[A-Za-z0-9._:-]{1,64}$/;
18
+ const LIVE_FILE = /^([A-Za-z0-9_-]{1,128})\.live\.json$/;
19
+
20
+ export const livePath = (cwd, conversationId, env = process.env) => {
21
+ const base = sessionPath(cwd, conversationId, env);
22
+ return base ? base.replace(/\.json$/, '.live.json') : null;
23
+ };
24
+
25
+ const readRaw = (path) => {
26
+ let fd;
27
+ try {
28
+ if (!lstatSync(path).isFile()) return null;
29
+ fd = openSync(path, constants.O_RDONLY | (constants.O_NOFOLLOW ?? 0));
30
+ const { size } = fstatSync(fd);
31
+ if (size > MAX_FILE_BYTES) return null;
32
+ const buffer = Buffer.alloc(size);
33
+ readSync(fd, buffer, 0, size, 0);
34
+ const record = JSON.parse(buffer.toString('utf8'));
35
+ return record && ['alive', 'idle'].includes(record.state) && Number.isFinite(Date.parse(record.at)) ? record : null;
36
+ } catch {
37
+ return null;
38
+ } finally {
39
+ if (fd !== undefined) closeSync(fd);
40
+ }
41
+ };
42
+
43
+ // The record with its effective state: `alive`, `idle`, or `ended` once stale. Null when absent or damaged.
44
+ export const readLive = (path, now = Date.now()) => {
45
+ const record = readRaw(path);
46
+ if (!record) return null;
47
+ const age = now - Date.parse(record.at);
48
+ const stale = age > (record.state === 'alive' ? ALIVE_STALE_MS : IDLE_STALE_MS);
49
+ return { ...record, state: stale ? 'ended' : record.state };
50
+ };
51
+
52
+ // Every conversation's record in one route-state folder (one workspace), newest first.
53
+ export const listLive = (dir, now = Date.now()) => {
54
+ let names;
55
+ try { names = readdirSync(dir); } catch { return []; }
56
+ return names
57
+ .map((name) => LIVE_FILE.exec(name))
58
+ .filter(Boolean)
59
+ .map((m) => ({ id: m[1], ...readLive(join(dir, m[0]), now) }))
60
+ .filter((r) => r.state)
61
+ .sort((a, b) => Date.parse(b.at) - Date.parse(a.at));
62
+ };
63
+
64
+ export const markLive = (cwd, conversationId, state, { env = process.env, now = Date.now() } = {}) => {
65
+ const path = livePath(cwd, conversationId, env);
66
+ if (!path) return false;
67
+ const previous = readRaw(path);
68
+ if (previous?.state === state && now - Date.parse(previous.at) < LIVE_THROTTLE_MS) return false;
69
+ const record = { state, at: new Date(now).toISOString() };
70
+ if (typeof env.HERDR_PANE_ID === 'string' && PANE.test(env.HERDR_PANE_ID)) record.pane = env.HERDR_PANE_ID;
71
+ try {
72
+ if (lstatSync(path).isSymbolicLink()) return false;
73
+ } catch {
74
+ // absent is fine
75
+ }
76
+ mkdirSync(dirname(path), { recursive: true });
77
+ const staging = `${path}.${process.pid}.tmp`;
78
+ writeFileSync(staging, `${JSON.stringify(record)}\n`);
79
+ renameSync(staging, path);
80
+ return true;
81
+ };
@@ -1,7 +1,7 @@
1
1
  import { existsSync, readFileSync, writeFileSync, mkdirSync, renameSync, lstatSync } from 'node:fs';
2
2
  import { dirname, isAbsolute, join, resolve } from 'node:path';
3
3
  import { pathToFileURL } from 'node:url';
4
- import { PLUGIN_ROOT, sessionFile, toolName, toolArgs, workspaceOf } from './common.mjs';
4
+ import { PLUGIN_ROOT, sessionFile, sessionPath, toolName, toolArgs, workspaceOf } from './common.mjs';
5
5
  import { SHELL_TOOLS, targetPaths } from './policy.mjs';
6
6
 
7
7
  // The lit-typographic-motion done gate. A motion turn ends when the skill's own done-check says the film or cover is
@@ -11,13 +11,31 @@ import { SHELL_TOOLS, targetPaths } from './policy.mjs';
11
11
  // a render that never produced its manifest reads as "no full render has finished", and the hold names that.
12
12
  export const MOTION_ROUTE = 'lit-typographic-motion';
13
13
  export const MOTION_MAX_HOLDS = 2;
14
- const COMMAND = /\bmotion\.mjs["']?\s+(stage|make|cover-gate|cover|gate|sound|look|stills|sheet|video|perf)\b([^\n;&|]*)/;
14
+ const COMMAND = /\bmotion\.mjs["']?\s+(stage|make|cover-gate|cover|gate|sound|look|stills|sheet|video|perf|assets|styles|scaffold|blender)\b([^\n;&|]*)/;
15
15
  const IMAGE = /\.(png|jpe?g|webp|gif)$/i;
16
16
  const MAX_VIEWED = 2000;
17
17
  const DONE_MODULE = join(PLUGIN_ROOT, 'skills', MOTION_ROUTE, 'engine', 'node', 'done.mjs');
18
18
 
19
19
  const statePath = (payload) => sessionFile(payload)?.replace(/\.json$/, '.motion.json') ?? null;
20
20
 
21
+ // The model often works inside the film folder (`cd film && motion.mjs stage --out .`). That folder
22
+ // hashes to a different session path than the workspace root where the turn was armed, so
23
+ // recordMotionTool and evaluateMotionStop walk up the directory tree to find the nearest state file.
24
+ export function nearestMotionState(payload) {
25
+ const primary = statePath(payload);
26
+ if (primary && existsSync(primary)) return primary;
27
+ const id = payload.conversationId;
28
+ let dir = resolve(workspaceOf(payload));
29
+ for (;;) {
30
+ const parent = dirname(dir);
31
+ if (parent === dir) break;
32
+ dir = parent;
33
+ const candidate = sessionPath(dir, id)?.replace(/\.json$/, '.motion.json');
34
+ if (candidate && existsSync(candidate)) return candidate;
35
+ }
36
+ return primary;
37
+ }
38
+
21
39
  function isLink(p) {
22
40
  try {
23
41
  return lstatSync(p).isSymbolicLink();
@@ -27,7 +45,7 @@ function isLink(p) {
27
45
  }
28
46
 
29
47
  export function readMotion(payload) {
30
- const file = statePath(payload);
48
+ const file = nearestMotionState(payload);
31
49
  if (!file || !existsSync(file)) return null;
32
50
  try {
33
51
  const s = JSON.parse(readFileSync(file, 'utf8'));
@@ -38,7 +56,7 @@ export function readMotion(payload) {
38
56
  }
39
57
 
40
58
  function writeMotion(payload, state) {
41
- const file = statePath(payload);
59
+ const file = nearestMotionState(payload);
42
60
  if (!file || isLink(file) || isLink(dirname(file))) return state;
43
61
  mkdirSync(dirname(file), { recursive: true });
44
62
  const tmp = `${file}.tmp-${process.pid}`;
@@ -55,9 +73,20 @@ export function armMotionTurn(payload, now = Date.now()) {
55
73
 
56
74
  const unquote = (v) => v?.replace(/^["']|["']$/g, '');
57
75
 
76
+ // Expand `$VAR` set in the same command line (e.g. `D=out; motion.mjs stage --out $D`). The model
77
+ // often runs `--out $D` inside a film folder where D was assigned earlier in a compound command.
78
+ function expandVars(text) {
79
+ const assigns = new Map();
80
+ for (const m of String(text).matchAll(/\b([A-Z_][A-Z0-9_]*)=("[^"]*"|'[^']*'|[^\s;&|]+)/g)) {
81
+ assigns.set(m[1], unquote(m[2]));
82
+ }
83
+ return String(text).replace(/\$([A-Z_][A-Z0-9_]*)/g, (_, k) => assigns.get(k) ?? `$${k}`);
84
+ }
85
+
58
86
  /** One `motion.mjs <mode> ...` command line as { mode, out, round, stillsOnly }, or null. */
59
87
  export function parseMotionCommand(command, cwd) {
60
- const m = COMMAND.exec(String(command ?? ''));
88
+ const expanded = expandVars(String(command ?? ''));
89
+ const m = COMMAND.exec(expanded);
61
90
  if (!m) return null;
62
91
  const tokens = [...m[2].matchAll(/"[^"]*"|'[^']*'|[^\s]+/g)].map((t) => unquote(t[0]));
63
92
  const values = {};
@@ -73,6 +73,10 @@ export function resumeNote(plan) {
73
73
  ].join('\n');
74
74
  }
75
75
 
76
+ // Design skills let the user pick the look: the skill asks one `ask_question` round before it builds.
77
+ export const THEME_FIRST = new Set(['lit-pptx', 'lit-docx', 'frontend-ui-ux', 'lit-schematic', 'lit-diagram-drawer', 'readme-studio', 'lit-typographic-motion']);
78
+ const THEME_NOTE = 'Theme first: before building, ask the user with `ask_question` to choose the theme or preset (two to four real options from the skill, the recommended one first), unless the prompt already names one or says "you choose" / "알아서". If nobody can answer (headless), take the recommended option and say so in one line.';
79
+
76
80
  export function activation(hit, conversationId, kind = 'ignite') {
77
81
  const id = safeId(conversationId);
78
82
  const lines = [
@@ -85,6 +89,9 @@ export function activation(hit, conversationId, kind = 'ignite') {
85
89
  ];
86
90
  lines.push(HEADLESS_NOTE);
87
91
  if (hit.route === 'lit-plan') lines.push(PLAN_REMINDER);
92
+ if (THEME_FIRST.has(hit.route)) lines.push(THEME_NOTE);
93
+ // `go` reads the step the brief offered for this conversation, so the collector needs its id.
94
+ if (hit.route === 'lit-adhd' && id) lines.push(`Run the collector for this conversation: node ${dirname(skillPath('lit-adhd'))}/scripts/rewind.mjs --brief --lang <ko|en> --session ${id}`);
88
95
  if (hit.reviewMode) lines.push(`The user forced the ${hit.reviewMode} review mode.`);
89
96
  if (kind === 'confirm') {
90
97
  lines.push('The prompt has no task text after the keyword and nothing is active or resumable. After reading the skill, ask the user in one line what to run (a task for lit-loop, or a route such as plan or review) and wait for the answer before any other tool.');