egaki 0.0.1 → 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (46) hide show
  1. package/CHANGELOG.md +54 -0
  2. package/README.md +239 -0
  3. package/dist/antigravity-auth.d.ts +15 -0
  4. package/dist/antigravity-auth.d.ts.map +1 -0
  5. package/dist/antigravity-auth.js +544 -0
  6. package/dist/antigravity-image.d.ts +11 -0
  7. package/dist/antigravity-image.d.ts.map +1 -0
  8. package/dist/antigravity-image.js +285 -0
  9. package/dist/chatgpt-auth.js +294 -0
  10. package/dist/cli.d.ts +3 -0
  11. package/dist/cli.d.ts.map +1 -0
  12. package/dist/cli.js +666 -0
  13. package/dist/credentials.d.ts +18 -0
  14. package/dist/credentials.d.ts.map +1 -0
  15. package/dist/credentials.js +107 -0
  16. package/dist/gateway-model-candidates.generated.d.ts +11 -0
  17. package/dist/gateway-model-candidates.generated.d.ts.map +1 -0
  18. package/dist/gateway-model-candidates.generated.js +64 -0
  19. package/dist/login.d.ts +9 -0
  20. package/dist/login.d.ts.map +1 -0
  21. package/dist/login.js +112 -0
  22. package/dist/model-catalog.d.ts +42 -0
  23. package/dist/model-catalog.d.ts.map +1 -0
  24. package/dist/model-catalog.js +898 -0
  25. package/dist/models.d.ts +15 -0
  26. package/dist/models.d.ts.map +1 -0
  27. package/dist/models.js +196 -0
  28. package/dist/open-browser.d.ts +2 -0
  29. package/dist/open-browser.d.ts.map +1 -0
  30. package/dist/open-browser.js +37 -0
  31. package/dist/subscription.d.ts +5 -0
  32. package/dist/subscription.d.ts.map +1 -0
  33. package/dist/subscription.js +216 -0
  34. package/dist/video-model-catalog.d.ts +52 -0
  35. package/dist/video-model-catalog.d.ts.map +1 -0
  36. package/dist/video-model-catalog.js +245 -0
  37. package/package.json +68 -5
  38. package/src/cli.ts +998 -0
  39. package/src/credentials.ts +126 -0
  40. package/src/login.ts +163 -0
  41. package/src/model-catalog.ts +968 -0
  42. package/src/models.ts +258 -0
  43. package/src/open-browser.ts +48 -0
  44. package/src/subscription.ts +298 -0
  45. package/src/video-model-catalog.ts +302 -0
  46. package/index.js +0 -1
