@mytechtoday/augment-extensions 1.7.0 → 2.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +119 -8
- package/augment-extensions/coding-standards/bash/CHANGELOG.md +51 -0
- package/augment-extensions/coding-standards/bash/metadata.json +21 -0
- package/augment-extensions/coding-standards/c/metadata.json +50 -0
- package/augment-extensions/coding-standards/css/CHANGELOG.md +51 -0
- package/augment-extensions/coding-standards/css/metadata.json +30 -0
- package/augment-extensions/coding-standards/go/CHANGELOG.md +51 -0
- package/augment-extensions/coding-standards/go/metadata.json +57 -0
- package/augment-extensions/coding-standards/html/CHANGELOG.md +51 -0
- package/augment-extensions/coding-standards/html/metadata.json +25 -0
- package/augment-extensions/coding-standards/html-css-js/CHANGELOG.md +51 -0
- package/augment-extensions/coding-standards/html-css-js/metadata.json +40 -0
- package/augment-extensions/coding-standards/js/CHANGELOG.md +51 -0
- package/augment-extensions/coding-standards/js/metadata.json +37 -0
- package/augment-extensions/coding-standards/php/CHANGELOG.md +51 -0
- package/augment-extensions/coding-standards/php/metadata.json +35 -0
- package/augment-extensions/coding-standards/powershell/CHANGELOG.md +51 -0
- package/augment-extensions/coding-standards/powershell/metadata.json +33 -0
- package/augment-extensions/coding-standards/python/CHANGELOG.md +51 -0
- package/augment-extensions/coding-standards/python/metadata.json +38 -0
- package/augment-extensions/coding-standards/react/CHANGELOG.md +51 -0
- package/augment-extensions/coding-standards/react/metadata.json +31 -0
- package/augment-extensions/coding-standards/typescript/CHANGELOG.md +39 -0
- package/augment-extensions/coding-standards/typescript/README.md +248 -19
- package/augment-extensions/coding-standards/typescript/VERSION +2 -0
- package/augment-extensions/coding-standards/typescript/examples/biome.json +199 -0
- package/augment-extensions/coding-standards/typescript/examples/eslint-flat-config.js +166 -0
- package/augment-extensions/coding-standards/typescript/examples/monorepo-config/README.md +47 -0
- package/augment-extensions/coding-standards/typescript/examples/monorepo-config/package.json +37 -0
- package/augment-extensions/coding-standards/typescript/examples/monorepo-config/pnpm-workspace.yaml +5 -0
- package/augment-extensions/coding-standards/typescript/examples/monorepo-config/tsconfig.base.json +50 -0
- package/augment-extensions/coding-standards/typescript/examples/monorepo-config/turbo.json +47 -0
- package/augment-extensions/coding-standards/typescript/examples/vitest-setup.ts +198 -0
- package/augment-extensions/coding-standards/typescript/metadata.json +46 -0
- package/augment-extensions/coding-standards/typescript/module.json +25 -7
- package/augment-extensions/coding-standards/typescript/rules/architecture.md +1096 -0
- package/augment-extensions/coding-standards/typescript/rules/error-handling.md +1174 -0
- package/augment-extensions/coding-standards/typescript/rules/modern-features.md +625 -0
- package/augment-extensions/coding-standards/typescript/rules/monorepo.md +745 -0
- package/augment-extensions/coding-standards/typescript/rules/security-performance.md +850 -0
- package/augment-extensions/coding-standards/typescript/rules/testing.md +918 -0
- package/augment-extensions/coding-standards/typescript/rules/tooling.md +1071 -0
- package/augment-extensions/coding-standards/typescript/rules/type-patterns.md +750 -0
- package/augment-extensions/domain-rules/api-design/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/api-design/metadata.json +32 -0
- package/augment-extensions/domain-rules/database/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/database/metadata.json +50 -0
- package/augment-extensions/domain-rules/design/color/themes/catppuccin-latte/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/design/color/themes/catppuccin-latte/metadata.json +18 -0
- package/augment-extensions/domain-rules/design/color/themes/catppuccin-mocha/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/design/color/themes/catppuccin-mocha/metadata.json +18 -0
- package/augment-extensions/domain-rules/design/color/themes/dracula/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/design/color/themes/dracula/metadata.json +18 -0
- package/augment-extensions/domain-rules/design/color/themes/gruvbox-dark/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/design/color/themes/gruvbox-dark/metadata.json +18 -0
- package/augment-extensions/domain-rules/design/color/themes/gruvbox-light/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/design/color/themes/gruvbox-light/metadata.json +18 -0
- package/augment-extensions/domain-rules/design/color/themes/high-contrast/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/design/color/themes/high-contrast/metadata.json +18 -0
- package/augment-extensions/domain-rules/design/color/themes/monokai/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/design/color/themes/monokai/metadata.json +18 -0
- package/augment-extensions/domain-rules/design/color/themes/nord/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/design/color/themes/nord/metadata.json +18 -0
- package/augment-extensions/domain-rules/design/color/themes/one-dark/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/design/color/themes/one-dark/metadata.json +18 -0
- package/augment-extensions/domain-rules/design/color/themes/one-light/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/design/color/themes/one-light/metadata.json +18 -0
- package/augment-extensions/domain-rules/design/color/themes/solarized-dark/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/design/color/themes/solarized-dark/metadata.json +18 -0
- package/augment-extensions/domain-rules/design/color/themes/solarized-light/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/design/color/themes/solarized-light/metadata.json +18 -0
- package/augment-extensions/domain-rules/design/color/themes/tokyo-night/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/design/color/themes/tokyo-night/metadata.json +18 -0
- package/augment-extensions/domain-rules/mcp/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/mcp/metadata.json +42 -0
- package/augment-extensions/domain-rules/security/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/security/metadata.json +33 -0
- package/augment-extensions/domain-rules/seo-sales-marketing/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/seo-sales-marketing/metadata.json +40 -0
- package/augment-extensions/domain-rules/software-architecture/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/software-architecture/metadata.json +55 -0
- package/augment-extensions/domain-rules/wordpress/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/wordpress/metadata.json +42 -0
- package/augment-extensions/domain-rules/wordpress-plugin/CHANGELOG.md +51 -0
- package/augment-extensions/domain-rules/wordpress-plugin/metadata.json +70 -0
- package/augment-extensions/examples/design-patterns/CHANGELOG.md +51 -0
- package/augment-extensions/examples/design-patterns/metadata.json +29 -0
- package/augment-extensions/examples/gutenberg-block-plugin/CHANGELOG.md +51 -0
- package/augment-extensions/examples/gutenberg-block-plugin/metadata.json +26 -0
- package/augment-extensions/examples/rest-api-plugin/CHANGELOG.md +51 -0
- package/augment-extensions/examples/rest-api-plugin/metadata.json +27 -0
- package/augment-extensions/examples/woocommerce-extension/CHANGELOG.md +51 -0
- package/augment-extensions/examples/woocommerce-extension/metadata.json +27 -0
- package/augment-extensions/visual-design/metadata.json +34 -0
- package/augment-extensions/workflows/adr-support/CHANGELOG.md +51 -0
- package/augment-extensions/workflows/adr-support/metadata.json +41 -0
- package/augment-extensions/workflows/beads/CHANGELOG.md +51 -0
- package/augment-extensions/workflows/beads/metadata.json +23 -0
- package/augment-extensions/workflows/beads-integration/CHANGELOG.md +51 -0
- package/augment-extensions/workflows/beads-integration/metadata.json +30 -0
- package/augment-extensions/workflows/database/CHANGELOG.md +51 -0
- package/augment-extensions/workflows/database/metadata.json +30 -0
- package/augment-extensions/workflows/wordpress-plugin/CHANGELOG.md +51 -0
- package/augment-extensions/workflows/wordpress-plugin/metadata.json +41 -0
- package/augment-extensions/writing-standards/literature/shakespeare/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/literature/shakespeare/metadata.json +60 -0
- package/augment-extensions/writing-standards/screenplay/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/comedy-formats/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/comedy-formats/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/comedy-formats/monty-python/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/comedy-formats/monty-python/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/comedy-formats/saturday-night-live/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/comedy-formats/saturday-night-live/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/alfred-hitchcock/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/alfred-hitchcock/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/ari-aster/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/ari-aster/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/brad-bird/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/brad-bird/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/brian-de-palma/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/brian-de-palma/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/buster-keaton/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/buster-keaton/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/christopher-nolan/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/christopher-nolan/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/clint-eastwood/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/clint-eastwood/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/coen-brothers/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/coen-brothers/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/darren-aronofsky/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/darren-aronofsky/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/david-fincher/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/david-fincher/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/david-lynch/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/david-lynch/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/denis-villeneuve/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/denis-villeneuve/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/francis-ford-coppola/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/francis-ford-coppola/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/gary-marshall/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/gary-marshall/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/george-a-romero/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/george-a-romero/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/george-lucas/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/george-lucas/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/guillermo-del-toro/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/guillermo-del-toro/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/gus-van-sant/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/gus-van-sant/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/james-ivory-ismail-merchant/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/james-ivory-ismail-merchant/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/jim-jarmusch/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/jim-jarmusch/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/john-carpenter/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/john-carpenter/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/john-ford/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/john-ford/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/john-huston/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/john-huston/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/john-landis/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/john-landis/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/jonathan-demme/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/jonathan-demme/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/joseph-l-mankiewicz/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/joseph-l-mankiewicz/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/kathryn-bigelow/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/kathryn-bigelow/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/kelly-reichardt/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/kelly-reichardt/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/kevin-smith/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/kevin-smith/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/linda-shayne/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/linda-shayne/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/martin-scorsese/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/martin-scorsese/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/mel-brooks/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/mel-brooks/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/metadata.json +25 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/michael-curtiz/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/michael-curtiz/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/michael-mann/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/michael-mann/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/mike-nichols/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/mike-nichols/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/orson-welles/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/orson-welles/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/park-chan-wook/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/park-chan-wook/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/paul-thomas-anderson/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/paul-thomas-anderson/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/penny-marshall/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/penny-marshall/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/peter-bogdanovich/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/peter-bogdanovich/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/quentin-tarantino/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/quentin-tarantino/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/richard-linklater/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/richard-linklater/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/rob-reiner/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/rob-reiner/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/robert-altman/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/robert-altman/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/robert-eggers/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/robert-eggers/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/robert-zemeckis/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/robert-zemeckis/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/sam-peckinpah/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/sam-peckinpah/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/sidney-lumet/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/sidney-lumet/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/spike-lee/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/spike-lee/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/stanley-donen-gene-kelly/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/stanley-donen-gene-kelly/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/stanley-kubrick/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/stanley-kubrick/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/steve-martin/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/steve-martin/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/steven-spielberg/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/steven-spielberg/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/sydney-pollack/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/sydney-pollack/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/terry-gilliam/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/terry-gilliam/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/tim-burton/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/tim-burton/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/tobe-hooper/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/tobe-hooper/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/wes-anderson/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/wes-anderson/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/william-friedkin/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/directors/william-friedkin/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/films/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/films/blue-ruin/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/films/blue-ruin/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/films/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/fast-and-furious/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/fast-and-furious/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/harry-potter/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/harry-potter/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/james-bond/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/james-bond/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/john-wick/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/john-wick/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/lord-of-the-rings/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/lord-of-the-rings/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/mcu/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/mcu/metadata.json +25 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/metadata.json +25 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/star-trek/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/star-trek/metadata.json +33 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/star-wars/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/franchises/star-wars/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/metadata.json +50 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/narrative-theory/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/narrative-theory/joseph-campbell/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/narrative-theory/joseph-campbell/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/narrative-theory/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/producers/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/producers/bruckheimer-and-simpson/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/producers/bruckheimer-and-simpson/metadata.json +24 -0
- package/augment-extensions/writing-standards/screenplay/cinematic-styles/producers/metadata.json +23 -0
- package/augment-extensions/writing-standards/screenplay/genres/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/genres/metadata.json +43 -0
- package/augment-extensions/writing-standards/screenplay/metadata.json +65 -0
- package/augment-extensions/writing-standards/screenplay/styles/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/styles/metadata.json +38 -0
- package/augment-extensions/writing-standards/screenplay/themes/CHANGELOG.md +51 -0
- package/augment-extensions/writing-standards/screenplay/themes/metadata.json +47 -0
- package/cli/dist/__test_health-checker.d.ts +2 -0
- package/cli/dist/__test_health-checker.d.ts.map +1 -0
- package/cli/dist/__test_health-checker.js +4 -0
- package/cli/dist/__test_health-checker.js.map +1 -0
- package/cli/dist/__test_template-engine.d.ts +2 -0
- package/cli/dist/__test_template-engine.d.ts.map +1 -0
- package/cli/dist/__test_template-engine.js +4 -0
- package/cli/dist/__test_template-engine.js.map +1 -0
- package/cli/dist/cli.js +25 -0
- package/cli/dist/cli.js.map +1 -1
- package/cli/dist/commands/generate-shot-list/generator/index.d.ts +8 -2
- package/cli/dist/commands/generate-shot-list/generator/index.d.ts.map +1 -1
- package/cli/dist/commands/generate-shot-list/generator/index.js +28 -3
- package/cli/dist/commands/generate-shot-list/generator/index.js.map +1 -1
- package/cli/dist/commands/generate-shot-list/generator/types.d.ts +3 -0
- package/cli/dist/commands/generate-shot-list/generator/types.d.ts.map +1 -1
- package/cli/dist/commands/generate-shot-list/help-text.d.ts +1 -1
- package/cli/dist/commands/generate-shot-list/help-text.d.ts.map +1 -1
- package/cli/dist/commands/generate-shot-list/help-text.js +48 -5
- package/cli/dist/commands/generate-shot-list/help-text.js.map +1 -1
- package/cli/dist/commands/generate-shot-list/logger/jsonl-writer.d.ts +11 -1
- package/cli/dist/commands/generate-shot-list/logger/jsonl-writer.d.ts.map +1 -1
- package/cli/dist/commands/generate-shot-list/logger/jsonl-writer.js +61 -1
- package/cli/dist/commands/generate-shot-list/logger/jsonl-writer.js.map +1 -1
- package/cli/dist/commands/generate-shot-list/parser/docx-parser.d.ts +29 -0
- package/cli/dist/commands/generate-shot-list/parser/docx-parser.d.ts.map +1 -0
- package/cli/dist/commands/generate-shot-list/parser/docx-parser.js +111 -0
- package/cli/dist/commands/generate-shot-list/parser/docx-parser.js.map +1 -0
- package/cli/dist/commands/generate-shot-list/parser/finaldraft-parser.d.ts +18 -0
- package/cli/dist/commands/generate-shot-list/parser/finaldraft-parser.d.ts.map +1 -0
- package/cli/dist/commands/generate-shot-list/parser/finaldraft-parser.js +184 -0
- package/cli/dist/commands/generate-shot-list/parser/finaldraft-parser.js.map +1 -0
- package/cli/dist/commands/generate-shot-list/parser/index.d.ts +4 -3
- package/cli/dist/commands/generate-shot-list/parser/index.d.ts.map +1 -1
- package/cli/dist/commands/generate-shot-list/parser/index.js +54 -3
- package/cli/dist/commands/generate-shot-list/parser/index.js.map +1 -1
- package/cli/dist/commands/generate-shot-list/parser/pdf-parser.d.ts +24 -0
- package/cli/dist/commands/generate-shot-list/parser/pdf-parser.d.ts.map +1 -0
- package/cli/dist/commands/generate-shot-list/parser/pdf-parser.js +84 -0
- package/cli/dist/commands/generate-shot-list/parser/pdf-parser.js.map +1 -0
- package/cli/dist/commands/generate-shot-list/parser/rtf-parser.d.ts +28 -0
- package/cli/dist/commands/generate-shot-list/parser/rtf-parser.d.ts.map +1 -0
- package/cli/dist/commands/generate-shot-list/parser/rtf-parser.js +143 -0
- package/cli/dist/commands/generate-shot-list/parser/rtf-parser.js.map +1 -0
- package/cli/dist/commands/generate-shot-list/parser/types.d.ts +9 -6
- package/cli/dist/commands/generate-shot-list/parser/types.d.ts.map +1 -1
- package/cli/dist/commands/generate-shot-list/parser/types.js.map +1 -1
- package/cli/dist/commands/generate-shot-list/style/guideline-parser.d.ts +36 -0
- package/cli/dist/commands/generate-shot-list/style/guideline-parser.d.ts.map +1 -0
- package/cli/dist/commands/generate-shot-list/style/guideline-parser.js +108 -0
- package/cli/dist/commands/generate-shot-list/style/guideline-parser.js.map +1 -0
- package/cli/dist/commands/generate-shot-list/style/index.d.ts +39 -0
- package/cli/dist/commands/generate-shot-list/style/index.d.ts.map +1 -0
- package/cli/dist/commands/generate-shot-list/style/index.js +85 -0
- package/cli/dist/commands/generate-shot-list/style/index.js.map +1 -0
- package/cli/dist/commands/generate-shot-list/style/style-loader.d.ts +35 -0
- package/cli/dist/commands/generate-shot-list/style/style-loader.d.ts.map +1 -0
- package/cli/dist/commands/generate-shot-list/style/style-loader.js +178 -0
- package/cli/dist/commands/generate-shot-list/style/style-loader.js.map +1 -0
- package/cli/dist/commands/generate-shot-list/style/style-merger.d.ts +36 -0
- package/cli/dist/commands/generate-shot-list/style/style-merger.d.ts.map +1 -0
- package/cli/dist/commands/generate-shot-list/style/style-merger.js +123 -0
- package/cli/dist/commands/generate-shot-list/style/style-merger.js.map +1 -0
- package/cli/dist/commands/generate-shot-list/style/types.d.ts +105 -0
- package/cli/dist/commands/generate-shot-list/style/types.d.ts.map +1 -0
- package/cli/dist/commands/generate-shot-list/style/types.js +8 -0
- package/cli/dist/commands/generate-shot-list/style/types.js.map +1 -0
- package/cli/dist/commands/generate-shot-list.d.ts +1 -0
- package/cli/dist/commands/generate-shot-list.d.ts.map +1 -1
- package/cli/dist/commands/generate-shot-list.js +44 -1
- package/cli/dist/commands/generate-shot-list.js.map +1 -1
- package/cli/dist/commands/list.d.ts +1 -0
- package/cli/dist/commands/list.d.ts.map +1 -1
- package/cli/dist/commands/list.js +21 -5
- package/cli/dist/commands/list.js.map +1 -1
- package/cli/dist/commands/upgrade.d.ts +15 -0
- package/cli/dist/commands/upgrade.d.ts.map +1 -0
- package/cli/dist/commands/upgrade.js +229 -0
- package/cli/dist/commands/upgrade.js.map +1 -0
- package/cli/dist/commands/use.d.ts +15 -0
- package/cli/dist/commands/use.d.ts.map +1 -0
- package/cli/dist/commands/use.js +180 -0
- package/cli/dist/commands/use.js.map +1 -0
- package/cli/dist/commands/version-info.d.ts +15 -0
- package/cli/dist/commands/version-info.d.ts.map +1 -0
- package/cli/dist/commands/version-info.js +194 -0
- package/cli/dist/commands/version-info.js.map +1 -0
- package/cli/dist/core/compatibility-checker.d.ts +73 -0
- package/cli/dist/core/compatibility-checker.d.ts.map +1 -0
- package/cli/dist/core/compatibility-checker.js +188 -0
- package/cli/dist/core/compatibility-checker.js.map +1 -0
- package/cli/dist/core/index.d.ts +9 -0
- package/cli/dist/core/index.d.ts.map +1 -0
- package/cli/dist/core/index.js +16 -0
- package/cli/dist/core/index.js.map +1 -0
- package/cli/dist/core/module-loader.d.ts +68 -0
- package/cli/dist/core/module-loader.d.ts.map +1 -0
- package/cli/dist/core/module-loader.js +137 -0
- package/cli/dist/core/module-loader.js.map +1 -0
- package/cli/dist/core/version-manager.d.ts +62 -0
- package/cli/dist/core/version-manager.d.ts.map +1 -0
- package/cli/dist/core/version-manager.js +157 -0
- package/cli/dist/core/version-manager.js.map +1 -0
- package/cli/dist/core/version-resolver.d.ts +63 -0
- package/cli/dist/core/version-resolver.d.ts.map +1 -0
- package/cli/dist/core/version-resolver.js +163 -0
- package/cli/dist/core/version-resolver.js.map +1 -0
- package/cli/dist/gui/app.d.ts +17 -0
- package/cli/dist/gui/app.d.ts.map +1 -0
- package/cli/dist/gui/app.js +79 -0
- package/cli/dist/gui/app.js.map +1 -0
- package/cli/dist/gui/components/preview-pane.d.ts +40 -0
- package/cli/dist/gui/components/preview-pane.d.ts.map +1 -0
- package/cli/dist/gui/components/preview-pane.js +90 -0
- package/cli/dist/gui/components/preview-pane.js.map +1 -0
- package/cli/dist/gui/components/search-filter.d.ts +26 -0
- package/cli/dist/gui/components/search-filter.d.ts.map +1 -0
- package/cli/dist/gui/components/search-filter.js +168 -0
- package/cli/dist/gui/components/search-filter.js.map +1 -0
- package/cli/dist/gui/components/status-bar.d.ts +22 -0
- package/cli/dist/gui/components/status-bar.d.ts.map +1 -0
- package/cli/dist/gui/components/status-bar.js +58 -0
- package/cli/dist/gui/components/status-bar.js.map +1 -0
- package/cli/dist/gui/components/tree-navigator.d.ts +30 -0
- package/cli/dist/gui/components/tree-navigator.d.ts.map +1 -0
- package/cli/dist/gui/components/tree-navigator.js +133 -0
- package/cli/dist/gui/components/tree-navigator.js.map +1 -0
- package/cli/dist/gui/components/version-selector.d.ts +27 -0
- package/cli/dist/gui/components/version-selector.d.ts.map +1 -0
- package/cli/dist/gui/components/version-selector.js +110 -0
- package/cli/dist/gui/components/version-selector.js.map +1 -0
- package/cli/dist/gui/hooks/use-version-loader.d.ts +25 -0
- package/cli/dist/gui/hooks/use-version-loader.d.ts.map +1 -0
- package/cli/dist/gui/hooks/use-version-loader.js +116 -0
- package/cli/dist/gui/hooks/use-version-loader.js.map +1 -0
- package/cli/dist/gui/index.d.ts +15 -0
- package/cli/dist/gui/index.d.ts.map +1 -0
- package/cli/dist/gui/index.js +39 -0
- package/cli/dist/gui/index.js.map +1 -0
- package/cli/dist/gui/layouts/main-layout.d.ts +14 -0
- package/cli/dist/gui/layouts/main-layout.d.ts.map +1 -0
- package/cli/dist/gui/layouts/main-layout.js +205 -0
- package/cli/dist/gui/layouts/main-layout.js.map +1 -0
- package/cli/dist/gui/state/navigation-state.d.ts +39 -0
- package/cli/dist/gui/state/navigation-state.d.ts.map +1 -0
- package/cli/dist/gui/state/navigation-state.js +151 -0
- package/cli/dist/gui/state/navigation-state.js.map +1 -0
- package/cli/dist/gui/state/selection-state.d.ts +36 -0
- package/cli/dist/gui/state/selection-state.d.ts.map +1 -0
- package/cli/dist/gui/state/selection-state.js +132 -0
- package/cli/dist/gui/state/selection-state.js.map +1 -0
- package/cli/dist/gui/theme.d.ts +50 -0
- package/cli/dist/gui/theme.d.ts.map +1 -0
- package/cli/dist/gui/theme.js +73 -0
- package/cli/dist/gui/theme.js.map +1 -0
- package/cli/dist/utils/help.d.ts +13 -0
- package/cli/dist/utils/help.d.ts.map +1 -0
- package/cli/dist/utils/help.js +137 -0
- package/cli/dist/utils/help.js.map +1 -0
- package/cli/dist/utils/module-system.d.ts +8 -0
- package/cli/dist/utils/module-system.d.ts.map +1 -1
- package/cli/dist/utils/module-system.js +38 -3
- package/cli/dist/utils/module-system.js.map +1 -1
- package/cli/dist/utils/validate-versioning.d.ts +43 -0
- package/cli/dist/utils/validate-versioning.d.ts.map +1 -0
- package/cli/dist/utils/validate-versioning.js +258 -0
- package/cli/dist/utils/validate-versioning.js.map +1 -0
- package/package.json +10 -1
|
@@ -69,17 +69,36 @@ OPTIONAL ARGUMENTS
|
|
|
69
69
|
Maximum shot duration in seconds
|
|
70
70
|
Range: 1 - 60
|
|
71
71
|
Default: 12
|
|
72
|
-
|
|
72
|
+
|
|
73
73
|
Examples:
|
|
74
74
|
--max-shot-length 10
|
|
75
75
|
--max-shot-length 15
|
|
76
76
|
|
|
77
|
+
--logging
|
|
78
|
+
Enable debug logging to augx.jsonl
|
|
79
|
+
Logs all stages: parsing, generation, validation, formatting
|
|
80
|
+
Includes error details, warnings, and style decisions
|
|
81
|
+
|
|
82
|
+
Example:
|
|
83
|
+
--logging
|
|
84
|
+
|
|
85
|
+
--style <module-path>
|
|
86
|
+
Apply cinematic style guidelines (can be specified multiple times)
|
|
87
|
+
Format: writing-standards/screenplay/cinematic-styles/[category]/[style-name]
|
|
88
|
+
Categories: directors, franchises, films, comedy-formats
|
|
89
|
+
Priority: first --style flag = highest priority
|
|
90
|
+
|
|
91
|
+
Examples:
|
|
92
|
+
--style writing-standards/screenplay/cinematic-styles/directors/brian-de-palma
|
|
93
|
+
--style writing-standards/screenplay/cinematic-styles/directors/brian-de-palma \
|
|
94
|
+
--style writing-standards/screenplay/cinematic-styles/directors/alfred-hitchcock
|
|
95
|
+
|
|
77
96
|
--verbose
|
|
78
97
|
Enable verbose output with detailed progress information
|
|
79
|
-
|
|
98
|
+
|
|
80
99
|
--quiet
|
|
81
100
|
Suppress all output except errors
|
|
82
|
-
|
|
101
|
+
|
|
83
102
|
--help, -h
|
|
84
103
|
Display this help message
|
|
85
104
|
|
|
@@ -96,6 +115,19 @@ USAGE EXAMPLES
|
|
|
96
115
|
Custom output file:
|
|
97
116
|
augx generate-shot-list --path screenplay.fountain --output my-shots.html --format html
|
|
98
117
|
|
|
118
|
+
With debug logging:
|
|
119
|
+
augx generate-shot-list --path screenplay.md --logging
|
|
120
|
+
|
|
121
|
+
Apply cinematic style:
|
|
122
|
+
augx generate-shot-list --path screenplay.fountain \
|
|
123
|
+
--style writing-standards/screenplay/cinematic-styles/directors/christopher-nolan
|
|
124
|
+
|
|
125
|
+
Multiple styles (priority-based):
|
|
126
|
+
augx generate-shot-list --path screenplay.fountain \
|
|
127
|
+
--style writing-standards/screenplay/cinematic-styles/directors/brian-de-palma \
|
|
128
|
+
--style writing-standards/screenplay/cinematic-styles/directors/alfred-hitchcock \
|
|
129
|
+
--logging
|
|
130
|
+
|
|
99
131
|
Verbose mode:
|
|
100
132
|
augx generate-shot-list --path screenplay.md --verbose
|
|
101
133
|
|
|
@@ -114,14 +146,15 @@ SUPPORTED FORMATS
|
|
|
114
146
|
• HTML (html) - Interactive format with character counting
|
|
115
147
|
|
|
116
148
|
ERROR HANDLING
|
|
117
|
-
|
|
118
|
-
|
|
149
|
+
When --logging is enabled, all events are logged to augx.jsonl
|
|
150
|
+
|
|
119
151
|
Common errors:
|
|
120
152
|
• PE001: Invalid scene heading format
|
|
121
153
|
• VE001: Shot exceeds character limit
|
|
122
154
|
• VE002: Shot exceeds duration limit
|
|
123
155
|
• IO001: Input file not found
|
|
124
156
|
• IO002: Output file cannot be written
|
|
157
|
+
• STYLE_CONFLICT: Multiple styles have conflicting guidelines
|
|
125
158
|
|
|
126
159
|
EXIT CODES
|
|
127
160
|
0 - Success
|
|
@@ -138,12 +171,22 @@ BEST PRACTICES
|
|
|
138
171
|
3. Limit shots to 12 seconds for better video quality
|
|
139
172
|
4. Use HTML output for interactive editing and character counting
|
|
140
173
|
5. Review warnings in the output for potential issues
|
|
174
|
+
6. Enable --logging for debugging and audit trails
|
|
175
|
+
7. Apply cinematic styles to match specific director aesthetics
|
|
176
|
+
|
|
177
|
+
CINEMATIC STYLES
|
|
178
|
+
• Styles are loaded from augment-extensions modules
|
|
179
|
+
• Multiple styles can be combined with priority-based merging
|
|
180
|
+
• First --style flag = highest priority (primary style)
|
|
181
|
+
• Conflicts are automatically resolved using primary style
|
|
182
|
+
• Style conflicts are logged when --logging is enabled
|
|
141
183
|
|
|
142
184
|
TIPS
|
|
143
185
|
• The generator automatically splits long scenes into multiple shots
|
|
144
186
|
• Context is repeated for each shot (set, characters, lighting)
|
|
145
187
|
• Metadata extraction identifies shot types and camera movements
|
|
146
188
|
• Character limits include full context, not just action description
|
|
189
|
+
• Style guidelines influence camera work, lighting, and pacing suggestions
|
|
147
190
|
|
|
148
191
|
For more information, visit:
|
|
149
192
|
https://github.com/mytech-today-now/augment-extensions
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"help-text.js","sourceRoot":"","sources":["../../../src/commands/generate-shot-list/help-text.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;
|
|
1
|
+
{"version":3,"file":"help-text.js","sourceRoot":"","sources":["../../../src/commands/generate-shot-list/help-text.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;AAiMH,kCAEC;AAjMY,QAAA,SAAS,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA0LxB,CAAC;AAEF;;GAEG;AACH,SAAgB,WAAW;IACzB,OAAO,CAAC,GAAG,CAAC,iBAAS,CAAC,CAAC;AACzB,CAAC"}
|
|
@@ -12,11 +12,21 @@
|
|
|
12
12
|
export declare class JSONLWriter {
|
|
13
13
|
private filePath;
|
|
14
14
|
private writeQueue;
|
|
15
|
-
|
|
15
|
+
private maxFileSize;
|
|
16
|
+
private maxBackups;
|
|
17
|
+
constructor(filePath: string, maxFileSize?: number, maxBackups?: number);
|
|
16
18
|
/**
|
|
17
19
|
* Initialize the writer (create directory if needed)
|
|
18
20
|
*/
|
|
19
21
|
initialize(): Promise<void>;
|
|
22
|
+
/**
|
|
23
|
+
* Check if file rotation is needed
|
|
24
|
+
*/
|
|
25
|
+
private shouldRotate;
|
|
26
|
+
/**
|
|
27
|
+
* Rotate log files
|
|
28
|
+
*/
|
|
29
|
+
private rotateFiles;
|
|
20
30
|
/**
|
|
21
31
|
* Write a log entry to the JSONL file
|
|
22
32
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"jsonl-writer.d.ts","sourceRoot":"","sources":["../../../../src/commands/generate-shot-list/logger/jsonl-writer.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;
|
|
1
|
+
{"version":3,"file":"jsonl-writer.d.ts","sourceRoot":"","sources":["../../../../src/commands/generate-shot-list/logger/jsonl-writer.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAYH;;GAEG;AACH,qBAAa,WAAW;IACtB,OAAO,CAAC,QAAQ,CAAS;IACzB,OAAO,CAAC,UAAU,CAAoC;IACtD,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,UAAU,CAAS;gBAEf,QAAQ,EAAE,MAAM,EAAE,WAAW,GAAE,MAAyB,EAAE,UAAU,GAAE,MAAU;IAM5F;;OAEG;IACG,UAAU,IAAI,OAAO,CAAC,IAAI,CAAC;IAWjC;;OAEG;YACW,YAAY;IAU1B;;OAEG;YACW,WAAW;IAoCzB;;;;OAIG;IACG,KAAK,CAAC,KAAK,EAAE,GAAG,GAAG,OAAO,CAAC,IAAI,CAAC;IAwBtC;;OAEG;IACG,SAAS,CAAC,OAAO,EAAE,GAAG,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC;IAM9C;;OAEG;IACG,KAAK,IAAI,OAAO,CAAC,IAAI,CAAC;IAI5B;;OAEG;IACH,WAAW,IAAI,MAAM;CAGtB;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,QAAQ,EAAE,MAAM,GAAG,WAAW,CAE/D"}
|
|
@@ -49,13 +49,17 @@ const util_1 = require("util");
|
|
|
49
49
|
const appendFile = (0, util_1.promisify)(fs.appendFile);
|
|
50
50
|
const mkdir = (0, util_1.promisify)(fs.mkdir);
|
|
51
51
|
const access = (0, util_1.promisify)(fs.access);
|
|
52
|
+
const stat = (0, util_1.promisify)(fs.stat);
|
|
53
|
+
const rename = (0, util_1.promisify)(fs.rename);
|
|
52
54
|
/**
|
|
53
55
|
* JSONL Writer class
|
|
54
56
|
*/
|
|
55
57
|
class JSONLWriter {
|
|
56
|
-
constructor(filePath) {
|
|
58
|
+
constructor(filePath, maxFileSize = 10 * 1024 * 1024, maxBackups = 5) {
|
|
57
59
|
this.writeQueue = Promise.resolve();
|
|
58
60
|
this.filePath = filePath;
|
|
61
|
+
this.maxFileSize = maxFileSize;
|
|
62
|
+
this.maxBackups = maxBackups;
|
|
59
63
|
}
|
|
60
64
|
/**
|
|
61
65
|
* Initialize the writer (create directory if needed)
|
|
@@ -70,6 +74,58 @@ class JSONLWriter {
|
|
|
70
74
|
await mkdir(dir, { recursive: true });
|
|
71
75
|
}
|
|
72
76
|
}
|
|
77
|
+
/**
|
|
78
|
+
* Check if file rotation is needed
|
|
79
|
+
*/
|
|
80
|
+
async shouldRotate() {
|
|
81
|
+
try {
|
|
82
|
+
const stats = await stat(this.filePath);
|
|
83
|
+
return stats.size >= this.maxFileSize;
|
|
84
|
+
}
|
|
85
|
+
catch {
|
|
86
|
+
// File doesn't exist yet
|
|
87
|
+
return false;
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
/**
|
|
91
|
+
* Rotate log files
|
|
92
|
+
*/
|
|
93
|
+
async rotateFiles() {
|
|
94
|
+
try {
|
|
95
|
+
// Delete oldest backup if we're at max backups
|
|
96
|
+
const oldestBackup = `${this.filePath}.${this.maxBackups}`;
|
|
97
|
+
try {
|
|
98
|
+
await access(oldestBackup);
|
|
99
|
+
await fs.promises.unlink(oldestBackup);
|
|
100
|
+
}
|
|
101
|
+
catch {
|
|
102
|
+
// File doesn't exist, that's fine
|
|
103
|
+
}
|
|
104
|
+
// Rotate existing backups
|
|
105
|
+
for (let i = this.maxBackups - 1; i >= 1; i--) {
|
|
106
|
+
const oldPath = `${this.filePath}.${i}`;
|
|
107
|
+
const newPath = `${this.filePath}.${i + 1}`;
|
|
108
|
+
try {
|
|
109
|
+
await access(oldPath);
|
|
110
|
+
await rename(oldPath, newPath);
|
|
111
|
+
}
|
|
112
|
+
catch {
|
|
113
|
+
// File doesn't exist, skip
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
// Rotate current file to .1
|
|
117
|
+
try {
|
|
118
|
+
await access(this.filePath);
|
|
119
|
+
await rename(this.filePath, `${this.filePath}.1`);
|
|
120
|
+
}
|
|
121
|
+
catch {
|
|
122
|
+
// File doesn't exist, that's fine
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
catch (error) {
|
|
126
|
+
console.error('Failed to rotate log files:', error);
|
|
127
|
+
}
|
|
128
|
+
}
|
|
73
129
|
/**
|
|
74
130
|
* Write a log entry to the JSONL file
|
|
75
131
|
*
|
|
@@ -79,6 +135,10 @@ class JSONLWriter {
|
|
|
79
135
|
// Queue the write to ensure sequential writes
|
|
80
136
|
this.writeQueue = this.writeQueue.then(async () => {
|
|
81
137
|
try {
|
|
138
|
+
// Check if rotation is needed
|
|
139
|
+
if (await this.shouldRotate()) {
|
|
140
|
+
await this.rotateFiles();
|
|
141
|
+
}
|
|
82
142
|
// Convert entry to JSON and add newline
|
|
83
143
|
const line = JSON.stringify(entry) + '\n';
|
|
84
144
|
// Append to file atomically
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"jsonl-writer.js","sourceRoot":"","sources":["../../../../src/commands/generate-shot-list/logger/jsonl-writer.ts"],"names":[],"mappings":";AAAA;;;;;;;GAOG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"jsonl-writer.js","sourceRoot":"","sources":["../../../../src/commands/generate-shot-list/logger/jsonl-writer.ts"],"names":[],"mappings":";AA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AgB;IAChD,OAAO,IAAI,WAAW,CAAC,QAAQ,CAAC,CAAC;AACnC,CAAC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { Parser, Screenplay } from './types';
|
|
2
|
+
/**
|
|
3
|
+
* Parser for Microsoft Word (.doc, .docx) format
|
|
4
|
+
*
|
|
5
|
+
* Extracts text from Word documents and delegates to PlainTextParser for screenplay parsing.
|
|
6
|
+
* Requires mammoth library for DOCX extraction.
|
|
7
|
+
*/
|
|
8
|
+
export declare class DOCXParser implements Parser {
|
|
9
|
+
private plainTextParser;
|
|
10
|
+
private mammoth;
|
|
11
|
+
constructor();
|
|
12
|
+
getName(): string;
|
|
13
|
+
canParse(content: string | Buffer, filePath?: string): boolean;
|
|
14
|
+
parse(content: string | Buffer): Promise<Screenplay>;
|
|
15
|
+
/**
|
|
16
|
+
* Convert HTML from mammoth to screenplay-formatted text
|
|
17
|
+
* Maps HTML styles to screenplay elements:
|
|
18
|
+
* - <h1>, <h2> → Scene headings
|
|
19
|
+
* - <strong>, <b> with ALL CAPS → Character names
|
|
20
|
+
* - Indented paragraphs → Dialogue
|
|
21
|
+
* - Regular paragraphs → Action
|
|
22
|
+
*/
|
|
23
|
+
private convertHtmlToScreenplayText;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Helper function to read DOCX file and parse it
|
|
27
|
+
*/
|
|
28
|
+
export declare function parseDOCXFile(filePath: string): Promise<Screenplay>;
|
|
29
|
+
//# sourceMappingURL=docx-parser.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"docx-parser.d.ts","sourceRoot":"","sources":["../../../../src/commands/generate-shot-list/parser/docx-parser.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAG7C;;;;;GAKG;AACH,qBAAa,UAAW,YAAW,MAAM;IACvC,OAAO,CAAC,eAAe,CAAkB;IACzC,OAAO,CAAC,OAAO,CAAM;;IAerB,OAAO,IAAI,MAAM;IAIjB,QAAQ,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,EAAE,QAAQ,CAAC,EAAE,MAAM,GAAG,OAAO;IAWxD,KAAK,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC,UAAU,CAAC;IA6C1D;;;;;;;OAOG;IACH,OAAO,CAAC,2BAA2B;CAsBpC;AAED;;GAEG;AACH,wBAAsB,aAAa,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,CAAC,CAKzE"}
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DOCXParser = void 0;
|
|
4
|
+
exports.parseDOCXFile = parseDOCXFile;
|
|
5
|
+
const plaintext_parser_1 = require("./plaintext-parser");
|
|
6
|
+
/**
|
|
7
|
+
* Parser for Microsoft Word (.doc, .docx) format
|
|
8
|
+
*
|
|
9
|
+
* Extracts text from Word documents and delegates to PlainTextParser for screenplay parsing.
|
|
10
|
+
* Requires mammoth library for DOCX extraction.
|
|
11
|
+
*/
|
|
12
|
+
class DOCXParser {
|
|
13
|
+
constructor() {
|
|
14
|
+
this.plainTextParser = new plaintext_parser_1.PlainTextParser();
|
|
15
|
+
// Lazy load mammoth to avoid bundling issues
|
|
16
|
+
try {
|
|
17
|
+
this.mammoth = require('mammoth');
|
|
18
|
+
}
|
|
19
|
+
catch (error) {
|
|
20
|
+
throw new Error('mammoth library is required for DOCX parsing. Install it with: npm install mammoth');
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
getName() {
|
|
24
|
+
return 'DOCX';
|
|
25
|
+
}
|
|
26
|
+
canParse(content, filePath) {
|
|
27
|
+
// Check file extension
|
|
28
|
+
if (filePath && /\.(docx?|doc)$/i.test(filePath)) {
|
|
29
|
+
return true;
|
|
30
|
+
}
|
|
31
|
+
// Check for DOCX magic number (PK zip archive)
|
|
32
|
+
const contentStr = typeof content === 'string' ? content : content.toString('binary');
|
|
33
|
+
return contentStr.startsWith('PK\x03\x04');
|
|
34
|
+
}
|
|
35
|
+
async parse(content) {
|
|
36
|
+
// Convert string to Buffer if needed
|
|
37
|
+
const buffer = typeof content === 'string'
|
|
38
|
+
? Buffer.from(content, 'binary')
|
|
39
|
+
: content;
|
|
40
|
+
try {
|
|
41
|
+
// Extract HTML with styles preserved
|
|
42
|
+
const result = await this.mammoth.convertToHtml({ buffer });
|
|
43
|
+
const html = result.value;
|
|
44
|
+
if (!html || html.trim().length === 0) {
|
|
45
|
+
throw new Error('DOCX contains no extractable content');
|
|
46
|
+
}
|
|
47
|
+
// Parse HTML to extract screenplay elements with style information
|
|
48
|
+
const text = this.convertHtmlToScreenplayText(html);
|
|
49
|
+
if (!text || text.trim().length === 0) {
|
|
50
|
+
throw new Error('DOCX contains no extractable text');
|
|
51
|
+
}
|
|
52
|
+
// Parse extracted text as plain text screenplay
|
|
53
|
+
const screenplay = this.plainTextParser.parse(text);
|
|
54
|
+
// Update format metadata
|
|
55
|
+
screenplay.format = 'docx';
|
|
56
|
+
screenplay.metadata = {
|
|
57
|
+
...screenplay.metadata,
|
|
58
|
+
format: 'docx',
|
|
59
|
+
originalFormat: 'docx',
|
|
60
|
+
extractedText: true,
|
|
61
|
+
extractedHtml: true,
|
|
62
|
+
messages: result.messages,
|
|
63
|
+
};
|
|
64
|
+
return screenplay;
|
|
65
|
+
}
|
|
66
|
+
catch (error) {
|
|
67
|
+
if (error instanceof Error) {
|
|
68
|
+
throw new Error(`Failed to parse DOCX: ${error.message}`);
|
|
69
|
+
}
|
|
70
|
+
throw error;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* Convert HTML from mammoth to screenplay-formatted text
|
|
75
|
+
* Maps HTML styles to screenplay elements:
|
|
76
|
+
* - <h1>, <h2> → Scene headings
|
|
77
|
+
* - <strong>, <b> with ALL CAPS → Character names
|
|
78
|
+
* - Indented paragraphs → Dialogue
|
|
79
|
+
* - Regular paragraphs → Action
|
|
80
|
+
*/
|
|
81
|
+
convertHtmlToScreenplayText(html) {
|
|
82
|
+
const lines = [];
|
|
83
|
+
// Simple HTML parser - extract text from tags
|
|
84
|
+
// Remove HTML tags but preserve structure
|
|
85
|
+
let text = html
|
|
86
|
+
.replace(/<h[12]>(.*?)<\/h[12]>/gi, '\n$1\n') // Headings as scene headings
|
|
87
|
+
.replace(/<strong>(.*?)<\/strong>/gi, '$1') // Preserve bold text
|
|
88
|
+
.replace(/<b>(.*?)<\/b>/gi, '$1') // Preserve bold text
|
|
89
|
+
.replace(/<p[^>]*>(.*?)<\/p>/gi, '\n$1\n') // Paragraphs
|
|
90
|
+
.replace(/<br\s*\/?>/gi, '\n') // Line breaks
|
|
91
|
+
.replace(/<[^>]+>/g, '') // Remove remaining tags
|
|
92
|
+
.replace(/ /g, ' ') // Replace
|
|
93
|
+
.replace(/&/g, '&') // Replace &
|
|
94
|
+
.replace(/</g, '<') // Replace <
|
|
95
|
+
.replace(/>/g, '>') // Replace >
|
|
96
|
+
.replace(/"/g, '"') // Replace "
|
|
97
|
+
.trim();
|
|
98
|
+
return text;
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
exports.DOCXParser = DOCXParser;
|
|
102
|
+
/**
|
|
103
|
+
* Helper function to read DOCX file and parse it
|
|
104
|
+
*/
|
|
105
|
+
async function parseDOCXFile(filePath) {
|
|
106
|
+
const fs = require('fs').promises;
|
|
107
|
+
const buffer = await fs.readFile(filePath);
|
|
108
|
+
const parser = new DOCXParser();
|
|
109
|
+
return parser.parse(buffer);
|
|
110
|
+
}
|
|
111
|
+
//# sourceMappingURL=docx-parser.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"docx-parser.js","sourceRoot":"","sources":["../../../../src/commands/generate-shot-list/parser/docx-parser.ts"],"names":[],"mappings":";;;AAyHA,sCAKC;AA7HD,yDAAqD;AAErD;;;;;GAKG;A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aAAa;aAC5D,OAAO,CAAC,cAAc,EAAE,IAAI,CAAC,CAAkB,cAAc;aAC7D,OAAO,CAAC,UAAU,EAAE,EAAE,CAAC,CAAwB,wBAAwB;aACvE,OAAO,CAAC,SAAS,EAAE,GAAG,CAAC,CAAwB,iBAAiB;aAChE,OAAO,CAAC,QAAQ,EAAE,GAAG,CAAC,CAAyB,gBAAgB;aAC/D,OAAO,CAAC,OAAO,EAAE,GAAG,CAAC,CAA0B,eAAe;aAC9D,OAAO,CAAC,OAAO,EAAE,GAAG,CAAC,CAA0B,eAAe;aAC9D,OAAO,CAAC,SAAS,EAAE,GAAG,CAAC,CAAwB,iBAAiB;aAChE,IAAI,EAAE,CAAC;QAEV,OAAO,IAAI,CAAC;IACd,CAAC;CAEF;AA3GD,gCA2GC;AAED;;GAEG;AACI,KAAK,UAAU,aAAa,CAAC,QAAgB;IAClD,MAAM,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC,QAAQ,CAAC;IAClC,MAAM,MAAM,GAAG,MAAM,EAAE,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;IAC3C,MAAM,MAAM,GAAG,IAAI,UAAU,EAAE,CAAC;IAChC,OAAO,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;AAC9B,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Parser, Screenplay } from './types';
|
|
2
|
+
/**
|
|
3
|
+
* Parser for Final Draft XML (.fdx) format
|
|
4
|
+
*
|
|
5
|
+
* Final Draft is the industry-standard professional screenwriting software.
|
|
6
|
+
* The .fdx format is XML-based with specific paragraph types for screenplay elements.
|
|
7
|
+
*/
|
|
8
|
+
export declare class FinalDraftParser implements Parser {
|
|
9
|
+
private xmlParser;
|
|
10
|
+
constructor();
|
|
11
|
+
getName(): string;
|
|
12
|
+
canParse(content: string, filePath?: string): boolean;
|
|
13
|
+
parse(content: string): Screenplay;
|
|
14
|
+
private extractText;
|
|
15
|
+
private parseSceneHeading;
|
|
16
|
+
private parseElement;
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=finaldraft-parser.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"finaldraft-parser.d.ts","sourceRoot":"","sources":["../../../../src/commands/generate-shot-list/parser/finaldraft-parser.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,UAAU,EAAsD,MAAM,SAAS,CAAC;AAGjG;;;;;GAKG;AACH,qBAAa,gBAAiB,YAAW,MAAM;IAC7C,OAAO,CAAC,SAAS,CAAY;;IAY7B,OAAO,IAAI,MAAM;IAIjB,QAAQ,CAAC,OAAO,EAAE,MAAM,EAAE,QAAQ,CAAC,EAAE,MAAM,GAAG,OAAO;IAUrD,KAAK,CAAC,OAAO,EAAE,MAAM,GAAG,UAAU;IA8FlC,OAAO,CAAC,WAAW;IAcnB,OAAO,CAAC,iBAAiB;IAuBzB,OAAO,CAAC,YAAY;CAuCrB"}
|
|
@@ -0,0 +1,184 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.FinalDraftParser = void 0;
|
|
4
|
+
const fast_xml_parser_1 = require("fast-xml-parser");
|
|
5
|
+
/**
|
|
6
|
+
* Parser for Final Draft XML (.fdx) format
|
|
7
|
+
*
|
|
8
|
+
* Final Draft is the industry-standard professional screenwriting software.
|
|
9
|
+
* The .fdx format is XML-based with specific paragraph types for screenplay elements.
|
|
10
|
+
*/
|
|
11
|
+
class FinalDraftParser {
|
|
12
|
+
constructor() {
|
|
13
|
+
this.xmlParser = new fast_xml_parser_1.XMLParser({
|
|
14
|
+
ignoreAttributes: false,
|
|
15
|
+
attributeNamePrefix: '@_',
|
|
16
|
+
textNodeName: '#text',
|
|
17
|
+
parseAttributeValue: true,
|
|
18
|
+
trimValues: true,
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
getName() {
|
|
22
|
+
return 'FinalDraft';
|
|
23
|
+
}
|
|
24
|
+
canParse(content, filePath) {
|
|
25
|
+
// Check file extension
|
|
26
|
+
if (filePath && /\.fdx$/i.test(filePath)) {
|
|
27
|
+
return true;
|
|
28
|
+
}
|
|
29
|
+
// Check for Final Draft XML structure
|
|
30
|
+
return content.includes('<FinalDraft') && content.includes('</FinalDraft>');
|
|
31
|
+
}
|
|
32
|
+
parse(content) {
|
|
33
|
+
const parsed = this.xmlParser.parse(content);
|
|
34
|
+
if (!parsed.FinalDraft) {
|
|
35
|
+
throw new Error('Invalid Final Draft XML: Missing FinalDraft root element');
|
|
36
|
+
}
|
|
37
|
+
const fdx = parsed.FinalDraft;
|
|
38
|
+
const content_elem = fdx.Content;
|
|
39
|
+
if (!content_elem || !content_elem.Paragraph) {
|
|
40
|
+
throw new Error('Invalid Final Draft XML: Missing Content or Paragraph elements');
|
|
41
|
+
}
|
|
42
|
+
// Extract title and author from TitlePage if available
|
|
43
|
+
let title = 'Untitled';
|
|
44
|
+
let author;
|
|
45
|
+
if (fdx.TitlePage && fdx.TitlePage.Content && fdx.TitlePage.Content.Paragraph) {
|
|
46
|
+
const titleParas = Array.isArray(fdx.TitlePage.Content.Paragraph)
|
|
47
|
+
? fdx.TitlePage.Content.Paragraph
|
|
48
|
+
: [fdx.TitlePage.Content.Paragraph];
|
|
49
|
+
for (const para of titleParas) {
|
|
50
|
+
const type = para['@_Type'];
|
|
51
|
+
const text = this.extractText(para);
|
|
52
|
+
if (type === 'Title' && text) {
|
|
53
|
+
title = text;
|
|
54
|
+
}
|
|
55
|
+
else if (type === 'Authors' && text) {
|
|
56
|
+
author = text;
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
// Parse paragraphs into scenes
|
|
61
|
+
const paragraphs = Array.isArray(content_elem.Paragraph)
|
|
62
|
+
? content_elem.Paragraph
|
|
63
|
+
: [content_elem.Paragraph];
|
|
64
|
+
const scenes = [];
|
|
65
|
+
let currentScene = null;
|
|
66
|
+
let lineNumber = 0;
|
|
67
|
+
for (const para of paragraphs) {
|
|
68
|
+
const type = para['@_Type'];
|
|
69
|
+
const text = this.extractText(para);
|
|
70
|
+
lineNumber++;
|
|
71
|
+
if (!text)
|
|
72
|
+
continue;
|
|
73
|
+
if (type === 'Scene Heading') {
|
|
74
|
+
// Start new scene
|
|
75
|
+
if (currentScene) {
|
|
76
|
+
currentScene.endLine = lineNumber - 1;
|
|
77
|
+
scenes.push(currentScene);
|
|
78
|
+
}
|
|
79
|
+
const heading = this.parseSceneHeading(text);
|
|
80
|
+
currentScene = {
|
|
81
|
+
number: scenes.length + 1,
|
|
82
|
+
heading,
|
|
83
|
+
elements: [],
|
|
84
|
+
startLine: lineNumber,
|
|
85
|
+
endLine: lineNumber,
|
|
86
|
+
};
|
|
87
|
+
}
|
|
88
|
+
else if (currentScene) {
|
|
89
|
+
// Add element to current scene
|
|
90
|
+
const element = this.parseElement(type, text, lineNumber);
|
|
91
|
+
if (element) {
|
|
92
|
+
currentScene.elements.push(element);
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
// Add final scene
|
|
97
|
+
if (currentScene) {
|
|
98
|
+
currentScene.endLine = lineNumber;
|
|
99
|
+
scenes.push(currentScene);
|
|
100
|
+
}
|
|
101
|
+
return {
|
|
102
|
+
title,
|
|
103
|
+
author,
|
|
104
|
+
scenes,
|
|
105
|
+
format: 'finaldraft',
|
|
106
|
+
metadata: {
|
|
107
|
+
format: 'finaldraft',
|
|
108
|
+
totalScenes: scenes.length,
|
|
109
|
+
parsedAt: new Date().toISOString(),
|
|
110
|
+
},
|
|
111
|
+
};
|
|
112
|
+
}
|
|
113
|
+
extractText(para) {
|
|
114
|
+
if (!para.Text)
|
|
115
|
+
return '';
|
|
116
|
+
const texts = Array.isArray(para.Text) ? para.Text : [para.Text];
|
|
117
|
+
return texts
|
|
118
|
+
.map((t) => {
|
|
119
|
+
if (typeof t === 'string')
|
|
120
|
+
return t;
|
|
121
|
+
if (t['#text'])
|
|
122
|
+
return t['#text'];
|
|
123
|
+
return '';
|
|
124
|
+
})
|
|
125
|
+
.join('')
|
|
126
|
+
.trim();
|
|
127
|
+
}
|
|
128
|
+
parseSceneHeading(text) {
|
|
129
|
+
// Match INT/EXT. LOCATION - TIME
|
|
130
|
+
const match = text.match(/^(INT\.|EXT\.|INT\/EXT\.|EXT\/INT\.)\s+(.+?)(?:\s+-\s+(.+))?$/i);
|
|
131
|
+
if (match) {
|
|
132
|
+
const intExt = match[1].replace('.', '').toUpperCase();
|
|
133
|
+
return {
|
|
134
|
+
intExt,
|
|
135
|
+
location: match[2].trim(),
|
|
136
|
+
timeOfDay: match[3]?.trim() || '',
|
|
137
|
+
raw: text,
|
|
138
|
+
};
|
|
139
|
+
}
|
|
140
|
+
// Default to INT if no match
|
|
141
|
+
return {
|
|
142
|
+
intExt: 'INT',
|
|
143
|
+
location: text,
|
|
144
|
+
timeOfDay: '',
|
|
145
|
+
raw: text,
|
|
146
|
+
};
|
|
147
|
+
}
|
|
148
|
+
parseElement(type, text, line) {
|
|
149
|
+
switch (type) {
|
|
150
|
+
case 'Action':
|
|
151
|
+
return { type: 'action', text, line, column: 0 };
|
|
152
|
+
case 'Character':
|
|
153
|
+
return {
|
|
154
|
+
type: 'dialogue',
|
|
155
|
+
dialogue: { character: { name: text }, speech: '' },
|
|
156
|
+
text: text,
|
|
157
|
+
line,
|
|
158
|
+
column: 0
|
|
159
|
+
};
|
|
160
|
+
case 'Dialogue':
|
|
161
|
+
return {
|
|
162
|
+
type: 'dialogue',
|
|
163
|
+
dialogue: { character: { name: '' }, speech: text },
|
|
164
|
+
text: text,
|
|
165
|
+
line,
|
|
166
|
+
column: 0
|
|
167
|
+
};
|
|
168
|
+
case 'Parenthetical':
|
|
169
|
+
return {
|
|
170
|
+
type: 'dialogue',
|
|
171
|
+
dialogue: { character: { name: '' }, parenthetical: text, speech: '' },
|
|
172
|
+
text: text,
|
|
173
|
+
line,
|
|
174
|
+
column: 0
|
|
175
|
+
};
|
|
176
|
+
case 'Transition':
|
|
177
|
+
return { type: 'transition', text, line, column: 0 };
|
|
178
|
+
default:
|
|
179
|
+
return null;
|
|
180
|
+
}
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
exports.FinalDraftParser = FinalDraftParser;
|
|
184
|
+
//# sourceMappingURL=finaldraft-parser.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"finaldraft-parser.js","sourceRoot":"","sources":["../../../../src/commands/generate-shot-list/parser/finaldraft-parser.ts"],"names":[],"mappings":";;;AACA,qDAA4C;AAE5C;;;;;GAKG;AACH,MAAa,gBAAgB;IAG3B;QACE,IAAI,CAAC,SAAS,GAAG,IAAI,2BAAS,CAAC;YAC7B,gBAAgB,EAAE,KAAK;YACvB,mBAAmB,EAAE,IAAI;YACzB,YAAY,EAAE,OAAO;YACrB,mBAAmB,EAAE,IAAI;YACzB,UAAU,EAAE,IAAI;SACjB,CAAC,CAAC;IACL,CAAC;IAED,OAAO;QACL,OAAO,YAAY,CAAC;IACtB,CAAC;IAED,QAAQ,CAAC,OAAe,EAAE,QAAiB;QACzC,uBAAuB;QACvB,IAAI,QAAQ,IAAI,SAAS,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC;YACzC,OAAO,IAAI,CAAC;QACd,CAAC;QAED,sCAAsC;QACtC,OAAO,OAAO,CAAC,QAAQ,CAAC,aAAa,CAAC,IAAI,OAAO,CAAC,QAAQ,CAAC,eAAe,CAAC,CAAC;IAC9E,CAAC;IAED,KAAK,CAAC,OAAe;QACnB,MAAM,MAAM,GAAG,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QAE7C,IAAI,CAAC,MAAM,CAAC,UAAU,EAAE,CAAC;YACvB,MAAM,IAAI,KAAK,CAAC,0DAA0D,CAAC,CAAC;QAC9E,CAAC;QAED,MAAM,GAAG,GAAG,MAAM,CAAC,UAAU,CAAC;QAC9B,MAAM,YAAY,GAAG,GAAG,C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|
11
11
|
/**
|
|
12
12
|
* Detect format from file extension
|
|
13
13
|
*/
|
|
14
|
-
export declare function detectFormatFromExtension(filename: string): 'fountain' | 'markdown' | 'plaintext' | null;
|
|
14
|
+
export declare function detectFormatFromExtension(filename: string): 'fountain' | 'markdown' | 'plaintext' | 'finaldraft' | 'pdf' | 'docx' | 'rtf' | null;
|
|
15
15
|
/**
|
|
16
16
|
* Detect format from content analysis
|
|
17
|
+
* Handles both text-based and binary format detection
|
|
17
18
|
*/
|
|
18
|
-
export declare function detectFormatFromContent(content: string): 'fountain' | 'markdown' | 'plaintext';
|
|
19
|
+
export declare function detectFormatFromContent(content: string | Buffer): 'fountain' | 'markdown' | 'plaintext' | 'finaldraft' | 'pdf' | 'docx' | 'rtf';
|
|
19
20
|
/**
|
|
20
21
|
* Auto-detect format and create appropriate parser
|
|
21
22
|
*/
|
|
22
|
-
export declare function createParserAuto(filename: string, content: string): Parser;
|
|
23
|
+
export declare function createParserAuto(filename: string, content: string | Buffer): Parser;
|
|
23
24
|
export * from './types';
|
|
24
25
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/commands/generate-shot-list/parser/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,MAAM,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/commands/generate-shot-list/parser/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,MAAM,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAShD;;GAEG;AACH,eAAO,MAAM,YAAY,EAAE,aAmB1B,CAAC;AAEF;;GAEG;AACH,wBAAgB,yBAAyB,CAAC,QAAQ,EAAE,MAAM,GAAG,UAAU,GAAG,UAAU,GAAG,WAAW,GAAG,YAAY,GAAG,KAAK,GAAG,MAAM,GAAG,KAAK,GAAG,IAAI,CAuBhJ;AAED;;;GAGG;AACH,wBAAgB,uBAAuB,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,GAAG,UAAU,GAAG,UAAU,GAAG,WAAW,GAAG,YAAY,GAAG,KAAK,GAAG,MAAM,GAAG,KAAK,CA8E/I;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,CAUnF;AAGD,cAAc,SAAS,CAAC"}
|