varg.ai-sdk 0.1.0 → 0.4.0-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (236) hide show
  1. package/.claude/settings.local.json +1 -1
  2. package/.env.example +3 -0
  3. package/.github/workflows/ci.yml +23 -0
  4. package/.husky/README.md +102 -0
  5. package/.husky/commit-msg +6 -0
  6. package/.husky/pre-commit +9 -0
  7. package/.husky/pre-push +6 -0
  8. package/.size-limit.json +8 -0
  9. package/.test-hooks.ts +5 -0
  10. package/CLAUDE.md +10 -3
  11. package/CONTRIBUTING.md +150 -0
  12. package/LICENSE.md +53 -0
  13. package/README.md +56 -209
  14. package/SKILLS.md +26 -10
  15. package/biome.json +7 -1
  16. package/bun.lock +1286 -0
  17. package/commitlint.config.js +22 -0
  18. package/docs/index.html +1130 -0
  19. package/docs/prompting.md +326 -0
  20. package/docs/react.md +834 -0
  21. package/docs/sdk.md +812 -0
  22. package/ffmpeg/CLAUDE.md +68 -0
  23. package/package.json +48 -8
  24. package/pipeline/cookbooks/scripts/animate-frames-parallel.ts +84 -0
  25. package/pipeline/cookbooks/scripts/combine-scenes.sh +53 -0
  26. package/pipeline/cookbooks/scripts/generate-frames-parallel.ts +99 -0
  27. package/pipeline/cookbooks/scripts/still-to-video.sh +37 -0
  28. package/pipeline/cookbooks/text-to-tiktok.md +669 -0
  29. package/pipeline/cookbooks/trendwatching.md +156 -0
  30. package/plan.md +281 -0
  31. package/scripts/.gitkeep +0 -0
  32. package/src/ai-sdk/cache.ts +142 -0
  33. package/src/ai-sdk/examples/cached-generation.ts +53 -0
  34. package/src/ai-sdk/examples/duet-scene-4.ts +53 -0
  35. package/src/ai-sdk/examples/duet-scene-5-audio.ts +32 -0
  36. package/src/ai-sdk/examples/duet-video.ts +56 -0
  37. package/src/ai-sdk/examples/editly-composition.ts +63 -0
  38. package/src/ai-sdk/examples/editly-test.ts +57 -0
  39. package/src/ai-sdk/examples/editly-video-test.ts +52 -0
  40. package/src/ai-sdk/examples/fal-lipsync.ts +43 -0
  41. package/src/ai-sdk/examples/higgsfield-image.ts +61 -0
  42. package/src/ai-sdk/examples/music-generation.ts +19 -0
  43. package/src/ai-sdk/examples/openai-sora.ts +34 -0
  44. package/src/ai-sdk/examples/replicate-bg-removal.ts +52 -0
  45. package/src/ai-sdk/examples/simpsons-scene.ts +61 -0
  46. package/src/ai-sdk/examples/talking-lion.ts +55 -0
  47. package/src/ai-sdk/examples/video-generation.ts +39 -0
  48. package/src/ai-sdk/examples/workflow-animated-girl.ts +104 -0
  49. package/src/ai-sdk/examples/workflow-before-after.ts +114 -0
  50. package/src/ai-sdk/examples/workflow-character-grid.ts +112 -0
  51. package/src/ai-sdk/examples/workflow-slideshow.ts +161 -0
  52. package/src/ai-sdk/file-cache.ts +112 -0
  53. package/src/ai-sdk/file.ts +238 -0
  54. package/src/ai-sdk/generate-element.ts +92 -0
  55. package/src/ai-sdk/generate-music.ts +46 -0
  56. package/src/ai-sdk/generate-video.ts +165 -0
  57. package/src/ai-sdk/index.ts +72 -0
  58. package/src/ai-sdk/music-model.ts +110 -0
  59. package/src/ai-sdk/providers/editly/editly.test.ts +1108 -0
  60. package/src/ai-sdk/providers/editly/ffmpeg.ts +60 -0
  61. package/src/ai-sdk/providers/editly/index.ts +817 -0
  62. package/src/ai-sdk/providers/editly/layers.ts +776 -0
  63. package/src/ai-sdk/providers/editly/plan.md +144 -0
  64. package/src/ai-sdk/providers/editly/types.ts +328 -0
  65. package/src/ai-sdk/providers/elevenlabs-provider.ts +255 -0
  66. package/src/ai-sdk/providers/fal-provider.ts +512 -0
  67. package/src/ai-sdk/providers/higgsfield.ts +379 -0
  68. package/src/ai-sdk/providers/openai.ts +251 -0
  69. package/src/ai-sdk/providers/replicate.ts +16 -0
  70. package/src/ai-sdk/video-model.ts +185 -0
  71. package/src/cli/commands/find.tsx +137 -0
  72. package/src/cli/commands/help.tsx +85 -0
  73. package/src/cli/commands/index.ts +6 -0
  74. package/src/cli/commands/list.tsx +238 -0
  75. package/src/cli/commands/render.tsx +71 -0
  76. package/src/cli/commands/run.tsx +511 -0
  77. package/src/cli/commands/which.tsx +253 -0
  78. package/src/cli/index.ts +114 -0
  79. package/src/cli/quiet.ts +44 -0
  80. package/src/cli/types.ts +32 -0
  81. package/src/cli/ui/components/Badge.tsx +29 -0
  82. package/src/cli/ui/components/DataTable.tsx +51 -0
  83. package/src/cli/ui/components/Header.tsx +23 -0
  84. package/src/cli/ui/components/HelpBlock.tsx +44 -0
  85. package/src/cli/ui/components/KeyValue.tsx +33 -0
  86. package/src/cli/ui/components/OptionRow.tsx +81 -0
  87. package/src/cli/ui/components/Separator.tsx +23 -0
  88. package/src/cli/ui/components/StatusBox.tsx +108 -0
  89. package/src/cli/ui/components/VargBox.tsx +51 -0
  90. package/src/cli/ui/components/VargProgress.tsx +36 -0
  91. package/src/cli/ui/components/VargSpinner.tsx +34 -0
  92. package/src/cli/ui/components/VargText.tsx +56 -0
  93. package/src/cli/ui/components/index.ts +19 -0
  94. package/src/cli/ui/index.ts +12 -0
  95. package/src/cli/ui/render.ts +35 -0
  96. package/src/cli/ui/theme.ts +63 -0
  97. package/src/cli/utils.ts +78 -0
  98. package/src/core/executor/executor.ts +201 -0
  99. package/src/core/executor/index.ts +13 -0
  100. package/src/core/executor/job.ts +214 -0
  101. package/src/core/executor/pipeline.ts +222 -0
  102. package/src/core/index.ts +11 -0
  103. package/src/core/registry/index.ts +9 -0
  104. package/src/core/registry/loader.ts +149 -0
  105. package/src/core/registry/registry.ts +221 -0
  106. package/src/core/registry/resolver.ts +206 -0
  107. package/src/core/schema/helpers.ts +134 -0
  108. package/src/core/schema/index.ts +8 -0
  109. package/src/core/schema/shared.ts +102 -0
  110. package/src/core/schema/types.ts +279 -0
  111. package/src/core/schema/validator.ts +92 -0
  112. package/src/definitions/actions/captions.ts +261 -0
  113. package/src/definitions/actions/edit.ts +298 -0
  114. package/src/definitions/actions/image.ts +125 -0
  115. package/src/definitions/actions/index.ts +114 -0
  116. package/src/definitions/actions/music.ts +205 -0
  117. package/src/definitions/actions/sync.ts +128 -0
  118. package/{action/transcribe/index.ts → src/definitions/actions/transcribe.ts} +63 -90
  119. package/src/definitions/actions/upload.ts +111 -0
  120. package/src/definitions/actions/video.ts +163 -0
  121. package/src/definitions/actions/voice.ts +119 -0
  122. package/src/definitions/index.ts +23 -0
  123. package/src/definitions/models/elevenlabs.ts +50 -0
  124. package/src/definitions/models/flux.ts +56 -0
  125. package/src/definitions/models/index.ts +36 -0
  126. package/src/definitions/models/kling.ts +56 -0
  127. package/src/definitions/models/llama.ts +54 -0
  128. package/src/definitions/models/nano-banana-pro.ts +102 -0
  129. package/src/definitions/models/sonauto.ts +68 -0
  130. package/src/definitions/models/soul.ts +65 -0
  131. package/src/definitions/models/wan.ts +54 -0
  132. package/src/definitions/models/whisper.ts +44 -0
  133. package/src/definitions/skills/index.ts +12 -0
  134. package/src/definitions/skills/talking-character.ts +87 -0
  135. package/src/definitions/skills/text-to-tiktok.ts +97 -0
  136. package/src/index.ts +118 -0
  137. package/src/providers/apify.ts +269 -0
  138. package/src/providers/base.ts +264 -0
  139. package/src/providers/elevenlabs.ts +217 -0
  140. package/src/providers/fal.ts +392 -0
  141. package/src/providers/ffmpeg.ts +544 -0
  142. package/src/providers/fireworks.ts +193 -0
  143. package/src/providers/groq.ts +149 -0
  144. package/src/providers/higgsfield.ts +145 -0
  145. package/src/providers/index.ts +143 -0
  146. package/src/providers/replicate.ts +147 -0
  147. package/src/providers/storage.ts +206 -0
  148. package/src/react/cli.ts +52 -0
  149. package/src/react/elements.ts +146 -0
  150. package/src/react/examples/branching.tsx +66 -0
  151. package/src/react/examples/captions-demo.tsx +37 -0
  152. package/src/react/examples/character-video.tsx +84 -0
  153. package/src/react/examples/grid.tsx +53 -0
  154. package/src/react/examples/layouts-demo.tsx +57 -0
  155. package/src/react/examples/madi.tsx +60 -0
  156. package/src/react/examples/music-test.tsx +35 -0
  157. package/src/react/examples/onlyfans-1m/workflow.tsx +88 -0
  158. package/src/react/examples/orange-portrait.tsx +41 -0
  159. package/src/react/examples/split-element-demo.tsx +60 -0
  160. package/src/react/examples/split-layout-demo.tsx +60 -0
  161. package/src/react/examples/split.tsx +41 -0
  162. package/src/react/examples/video-grid.tsx +46 -0
  163. package/src/react/index.ts +43 -0
  164. package/src/react/layouts/grid.tsx +28 -0
  165. package/src/react/layouts/index.ts +2 -0
  166. package/src/react/layouts/split.tsx +20 -0
  167. package/src/react/react.test.ts +309 -0
  168. package/src/react/render.ts +21 -0
  169. package/src/react/renderers/animate.ts +59 -0
  170. package/src/react/renderers/captions.ts +297 -0
  171. package/src/react/renderers/clip.ts +248 -0
  172. package/src/react/renderers/context.ts +17 -0
  173. package/src/react/renderers/image.ts +109 -0
  174. package/src/react/renderers/index.ts +22 -0
  175. package/src/react/renderers/music.ts +60 -0
  176. package/src/react/renderers/packshot.ts +84 -0
  177. package/src/react/renderers/progress.ts +173 -0
  178. package/src/react/renderers/render.ts +243 -0
  179. package/src/react/renderers/slider.ts +69 -0
  180. package/src/react/renderers/speech.ts +53 -0
  181. package/src/react/renderers/split.ts +91 -0
  182. package/src/react/renderers/subtitle.ts +16 -0
  183. package/src/react/renderers/swipe.ts +75 -0
  184. package/src/react/renderers/title.ts +17 -0
  185. package/src/react/renderers/utils.ts +124 -0
  186. package/src/react/renderers/video.ts +127 -0
  187. package/src/react/runtime/jsx-dev-runtime.ts +43 -0
  188. package/src/react/runtime/jsx-runtime.ts +35 -0
  189. package/src/react/types.ts +232 -0
  190. package/src/studio/index.ts +26 -0
  191. package/src/studio/scanner.ts +102 -0
  192. package/src/studio/server.ts +554 -0
  193. package/src/studio/stages.ts +251 -0
  194. package/src/studio/step-renderer.ts +279 -0
  195. package/src/studio/types.ts +60 -0
  196. package/src/studio/ui/cache.html +303 -0
  197. package/src/studio/ui/index.html +1820 -0
  198. package/src/tests/all.test.ts +509 -0
  199. package/src/tests/index.ts +33 -0
  200. package/src/tests/unit.test.ts +403 -0
  201. package/tsconfig.cli.json +8 -0
  202. package/tsconfig.json +21 -3
  203. package/TEST_RESULTS.md +0 -122
  204. package/action/captions/SKILL.md +0 -170
  205. package/action/captions/index.ts +0 -227
  206. package/action/edit/SKILL.md +0 -235
  207. package/action/edit/index.ts +0 -493
  208. package/action/image/SKILL.md +0 -140
  209. package/action/image/index.ts +0 -112
  210. package/action/sync/SKILL.md +0 -136
  211. package/action/sync/index.ts +0 -187
  212. package/action/transcribe/SKILL.md +0 -179
  213. package/action/video/SKILL.md +0 -116
  214. package/action/video/index.ts +0 -135
  215. package/action/voice/SKILL.md +0 -125
  216. package/action/voice/index.ts +0 -201
  217. package/index.ts +0 -38
  218. package/lib/README.md +0 -144
  219. package/lib/ai-sdk/fal.ts +0 -106
  220. package/lib/ai-sdk/replicate.ts +0 -107
  221. package/lib/elevenlabs.ts +0 -382
  222. package/lib/fal.ts +0 -478
  223. package/lib/ffmpeg.ts +0 -467
  224. package/lib/fireworks.ts +0 -235
  225. package/lib/groq.ts +0 -246
  226. package/lib/higgsfield.ts +0 -176
  227. package/lib/remotion/SKILL.md +0 -823
  228. package/lib/remotion/cli.ts +0 -115
  229. package/lib/remotion/functions.ts +0 -283
  230. package/lib/remotion/index.ts +0 -19
  231. package/lib/remotion/templates.ts +0 -73
  232. package/lib/replicate.ts +0 -304
  233. package/output.txt +0 -1
  234. package/test-import.ts +0 -7
  235. package/test-services.ts +0 -97
  236. package/utilities/s3.ts +0 -147
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "permissions": {
3
- "allow": ["Bash(mkdir:*)"],
3
+ "allow": ["Bash(bun run:*)", "WebFetch(domain:fal.ai)"],
4
4
  "deny": [],
5
5
  "ask": []
6
6
  }
