@litfamily/litcodex 1.0.6 → 1.0.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +327 -23
- package/dist/cli.js +42 -0
- package/dist/config-migration/config-paths.js +9 -2
- package/dist/install/execute.d.ts +2 -0
- package/dist/install/execute.js +8 -3
- package/dist/install/generated-skill-payload-hashes.d.ts +617 -21
- package/dist/install/generated-skill-payload-hashes.js +617 -21
- package/dist/install/index.js +13 -2
- package/dist/install/marketplace-payload.d.ts +1 -0
- package/dist/install/marketplace-payload.js +73 -2
- package/dist/install/motion-runtime.d.ts +36 -0
- package/dist/install/motion-runtime.js +82 -0
- package/dist/install/office-runtime.d.ts +20 -0
- package/dist/install/office-runtime.js +37 -0
- package/dist/install/skill-catalog.d.ts +1 -1
- package/dist/install/skill-catalog.js +26 -2
- package/dist/install/skill-resource-hashes.d.ts +1 -1
- package/dist/install/skill-resource-hashes.js +1 -1
- package/dist/postinstall.js +14 -2
- package/marketplace/plugins/litcodex/.codex-plugin/plugin.json +1 -1
- package/marketplace/plugins/litcodex/components/auto-update/package.json +1 -1
- package/marketplace/plugins/litcodex/components/comment-checker/package.json +1 -1
- package/marketplace/plugins/litcodex/components/git-bash/package.json +1 -1
- package/marketplace/plugins/litcodex/components/lit-loop/directive.md +90 -5
- package/marketplace/plugins/litcodex/components/lit-loop/directives/lit-comprehend.md +13 -17
- package/marketplace/plugins/litcodex/components/lit-loop/directives/litwork.md +8 -0
- package/marketplace/plugins/litcodex/components/lit-loop/dist/codex-hook.js +8 -1
- package/marketplace/plugins/litcodex/components/lit-loop/dist/motion-route.d.ts +18 -0
- package/marketplace/plugins/litcodex/components/lit-loop/dist/motion-route.js +95 -0
- package/marketplace/plugins/litcodex/components/lit-loop/dist/skill-renames.d.ts +3 -1
- package/marketplace/plugins/litcodex/components/lit-loop/dist/skill-renames.js +10 -5
- package/marketplace/plugins/litcodex/components/lit-loop/package.json +1 -1
- package/marketplace/plugins/litcodex/components/lsp/package.json +1 -1
- package/marketplace/plugins/litcodex/components/rules/bundled-rules/lit-humanizer.md +12 -0
- package/marketplace/plugins/litcodex/components/rules/dist/cli.js +22 -10
- package/marketplace/plugins/litcodex/components/rules/dist/deliverable-hedge-guard.d.ts +23 -34
- package/marketplace/plugins/litcodex/components/rules/dist/deliverable-hedge-guard.js +420 -388
- package/marketplace/plugins/litcodex/components/rules/package.json +1 -1
- package/marketplace/plugins/litcodex/components/start-work-continuation/package.json +1 -1
- package/marketplace/plugins/litcodex/components/telemetry/package.json +1 -1
- package/marketplace/plugins/litcodex/components/wikify-knowledge/package.json +1 -1
- package/marketplace/plugins/litcodex/hooks/hooks.json +32 -21
- package/marketplace/plugins/litcodex/skills/autoconference/assets/report_template.md +1 -1
- package/marketplace/plugins/litcodex/skills/browser-drive/SKILL.md +4 -0
- package/marketplace/plugins/litcodex/skills/browser-drive/scripts/capability-probe.mjs +25 -2
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/SKILL.md +14 -15
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/THIRD-PARTY-NOTICE.txt +7 -0
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/examples/readme-ab/README.md +13 -0
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/adaptive-layout.md +12 -83
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/brand-and-imagery.md +17 -65
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/complete-contract.md +44 -13
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/composition.md +14 -80
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/craft-floor.md +103 -0
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/creative-directions.md +13 -82
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/evidence-review.md +14 -112
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/implementation-platforms.md +16 -68
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/inclusive-interface.md +12 -86
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/interaction-motion.md +13 -82
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/motion-guide.md +123 -0
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/operating-lanes.md +12 -100
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/performance-delivery.md +12 -78
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/probe-and-review.md +41 -0
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/product-direction.md +10 -88
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/production-interview.md +10 -12
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/redesign-playbook.md +12 -74
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/slop-register.md +98 -0
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/system-foundations.md +13 -100
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/visual-language.md +11 -74
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/references/visual-reconstruction.md +9 -78
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/scripts/hover-probe.mjs +28 -0
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/scripts/page-probe.mjs +423 -0
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/scripts/probe.mjs +261 -0
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/scripts/route-mode.mjs +19 -0
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/scripts/rule-data.mjs +115 -0
- package/marketplace/plugins/litcodex/skills/frontend-ui-ux/scripts/serve-static.mjs +24 -0
- package/marketplace/plugins/litcodex/skills/lit-comprehend/SKILL.md +45 -53
- package/marketplace/plugins/litcodex/skills/lit-comprehend/references/artifact-template.md +10 -44
- package/marketplace/plugins/litcodex/skills/lit-comprehend/scripts/verify-explainer.ts +0 -18
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/NOTICE +33 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/SKILL.md +167 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/agents/openai.yaml +6 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-architecture-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-architecture-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-architecture-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-bar-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-bar-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-bar-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-beeswarm-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-beeswarm-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-beeswarm-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-bubble-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-bubble-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-bubble-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-bump-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-bump-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-bump-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-data-flow-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-data-flow-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-data-flow-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-datalake-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-datalake-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-datalake-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-db-schema-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-db-schema-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-db-schema-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-dependency-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-dependency-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-dependency-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-deployment-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-deployment-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-deployment-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-dp-integration-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-dp-integration-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-dp-integration-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-dp-security-matrix-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-dp-security-matrix-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-dp-security-matrix-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-er-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-er-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-er-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-fishbone-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-fishbone-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-fishbone-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-flowchart-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-flowchart-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-flowchart-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-gantt-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-gantt-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-gantt-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-heatmap-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-heatmap-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-heatmap-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-high-level-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-high-level-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-high-level-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-high-level-vertical-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-high-level-vertical-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-high-level-vertical-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-import-drawio-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-import-drawio-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-import-drawio-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-import-excalidraw-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-import-excalidraw-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-import-excalidraw-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-import-mermaid-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-import-mermaid-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-import-mermaid-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-it-state-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-it-state-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-it-state-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-journey-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-journey-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-journey-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-kanban-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-kanban-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-kanban-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-layers-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-layers-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-layers-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-line-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-line-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-line-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-loop-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-loop-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-loop-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-loop-terminal-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-loop-terminal-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-loop-terminal-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-marimekko-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-marimekko-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-marimekko-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-medallion-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-medallion-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-medallion-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-nested-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-nested-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-nested-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-org-chart-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-org-chart-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-org-chart-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-paved-road-animated-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-paved-road-animated-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-paved-road-animated-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-polar-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-polar-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-polar-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-policy-trace-animated-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-policy-trace-animated-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-policy-trace-animated-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-process-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-process-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-process-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-pyramid-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-pyramid-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-pyramid-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-quadrant-consultant-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-quadrant-consultant-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-quadrant-consultant-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-quadrant-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-quadrant-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-quadrant-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-queue-animated-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-queue-animated-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-queue-animated-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-radar-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-radar-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-radar-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-ridgeline-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-ridgeline-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-ridgeline-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-sankey-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-sankey-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-sankey-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-scatter-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-scatter-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-scatter-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-sequence-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-sequence-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-sequence-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-sequence-oauth-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-sequence-oauth-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-sequence-oauth-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-slopegraph-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-slopegraph-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-slopegraph-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-state-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-state-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-state-lifecycle-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-state-lifecycle-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-state-lifecycle-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-state-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-story-map-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-story-map-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-story-map-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-streamgraph-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-streamgraph-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-streamgraph-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-swimlane-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-swimlane-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-swimlane-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-timeline-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-timeline-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-timeline-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-tree-block-decomposition-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-tree-block-decomposition-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-tree-block-decomposition-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-tree-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-tree-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-tree-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-treemap-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-treemap-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-treemap-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-uml-class-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-uml-class-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-uml-class-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-venn-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-venn-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-venn-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-wardley-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-wardley-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-wardley-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-waterfall-dark.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-waterfall-full.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/examples/type-waterfall-light.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/fonts/OFL.txt +94 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/fonts/PretendardVariable.woff2 +0 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/fonts/provenance.json +22 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/icons.html +231 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/index.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/licenses/devicon-MIT.txt +20 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/licenses/diagram-design-MIT.txt +21 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/licenses/log-z-MIT.txt +21 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/licenses/simple-icons-CC0.md +30 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/assets/licenses/tabler-MIT.txt +21 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/01-service-architecture/after.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/01-service-architecture/brief.md +33 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/01-service-architecture/constructed-naive-foil.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/02-release-decision/after.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/02-release-decision/brief.md +18 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/02-release-decision/constructed-naive-foil.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/03-data-retention/after.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/03-data-retention/brief.md +19 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/03-data-retention/constructed-naive-foil.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/04-oauth-sequence/after.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/04-oauth-sequence/brief.md +17 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/04-oauth-sequence/constructed-naive-foil.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/05-review-lanes/after.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/05-review-lanes/brief.md +17 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/05-review-lanes/constructed-naive-foil.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/06-rollout-gates/after.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/06-rollout-gates/brief.md +17 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/06-rollout-gates/constructed-naive-foil.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/07-deployment-boundary/after.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/07-deployment-boundary/brief.md +19 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/07-deployment-boundary/constructed-naive-foil.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/08-policy-traces/after.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/08-policy-traces/brief.md +20 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/examples/08-policy-traces/constructed-naive-foil.html +1 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/accessibility.md +37 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/export.md +29 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/import-drawio.md +21 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/import-excalidraw.md +14 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/import-mermaid.md +18 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/import-schema.md +28 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/korean-typography.md +34 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/motion.md +29 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/office-pptx-docx.md +42 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/output-spec.md +48 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/primitive-annotation.md +12 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/primitive-icons.md +21 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/primitive-sketchy.md +11 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/primitive-terminal.md +11 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/profiles.md +24 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/semantic-patterns.md +27 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/style-guide.md +67 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-architecture.md +51 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-bar.md +51 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-beeswarm.md +49 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-bubble.md +49 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-bump.md +49 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-catalog.json +1433 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-data-flow.md +51 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-datalake.md +49 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-db-schema.md +49 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-dependency.md +49 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-deployment.md +49 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-dp-integration.md +49 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-dp-security-matrix.md +49 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-er.md +49 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-fishbone.md +49 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-flowchart.md +49 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-gantt.md +49 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-heatmap.md +53 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-high-level-vertical.md +53 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-high-level.md +53 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-import-drawio.md +53 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-import-excalidraw.md +53 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-import-mermaid.md +53 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-it-state.md +54 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-journey.md +54 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-kanban.md +54 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-layers.md +54 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-line.md +54 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-loop-terminal.md +53 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-loop.md +54 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-marimekko.md +54 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-medallion.md +54 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-nested.md +59 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-org-chart.md +58 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-paved-road-animated.md +72 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-polar.md +67 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-policy-trace-animated.md +69 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-process.md +58 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-pyramid.md +59 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-quadrant-consultant.md +60 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-quadrant.md +57 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-queue-animated.md +63 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-radar.md +57 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-ridgeline.md +63 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-sankey.md +68 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-scatter.md +60 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-sequence-oauth.md +66 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-sequence.md +63 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-slopegraph.md +65 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-state-lifecycle.md +53 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-state.md +59 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-story-map.md +52 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-streamgraph.md +53 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-swimlane.md +52 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-timeline.md +52 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-tree-block-decomposition.md +57 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-tree.md +54 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-treemap.md +54 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-uml-class.md +52 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-venn.md +51 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-wardley.md +52 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/type-waterfall.md +54 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/references/verifier-guide.md +59 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/block-registry.mjs +43 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/brief-contract.mjs +94 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/check-visible-text.mjs +15 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/diagram-craft-rules.mjs +14 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/diagram-metrics.mjs +219 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/doctor.mjs +28 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/drawio-model.mjs +162 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/drawio-source.mjs +147 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/drawio-xml.mjs +148 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/export.mjs +122 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/import-common.mjs +85 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/import-drawio.mjs +48 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/import-excalidraw.mjs +234 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/import-mermaid.mjs +104 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/mermaid-common.mjs +115 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/mermaid-er.mjs +70 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/mermaid-flowchart.mjs +178 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/mermaid-sequence.mjs +137 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/mermaid-state.mjs +80 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/office-safety.mjs +54 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/runtime-probes.mjs +11 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/verify-all.mjs +85 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/verify-brief.mjs +16 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/verify-diagram.mjs +27 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/verify-motion.mjs +12 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/verify-type.mjs +48 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/visual-quality-geometry.mjs +226 -0
- package/marketplace/plugins/litcodex/skills/lit-diagram-drawer/scripts/visual-quality.mjs +147 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/LICENSE +21 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/NOTICE +3 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/SKILL.md +102 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/agents/openai.yaml +14 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/references/frontmatter_schema.md +42 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/references/journal_style_spec.md +17 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/references/markdown_quality_checklist.md +37 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/references/slop_phrase_list.yaml +58 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/references/slop_rules.md +35 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/runtime/requirements.in +5 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/runtime/requirements.lock +20 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/scripts/clean_markdown.py +95 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/scripts/convert_md_to_docx.py +1046 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/scripts/convert_md_to_pdf.py +281 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/scripts/convert_pdf.py +130 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/scripts/docx_craft.py +95 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/scripts/edit_docx.py +297 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/scripts/embed_images.py +78 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/scripts/generate_docx_templates.py +491 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/scripts/slop_lint.py +473 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/scripts/visual_audit.py +41 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/templates/docx/acs.docx +0 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/templates/docx/elsevier.docx +0 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/templates/docx/ieee.docx +0 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/templates/docx/korean-generic.docx +0 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/templates/docx/nature.docx +0 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/templates/latex/acs/README.md +5 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/templates/latex/acs/template.tex +37 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/templates/latex/elsevier/README.md +5 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/templates/latex/elsevier/template.tex +38 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/templates/latex/ieee/README.md +5 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/templates/latex/ieee/template.tex +37 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/templates/latex/korean-generic/README.md +5 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/templates/latex/korean-generic/template.tex +37 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/templates/latex/nature/README.md +5 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/templates/latex/nature/template.tex +37 -0
- package/marketplace/plugins/litcodex/skills/lit-docx/templates/registry.yaml +1366 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/NOTICE +160 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/SKILL.md +146 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/always-on-rule.md +9 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/assets/always-on-rule.md +9 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/assets/report-skeleton.md +25 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/assets/slide-text-skeleton.md +28 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/bench/prompts.md +73 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/accessibility-note/after.md +7 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/accessibility-note/before.md +7 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/api-reference/after.md +9 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/api-reference/before.md +15 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/changelog/after.md +5 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/changelog/before.md +12 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/code-comments/after.md +10 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/code-comments/before.md +19 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/commit/after.md +5 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/commit/before.md +7 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/data-release/after.md +7 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/data-release/before.md +9 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/english-essay/after.md +5 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/english-essay/before.md +5 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/incident-update/after.md +7 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/incident-update/before.md +7 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/ko-essay/after.md +7 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/ko-essay/before.md +9 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/ko-report/after.md +9 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/ko-report/before.md +13 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/ko-slide/after.md +19 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/ko-slide/before.md +21 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/meeting-brief/after.md +9 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/meeting-brief/before.md +11 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/policy-faq/after.md +9 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/policy-faq/before.md +9 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/pr/after.md +15 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/pr/before.md +17 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/project-update/after.md +7 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/project-update/before.md +9 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/readme/after.md +12 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/readme/before.md +14 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/report/after.md +13 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/report/before.md +11 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/research-abstract/after.md +5 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/research-abstract/before.md +5 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/slides/after.md +19 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/slides/before.md +19 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/troubleshooting/after.md +11 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/examples/troubleshooting/before.md +11 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/motion-guide.md +123 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/references/code-patterns.md +468 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/references/deliverable-channels.md +111 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/references/en-patterns-checklist.md +43 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/references/en-patterns-content.md +243 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/references/en-patterns-structure.md +375 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/references/en-patterns.md +57 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/references/ko-metrics.md +33 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/references/ko-patterns-a-d.md +659 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/references/ko-patterns-e-j.md +387 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/references/ko-patterns.md +31 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/references/prompt-injection-handling.md +7 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/references/rewrite-playbook.md +54 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/references/taxonomy.md +153 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/rules.json +884 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/scripts/core.mjs +208 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/scripts/detect.mjs +83 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/scripts/extract_office_text.py +89 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/scripts/ko-metrics.mjs +124 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/scripts/test-fixtures.mjs +155 -0
- package/marketplace/plugins/litcodex/skills/lit-humanizer/scripts/test-ko-metrics.mjs +27 -0
- package/marketplace/plugins/litcodex/skills/lit-init/references/deep-repository-map.md +6 -10
- package/marketplace/plugins/litcodex/skills/lit-loop/SKILL.md +95 -12
- package/marketplace/plugins/litcodex/skills/lit-loop/agents/openai.yaml +3 -2
- package/marketplace/plugins/litcodex/skills/lit-loop/references/full-workflow.md +10 -3
- package/marketplace/plugins/litcodex/skills/lit-pptx/NOTICE +7 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/SKILL.md +102 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/agents/analyst.md +49 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/agents/antithesis.md +59 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/agents/architect.md +44 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/agents/critic.md +42 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/agents/openai.yaml +14 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/agents/synthesizer.md +47 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/agents/thesis.md +33 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/assets/azure/circle-lg.png +0 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/assets/azure/circle-md.png +0 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/assets/azure/circle-sm.png +0 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/fonts/a2z-font/A2Z-Black.otf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/fonts/a2z-font/A2Z-Bold.otf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/fonts/a2z-font/A2Z-Light.otf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/fonts/a2z-font/A2Z-Medium.otf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/fonts/a2z-font/A2Z-Regular.otf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/fonts/a2z-font/OFL.txt +94 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/fonts/a2z-font/SOURCE.md +29 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/pretendard-font/LICENSE.txt +94 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/pretendard-font/public/static/PretendardGOV-Bold.otf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/pretendard-font/public/static/PretendardGOV-Regular.otf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/references/anti-slop-checklist.md +71 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/references/authoring-guide.md +141 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/references/consensus-protocol.md +125 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/references/data-display-cookbook.md +45 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/references/design-system-azure.md +58 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/references/interview-protocol.md +113 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/runtime/package-lock.json +747 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/runtime/package.json +13 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/runtime/requirements.in +2 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/runtime/requirements.lock +14 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/check_ooxml.py +40 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/compile-deck.js +399 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/craft_extras.py +246 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/embed_fonts.py +201 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/inventory.py +95 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/learn_template.py +433 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/lib/derive-palette.js +176 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/lib/directive-parser.js +244 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/lib/font-map.js +79 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/lib/gen-bg.js +85 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/lib/gen-gradient-assets.js +36 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/lib/layout-resolver.js +734 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/lib/markdown-loader.js +136 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/lib/render-adapter-html.js +358 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/lib/render-adapter-pptx.js +1885 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/lib/slide-ast.js +517 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/lib/spec-validator.js +94 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/lib/template-registry.js +355 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/office-run.mjs +137 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/package.json +1 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/qa_deck.py +795 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/scripts/validate_pptx.py +206 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/specs/markdown-slide-spec-v1.md +251 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/specs/markdown-slide-spec-v2.md +207 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/specs/slide-ast-v1.schema.json +229 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/specs/slide-ast-v2.schema.json +144 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/specs/template-enrollment-contract.md +379 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/templates/bauhaus_light.css +4 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/templates/boilerplate_professional.css +508 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/templates/enrolled/AZURE-A2Z/capabilities.yaml +146 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/templates/enrolled/AZURE-A2Z/layout-mapping.yaml +454 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/templates/enrolled/AZURE-A2Z/template.yaml +37 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/templates/enrolled/AZURE-PRO/capabilities.yaml +154 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/templates/enrolled/AZURE-PRO/layout-mapping.yaml +464 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/templates/enrolled/AZURE-PRO/template.yaml +37 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/templates/enrolled/BOILERPLATE-A2Z/capabilities.yaml +179 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/templates/enrolled/BOILERPLATE-A2Z/layout-mapping.yaml +299 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/templates/enrolled/BOILERPLATE-A2Z/template.yaml +45 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/templates/enrolled/BOILERPLATE-PRETENDARD/capabilities.yaml +181 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/templates/enrolled/BOILERPLATE-PRETENDARD/layout-mapping.yaml +299 -0
- package/marketplace/plugins/litcodex/skills/lit-pptx/templates/enrolled/BOILERPLATE-PRETENDARD/template.yaml +44 -0
- package/marketplace/plugins/litcodex/skills/lit-scientific-visualization/SKILL.md +2 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/SKILL.md +73 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/agents/openai.yaml +15 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/NOTICE +23 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/THIRD_PARTY_NOTICES +32 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/browser-app.js +735 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/completion.mjs +9 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/compose.mjs +255 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/constants.mjs +264 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/driver.mjs +169 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/encode.mjs +163 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/flash.mjs +251 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/fonts.mjs +169 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/gate.mjs +466 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/image.mjs +267 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/look.mjs +182 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/passes.mjs +181 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/presets.mjs +110 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/report.mjs +56 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/runtime.mjs +287 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/scenes.mjs +309 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/sound.mjs +463 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/stage-gate.mjs +155 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/stage-init.js +215 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/stage-kit.js +515 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/stage-qa.js +147 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/stage-qa.mjs +243 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/stage-render.mjs +335 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/stage-worker.mjs +26 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/stage.mjs +311 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/stroke.mjs +264 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/timeline.mjs +153 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/treatment.mjs +280 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/type.mjs +234 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/engine/util.mjs +198 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/archivo/Archivo-w100-wt400.ttf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/archivo/Archivo-w100-wt700.ttf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/archivo/Archivo-w100-wt900.ttf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/archivo/Archivo-w125-wt400.ttf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/archivo/Archivo-w125-wt700.ttf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/archivo/Archivo-w125-wt900.ttf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/archivo/Archivo-w75-wt400.ttf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/archivo/Archivo-w75-wt700.ttf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/archivo/Archivo-w75-wt900.ttf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/archivo/OFL.txt +93 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/archivo/SHA256SUMS +16 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/stroke/CREDITS +6 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/stroke/EMSAllure.svg +216 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/stroke/EMSFelix.svg +216 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/stroke/EMSOsmotron.svg +216 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/stroke/EMSReadability.svg +216 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/stroke/EMSTech.svg +217 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/stroke/OFL.txt +86 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/vt323/OFL.txt +93 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/fonts/vt323/VT323-Regular.ttf +0 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/references/quality-gate.md +137 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/references/runtime.md +68 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/references/scene-author.md +57 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/references/stage.md +175 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/references/style-bibles.md +103 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/references/treatment.md +119 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/references/type-and-timing.md +83 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/runtime/package-lock.json +59 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/runtime/package.json +1 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/runtime/requirements-audio.txt +1082 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/runtime/word-timing-models.json +11 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/scripts/beat-grid.py +50 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/scripts/render.mjs +807 -0
- package/marketplace/plugins/litcodex/skills/lit-typographic-motion/scripts/runtime.mjs +43 -0
- package/marketplace/plugins/litcodex/skills/litresearch/SKILL.md +28 -41
- package/marketplace/plugins/litcodex/skills/litwork/SKILL.md +8 -0
- package/marketplace/plugins/litcodex/skills/litwork/references/delivery-playbook.md +6 -0
- package/node_modules/@litcodex/lit-loop/directive.md +90 -5
- package/node_modules/@litcodex/lit-loop/directives/lit-comprehend.md +13 -17
- package/node_modules/@litcodex/lit-loop/directives/litwork.md +8 -0
- package/node_modules/@litcodex/lit-loop/dist/codex-hook.js +8 -1
- package/node_modules/@litcodex/lit-loop/dist/motion-route.d.ts +18 -0
- package/node_modules/@litcodex/lit-loop/dist/motion-route.js +95 -0
- package/node_modules/@litcodex/lit-loop/dist/skill-renames.d.ts +3 -1
- package/node_modules/@litcodex/lit-loop/dist/skill-renames.js +10 -5
- package/node_modules/@litcodex/lit-loop/package.json +1 -1
- package/node_modules/@litcodex/lit-loop/skills/browser-drive/SKILL.md +4 -0
- package/node_modules/@litcodex/lit-loop/skills/browser-drive/scripts/capability-probe.mjs +25 -2
- package/node_modules/@litcodex/lit-loop/skills/lit-comprehend/SKILL.md +45 -53
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/NOTICE +160 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/SKILL.md +146 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/always-on-rule.md +9 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/assets/always-on-rule.md +9 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/assets/report-skeleton.md +25 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/assets/slide-text-skeleton.md +28 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/bench/prompts.md +73 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/accessibility-note/after.md +7 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/accessibility-note/before.md +7 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/api-reference/after.md +9 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/api-reference/before.md +15 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/changelog/after.md +5 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/changelog/before.md +12 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/code-comments/after.md +10 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/code-comments/before.md +19 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/commit/after.md +5 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/commit/before.md +7 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/data-release/after.md +7 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/data-release/before.md +9 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/english-essay/after.md +5 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/english-essay/before.md +5 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/incident-update/after.md +7 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/incident-update/before.md +7 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/ko-essay/after.md +7 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/ko-essay/before.md +9 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/ko-report/after.md +9 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/ko-report/before.md +13 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/ko-slide/after.md +19 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/ko-slide/before.md +21 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/meeting-brief/after.md +9 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/meeting-brief/before.md +11 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/policy-faq/after.md +9 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/policy-faq/before.md +9 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/pr/after.md +15 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/pr/before.md +17 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/project-update/after.md +7 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/project-update/before.md +9 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/readme/after.md +12 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/readme/before.md +14 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/report/after.md +13 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/report/before.md +11 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/research-abstract/after.md +5 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/research-abstract/before.md +5 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/slides/after.md +19 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/slides/before.md +19 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/troubleshooting/after.md +11 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/examples/troubleshooting/before.md +11 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/motion-guide.md +123 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/references/code-patterns.md +468 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/references/deliverable-channels.md +111 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/references/en-patterns-checklist.md +43 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/references/en-patterns-content.md +243 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/references/en-patterns-structure.md +375 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/references/en-patterns.md +57 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/references/ko-metrics.md +33 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/references/ko-patterns-a-d.md +659 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/references/ko-patterns-e-j.md +387 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/references/ko-patterns.md +31 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/references/prompt-injection-handling.md +7 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/references/rewrite-playbook.md +54 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/references/taxonomy.md +153 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/rules.json +884 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/scripts/core.mjs +208 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/scripts/detect.mjs +83 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/scripts/extract_office_text.py +89 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/scripts/ko-metrics.mjs +124 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/scripts/test-fixtures.mjs +155 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-humanizer/scripts/test-ko-metrics.mjs +27 -0
- package/node_modules/@litcodex/lit-loop/skills/lit-init/references/deep-repository-map.md +6 -10
- package/node_modules/@litcodex/lit-loop/skills/lit-loop/SKILL.md +95 -12
- package/node_modules/@litcodex/lit-loop/skills/lit-scientific-visualization/SKILL.md +2 -0
- package/node_modules/@litcodex/lit-loop/skills/litresearch/SKILL.md +28 -41
- package/node_modules/@litcodex/lit-loop/skills/litwork/SKILL.md +8 -0
- package/package.json +3 -3
- package/readme-assets/ab-simple/assets/s11-baseline-desktop.webp +0 -0
- package/readme-assets/ab-simple/assets/s11-baseline-phone.webp +0 -0
- package/readme-assets/ab-simple/assets/s11-lit-desktop.webp +0 -0
- package/readme-assets/ab-simple/assets/s11-lit-phone.webp +0 -0
- package/readme-assets/ab-simple/assets/s3-baseline-desktop.webp +0 -0
- package/readme-assets/ab-simple/assets/s3-baseline-phone.webp +0 -0
- package/readme-assets/ab-simple/assets/s3-lit-desktop.webp +0 -0
- package/readme-assets/ab-simple/assets/s3-lit-phone.webp +0 -0
- package/readme-assets/ab-simple/assets/s4-baseline-desktop.webp +0 -0
- package/readme-assets/ab-simple/assets/s4-baseline-phone.webp +0 -0
- package/readme-assets/ab-simple/assets/s4-lit-desktop.webp +0 -0
- package/readme-assets/ab-simple/assets/s4-lit-phone.webp +0 -0
- package/readme-assets/ab-simple/assets/s5-baseline-slides.webp +0 -0
- package/readme-assets/ab-simple/assets/s5-lit-slides.webp +0 -0
- package/readme-assets/ab-simple/assets/s7-lit-diagram.webp +0 -0
- package/readme-assets/ab-simple/assets/s8-baseline-slides.webp +0 -0
- package/readme-assets/ab-simple/assets/s8-lit-slides.webp +0 -0
- package/readme-assets/ab-simple/assets/s9-lit-pages.webp +0 -0
- package/readme-assets/badge-version.svg +1 -1
- package/readme-assets/cover-motion-still.webp +0 -0
- package/readme-assets/cover-motion.webp +0 -0
- package/readme-assets/skills/autoconference.webp +0 -0
- package/readme-assets/skills/automatic-checks.webp +0 -0
- package/readme-assets/skills/autoresearch.webp +0 -0
- package/readme-assets/skills/browser-drive.webp +0 -0
- package/readme-assets/skills/coding-session-audit.webp +0 -0
- package/readme-assets/skills/debugging.webp +0 -0
- package/readme-assets/skills/deep-interview.webp +0 -0
- package/readme-assets/skills/frontend-ui-ux.webp +0 -0
- package/readme-assets/skills/lit-burnoff-file.webp +0 -0
- package/readme-assets/skills/lit-burnoff.webp +0 -0
- package/readme-assets/skills/lit-code.webp +0 -0
- package/readme-assets/skills/lit-commit.webp +0 -0
- package/readme-assets/skills/lit-comprehend.webp +0 -0
- package/readme-assets/skills/lit-crucible.webp +0 -0
- package/readme-assets/skills/lit-diagram-drawer.webp +0 -0
- package/readme-assets/skills/lit-docx.webp +0 -0
- package/readme-assets/skills/lit-fetch.webp +0 -0
- package/readme-assets/skills/lit-handoff.webp +0 -0
- package/readme-assets/skills/lit-humanizer.webp +0 -0
- package/readme-assets/skills/lit-init.webp +0 -0
- package/readme-assets/skills/lit-loop.webp +0 -0
- package/readme-assets/skills/lit-plan.webp +0 -0
- package/readme-assets/skills/lit-pptx.webp +0 -0
- package/readme-assets/skills/lit-recap.webp +0 -0
- package/readme-assets/skills/lit-scientific-visualization.webp +0 -0
- package/readme-assets/skills/lit-team.webp +0 -0
- package/readme-assets/skills/lit-typographic-motion.webp +0 -0
- package/readme-assets/skills/litcodex-contribute-bug-fix.webp +0 -0
- package/readme-assets/skills/litcodex-doctor.webp +0 -0
- package/readme-assets/skills/litcodex-report-bug.webp +0 -0
- package/readme-assets/skills/litgoal.webp +0 -0
- package/readme-assets/skills/litresearch.webp +0 -0
- package/readme-assets/skills/litwork.webp +0 -0
- package/readme-assets/skills/lsp-setup.webp +0 -0
- package/readme-assets/skills/readme-studio.webp +0 -0
- package/readme-assets/skills/refactor.webp +0 -0
- package/readme-assets/skills/review-work.webp +0 -0
- package/readme-assets/skills/start-approved-plan.webp +0 -0
- package/readme-assets/skills/structural-search.webp +0 -0
- package/readme-assets/skills/visual-qa.webp +0 -0
- package/readme-assets/skills/wikify.webp +0 -0
- package/marketplace/plugins/litcodex/skills/lit-korean/SKILL.md +0 -206
- package/marketplace/plugins/litcodex/skills/lit-korean/references/prompt-injection-handling.md +0 -23
- package/marketplace/plugins/litcodex/skills/lit-korean/references/quick-rules.md +0 -38
- package/marketplace/plugins/litcodex/skills/lit-korean/references/safety-checklist.md +0 -38
- package/node_modules/@litcodex/lit-loop/skills/lit-korean/SKILL.md +0 -206
- package/node_modules/@litcodex/lit-loop/skills/lit-korean/references/prompt-injection-handling.md +0 -23
- package/node_modules/@litcodex/lit-loop/skills/lit-korean/references/quick-rules.md +0 -38
- package/node_modules/@litcodex/lit-loop/skills/lit-korean/references/safety-checklist.md +0 -38
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
// Brief -> timeline. Tier 1 paces every unit at 1.25x the one reading floor and snaps each cut
|
|
2
|
+
// forward onto the beat grid (default 100 BPM); Tier 2 snaps the same holds onto a librosa beat
|
|
3
|
+
// grid produced for this run's own audio. The anchor-and-snap method is re-implemented generically
|
|
4
|
+
// against the brief's own text (MO-A-06); nothing here encodes another film's edit list.
|
|
5
|
+
import { FRAME, READING, TIMING } from "./constants.mjs";
|
|
6
|
+
import { countUnits, eojeols, readingFloor, scriptOf, smart } from "./type.mjs";
|
|
7
|
+
|
|
8
|
+
export const SCENE_IDS = Object.freeze(["title-slam", "word-line", "kinetic-list", "number-counter", "stroke-signature", "end-card"]);
|
|
9
|
+
const LIST_SPLIT = /\s+[·•|/]\s+|[,;]\s+/u;
|
|
10
|
+
|
|
11
|
+
function lineText(item) {
|
|
12
|
+
return typeof item === "string" ? item : String(item?.text ?? "");
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
/** Validate and normalise a user brief into lines with scene assignments. */
|
|
16
|
+
export function normalizeBrief(raw) {
|
|
17
|
+
if (!raw || typeof raw !== "object") throw new Error("brief must be a JSON object");
|
|
18
|
+
const lines = (Array.isArray(raw.lines) ? raw.lines : []).map((item) => ({
|
|
19
|
+
text: smart(lineText(item)).trim(),
|
|
20
|
+
scene: typeof item === "object" && item ? item.scene : undefined,
|
|
21
|
+
accent: typeof item === "object" && item ? item.accent === true : false,
|
|
22
|
+
font: typeof item === "object" && item ? item.font : undefined,
|
|
23
|
+
}));
|
|
24
|
+
if (lines.length === 0 && raw.title) lines.push({ text: smart(String(raw.title)).trim() });
|
|
25
|
+
if (lines.length === 0) throw new Error('brief needs "lines" (one to eight strings) or a "title"');
|
|
26
|
+
if (lines.length > 8) throw new Error("brief has more than eight lines; split the film");
|
|
27
|
+
for (const line of lines) {
|
|
28
|
+
if (!line.text) throw new Error("brief contains an empty line");
|
|
29
|
+
if (Array.from(line.text).length > 160) throw new Error(`line longer than 160 characters: ${line.text.slice(0, 40)}…`);
|
|
30
|
+
if (line.scene !== undefined && !SCENE_IDS.includes(line.scene)) throw new Error(`unknown scene "${line.scene}" (choose ${SCENE_IDS.join(", ")})`);
|
|
31
|
+
}
|
|
32
|
+
const bpm = raw.bpm === undefined ? TIMING.defaultBpm : Number(raw.bpm);
|
|
33
|
+
if (!Number.isFinite(bpm) || bpm < TIMING.minBpm || bpm > TIMING.maxBpm) throw new Error(`bpm must be ${TIMING.minBpm}..${TIMING.maxBpm}`);
|
|
34
|
+
const seed = raw.seed === undefined ? TIMING.defaultSeed : Number(raw.seed);
|
|
35
|
+
if (!Number.isInteger(seed) || seed < 0 || seed > 0xffffffff) throw new Error("seed must be an unsigned 32-bit integer");
|
|
36
|
+
const durationSec = raw.durationSec === undefined ? 0 : Number(raw.durationSec);
|
|
37
|
+
if (!Number.isFinite(durationSec) || durationSec < 0 || durationSec > 180) throw new Error("durationSec must be 0..180");
|
|
38
|
+
assignScenes(lines);
|
|
39
|
+
const filmName = raw.filmName === undefined || raw.filmName === null || raw.filmName === "" ? null : smart(String(raw.filmName)).trim();
|
|
40
|
+
return { title: raw.title ? smart(String(raw.title)) : lines[0].text, filmName, showIndex: raw.showIndex === true, mood: raw.mood ?? "", preset: raw.preset, presetSource: raw.presetSource === "user" ? "user" : "agent", lines, bpm, seed, durationSec };
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
function assignScenes(lines) {
|
|
44
|
+
const n = lines.length;
|
|
45
|
+
lines.forEach((line, i) => {
|
|
46
|
+
if (line.scene) return;
|
|
47
|
+
if (i === 0) line.scene = "title-slam";
|
|
48
|
+
else if (i === n - 1 && n >= 3) line.scene = "end-card";
|
|
49
|
+
else if (line.text.split(LIST_SPLIT).filter(Boolean).length >= 3) line.scene = "kinetic-list";
|
|
50
|
+
else if (/^\D{0,24}\d[\d,]*(?:\.\d+)?\D{0,40}$/u.test(line.text) && eojeols(line.text).length <= 5) line.scene = "number-counter";
|
|
51
|
+
else line.scene = "word-line";
|
|
52
|
+
});
|
|
53
|
+
for (const line of lines) {
|
|
54
|
+
if (line.scene === "stroke-signature" && scriptOf(line.text) !== "latin") line.scene = "word-line";
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
/** The reveal units inside a shot: whole 어절/words for a karaoke line, whole items for a list. */
|
|
59
|
+
export function revealUnits(line) {
|
|
60
|
+
if (line.scene === "word-line") return eojeols(line.text);
|
|
61
|
+
if (line.scene === "kinetic-list") return line.text.split(LIST_SPLIT).map((item) => item.trim()).filter(Boolean);
|
|
62
|
+
return [];
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
/** Seconds a shot needs before snapping: 1.25x its floor, and room for its reveal steps. */
|
|
66
|
+
function shotNeed(line) {
|
|
67
|
+
const floor = readingFloor(line.text, "line");
|
|
68
|
+
const units = revealUnits(line);
|
|
69
|
+
const revealRoom = units.length ? (units.length * TIMING.paceFactor * READING.revealFloor) / 0.7 : 0;
|
|
70
|
+
const { C } = countUnits(line.text);
|
|
71
|
+
const cpsRoom = (C / READING.maxLatinCps) * TIMING.paceFactor;
|
|
72
|
+
const signature = line.scene === "stroke-signature" ? 2.4 : 0;
|
|
73
|
+
return Math.max(TIMING.paceFactor * floor, revealRoom, cpsRoom, signature);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
/**
|
|
77
|
+
* Build the canonical timeline (spec §A10). `beatGrid` (Tier 2) is an ascending array of beat
|
|
78
|
+
* seconds; without it the grid is regular at `bpm`.
|
|
79
|
+
*/
|
|
80
|
+
export function buildTimeline(brief, { beatGrid = null, fps = FRAME.fps } = {}) {
|
|
81
|
+
const beat = 60 / brief.bpm;
|
|
82
|
+
const beatAt = (k) => {
|
|
83
|
+
if (!beatGrid) return k * beat;
|
|
84
|
+
if (k < beatGrid.length) return beatGrid[k];
|
|
85
|
+
const tail = beatGrid.length > 1 ? beatGrid[beatGrid.length - 1] - beatGrid[beatGrid.length - 2] : beat;
|
|
86
|
+
return beatGrid[beatGrid.length - 1] + (k - beatGrid.length + 1) * tail;
|
|
87
|
+
};
|
|
88
|
+
const needs = brief.lines.map(shotNeed);
|
|
89
|
+
const beats = [];
|
|
90
|
+
let index = 0;
|
|
91
|
+
for (const need of needs) {
|
|
92
|
+
let end = index + TIMING.minSceneBeats;
|
|
93
|
+
while (beatAt(end) - beatAt(index) < need - 1e-9) end++;
|
|
94
|
+
beats.push([index, end]);
|
|
95
|
+
index = end;
|
|
96
|
+
}
|
|
97
|
+
const target = brief.durationSec;
|
|
98
|
+
let extra = 0;
|
|
99
|
+
while (target > 0 && beatAt(beats[beats.length - 1][1]) < target - 1e-9) {
|
|
100
|
+
const shot = extra % beats.length;
|
|
101
|
+
beats[shot][1] += 1;
|
|
102
|
+
for (let j = shot + 1; j < beats.length; j++) {
|
|
103
|
+
beats[j][0] += 1;
|
|
104
|
+
beats[j][1] += 1;
|
|
105
|
+
}
|
|
106
|
+
extra++;
|
|
107
|
+
}
|
|
108
|
+
const shotCounts = new Map();
|
|
109
|
+
const timeline = [];
|
|
110
|
+
const shots = [];
|
|
111
|
+
brief.lines.forEach((line, i) => {
|
|
112
|
+
const [b0, b1] = beats[i];
|
|
113
|
+
const start = i === 0 ? 0 : round(beatAt(b0));
|
|
114
|
+
const end = round(beatAt(b1));
|
|
115
|
+
const shotIndex = shotCounts.get(line.scene) ?? 0;
|
|
116
|
+
shotCounts.set(line.scene, shotIndex + 1);
|
|
117
|
+
const id = `s${i + 1}-${line.scene}`;
|
|
118
|
+
const entry = { id, sceneId: line.scene, shotIndex, start, end, holdSec: round(end - start), kind: "line", text: line.text, script: scriptOf(line.text), beatSec: round(beatAt(b0)) };
|
|
119
|
+
timeline.push(entry);
|
|
120
|
+
const units = revealUnits(line);
|
|
121
|
+
const reveals = [];
|
|
122
|
+
if (units.length) {
|
|
123
|
+
const span = (end - start) * 0.7;
|
|
124
|
+
const step = Math.max(READING.revealFloor * TIMING.paceFactor, span / units.length);
|
|
125
|
+
units.forEach((text, k) => {
|
|
126
|
+
const rs = round(start + k * step);
|
|
127
|
+
const re = k === units.length - 1 ? end : round(start + (k + 1) * step);
|
|
128
|
+
const unit = { id: `${id}/r${k}`, sceneId: line.scene, shotIndex, start: rs, end: re, holdSec: round(re - rs), kind: "reveal", text, script: scriptOf(text), beatSec: round(beatAt(nearestBeatIndex(beatAt, rs))) };
|
|
129
|
+
timeline.push(unit);
|
|
130
|
+
reveals.push(unit);
|
|
131
|
+
});
|
|
132
|
+
}
|
|
133
|
+
shots.push({ ...entry, line, reveals, beat: round(beatAt(b0 + 1) - beatAt(b0)), frameStart: Math.round(start * fps), frameEnd: Math.round(end * fps) - 1 });
|
|
134
|
+
});
|
|
135
|
+
const durationSec = round(beatAt(beats[beats.length - 1][1]));
|
|
136
|
+
return { timeline, shots, durationSec, bpm: beatGrid ? null : brief.bpm, beatGrid: beatGrid ? [...beatGrid] : null, fps, totalFrames: Math.round(durationSec * fps) };
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
function nearestBeatIndex(beatAt, t) {
|
|
140
|
+
let k = 0;
|
|
141
|
+
while (beatAt(k + 1) <= t + 1e-9) k++;
|
|
142
|
+
return k;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
const round = (value) => Math.round(value * 1e6) / 1e6;
|
|
146
|
+
|
|
147
|
+
/** The accent moment: the one timeline entry allowed to show the preset's accent (MO-C-29). */
|
|
148
|
+
export function accentShot(shots) {
|
|
149
|
+
const flagged = shots.find((shot) => shot.line.accent);
|
|
150
|
+
if (flagged) return flagged.id;
|
|
151
|
+
const end = shots.find((shot) => shot.sceneId === "end-card");
|
|
152
|
+
return (end ?? shots[shots.length - 1]).id;
|
|
153
|
+
}
|
|
@@ -0,0 +1,280 @@
|
|
|
1
|
+
// The treatment is the film's plan, written before any render on both paths. This validator runs
|
|
2
|
+
// before every render (stills-only too). Any fault throws TreatmentError with the field name; the
|
|
3
|
+
// CLI turns it into exit 16 BLOCKED_TREATMENT_INVALID. It checks structure and the anti-restatement
|
|
4
|
+
// rules, never taste: taste is the look rounds' job.
|
|
5
|
+
import { existsSync, readdirSync, readFileSync } from "node:fs";
|
|
6
|
+
import { join } from "node:path";
|
|
7
|
+
import { SOUND_PALETTES } from "./constants.mjs";
|
|
8
|
+
import { FONTS, SKILL_ROOT } from "./fonts.mjs";
|
|
9
|
+
|
|
10
|
+
export class TreatmentError extends Error {
|
|
11
|
+
constructor(field, message) {
|
|
12
|
+
super(`${field}: ${message}`);
|
|
13
|
+
this.field = field;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export const GENRES = Object.freeze(["announcement", "brand-mood", "event", "explainer", "motion-graphics", "type-led", "other"]);
|
|
18
|
+
// Minimum beat count per genre: the stage count of its arc (references/treatment.md).
|
|
19
|
+
export const ARC_STAGES = Object.freeze({ announcement: 5, "brand-mood": 4, event: 4, explainer: 4, "motion-graphics": 5, other: 3 });
|
|
20
|
+
const LONG_GENRES = new Set(["announcement", "event", "explainer", "motion-graphics"]);
|
|
21
|
+
export const DEVICE_KINDS = Object.freeze(["illustration", "diagram", "chart", "icon", "shape", "path", "mask", "depth3d", "particles", "grid", "gradient", "photo-texture"]);
|
|
22
|
+
const TEXTURE_KINDS = new Set(["grid", "gradient", "particles", "photo-texture"]);
|
|
23
|
+
export const FACES = Object.freeze([...new Set(FONTS.map((font) => font.family))]);
|
|
24
|
+
const MIN_BEAT_SEC = 1.2;
|
|
25
|
+
const MAX_GAP_SEC = 0.25;
|
|
26
|
+
|
|
27
|
+
const LENGTH_ASKED = /\d+(?:\.\d+)?\s*(?:초|분|s\b|secs?\b|seconds?\b|min(?:ute)?s?\b)/iu;
|
|
28
|
+
const SILENCE_ASKED = /무음|소리\s*없|음악\s*없|\bsilent\b|\bsilence\b|\bno\s+(?:sound|audio|music)\b|\bwithout\s+(?:sound|audio|music)\b|\bmuted?\b/iu;
|
|
29
|
+
const MUTED_CHANNEL = /무음|소리\s*없|\bmuted?\b|\bsilent\b|\bsound\s*off\b/iu;
|
|
30
|
+
const PLACEHOLDER = /<[^<>\n]{1,80}>/u;
|
|
31
|
+
const QUOTED = /"[^"\n]*"|“[^”\n]*”|'[^'\n]*'|「[^」\n]*」/gu;
|
|
32
|
+
const TYPE_CUE = /\bkinetic[\s-]+type(?:graphy)?\b|\btypographic[\s-]+motion\b|\blyrics?\b|\blyric[\s-]+videos?\b|\btitle[\s-]+sequences?\b|\bopening[\s-]+titles?\b|키네틱\s*타이포|타이포|가사|오프닝\s*타이틀|타이틀\s*시퀀스/iu;
|
|
33
|
+
|
|
34
|
+
/** NFC, lowercase, then no whitespace and no punctuation or symbols. */
|
|
35
|
+
export function normalizeText(text) {
|
|
36
|
+
return String(text).normalize("NFC").toLowerCase().replace(/[\s\p{P}\p{S}]+/gu, "");
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
export const stripQuoted = (text) => String(text).replace(QUOTED, " ");
|
|
40
|
+
|
|
41
|
+
/** A type-led cue in the request: a type compound or word, or a quoted span of two or more words. */
|
|
42
|
+
export function typeLedCue(request) {
|
|
43
|
+
const text = String(request);
|
|
44
|
+
const word = TYPE_CUE.exec(text)?.[0];
|
|
45
|
+
if (word) return word;
|
|
46
|
+
for (const match of text.matchAll(QUOTED)) if (match[0].slice(1, -1).trim().split(/\s+/u).filter(Boolean).length >= 2) return "quoted span";
|
|
47
|
+
return null;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
/** True when `candidate` shares a normalized substring of `limit` characters with `against`. */
|
|
51
|
+
function sharesRun(candidate, against, limit) {
|
|
52
|
+
if (limit < 1) return false;
|
|
53
|
+
const a = Array.from(normalizeText(candidate));
|
|
54
|
+
const b = normalizeText(against);
|
|
55
|
+
for (let i = 0; i + limit <= a.length; i++) if (b.includes(a.slice(i, i + limit).join(""))) return true;
|
|
56
|
+
return false;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
const isText = (value) => typeof value === "string" && value.trim().length > 0;
|
|
60
|
+
const sentences = (text) => String(text).trim().split(/(?<=[.!?。])\s+(?=\S)/u).filter(Boolean).length;
|
|
61
|
+
|
|
62
|
+
function requireText(t, field, value = t[field]) {
|
|
63
|
+
if (value === undefined || value === null) throw new TreatmentError(field, "missing");
|
|
64
|
+
if (!isText(value)) throw new TreatmentError(field, "must be a non-empty string");
|
|
65
|
+
return value;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
/** Every string leaf that still holds an example placeholder such as "<one sentence>". */
|
|
69
|
+
function findPlaceholder(value, path) {
|
|
70
|
+
if (typeof value === "string") return PLACEHOLDER.test(value) ? path : null;
|
|
71
|
+
if (Array.isArray(value)) {
|
|
72
|
+
for (let i = 0; i < value.length; i++) {
|
|
73
|
+
const hit = findPlaceholder(value[i], `${path}[${i}]`);
|
|
74
|
+
if (hit) return hit;
|
|
75
|
+
}
|
|
76
|
+
return null;
|
|
77
|
+
}
|
|
78
|
+
if (value && typeof value === "object") {
|
|
79
|
+
for (const [key, child] of Object.entries(value)) {
|
|
80
|
+
const hit = findPlaceholder(child, path ? `${path}.${key}` : key);
|
|
81
|
+
if (hit) return hit;
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
return null;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
/** Free-text leaves compared for copiedExample, as [field kind, normalized value] pairs. */
|
|
88
|
+
export function freeTextLeaves(t) {
|
|
89
|
+
const leaves = [];
|
|
90
|
+
const put = (kind, value) => {
|
|
91
|
+
if (typeof value === "string" && normalizeText(value)) leaves.push([kind, normalizeText(value)]);
|
|
92
|
+
};
|
|
93
|
+
put("idea", t?.idea);
|
|
94
|
+
put("audience", t?.audience);
|
|
95
|
+
put("channel", t?.channel);
|
|
96
|
+
put("ambition", t?.ambition);
|
|
97
|
+
for (const beat of Array.isArray(t?.beats) ? t.beats : []) for (const key of ["purpose", "onScreen", "motion", "sound"]) put(`beats[].${key}`, beat?.[key]);
|
|
98
|
+
for (const line of Array.isArray(t?.copy?.lines) ? t.copy.lines : []) put("copy.lines[]", line);
|
|
99
|
+
for (const entry of Array.isArray(t?.palette) ? t.palette : []) put("palette[].role", entry?.role);
|
|
100
|
+
return leaves;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
/** The JSON examples shipped in this skill's references (any fenced json block with a genre). */
|
|
104
|
+
export function shippedExamples(root = SKILL_ROOT) {
|
|
105
|
+
const dir = join(root, "references");
|
|
106
|
+
if (!existsSync(dir)) return [];
|
|
107
|
+
const examples = [];
|
|
108
|
+
for (const name of readdirSync(dir).filter((n) => n.endsWith(".md")).sort()) {
|
|
109
|
+
for (const block of readFileSync(join(dir, name), "utf8").matchAll(/```json\n([\s\S]*?)```/gu)) {
|
|
110
|
+
try {
|
|
111
|
+
const value = JSON.parse(block[1]);
|
|
112
|
+
if (value && typeof value === "object" && "genre" in value) examples.push(value);
|
|
113
|
+
} catch {
|
|
114
|
+
// A non-JSON snippet is documentation, not an example treatment.
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
return examples;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
function copiedFrom(t, examples) {
|
|
122
|
+
const mine = freeTextLeaves(t);
|
|
123
|
+
if (mine.length === 0) return false;
|
|
124
|
+
for (const example of examples) {
|
|
125
|
+
const theirs = new Set(freeTextLeaves(example).map(([kind, value]) => `${kind}\u0000${value}`));
|
|
126
|
+
const equal = mine.filter(([kind, value]) => theirs.has(`${kind}\u0000${value}`)).length;
|
|
127
|
+
if (equal * 2 >= mine.length) return true;
|
|
128
|
+
}
|
|
129
|
+
return false;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
/** Seconds of the film covered by the union of the listed beats. */
|
|
133
|
+
function beatCoverage(beats, indices) {
|
|
134
|
+
const spans = [...new Set(indices)].filter((i) => Number.isInteger(i) && beats[i]).map((i) => [beats[i].t0, beats[i].t1]).sort((a, b) => a[0] - b[0]);
|
|
135
|
+
let total = 0;
|
|
136
|
+
let end = Number.NEGATIVE_INFINITY;
|
|
137
|
+
for (const [a, b] of spans) {
|
|
138
|
+
if (b <= end) continue;
|
|
139
|
+
total += b - Math.max(a, end);
|
|
140
|
+
end = b;
|
|
141
|
+
}
|
|
142
|
+
return total;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
/**
|
|
146
|
+
* Validate a parsed treatment. Returns it unchanged when valid; throws TreatmentError otherwise.
|
|
147
|
+
* Field order follows references/treatment.md so the first reported field is the first to fix.
|
|
148
|
+
*/
|
|
149
|
+
export function validateTreatment(t, { examples = shippedExamples() } = {}) {
|
|
150
|
+
if (!t || typeof t !== "object" || Array.isArray(t)) throw new TreatmentError("treatment", "must be a JSON object");
|
|
151
|
+
const placeholder = findPlaceholder(t, "");
|
|
152
|
+
if (placeholder) throw new TreatmentError(placeholder, "still holds an example placeholder (<...>); write the real value");
|
|
153
|
+
if (examples.length && copiedFrom(t, examples)) throw new TreatmentError("copiedExample", "half or more of the free-text fields equal a shipped example; write this film's own treatment");
|
|
154
|
+
|
|
155
|
+
const request = requireText(t, "request");
|
|
156
|
+
const unquoted = normalizeText(stripQuoted(request));
|
|
157
|
+
const limit = Math.min(10, Math.floor(Array.from(unquoted).length / 2));
|
|
158
|
+
if (!GENRES.includes(t.genre)) throw new TreatmentError("genre", t.genre === undefined ? "missing" : `must be one of ${GENRES.join(", ")}`);
|
|
159
|
+
if (!["type", "stage"].includes(t.path)) throw new TreatmentError("path", t.path === undefined ? "missing" : "must be type or stage");
|
|
160
|
+
requireText(t, "pathReason");
|
|
161
|
+
const idea = requireText(t, "idea");
|
|
162
|
+
if (sentences(idea) > 1) throw new TreatmentError("idea", "must be one sentence");
|
|
163
|
+
if (sharesRun(idea, stripQuoted(request), limit)) throw new TreatmentError("idea", `restates the request (shares ${limit}+ normalized characters with it); say what the film shows instead`);
|
|
164
|
+
requireText(t, "audience");
|
|
165
|
+
requireText(t, "channel");
|
|
166
|
+
if (!["16:9", "9:16"].includes(t.format)) throw new TreatmentError("format", t.format === undefined ? "missing" : "must be 16:9 or 9:16");
|
|
167
|
+
requireText(t, "formatReason");
|
|
168
|
+
|
|
169
|
+
if (t.durationSec === undefined) throw new TreatmentError("durationSec", "missing");
|
|
170
|
+
if (typeof t.durationSec !== "number" || !Number.isFinite(t.durationSec) || t.durationSec < 4 || t.durationSec > 90) throw new TreatmentError("durationSec", "must be a number of seconds from 4 to 90");
|
|
171
|
+
if (LONG_GENRES.has(t.genre) && t.durationSec < 10 && !LENGTH_ASKED.test(request)) throw new TreatmentError("durationSec", `a ${t.genre} film runs at least 10 s unless the user asked for a length; the arc needs the room`);
|
|
172
|
+
|
|
173
|
+
if (t.subject === undefined) throw new TreatmentError("subject", "missing");
|
|
174
|
+
if (!t.subject || typeof t.subject !== "object") throw new TreatmentError("subject", "must be {name, source, specifics[]}");
|
|
175
|
+
requireText(t, "subject.name", t.subject.name);
|
|
176
|
+
if (!["user", "invented"].includes(t.subject.source)) throw new TreatmentError("subject.source", "must be user or invented");
|
|
177
|
+
if (!Array.isArray(t.subject.specifics) || t.subject.specifics.some((s) => !isText(s))) throw new TreatmentError("subject.specifics", "must be an array of concrete specifics");
|
|
178
|
+
if (t.subject.source === "invented" && t.subject.specifics.length < 2) throw new TreatmentError("subject.specifics", "an invented subject needs at least 2 concrete specifics (what it is or does, for whom, one distinctive detail)");
|
|
179
|
+
|
|
180
|
+
if (t.copy === undefined) throw new TreatmentError("copy", "missing");
|
|
181
|
+
if (!t.copy || !["user", "invented"].includes(t.copy.source)) throw new TreatmentError("copy.source", "must be user or invented");
|
|
182
|
+
if (!Array.isArray(t.copy.lines) || t.copy.lines.length === 0) throw new TreatmentError("copy.lines", "must list at least one line");
|
|
183
|
+
const wholeRequest = normalizeText(request);
|
|
184
|
+
t.copy.lines.forEach((line, i) => {
|
|
185
|
+
const field = `copy.lines[${i}]`;
|
|
186
|
+
if (!isText(line)) throw new TreatmentError(field, "must be a non-empty string");
|
|
187
|
+
if (t.copy.source === "user" && !wholeRequest.includes(normalizeText(line))) throw new TreatmentError(field, "copy.source is user, but this line is not in the request");
|
|
188
|
+
if (t.copy.source === "invented" && sharesRun(line, stripQuoted(request), limit)) throw new TreatmentError(field, "invented copy restates the request; write it from subject.specifics");
|
|
189
|
+
});
|
|
190
|
+
|
|
191
|
+
if (t.beats === undefined) throw new TreatmentError("beats", "missing");
|
|
192
|
+
if (!Array.isArray(t.beats) || t.beats.length === 0) throw new TreatmentError("beats", "must be a non-empty array");
|
|
193
|
+
t.beats.forEach((beat, i) => {
|
|
194
|
+
const field = `beats[${i}]`;
|
|
195
|
+
if (!beat || typeof beat !== "object") throw new TreatmentError(field, "must be {t0, t1, purpose, onScreen, motion, sound}");
|
|
196
|
+
for (const key of ["t0", "t1"]) if (typeof beat[key] !== "number" || !Number.isFinite(beat[key])) throw new TreatmentError(`${field}.${key}`, "must be a number of seconds");
|
|
197
|
+
for (const key of ["purpose", "onScreen", "motion", "sound"]) requireText(t, `${field}.${key}`, beat[key]);
|
|
198
|
+
if (beat.t1 - beat.t0 < MIN_BEAT_SEC - 1e-9) throw new TreatmentError(field, `lasts ${(beat.t1 - beat.t0).toFixed(2)} s; every beat is at least ${MIN_BEAT_SEC} s`);
|
|
199
|
+
const previousEnd = i === 0 ? 0 : t.beats[i - 1].t1;
|
|
200
|
+
if (beat.t0 - previousEnd > MAX_GAP_SEC + 1e-9) throw new TreatmentError(field, `starts ${(beat.t0 - previousEnd).toFixed(2)} s after the previous beat ends; gaps are at most ${MAX_GAP_SEC} s`);
|
|
201
|
+
if (i > 0 && beat.t0 < t.beats[i - 1].t0) throw new TreatmentError(field, "beats must be in time order");
|
|
202
|
+
});
|
|
203
|
+
if (t.durationSec - t.beats[t.beats.length - 1].t1 > MAX_GAP_SEC + 1e-9) throw new TreatmentError(`beats[${t.beats.length - 1}]`, `ends before durationSec; beats cover 0 to ${t.durationSec} s`);
|
|
204
|
+
const needed = t.genre === "type-led" ? t.copy.lines.length : ARC_STAGES[t.genre];
|
|
205
|
+
if (t.beats.length < needed) throw new TreatmentError("beats", `a ${t.genre} film needs at least ${needed} beats (${t.genre === "type-led" ? "one per supplied line" : "one per arc stage"}); it has ${t.beats.length}`);
|
|
206
|
+
|
|
207
|
+
if (t.path === "type") {
|
|
208
|
+
if (t.format !== "16:9") throw new TreatmentError("path", "the type path renders 16:9 only; a 9:16 film takes the stage path");
|
|
209
|
+
if (t.copy.source !== "user" && !typeLedCue(request)) throw new TreatmentError("path", "the type path needs the user's own words or a type-led cue in the request");
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
if (t.visualDevices === undefined) throw new TreatmentError("visualDevices", "missing");
|
|
213
|
+
if (!Array.isArray(t.visualDevices)) throw new TreatmentError("visualDevices", "must be an array");
|
|
214
|
+
t.visualDevices.forEach((device, i) => {
|
|
215
|
+
const field = `visualDevices[${i}]`;
|
|
216
|
+
if (!DEVICE_KINDS.includes(device?.kind)) throw new TreatmentError(`${field}.kind`, `must be one of ${DEVICE_KINDS.join(", ")}`);
|
|
217
|
+
if (!["subject", "support", "texture"].includes(device.role)) throw new TreatmentError(`${field}.role`, "must be subject, support or texture");
|
|
218
|
+
if (TEXTURE_KINDS.has(device.kind) && device.role !== "texture") throw new TreatmentError(`${field}.role`, `${device.kind} is always texture`);
|
|
219
|
+
if (!Array.isArray(device.beats) || device.beats.some((b) => !Number.isInteger(b) || b < 0 || b >= t.beats.length)) throw new TreatmentError(`${field}.beats`, "must list beat indices");
|
|
220
|
+
});
|
|
221
|
+
if (t.path === "stage") {
|
|
222
|
+
const subject = t.visualDevices.filter((d) => d.role === "subject");
|
|
223
|
+
if (subject.length === 0) throw new TreatmentError("visualDevices", "the stage path needs a role: subject device, a drawn depiction of what the film is about");
|
|
224
|
+
const covered = beatCoverage(t.beats, subject.flatMap((d) => d.beats));
|
|
225
|
+
if (covered < 0.5 * t.durationSec - 1e-9) throw new TreatmentError("visualDevices", `subject devices cover ${covered.toFixed(1)} s of ${t.durationSec} s; they must cover at least half the film`);
|
|
226
|
+
const counting = new Set(t.visualDevices.filter((d) => !TEXTURE_KINDS.has(d.kind)).map((d) => d.kind));
|
|
227
|
+
if (counting.size < 2) throw new TreatmentError("visualDevices", "the stage path needs at least 2 distinct non-texture kinds (grid, gradient, particles and photo-texture do not count)");
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
if (t.typePlan === undefined) throw new TreatmentError("typePlan", "missing");
|
|
231
|
+
if (!t.typePlan || typeof t.typePlan !== "object") throw new TreatmentError("typePlan", "must be {faces, hierarchy, maxWordsOnScreen}");
|
|
232
|
+
if (!Array.isArray(t.typePlan.faces) || t.typePlan.faces.length === 0) throw new TreatmentError("typePlan.faces", `must list faces from ${FACES.join(", ")}`);
|
|
233
|
+
for (const face of t.typePlan.faces) if (!FACES.some((f) => f.toLowerCase() === String(face).toLowerCase())) throw new TreatmentError("typePlan.faces", `${face} is not one of this product's verified faces (${FACES.join(", ")})`);
|
|
234
|
+
requireText(t, "typePlan.hierarchy", t.typePlan.hierarchy);
|
|
235
|
+
if (!Number.isInteger(t.typePlan.maxWordsOnScreen) || t.typePlan.maxWordsOnScreen < 1) throw new TreatmentError("typePlan.maxWordsOnScreen", "must be a positive integer");
|
|
236
|
+
|
|
237
|
+
if (t.palette === undefined) throw new TreatmentError("palette", "missing");
|
|
238
|
+
if (!Array.isArray(t.palette) || t.palette.length < 3 || t.palette.length > 6) throw new TreatmentError("palette", "must list 3 to 6 colours");
|
|
239
|
+
t.palette.forEach((entry, i) => {
|
|
240
|
+
if (!/^#[0-9a-f]{6}$/iu.test(entry?.hex ?? "")) throw new TreatmentError(`palette[${i}].hex`, "must be #RRGGBB");
|
|
241
|
+
requireText(t, `palette[${i}].role`, entry.role);
|
|
242
|
+
});
|
|
243
|
+
|
|
244
|
+
if (t.sound === undefined) throw new TreatmentError("sound", "missing");
|
|
245
|
+
if (!t.sound || !["generated", "supplied", "authored", "none"].includes(t.sound.mode)) throw new TreatmentError("sound.mode", "must be generated, supplied, authored or none");
|
|
246
|
+
if (t.sound.mode === "none" && !SILENCE_ASKED.test(request) && !MUTED_CHANNEL.test(t.channel)) throw new TreatmentError("sound.mode", "none only when the user asked for silence or the channel plays muted by design; the default is generated");
|
|
247
|
+
if (t.sound.mode !== "none") requireText(t, "sound.plan", t.sound.plan);
|
|
248
|
+
if (t.sound.mode === "generated") {
|
|
249
|
+
if (!SOUND_PALETTES.includes(t.sound.palette)) throw new TreatmentError("sound.palette", `must be one of ${SOUND_PALETTES.join(", ")}`);
|
|
250
|
+
if (!/^[A-G](?:#|b)? (?:major|minor)$/u.test(t.sound.key ?? "")) throw new TreatmentError("sound.key", 'must look like "D minor" or "F# major"');
|
|
251
|
+
if (!Number.isInteger(t.sound.tempo) || t.sound.tempo < 60 || t.sound.tempo > 160) throw new TreatmentError("sound.tempo", "must be an integer BPM from 60 to 160");
|
|
252
|
+
}
|
|
253
|
+
if (t.sound.mode === "supplied" || t.sound.mode === "authored") requireText(t, "sound.file", t.sound.file);
|
|
254
|
+
|
|
255
|
+
const invented = t.copy.source === "invented" || t.subject.source === "invented";
|
|
256
|
+
if (invented) {
|
|
257
|
+
if (t.inventions === undefined) throw new TreatmentError("inventions", "missing");
|
|
258
|
+
if (!Array.isArray(t.inventions) || t.inventions.length === 0 || t.inventions.some((s) => !isText(s))) throw new TreatmentError("inventions", "must list every invented name, fact and line");
|
|
259
|
+
if (t.subject.source === "invented" && !t.inventions.some((s) => normalizeText(s).includes(normalizeText(t.subject.name)))) throw new TreatmentError("inventions", "must contain subject.name");
|
|
260
|
+
} else if (t.inventions !== undefined && !Array.isArray(t.inventions)) throw new TreatmentError("inventions", "must be an array");
|
|
261
|
+
if (t.inventions === undefined) throw new TreatmentError("inventions", "missing (use [] when nothing is invented)");
|
|
262
|
+
|
|
263
|
+
if (t.fps !== undefined && t.fps !== 30 && t.fps !== 60) throw new TreatmentError("fps", "optional; 60 by default, or 30");
|
|
264
|
+
if (t.seed !== undefined && (!Number.isInteger(t.seed) || t.seed < 0 || t.seed > 0xffffffff)) throw new TreatmentError("seed", "optional; an unsigned 32-bit integer");
|
|
265
|
+
const ambition = requireText(t, "ambition");
|
|
266
|
+
if (sentences(ambition) > 2) throw new TreatmentError("ambition", "must be 1 or 2 sentences");
|
|
267
|
+
return t;
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
/** Read and validate `<file>`; a missing or unparsable file is a treatment fault too. */
|
|
271
|
+
export function loadTreatment(file) {
|
|
272
|
+
if (!existsSync(file)) throw new TreatmentError("treatment", `no treatment.json at ${file}; write it before any render (references/treatment.md)`);
|
|
273
|
+
let parsed;
|
|
274
|
+
try {
|
|
275
|
+
parsed = JSON.parse(readFileSync(file, "utf8"));
|
|
276
|
+
} catch (error) {
|
|
277
|
+
throw new TreatmentError("treatment", `not valid JSON (${error.message})`);
|
|
278
|
+
}
|
|
279
|
+
return validateTreatment(parsed);
|
|
280
|
+
}
|
|
@@ -0,0 +1,234 @@
|
|
|
1
|
+
// Type kit: typographic punctuation, Unicode script runs, 어절 breaks, the one reading-floor
|
|
2
|
+
// function, and kerned glyph layout from real outlines (opentype.js, injected so the pure parts of
|
|
3
|
+
// this module run without the runtime cache). Method adapted from the credited engine's type module:
|
|
4
|
+
// per-glyph positions come from the kerned run, never from measuring a slice (MO-A-32).
|
|
5
|
+
import { READING } from "./constants.mjs";
|
|
6
|
+
|
|
7
|
+
const HANGUL_SYLLABLE = /[가-힣]/u;
|
|
8
|
+
const HANGUL_ANY = /[ᄀ-ᇿ-ꥠ-가-힣ힰ-]/u;
|
|
9
|
+
const LATIN_LETTER = /\p{Script=Latin}/u;
|
|
10
|
+
|
|
11
|
+
/** Typewriter punctuation to typographic (MO-A-34), over the brief's own text only. */
|
|
12
|
+
export function smart(text) {
|
|
13
|
+
return String(text)
|
|
14
|
+
.replace(/\.\.\./gu, "…")
|
|
15
|
+
.replace(/(\p{L}|\p{N})'(?=\p{L})/gu, "$1’")
|
|
16
|
+
.replace(/(^|[\s([{—–-])'(?=(?:\d0s|em|til|cause|round|tis|twas)\b)/giu, "$1’")
|
|
17
|
+
.replace(/(^|[\s([{—–-])'/gu, "$1‘")
|
|
18
|
+
.replace(/'/gu, "’")
|
|
19
|
+
.replace(/(^|[\s([{—–-])"/gu, "$1“")
|
|
20
|
+
.replace(/"/gu, "”");
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
/** Typographic punctuation back to typewriter form, for a typed-input mono voice. */
|
|
24
|
+
export const plain = (text) =>
|
|
25
|
+
String(text).replace(/[‘’]/gu, "'").replace(/[“”]/gu, '"').replace(/…/gu, "...");
|
|
26
|
+
|
|
27
|
+
/** 'hangul' | 'latin' | 'neutral' (digits, punctuation, spaces and symbols belong to no run). */
|
|
28
|
+
export function charScript(char) {
|
|
29
|
+
if (HANGUL_ANY.test(char)) return "hangul";
|
|
30
|
+
if (LATIN_LETTER.test(char)) return "latin";
|
|
31
|
+
return "neutral";
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* Split text into script runs (MO-FT-04). A neutral character joins the run beside it; between two
|
|
36
|
+
* different runs it falls back to the run on its left; with no left run it joins the right one.
|
|
37
|
+
*/
|
|
38
|
+
export function scriptRuns(text) {
|
|
39
|
+
const chars = Array.from(String(text));
|
|
40
|
+
const classes = chars.map(charScript);
|
|
41
|
+
const resolved = classes.slice();
|
|
42
|
+
for (let i = 0; i < chars.length; i++) {
|
|
43
|
+
if (classes[i] !== "neutral") continue;
|
|
44
|
+
let left = null;
|
|
45
|
+
for (let j = i - 1; j >= 0; j--) if (resolved[j] !== "neutral") { left = resolved[j]; break; }
|
|
46
|
+
let right = null;
|
|
47
|
+
for (let j = i + 1; j < chars.length; j++) if (classes[j] !== "neutral") { right = classes[j]; break; }
|
|
48
|
+
resolved[i] = left ?? right ?? "latin";
|
|
49
|
+
}
|
|
50
|
+
const runs = [];
|
|
51
|
+
for (let i = 0; i < chars.length; i++) {
|
|
52
|
+
const last = runs[runs.length - 1];
|
|
53
|
+
if (last && last.script === resolved[i]) last.text += chars[i];
|
|
54
|
+
else runs.push({ script: resolved[i], text: chars[i], start: i });
|
|
55
|
+
}
|
|
56
|
+
for (const run of runs) run.end = run.start + Array.from(run.text).length;
|
|
57
|
+
return runs;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export function scriptOf(text) {
|
|
61
|
+
const hasHangul = HANGUL_ANY.test(text);
|
|
62
|
+
const hasLatin = LATIN_LETTER.test(text);
|
|
63
|
+
return hasHangul && hasLatin ? "mixed" : hasHangul ? "hangul" : "latin";
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
/** Break candidates are whitespace only: a 어절 is never split (MO-A-13, MO-FT-05). */
|
|
67
|
+
export const eojeols = (text) => String(text).trim().split(/\s+/u).filter(Boolean);
|
|
68
|
+
|
|
69
|
+
/** H Hangul syllables, W Latin words, C Latin-run characters including spaces (MO-C-07/08). */
|
|
70
|
+
export function countUnits(text) {
|
|
71
|
+
const value = String(text);
|
|
72
|
+
const H = Array.from(value).filter((c) => HANGUL_SYLLABLE.test(c)).length;
|
|
73
|
+
const W = (value.match(/[\p{Script=Latin}\p{Nd}'’-]+/gu) ?? []).filter((w) => /[\p{Script=Latin}\p{Nd}]/u.test(w)).length;
|
|
74
|
+
const C = scriptRuns(value)
|
|
75
|
+
.filter((run) => run.script === "latin")
|
|
76
|
+
.reduce((sum, run) => sum + Array.from(run.text).length, 0);
|
|
77
|
+
return { H, W, C };
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
/** The one reading-floor function (seconds) for a timeline unit of the given kind. */
|
|
81
|
+
export function readingFloor(text, kind) {
|
|
82
|
+
if (kind === "reveal") return READING.revealFloor;
|
|
83
|
+
const { H, W } = countUnits(text);
|
|
84
|
+
const rate = READING.secondsPerHangulSyllable * H + W / READING.wordsPerSecond;
|
|
85
|
+
if (kind === "word") return Math.max(READING.wordFloor, rate);
|
|
86
|
+
return Math.max(H > 0 ? READING.lineFloorHangul : READING.lineFloorLatin, rate);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
/** Loaded opentype.js faces plus a glyph registry the browser rasterizer consumes. */
|
|
90
|
+
export class FontBook {
|
|
91
|
+
constructor(opentype, files) {
|
|
92
|
+
this.opentype = opentype;
|
|
93
|
+
this.files = files;
|
|
94
|
+
this.fonts = new Map();
|
|
95
|
+
this.glyphs = new Map();
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
font(key) {
|
|
99
|
+
let font = this.fonts.get(key);
|
|
100
|
+
if (!font) {
|
|
101
|
+
const bytes = this.files[key]?.bytes;
|
|
102
|
+
if (!bytes) throw new Error(`font not loaded: ${key}`);
|
|
103
|
+
font = this.opentype.parse(bytes.buffer.slice(bytes.byteOffset, bytes.byteOffset + bytes.byteLength));
|
|
104
|
+
this.fonts.set(key, font);
|
|
105
|
+
}
|
|
106
|
+
return font;
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
metrics(key) {
|
|
110
|
+
const font = this.font(key);
|
|
111
|
+
const cap = font.tables.os2?.sCapHeight || font.charToGlyph("H").getBoundingBox().y2;
|
|
112
|
+
return { upm: font.unitsPerEm, ascent: font.ascender, descent: font.descender, capHeight: cap };
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
/** Glyph for a character, or null when the face has no mapping (.notdef). */
|
|
116
|
+
glyph(key, char) {
|
|
117
|
+
const font = this.font(key);
|
|
118
|
+
const glyph = font.charToGlyph(char);
|
|
119
|
+
if (!glyph || glyph.index === 0) return null;
|
|
120
|
+
const id = `${key}#${glyph.index}`;
|
|
121
|
+
if (!this.glyphs.has(id)) {
|
|
122
|
+
const box = glyph.getBoundingBox();
|
|
123
|
+
const path = glyph.getPath(0, 0, font.unitsPerEm);
|
|
124
|
+
this.glyphs.set(id, {
|
|
125
|
+
id,
|
|
126
|
+
d: path.commands.length ? path.toPathData(2) : "",
|
|
127
|
+
box: [box.x1, -box.y2, box.x2, -box.y1],
|
|
128
|
+
empty: path.commands.length === 0,
|
|
129
|
+
});
|
|
130
|
+
}
|
|
131
|
+
return { id, index: glyph.index, advance: glyph.advanceWidth, glyph, entry: this.glyphs.get(id) };
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
kerning(key, left, right) {
|
|
135
|
+
if (!left || !right) return 0;
|
|
136
|
+
return this.font(key).getKerningValue(left.glyph, right.glyph) || 0;
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
/**
|
|
141
|
+
* Kerned layout of one line. `voice` maps a script to a font key; Hangul runs always get zero
|
|
142
|
+
* tracking (MO-FT-04). Positions are in px from the left baseline origin.
|
|
143
|
+
*/
|
|
144
|
+
export function layoutLine(book, text, voice, sizePx, trackingEm = 0) {
|
|
145
|
+
const glyphs = [];
|
|
146
|
+
const runs = [];
|
|
147
|
+
const missing = [];
|
|
148
|
+
let x = 0;
|
|
149
|
+
let ink = null;
|
|
150
|
+
let capHeight = 0;
|
|
151
|
+
let ascent = 0;
|
|
152
|
+
let descent = 0;
|
|
153
|
+
for (const run of scriptRuns(text)) {
|
|
154
|
+
const key = voice[run.script] ?? voice.latin;
|
|
155
|
+
const m = book.metrics(key);
|
|
156
|
+
const scale = sizePx / m.upm;
|
|
157
|
+
const tracking = run.script === "hangul" ? 0 : trackingEm * sizePx;
|
|
158
|
+
capHeight = Math.max(capHeight, m.capHeight * scale);
|
|
159
|
+
ascent = Math.max(ascent, m.ascent * scale);
|
|
160
|
+
descent = Math.min(descent, m.descent * scale);
|
|
161
|
+
runs.push({ script: run.script, fontKey: key, start: run.start, end: run.end, trackingEm: run.script === "hangul" ? 0 : trackingEm });
|
|
162
|
+
let previous = null;
|
|
163
|
+
const chars = Array.from(run.text);
|
|
164
|
+
for (let i = 0; i < chars.length; i++) {
|
|
165
|
+
const char = chars[i];
|
|
166
|
+
const g = book.glyph(key, char);
|
|
167
|
+
if (!g) {
|
|
168
|
+
if (!/\s/u.test(char)) missing.push({ char, fontKey: key });
|
|
169
|
+
x += (m.upm / 3) * scale;
|
|
170
|
+
previous = null;
|
|
171
|
+
continue;
|
|
172
|
+
}
|
|
173
|
+
x += book.kerning(key, previous, g) * scale;
|
|
174
|
+
glyphs.push({ char, id: g.id, x, s: scale, run: runs.length - 1, advance: g.advance * scale });
|
|
175
|
+
if (!g.entry.empty) {
|
|
176
|
+
const b = g.entry.box;
|
|
177
|
+
ink = ink ? [Math.min(ink[0], x + b[0] * scale), Math.min(ink[1], b[1] * scale), Math.max(ink[2], x + b[2] * scale), Math.max(ink[3], b[3] * scale)] : [x + b[0] * scale, b[1] * scale, x + b[2] * scale, b[3] * scale];
|
|
178
|
+
}
|
|
179
|
+
x += g.advance * scale + (i < chars.length - 1 ? tracking : 0);
|
|
180
|
+
previous = g;
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
return { text, sizePx, width: x, glyphs, runs, missing, ink: ink ?? [0, 0, 0, 0], capHeight, ascent, descent: -descent };
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
/** x of glyph `index` in a kerned run: where to start drawing text[index..] when a word is split. */
|
|
187
|
+
export function glyphX(layout, index) {
|
|
188
|
+
if (index <= 0) return 0;
|
|
189
|
+
if (index >= layout.glyphs.length) return layout.width;
|
|
190
|
+
return layout.glyphs[index].x;
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
/**
|
|
194
|
+
* Break text into lines no wider than maxWidth, only at whitespace, then shrink the size until the
|
|
195
|
+
* widest 어절 fits. Returns { sizePx, lines: [layout...] }.
|
|
196
|
+
*/
|
|
197
|
+
export function fitBlock(book, text, voice, { maxWidth, sizePx, minSizePx = 28, maxLines = 3, trackingEm = 0 }) {
|
|
198
|
+
for (let size = sizePx; size >= minSizePx; size = Math.floor(size * 0.94)) {
|
|
199
|
+
const words = eojeols(text);
|
|
200
|
+
const lines = [];
|
|
201
|
+
let current = "";
|
|
202
|
+
let overflow = false;
|
|
203
|
+
for (const word of words) {
|
|
204
|
+
const candidate = current ? `${current} ${word}` : word;
|
|
205
|
+
if (layoutLine(book, candidate, voice, size, trackingEm).width <= maxWidth) current = candidate;
|
|
206
|
+
else {
|
|
207
|
+
if (!current) { overflow = true; break; }
|
|
208
|
+
lines.push(current);
|
|
209
|
+
current = word;
|
|
210
|
+
if (layoutLine(book, current, voice, size, trackingEm).width > maxWidth) { overflow = true; break; }
|
|
211
|
+
}
|
|
212
|
+
}
|
|
213
|
+
if (current && !overflow) lines.push(current);
|
|
214
|
+
if (!overflow && lines.length <= maxLines) return { sizePx: size, lines: lines.map((line) => layoutLine(book, line, voice, size, trackingEm)) };
|
|
215
|
+
}
|
|
216
|
+
throw new Error(`text does not fit the title-safe width at ${minSizePx}px: ${text}`);
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
/** Pre-flight glyph coverage (MO-D-04): every codepoint must resolve in its script's face. */
|
|
220
|
+
export function missingGlyphs(book, text, voices) {
|
|
221
|
+
const missing = [];
|
|
222
|
+
const seen = new Set();
|
|
223
|
+
for (const voice of voices) {
|
|
224
|
+
for (const run of scriptRuns(smart(text))) {
|
|
225
|
+
const key = voice[run.script] ?? voice.latin;
|
|
226
|
+
for (const char of Array.from(run.text)) {
|
|
227
|
+
if (/\s/u.test(char) || seen.has(`${key}:${char}`)) continue;
|
|
228
|
+
seen.add(`${key}:${char}`);
|
|
229
|
+
if (!book.glyph(key, char)) missing.push({ char, codepoint: `U+${char.codePointAt(0).toString(16).toUpperCase().padStart(4, "0")}`, fontKey: key });
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
return missing;
|
|
234
|
+
}
|