Skip to content

Commit 6c459ad

Browse files
authored
Merge pull request #87 from ajcwebdev/fix
Fix Docker Command
2 parents 3e21548 + 1f892cd commit 6c459ad

File tree

5 files changed

+128
-128
lines changed

5 files changed

+128
-128
lines changed

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
"test-all": "tsx --test test/all.test.ts",
4444
"ta": "tsx --test test/all.test.ts",
4545
"clean": "tsx scripts/cleanContent.ts",
46-
"docker-cli": "docker run --rm -it -v $PWD/content:/usr/src/app/content autoshow",
46+
"docker-cli": "docker run --rm -v $PWD/content:/usr/src/app/content autoshow",
4747
"docker-serve": "docker run -d -p 3000:3000 -v $PWD/content:/usr/src/app/content autoshow serve",
4848
"prune": "docker system prune -af --volumes && docker image prune -af && docker container prune -f && docker volume prune -af",
4949
"bun": "bun --env-file=.env --no-warnings src/cli/commander.ts",

test/all.test.ts

+65-65
Original file line numberDiff line numberDiff line change
@@ -17,265 +17,265 @@ const commands = [
1717
// Process all videos in a specified YouTube playlist.
1818
cmd: 'npm run as -- --playlist "https://www.youtube.com/playlist?list=PLCVnrVv4KhXPz0SoAVu8Rc1emAdGPbSbr"',
1919
expectedFiles: [
20-
{ file: '2024-09-24-ep1-fsjam-podcast-prompt.md', newName: '02A-playlist-default.md' },
21-
{ file: '2024-09-24-ep0-fsjam-podcast-prompt.md', newName: '02B-playlist-default.md' }
20+
{ file: '2024-09-24-ep1-fsjam-podcast-prompt.md', newName: '02-playlist-default.md' },
21+
{ file: '2024-09-24-ep0-fsjam-podcast-prompt.md', newName: '03-playlist-default.md' }
2222
]
2323
},
2424
{
2525
// Process multiple YouTube videos from URLs listed in a file.
2626
cmd: 'npm run as -- --urls "content/example-urls.md"',
2727
expectedFiles: [
28-
{ file: '2024-09-24-ep1-fsjam-podcast-prompt.md', newName: '03A-urls-default.md' },
29-
{ file: '2024-09-24-ep0-fsjam-podcast-prompt.md', newName: '03B-urls-default.md' }
28+
{ file: '2024-09-24-ep1-fsjam-podcast-prompt.md', newName: '04-urls-default.md' },
29+
{ file: '2024-09-24-ep0-fsjam-podcast-prompt.md', newName: '05-urls-default.md' }
3030
]
3131
},
3232
{
3333
// Process a single local audio file.
3434
cmd: 'npm run as -- --file "content/audio.mp3"',
3535
expectedFile: 'audio-prompt.md',
36-
newName: '04-file-default.md'
36+
newName: '06-file-default.md'
3737
},
3838
{
3939
// Process local audio file with title prompts, Whisper 'tiny' model, and Ollama.
4040
cmd: 'npm run as -- --file "content/audio.mp3" --prompt titles --whisper tiny --ollama LLAMA_3_2_1B',
4141
expectedFile: 'audio-ollama-shownotes.md',
42-
newName: '05-titles-prompt-whisper-tiny-ollama-shownotes.md'
42+
newName: '07-titles-prompt-whisper-tiny-ollama-shownotes.md'
4343
},
4444
{
4545
// Process local audio file with Whisper 'tiny' model.
4646
cmd: 'npm run as -- --file "content/audio.mp3" --whisper tiny',
4747
expectedFile: 'audio-prompt.md',
48-
newName: '06-whisper-tiny.md'
48+
newName: '08-whisper-tiny.md'
4949
},
5050
{
5151
// Process a local audio file with all available prompt options (except smallChapters and longChapters)
5252
cmd: 'npm run as -- --file "content/audio.mp3" --prompt titles summary mediumChapters takeaways questions',
5353
expectedFile: 'audio-prompt.md',
54-
newName: '07-all-prompts.md'
54+
newName: '09-all-prompts.md'
5555
},
5656
{
5757
// Process a local audio file with multiple prompt sections, Whisper 'tiny' model, and Ollama.
5858
cmd: 'npm run as -- --file "content/audio.mp3" --prompt titles summary shortChapters takeaways questions --whisper tiny --ollama',
5959
expectedFile: 'audio-ollama-shownotes.md',
60-
newName: '08-all-prompts-ollama-shownotes.md'
60+
newName: '10-all-prompts-ollama-shownotes.md'
6161
},
6262
{
6363
// Process playlist videos with titles and longChapters prompts, tiny Whisper model, and Ollama for LLM processing.
6464
cmd: 'npm run as -- --playlist "https://www.youtube.com/playlist?list=PLCVnrVv4KhXPz0SoAVu8Rc1emAdGPbSbr" --prompt titles longChapters --whisper tiny --ollama',
6565
expectedFiles: [
66-
{ file: '2024-09-24-ep1-fsjam-podcast-ollama-shownotes.md', newName: '09A-prompt-whisper-ollama-shownotes.md' },
67-
{ file: '2024-09-24-ep0-fsjam-podcast-ollama-shownotes.md', newName: '09B-prompt-whisper-ollama-shownotes.md' }
66+
{ file: '2024-09-24-ep1-fsjam-podcast-ollama-shownotes.md', newName: '11-prompt-whisper-ollama-shownotes.md' },
67+
{ file: '2024-09-24-ep0-fsjam-podcast-ollama-shownotes.md', newName: '12-prompt-whisper-ollama-shownotes.md' }
6868
]
6969
},
7070
{
7171
// Process multiple YouTube videos from URLs with title prompts, Whisper 'tiny' model, and Ollama.
7272
cmd: 'npm run as -- --urls "content/example-urls.md" --prompt titles --whisper tiny --ollama',
7373
expectedFiles: [
74-
{ file: '2024-09-24-ep1-fsjam-podcast-ollama-shownotes.md', newName: '10A-prompt-whisper-ollama-shownotes.md' },
75-
{ file: '2024-09-24-ep0-fsjam-podcast-ollama-shownotes.md', newName: '10B-prompt-whisper-ollama-shownotes.md' }
74+
{ file: '2024-09-24-ep1-fsjam-podcast-ollama-shownotes.md', newName: '13-prompt-whisper-ollama-shownotes.md' },
75+
{ file: '2024-09-24-ep0-fsjam-podcast-ollama-shownotes.md', newName: '14-prompt-whisper-ollama-shownotes.md' }
7676
]
7777
},
7878
{
7979
// Process podcast RSS feed from default order.
8080
cmd: 'npm run as -- --rss "https://ajcwebdev.substack.com/feed" --whisper tiny',
8181
expectedFile: '2021-05-10-thoughts-on-lambda-school-layoffs-prompt.md',
82-
newName: '11-rss-whisper-tiny.md'
82+
newName: '15-rss-whisper-tiny.md'
8383
},
8484
{
8585
// Download JSON file with metadata for each item in the RSS feed.
8686
cmd: 'npm run as -- --rss "https://ajcwebdev.substack.com/feed" --info',
8787
expectedFile: 'ajcwebdev_info.json',
88-
newName: '12-ajcwebdev-rss-info.json',
88+
newName: '16-ajcwebdev-rss-info.json',
8989
},
9090
{
91-
cmd: 'npm run docker -- --video "https://www.youtube.com/watch?v=MORMZXEaONk"',
91+
cmd: 'npm run docker-cli -- --video "https://www.youtube.com/watch?v=MORMZXEaONk"',
9292
expectedFile: '2024-09-24-ep0-fsjam-podcast-prompt.md',
93-
newName: '15-docker-video-default.md'
93+
newName: '17-docker-video-default.md'
9494
},
9595
{
96-
cmd: 'npm run docker -- --playlist "https://www.youtube.com/playlist?list=PLCVnrVv4KhXPz0SoAVu8Rc1emAdGPbSbr"',
96+
cmd: 'npm run docker-cli -- --playlist "https://www.youtube.com/playlist?list=PLCVnrVv4KhXPz0SoAVu8Rc1emAdGPbSbr"',
9797
expectedFiles: [
98-
{ file: '2024-09-24-ep1-fsjam-podcast-prompt.md', newName: '16A-docker-playlist-default.md' },
99-
{ file: '2024-09-24-ep0-fsjam-podcast-prompt.md', newName: '16B-docker-playlist-default.md' }
98+
{ file: '2024-09-24-ep1-fsjam-podcast-prompt.md', newName: '18-docker-playlist-default.md' },
99+
{ file: '2024-09-24-ep0-fsjam-podcast-prompt.md', newName: '19-docker-playlist-default.md' }
100100
]
101101
},
102102
{
103-
cmd: 'npm run docker -- --urls "content/example-urls.md"',
103+
cmd: 'npm run docker-cli -- --urls "content/example-urls.md"',
104104
expectedFiles: [
105-
{ file: '2024-09-24-ep1-fsjam-podcast-prompt.md', newName: '17A-docker-urls-default.md' },
106-
{ file: '2024-09-24-ep0-fsjam-podcast-prompt.md', newName: '17B-docker-urls-default.md' }
105+
{ file: '2024-09-24-ep1-fsjam-podcast-prompt.md', newName: '20-docker-urls-default.md' },
106+
{ file: '2024-09-24-ep0-fsjam-podcast-prompt.md', newName: '21-docker-urls-default.md' }
107107
]
108108
},
109109
{
110-
cmd: 'npm run docker -- --file "content/audio.mp3"',
110+
cmd: 'npm run docker-cli -- --file "content/audio.mp3"',
111111
expectedFile: 'audio-prompt.md',
112-
newName: '18-docker-file-default.md'
112+
newName: '22-docker-file-default.md'
113113
},
114114
{
115-
cmd: 'npm run docker -- --file "content/audio.mp3" --prompt titles --whisperDocker tiny --ollama LLAMA_3_2_1B',
115+
cmd: 'npm run docker-cli -- --file "content/audio.mp3" --prompt titles --whisper tiny --ollama LLAMA_3_2_1B',
116116
expectedFile: 'audio-ollama-shownotes.md',
117-
newName: '19-docker-titles-prompt-whisper-tiny-ollama-shownotes.md'
117+
newName: '23-docker-titles-prompt-whisper-tiny-ollama-shownotes.md'
118118
},
119119
{
120-
cmd: 'npm run docker -- --file "content/audio.mp3" --whisperDocker tiny',
120+
cmd: 'npm run docker-cli -- --file "content/audio.mp3" --whisper tiny',
121121
expectedFile: 'audio-prompt.md',
122-
newName: '20-docker-whisper-tiny.md'
122+
newName: '24-docker-whisper-tiny.md'
123123
},
124124
{
125-
cmd: 'npm run docker -- --file "content/audio.mp3" --prompt titles summary mediumChapters takeaways questions',
125+
cmd: 'npm run docker-cli -- --file "content/audio.mp3" --prompt titles summary mediumChapters takeaways questions',
126126
expectedFile: 'audio-prompt.md',
127-
newName: '21-docker-all-prompts.md'
127+
newName: '25-docker-all-prompts.md'
128128
},
129129
{
130-
cmd: 'npm run docker -- --file "content/audio.mp3" --prompt titles summary shortChapters takeaways questions --whisperDocker tiny --ollama LLAMA_3_2_1B',
130+
cmd: 'npm run docker-cli -- --file "content/audio.mp3" --prompt titles summary shortChapters takeaways questions --whisper tiny --ollama LLAMA_3_2_1B',
131131
expectedFile: 'audio-ollama-shownotes.md',
132-
newName: '22-docker-all-prompts-ollama-shownotes.md'
132+
newName: '26-docker-all-prompts-ollama-shownotes.md'
133133
},
134134
{
135-
cmd: 'npm run docker -- --playlist "https://www.youtube.com/playlist?list=PLCVnrVv4KhXPz0SoAVu8Rc1emAdGPbSbr" --prompt titles --whisperDocker tiny --ollama LLAMA_3_2_1B',
135+
cmd: 'npm run docker-cli -- --playlist "https://www.youtube.com/playlist?list=PLCVnrVv4KhXPz0SoAVu8Rc1emAdGPbSbr" --prompt titles --whisper tiny --ollama LLAMA_3_2_1B',
136136
expectedFiles: [
137-
{ file: '2024-09-24-ep1-fsjam-podcast-ollama-shownotes.md', newName: '23A-docker-prompt-whisper-ollama-shownotes.md' },
138-
{ file: '2024-09-24-ep0-fsjam-podcast-ollama-shownotes.md', newName: '23B-docker-prompt-whisper-ollama-shownotes.md' }
137+
{ file: '2024-09-24-ep1-fsjam-podcast-ollama-shownotes.md', newName: '27-docker-prompt-whisper-ollama-shownotes.md' },
138+
{ file: '2024-09-24-ep0-fsjam-podcast-ollama-shownotes.md', newName: '28-docker-prompt-whisper-ollama-shownotes.md' }
139139
]
140140
},
141141
{
142-
cmd: 'npm run docker -- --urls "content/example-urls.md" --prompt titles --whisperDocker tiny --ollama LLAMA_3_2_1B',
142+
cmd: 'npm run docker-cli -- --urls "content/example-urls.md" --prompt titles --whisper tiny --ollama LLAMA_3_2_1B',
143143
expectedFiles: [
144-
{ file: '2024-09-24-ep1-fsjam-podcast-ollama-shownotes.md', newName: '24A-docker-prompt-whisper-ollama-shownotes.md' },
145-
{ file: '2024-09-24-ep0-fsjam-podcast-ollama-shownotes.md', newName: '24B-docker-prompt-whisper-ollama-shownotes.md' }
144+
{ file: '2024-09-24-ep1-fsjam-podcast-ollama-shownotes.md', newName: '29-docker-prompt-whisper-ollama-shownotes.md' },
145+
{ file: '2024-09-24-ep0-fsjam-podcast-ollama-shownotes.md', newName: '30-docker-prompt-whisper-ollama-shownotes.md' }
146146
]
147147
},
148148
{
149-
cmd: 'npm run docker -- --rss "https://ajcwebdev.substack.com/feed"',
149+
cmd: 'npm run docker-cli -- --rss "https://ajcwebdev.substack.com/feed"',
150150
expectedFile: '2021-05-10-thoughts-on-lambda-school-layoffs-prompt.md',
151-
newName: '25-docker-rss-default.md'
151+
newName: '31-docker-rss-default.md'
152152
},
153153
{
154-
cmd: 'npm run docker -- --rss "https://ajcwebdev.substack.com/feed" --info',
154+
cmd: 'npm run docker-cli -- --rss "https://ajcwebdev.substack.com/feed" --info',
155155
expectedFile: 'ajcwebdev_info.json',
156-
newName: '26-docker-ajcwebdev-rss-info.json',
156+
newName: '32-docker-ajcwebdev-rss-info.json',
157157
},
158158
{
159159
// Process local audio file with Dockerized Whisper 'base' model.
160-
cmd: 'npm run as -- --file "content/audio.mp3" --whisperDocker base',
160+
cmd: 'npm run as -- --file "content/audio.mp3" --whisper base',
161161
expectedFile: 'audio-prompt.md',
162-
newName: '27-docker-whisper-docker-base.md'
162+
newName: '33-docker-whisper-docker-base.md'
163163
},
164164
{
165165
// Process multiple YouTube videos from URLs with title prompts, Whisper 'tiny' model, and ChatGPT GPT_4o_MINI model.
166166
cmd: 'npm run as -- --urls "content/example-urls.md" --prompt titles --whisper tiny --chatgpt GPT_4o_MINI',
167167
expectedFiles: [
168-
{ file: '2024-09-24-ep1-fsjam-podcast-chatgpt-shownotes.md', newName: '28A-chatgpt-gpt-4o-mini.md' },
169-
{ file: '2024-09-24-ep0-fsjam-podcast-chatgpt-shownotes.md', newName: '28B-chatgpt-gpt-4o-mini.md' }
168+
{ file: '2024-09-24-ep1-fsjam-podcast-chatgpt-shownotes.md', newName: '34-chatgpt-gpt-4o-mini.md' },
169+
{ file: '2024-09-24-ep0-fsjam-podcast-chatgpt-shownotes.md', newName: '35-chatgpt-gpt-4o-mini.md' }
170170
]
171171
},
172172
{
173173
// Process a video using ChatGPT for LLM operations.
174174
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --chatgpt',
175175
expectedFile: '2024-09-24-ep0-fsjam-podcast-chatgpt-shownotes.md',
176-
newName: '29-chatgpt-default.md'
176+
newName: '36-chatgpt-default.md'
177177
},
178178
{
179179
// Process video with ChatGPT using GPT_4o_MINI model.
180180
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --chatgpt GPT_4o_MINI',
181181
expectedFile: '2024-09-24-ep0-fsjam-podcast-chatgpt-shownotes.md',
182-
newName: '30-chatgpt-gpt-4o-mini.md'
182+
newName: '37-chatgpt-gpt-4o-mini.md'
183183
},
184184
{
185185
// Process a video using Claude for LLM operations.
186186
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --claude',
187187
expectedFile: '2024-09-24-ep0-fsjam-podcast-claude-shownotes.md',
188-
newName: '31-claude-default.md'
188+
newName: '38-claude-default.md'
189189
},
190190
{
191191
// Process video with Claude using CLAUDE_3_SONNET model.
192192
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --claude CLAUDE_3_SONNET',
193193
expectedFile: '2024-09-24-ep0-fsjam-podcast-claude-shownotes.md',
194-
newName: '32-claude-shownotes.md'
194+
newName: '39-claude-shownotes.md'
195195
},
196196
{
197197
// Process a video using Gemini for LLM operations.
198198
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --gemini',
199199
expectedFile: '2024-09-24-ep0-fsjam-podcast-gemini-shownotes.md',
200-
newName: '33-gemini-shownotes.md'
200+
newName: '40-gemini-shownotes.md'
201201
},
202202
{
203203
// Process video with Gemini using GEMINI_1_5_FLASH model.
204204
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --gemini GEMINI_1_5_FLASH',
205205
expectedFile: '2024-09-24-ep0-fsjam-podcast-gemini-shownotes.md',
206-
newName: '34-gemini-shownotes.md'
206+
newName: '41-gemini-shownotes.md'
207207
},
208208
{
209209
// Process a video using Cohere for LLM operations
210210
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --cohere',
211211
expectedFile: '2024-09-24-ep0-fsjam-podcast-cohere-shownotes.md',
212-
newName: '35-cohere-shownotes.md'
212+
newName: '42-cohere-shownotes.md'
213213
},
214214
{
215215
// Process video with Cohere using COMMAND_R_PLUS model.
216216
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --cohere COMMAND_R_PLUS',
217217
expectedFile: '2024-09-24-ep0-fsjam-podcast-cohere-shownotes.md',
218-
newName: '36-cohere-shownotes.md'
218+
newName: '43-cohere-shownotes.md'
219219
},
220220
{
221221
// Process a video using Mistral for LLM operations
222222
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --mistral',
223223
expectedFile: '2024-09-24-ep0-fsjam-podcast-mistral-shownotes.md',
224-
newName: '37-mistral-shownotes.md'
224+
newName: '44-mistral-shownotes.md'
225225
},
226226
{
227227
// Process video with Mistral using MIXTRAL_8x7b model.
228228
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --mistral MIXTRAL_8x7b',
229229
expectedFile: '2024-09-24-ep0-fsjam-podcast-mistral-shownotes.md',
230-
newName: '38-mistral-shownotes.md'
230+
newName: '45-mistral-shownotes.md'
231231
},
232232
{
233233
// Process a video using Fireworks for LLM operations
234234
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --fireworks',
235235
expectedFile: '2024-09-24-ep0-fsjam-podcast-fireworks-shownotes.md',
236-
newName: '39-fireworks-shownotes.md'
236+
newName: '46-fireworks-shownotes.md'
237237
},
238238
{
239239
// Process a video using Together for LLM operations
240240
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --together',
241241
expectedFile: '2024-09-24-ep0-fsjam-podcast-together-shownotes.md',
242-
newName: '40-together-shownotes.md'
242+
newName: '47-together-shownotes.md'
243243
},
244244
{
245245
// Process a video using BLANK for LLM operations
246246
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --groq',
247247
expectedFile: '2024-09-24-ep0-fsjam-podcast-groq-shownotes.md',
248-
newName: '41-groq-shownotes.md'
248+
newName: '48-groq-shownotes.md'
249249
},
250250
{
251251
// Process a video using Deepgram for transcription
252252
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --deepgram',
253253
expectedFile: '2024-09-24-ep0-fsjam-podcast-prompt.md',
254-
newName: '42-deepgram-prompt.md'
254+
newName: '49-deepgram-prompt.md'
255255
},
256256
{
257257
// Process video using Deepgram and Llama.
258258
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --deepgram --ollama',
259259
expectedFile: '2024-09-24-ep0-fsjam-podcast-ollama-shownotes.md',
260-
newName: '43-deepgram-ollama-shownotes.md'
260+
newName: '50-deepgram-ollama-shownotes.md'
261261
},
262262
{
263263
// Process a video using AssemblyAI for transcription
264264
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --assembly',
265265
expectedFile: '2024-09-24-ep0-fsjam-podcast-prompt.md',
266-
newName: '44-assembly-prompt.md'
266+
newName: '51-assembly-prompt.md'
267267
},
268268
{
269269
// Process video using AssemblyAI and Llama.
270270
cmd: 'npm run as -- --video "https://www.youtube.com/watch?v=MORMZXEaONk" --assembly --ollama',
271271
expectedFile: '2024-09-24-ep0-fsjam-podcast-ollama-shownotes.md',
272-
newName: '45-assembly-ollama-shownotes.md'
272+
newName: '52-assembly-ollama-shownotes.md'
273273
},
274274
{
275275
// Process an audio file using AssemblyAI with speaker labels
276276
cmd: 'npm run as -- --video "https://ajc.pics/audio/fsjam-short.mp3" --assembly --speakerLabels',
277277
expectedFile: '2024-05-08-fsjam-short-prompt.md',
278-
newName: '46-assembly-speaker-labels-prompt.md'
278+
newName: '53-assembly-speaker-labels-prompt.md'
279279
}
280280
]
281281

0 commit comments

Comments
 (0)