package/.env.example CHANGED
@@ -22,3 +22,6 @@ CLOUDFLARE_R2_BUCKET=m
22
22
 
23
23
  # replicate (optional)
24
24
  REPLICATE_API_TOKEN=r8_xxx
25
+
26
+ # apify (web scraping actors)
27
+ APIFY_TOKEN=apify_api_xxx
@@ -0,0 +1,23 @@
1
+ name: CI
2
+
3
+ on:
4
+ push:
5
+ branches: [main]
6
+ pull_request:
7
+ branches: [main]
8
+
9
+ jobs:
10
+ lint-and-format:
11
+ runs-on: ubuntu-latest
12
+ steps:
13
+ - uses: actions/checkout@v4
14
+
15
+ - uses: oven-sh/setup-bun@v2
16
+ with:
17
+ bun-version: latest
18
+
19
+ - name: Install dependencies
20
+ run: bun install
21
+
22
+ - name: Check
23
+ run: bun run check
@@ -0,0 +1,102 @@
1
+ # Git Hooks Configuration
2
+
3
+ This project uses [Husky](https://typicode.github.io/husky/) to manage Git hooks for maintaining code quality and security.
4
+
5
+ ## Installed Hooks
6
+
7
+ ### `pre-commit`
8
+ Runs before each commit:
9
+ - **Gitleaks** - Scans staged files for secrets and credentials
10
+ - **Lint-staged** - Runs Biome linter/formatter on staged files
11
+
12
+ ### `commit-msg`
13
+ Validates commit messages:
14
+ - **Commitlint** - Enforces [Conventional Commits](https://www.conventionalcommits.org/) format
15
+
16
+ ### `pre-push`
17
+ Runs before pushing to remote:
18
+ - **TypeScript type checking** - Ensures no type errors before push
19
+
20
+ ## Commit Message Format
21
+
22
+ Follow the Conventional Commits specification:
23
+
24
+ ```
25
+ <type>(<scope>): <subject>
26
+
27
+ <body>
28
+
29
+ <footer>
30
+ ```
31
+
32
+ ### Types
33
+ - `feat`: New feature
34
+ - `fix`: Bug fix
35
+ - `docs`: Documentation changes
36
+ - `style`: Code style changes (formatting, etc)
37
+ - `refactor`: Code refactoring
38
+ - `perf`: Performance improvements
39
+ - `test`: Test changes
40
+ - `build`: Build system changes
41
+ - `ci`: CI/CD changes
42
+ - `chore`: Other changes
43
+ - `revert`: Revert previous commit
44
+
45
+ ### Examples
46
+ ```bash
47
+ feat: add video generation API
48
+ fix(transcribe): handle empty audio files
49
+ docs: update installation guide
50
+ refactor: simplify audio processing pipeline
51
+ ```
52
+
53
+ ## Available Scripts
54
+
55
+ ```bash
56
+ # Run linter
57
+ bun run lint
58
+
59
+ # Format code
60
+ bun run format
61
+
62
+ # Type check
63
+ bun run type-check
64
+
65
+ # Check bundle size
66
+ bun run size
67
+ ```
68
+
69
+ ## Bypassing Hooks
70
+
71
+ ⚠️ **Not recommended** - Only use when absolutely necessary:
72
+
73
+ ```bash
74
+ # Skip all hooks
75
+ git commit --no-verify -m "emergency fix"
76
+
77
+ # Skip specific checks by setting env vars
78
+ HUSKY=0 git commit -m "skip all hooks"
79
+ ```
80
+
81
+ ## Troubleshooting
82
+
83
+ If hooks aren't running:
84
+
85
+ ```bash
86
+ # Reinstall hooks
87
+ rm -rf .husky/_
88
+ bun run prepare
89
+ chmod +x .husky/pre-commit .husky/commit-msg .husky/pre-push
90
+ ```
91
+
92
+ ## Size Limits
93
+
94
+ Bundle size limits are defined in `.size-limit.json`. Check size before publishing:
95
+
96
+ ```bash
97
+ bun run size
98
+ ```
99
+
100
+
101
+
102
+
@@ -0,0 +1,6 @@
1
+ # Check commit message format
2
+ bunx --no -- commitlint --edit ${1}
3
+
4
+
5
+
6
+
@@ -0,0 +1,9 @@
1
+ # Check for secrets with gitleaks
2
+ gitleaks protect --staged
3
+
4
+ # Run linters on staged files
5
+ bunx lint-staged
6
+
7
+
8
+
9
+
@@ -0,0 +1,6 @@
1
+ # Run type checking before push
2
+ bun run type-check
3
+
4
+
5
+
6
+
@@ -0,0 +1,8 @@
1
+ [
2
+ {
3
+ "name": "SDK Main Export",
4
+ "path": "index.ts",
5
+ "limit": "50 KB",
6
+ "ignore": ["node_modules"]
7
+ }
8
+ ]
package/.test-hooks.ts ADDED
@@ -0,0 +1,5 @@
1
+ // Test file for git hooks validation
2
+ export function testHooks() {
3
+ console.log("Testing git hooks");
4
+ return true;
5
+ }
package/CLAUDE.md CHANGED
@@ -8,10 +8,17 @@ Default to using Bun instead of Node.js.
8
8
 
9
9
  ## Working with this SDK
10
10
 
11
- - **Use existing tools**: Always use the built-in CLI tools via bash commands (e.g., `bun run lib/fal.ts`, `bun run lib/elevenlabs.ts`)
12
- - **Don't write custom scripts**: Avoid creating new TypeScript/JavaScript scripts. Use the existing lib/ tools directly
11
+ - **Use the varg CLI**: Run actions via `bun run src/cli/index.ts run <action> [options]`
12
+ - Use `--quiet` for minimal output (recommended for scripts)
13
+ - Use `--json` for JSON output
14
+ - Example: `bun run src/cli/index.ts run video --prompt "sunset over ocean" --quiet`
15
+ - **Available actions**: image, video, voice, music, transcribe, captions, sync, upload, edit
16
+ - **List actions**: `bun run src/cli/index.ts list`
17
+ - **Action help**: `bun run src/cli/index.ts run <action> --help`
13
18
  - **Media folders**: Store input files in `media/` folder, outputs go to `output/` folder
14
- - **Local file support**: Tools like `lib/fal.ts` support local file paths (e.g., `media/image.png`) in addition to URLs
19
+ - **Local file support**: Actions support local file paths (e.g., `media/image.png`) in addition to URLs
20
+ - **Providers**: Located in `src/providers/` (fal, elevenlabs, replicate, groq, etc.)
21
+ - **Action definitions**: Located in `src/definitions/actions/`
15
22
 
16
23
  - Use `bun <file>` instead of `node <file>` or `ts-node <file>`
17
24
  - Use `bun test` instead of `jest` or `vitest`
@@ -0,0 +1,150 @@
1
+ # Contributing to @vargai/sdk
2
+
3
+ ## Development Setup
4
+
5
+ This project uses **Bun** as the runtime and package manager.
6
+
7
+ ```bash
8
+ # Install dependencies
9
+ bun install
10
+
11
+ # Run linter
12
+ bun run lint
13
+
14
+ # Format code
15
+ bun run format
16
+
17
+ # Type check
18
+ bun run type-check
19
+
20
+ # Check bundle size
21
+ bun run size
22
+ ```
23
+
24
+ ## Git Workflow
25
+
26
+ This project uses automated Git hooks powered by [Husky](https://typicode.github.io/husky/) to maintain code quality and security.
27
+
28
+ ### Automated Checks
29
+
30
+ #### Before Commit (`pre-commit`)
31
+ 1. **Gitleaks** - Scans for secrets, API keys, and credentials
32
+ 2. **Biome** - Lints and formats staged files automatically
33
+
34
+ #### Commit Message (`commit-msg`)
35
+ 3. **Commitlint** - Validates commit message format
36
+
37
+ #### Before Push (`pre-push`)
38
+ 4. **TypeScript** - Type checking to catch errors early
39
+
40
+ ### Commit Message Format
41
+
42
+ We follow [Conventional Commits](https://www.conventionalcommits.org/) specification:
43
+
44
+ ```
45
+ <type>(<scope>): <subject>
46
+ ```
47
+
48
+ **Available types:**
49
+ - `feat`: New feature
50
+ - `fix`: Bug fix
51
+ - `docs`: Documentation only changes
52
+ - `style`: Code style changes (formatting, missing semi colons, etc)
53
+ - `refactor`: Code change that neither fixes a bug nor adds a feature
54
+ - `perf`: Performance improvements
55
+ - `test`: Adding or updating tests
56
+ - `build`: Changes to build system or dependencies
57
+ - `ci`: CI/CD configuration changes
58
+ - `chore`: Other changes that don't modify src or test files
59
+ - `revert`: Reverts a previous commit
60
+
61
+ **Examples:**
62
+ ```bash
63
+ feat: add voice cloning endpoint
64
+ feat(video): implement background removal
65
+ fix: handle null pointer in transcription
66
+ fix(captions): correct timestamp alignment
67
+ docs: update API documentation
68
+ refactor: simplify audio processing pipeline
69
+ perf(image): optimize memory usage
70
+ chore: update dependencies
71
+ ```
72
+
73
+ ### Code Style
74
+
75
+ We use [Biome](https://biomejs.dev/) for linting and formatting:
76
+
77
+ - **Automatic formatting** on commit via lint-staged
78
+ - **Manual formatting**: `bun run format`
79
+ - **Manual linting**: `bun run lint`
80
+
81
+ ### Bundle Size
82
+
83
+ SDK bundle size is monitored via size-limit:
84
+
85
+ ```bash
86
+ bun run size
87
+ ```
88
+
89
+ Current limits are defined in `.size-limit.json`.
90
+
91
+ ## Pull Request Process
92
+
93
+ 1. Fork the repository
94
+ 2. Create a feature branch: `git checkout -b feat/amazing-feature`
95
+ 3. Make your changes
96
+ 4. Commit with conventional format: `git commit -m "feat: add amazing feature"`
97
+ 5. Push to your fork: `git push origin feat/amazing-feature`
98
+ 6. Open a Pull Request
99
+
100
+ ### PR Guidelines
101
+
102
+ - ✅ All automated checks must pass
103
+ - ✅ Follow conventional commits format
104
+ - ✅ Update documentation if needed
105
+ - ✅ Add tests for new features
106
+ - ✅ Keep bundle size within limits
107
+
108
+ ## Bypassing Hooks
109
+
110
+ ⚠️ **Only in emergencies:**
111
+
112
+ ```bash
113
+ # Skip all hooks (not recommended)
114
+ git commit --no-verify -m "emergency fix"
115
+ ```
116
+
117
+ ## Troubleshooting
118
+
119
+ ### Hooks not running?
120
+
121
+ ```bash
122
+ # Reinstall hooks
123
+ bun run prepare
124
+ chmod +x .husky/*
125
+ ```
126
+
127
+ ### Type errors?
128
+
129
+ ```bash
130
+ bun run type-check
131
+ ```
132
+
133
+ ### Format issues?
134
+
135
+ ```bash
136
+ bun run format
137
+ ```
138
+
139
+ ### Secrets detected?
140
+
141
+ If gitleaks detects secrets:
142
+ 1. **DO NOT** bypass the hook
143
+ 2. Remove the secret from your code
144
+ 3. Use environment variables instead
145
+ 4. If already committed, rotate the exposed credentials
146
+
147
+ ## Questions?
148
+
149
+ Open an issue or reach out to the maintainers.
150
+
package/LICENSE.md ADDED
@@ -0,0 +1,53 @@
1
+ LICENSE
2
+
3
+ Apache License
4
+ Version 2.0, January 2004
5
+ http://www.apache.org/licenses/
6
+
7
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
8
+
9
+ 1. Definitions.
10
+
11
+ "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity.
16
+
17
+ "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License.
18
+
19
+ "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files.
20
+
21
+ "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types.
22
+
23
+ "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below).
24
+
25
+ "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof.
26
+
27
+ "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution."
28
+
29
+ "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work.
30
+
31
+ 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form.
32
+
33
+ 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed.
34
+
35
+ 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions:
36
+
37
+ You must give any other recipients of the Work or Derivative Works a copy of this License; and
38
+ You must cause any modified files to carry prominent notices stating that You changed the files; and
39
+ You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and
40
+ If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License.
41
+ You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License.
42
+
43
+ 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions.
44
+
45
+ 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file.
46
+
47
+ 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License.
48
+
49
+ 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages.
50
+
51
+ 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability.
52
+
53
+ END OF TERMS AND CONDITIONS