@@ -0,0 +1,245 @@
1
+ // Single source of truth for video generation models.
2
+ // Stores provider, strategy, capabilities, and duration-based pricing metadata.
3
+ // Gateway billing uses this catalog to estimate per-request video cost.
4
+ const commonRatios = ['16:9', '9:16', '1:1', '4:3', '3:4'];
5
+ export const VIDEO_CATALOG = [
6
+ {
7
+ id: 'veo-3.1-generate-001',
8
+ name: 'Veo 3.1',
9
+ provider: 'google',
10
+ strategy: 'video',
11
+ released: '2026-01',
12
+ cost: {
13
+ type: 'per-video-second',
14
+ defaultDurationSec: 8,
15
+ tiers: [
16
+ { resolution: '720p', audio: false, costPerSecond: 0.2 },
17
+ { resolution: '720p', audio: true, costPerSecond: 0.4 },
18
+ { resolution: '1080p', audio: false, costPerSecond: 0.2 },
19
+ { resolution: '1080p', audio: true, costPerSecond: 0.4 },
20
+ { resolution: '4k', audio: false, costPerSecond: 0.4 },
21
+ { resolution: '4k', audio: true, costPerSecond: 0.6 },
22
+ ],
23
+ },
24
+ features: {
25
+ textToVideo: true,
26
+ imageToVideo: false,
27
+ capabilities: ['t2v'],
28
+ aspectRatios: ['16:9', '9:16'],
29
+ resolutions: ['720p', '1080p', '4k'],
30
+ durationRangeSec: { min: 4, max: 8 },
31
+ seed: true,
32
+ multipleVideos: true,
33
+ },
34
+ },
35
+ {
36
+ id: 'veo-3.1-fast-generate-001',
37
+ name: 'Veo 3.1 Fast',
38
+ provider: 'google',
39
+ strategy: 'video',
40
+ released: '2026-01',
41
+ cost: {
42
+ type: 'per-video-second',
43
+ defaultDurationSec: 8,
44
+ tiers: [
45
+ { resolution: '720p', audio: false, costPerSecond: 0.1 },
46
+ { resolution: '720p', audio: true, costPerSecond: 0.15 },
47
+ { resolution: '1080p', audio: false, costPerSecond: 0.1 },
48
+ { resolution: '1080p', audio: true, costPerSecond: 0.15 },
49
+ { resolution: '4k', audio: false, costPerSecond: 0.3 },
50
+ { resolution: '4k', audio: true, costPerSecond: 0.35 },
51
+ ],
52
+ },
53
+ features: {
54
+ textToVideo: true,
55
+ imageToVideo: false,
56
+ capabilities: ['t2v'],
57
+ aspectRatios: ['16:9', '9:16'],
58
+ resolutions: ['720p', '1080p', '4k'],
59
+ durationRangeSec: { min: 4, max: 8 },
60
+ seed: true,
61
+ multipleVideos: true,
62
+ },
63
+ },
64
+ {
65
+ id: 'veo-3.0-generate-001',
66
+ name: 'Veo 3.0',
67
+ provider: 'google',
68
+ strategy: 'video',
69
+ released: '2025-12',
70
+ cost: {
71
+ type: 'per-video-second',
72
+ defaultDurationSec: 8,
73
+ tiers: [
74
+ { resolution: '720p', audio: false, costPerSecond: 0.2 },
75
+ { resolution: '720p', audio: true, costPerSecond: 0.4 },
76
+ { resolution: '1080p', audio: false, costPerSecond: 0.2 },
77
+ { resolution: '1080p', audio: true, costPerSecond: 0.4 },
78
+ ],
79
+ },
80
+ features: {
81
+ textToVideo: true,
82
+ imageToVideo: false,
83
+ capabilities: ['t2v'],
84
+ aspectRatios: ['16:9', '9:16'],
85
+ resolutions: ['720p', '1080p'],
86
+ durationRangeSec: { min: 4, max: 8 },
87
+ seed: true,
88
+ multipleVideos: true,
89
+ },
90
+ },
91
+ {
92
+ id: 'veo-3.0-fast-generate-001',
93
+ name: 'Veo 3.0 Fast',
94
+ provider: 'google',
95
+ strategy: 'video',
96
+ released: '2025-12',
97
+ cost: {
98
+ type: 'per-video-second',
99
+ defaultDurationSec: 8,
100
+ tiers: [
101
+ { resolution: '720p', audio: false, costPerSecond: 0.1 },
102
+ { resolution: '720p', audio: true, costPerSecond: 0.15 },
103
+ { resolution: '1080p', audio: false, costPerSecond: 0.1 },
104
+ { resolution: '1080p', audio: true, costPerSecond: 0.15 },
105
+ ],
106
+ },
107
+ features: {
108
+ textToVideo: true,
109
+ imageToVideo: false,
110
+ capabilities: ['t2v'],
111
+ aspectRatios: ['16:9', '9:16'],
112
+ resolutions: ['720p', '1080p'],
113
+ durationRangeSec: { min: 4, max: 8 },
114
+ seed: true,
115
+ multipleVideos: true,
116
+ },
117
+ },
118
+ {
119
+ id: 'grok-imagine-video',
120
+ name: 'Grok Imagine Video',
121
+ provider: 'xai',
122
+ strategy: 'video',
123
+ released: '2026-03',
124
+ cost: {
125
+ type: 'per-video-second',
126
+ defaultDurationSec: 5,
127
+ tiers: [
128
+ { resolution: '480p', costPerSecond: 0.05 },
129
+ { resolution: '720p', costPerSecond: 0.07 },
130
+ ],
131
+ },
132
+ features: {
133
+ textToVideo: true,
134
+ imageToVideo: true,
135
+ capabilities: ['t2v', 'i2v', 'editing'],
136
+ aspectRatios: ['1:1', '16:9', '9:16', '4:3', '3:4', '3:2', '2:3'],
137
+ resolutions: ['480p', '720p'],
138
+ durationRangeSec: { min: 1, max: 15 },
139
+ seed: false,
140
+ multipleVideos: false,
141
+ },
142
+ },
143
+ {
144
+ id: 'kling-v2.6-t2v',
145
+ name: 'Kling v2.6 T2V',
146
+ provider: 'klingai',
147
+ strategy: 'video',
148
+ released: '2025-12',
149
+ cost: {
150
+ type: 'per-video-second',
151
+ defaultDurationSec: 5,
152
+ tiers: [
153
+ { mode: 'std', costPerSecond: 0.042 },
154
+ { mode: 'pro', audio: false, costPerSecond: 0.07 },
155
+ { mode: 'pro', audio: true, costPerSecond: 0.14 },
156
+ ],
157
+ },
158
+ features: {
159
+ textToVideo: true,
160
+ imageToVideo: false,
161
+ capabilities: ['t2v'],
162
+ aspectRatios: commonRatios,
163
+ durationRangeSec: { min: 5, max: 10 },
164
+ seed: false,
165
+ multipleVideos: false,
166
+ },
167
+ },
168
+ {
169
+ id: 'wan-v2.6-t2v',
170
+ name: 'Wan v2.6 T2V',
171
+ provider: 'alibaba',
172
+ strategy: 'video',
173
+ released: '2026-01',
174
+ cost: {
175
+ type: 'per-video-second',
176
+ defaultDurationSec: 5,
177
+ tiers: [
178
+ { resolution: '720p', costPerSecond: 0.1 },
179
+ { resolution: '1080p', costPerSecond: 0.15 },
180
+ ],
181
+ },
182
+ features: {
183
+ textToVideo: true,
184
+ imageToVideo: false,
185
+ capabilities: ['t2v'],
186
+ resolutions: ['720p', '1080p'],
187
+ durationRangeSec: { min: 2, max: 15 },
188
+ seed: false,
189
+ multipleVideos: false,
190
+ },
191
+ },
192
+ // Fal direct BYOK models — duration pricing depends on Fal endpoint/config.
193
+ {
194
+ id: 'luma-ray-2',
195
+ name: 'Luma Ray 2 (Fal)',
196
+ provider: 'fal',
197
+ strategy: 'video',
198
+ released: '2025-11',
199
+ cost: { type: 'unknown' },
200
+ features: {
201
+ textToVideo: true,
202
+ imageToVideo: true,
203
+ capabilities: ['t2v', 'i2v'],
204
+ aspectRatios: commonRatios,
205
+ seed: true,
206
+ multipleVideos: false,
207
+ },
208
+ },
209
+ {
210
+ id: 'minimax-video',
211
+ name: 'MiniMax Video (Fal)',
212
+ provider: 'fal',
213
+ strategy: 'video',
214
+ released: '2025-10',
215
+ cost: { type: 'unknown' },
216
+ features: {
217
+ textToVideo: true,
218
+ imageToVideo: false,
219
+ capabilities: ['t2v'],
220
+ aspectRatios: commonRatios,
221
+ seed: false,
222
+ multipleVideos: false,
223
+ },
224
+ },
225
+ {
226
+ id: 'hunyuan-video',
227
+ name: 'Hunyuan Video (Fal)',
228
+ provider: 'fal',
229
+ strategy: 'video',
230
+ released: '2025-09',
231
+ cost: { type: 'unknown' },
232
+ features: {
233
+ textToVideo: true,
234
+ imageToVideo: true,
235
+ capabilities: ['t2v', 'i2v'],
236
+ aspectRatios: commonRatios,
237
+ seed: true,
238
+ multipleVideos: false,
239
+ },
240
+ },
241
+ ];
242
+ const videoCatalogIndex = new Map(VIDEO_CATALOG.map((m) => [m.id, m]));
243
+ export function findVideoModel(id) {
244
+ return videoCatalogIndex.get(id);
245
+ }
package/package.json CHANGED
@@ -1,8 +1,71 @@
1
1
  {
2
2
  "name": "egaki",
3
- "version": "0.0.1",
3
+ "version": "0.1.0",
4
+ "type": "module",
5
+ "main": "./dist/cli.js",
6
+ "types": "./dist/cli.d.ts",
7
+ "exports": {
8
+ "./package.json": "./package.json",
9
+ ".": {
10
+ "types": "./dist/cli.d.ts",
11
+ "default": "./dist/cli.js"
12
+ },
13
+ "./src": {
14
+ "types": "./src/cli.ts",
15
+ "default": "./src/cli.ts"
16
+ },
17
+ "./src/*": {
18
+ "types": "./src/*.ts",
19
+ "default": "./src/*.ts"
20
+ }
21
+ },
4
22
  "description": "AI image and video generation CLI",
5
- "main": "index.js",
6
- "keywords": ["ai", "image", "video", "generation"],
7
- "license": "MIT"
8
- }
23
+ "bin": "dist/cli.js",
24
+ "repository": {
25
+ "type": "git",
26
+ "url": "https://github.com/remorses/egaki.git",
27
+ "directory": "."
28
+ },
29
+ "homepage": "https://github.com/remorses/egaki#readme",
30
+ "bugs": {
31
+ "url": "https://github.com/remorses/egaki/issues"
32
+ },
33
+ "files": [
34
+ "src",
35
+ "dist",
36
+ "README.md",
37
+ "CHANGELOG.md"
38
+ ],
39
+ "keywords": [
40
+ "ai",
41
+ "image",
42
+ "video",
43
+ "generation",
44
+ "cli",
45
+ "gemini"
46
+ ],
47
+ "license": "MIT",
48
+ "dependencies": {
49
+ "@ai-sdk/fal": "2.0.21",
50
+ "@ai-sdk/google": "3.0.33",
51
+ "@ai-sdk/openai": "3.0.36",
52
+ "@ai-sdk/replicate": "2.0.20",
53
+ "@clack/prompts": "^1.0.1",
54
+ "ai": "6.0.103",
55
+ "goke": "^6.1.3",
56
+ "js-yaml": "^4.1.1",
57
+ "picocolors": "^1.1.1",
58
+ "string-dedent": "^3.0.2",
59
+ "zod": "^4.3.6"
60
+ },
61
+ "devDependencies": {
62
+ "@types/js-yaml": "^4.0.9",
63
+ "@types/node": "^25.3.0",
64
+ "tsx": "^4.21.0",
65
+ "typescript": "^5.9.3"
66
+ },
67
+ "scripts": {
68
+ "dev": "tsx src/cli.ts",
69
+ "build": "tsc && chmod +x dist/cli.js"
70
+ }
71
+ }