Skip to content

feat: add setup-ai bootstrap - #12

Merged
msitarzewski merged 1 commit into
msitarzewski:mainfrom
avezou:feature/ai-pipeline
Sep 12, 2026
Merged

msitarzewski merged 1 commit into
msitarzewski:mainfrom
avezou:feature/ai-pipeline

Conversation

@avezou

@avezou avezou commented Aug 16, 2026

Copy link
Copy Markdown
Contributor

setup-ai.sh:

  • build whisper-cli with the current Cmake-based layout
  • download models/ggml-medium.bin
  • prompt for LLM provider settings and write them to .env
  • update docs to reflect changes

Summary

Adds a one-shot setup-ai.sh bootstrap for the AI pipeline so users can setup whisper.cpp, download the default mode, and configure LLM provider from one guided flow.

  • clone/recover whisper.cpp and build whisper-cli
  • download models/ggml-medium.bin
  • prompt for LLM provider settins and write them to .env

Changes

  • setup-ai.sh  — (NEW) adds the one-shot AI bootstrap flow to clone/build  whisper.cpp , download the model, and write LLM settings into  .env .
  •  server/lib/whisper-transcriber.js  — aligns the server’s auto-build path with the current  whisper.cpp  CMake layout so transcription can build the CLI correctly.
  •  tests/test-setup-ai.sh  — adds a smoke test that runs the setup script against a fake toolchain and verifies the expected outputs.
  •  run-pre-validation.sh  — includes the new setup script test in the repo’s validation flow and runs shell tests with bash.
  •  package.json  — adds an  npm run test:setup-ai  shortcut for the new smoke test.
  •  README.md  — updates the AI setup docs to point users at  ./setup-ai.sh  and notes the required  cmake  dependency.
  •  QUICKSTART.md  — mentions the optional AI bootstrap step in first-time setup.
  •  web/js/main.js  — points capability-gating hints at  ./setup-ai.sh  instead of manual whisper.cpp/LLM steps.
  •  .gitignore  — ignores the local  whisper.cpp/  checkout and downloaded model files.
  •  CHANGELOG.md  — records the new AI bootstrap script in the unreleased notes.

Test Plan

  • Server tests pass (npm test)
  • Manual test: start session, verify audio
  • Tested in Chrome (chromium on Archlinux)
  • Tested in Firefox

Screenshots

Adds a one-shot `setup-ai.sh` bootstrap for the AI pipeline so users can
setup whisper.cpp, download the default mode, and configure LLM provider
from one guided flow.

setup-ai.sh:
  - clone/recover `whisper.cpp`
  - build `whisper-cli` with the current Cmake-based layout
  - download `models/ggml-medium.bin`
  - prompt for LLM provider settings and write them to `.env`
  - update docs to reflect changes
@msitarzewski
msitarzewski merged commit b3f820b into msitarzewski:main Sep 12, 2026
@msitarzewski

Copy link
Copy Markdown
Owner

Merged — thank you, and I'm sorry this sat for four weeks. That's on me, not on the PR.

This is a genuinely useful contribution. setup-ai.sh was sitting near the top of my roadmap notes as the next thing to build, and you showed up and built it. A few things I particularly appreciated reading through it:

  • The whisper-transcriber.js fix is the real win. The old auto-build path was still assuming the pre-CMake layout, so it had quietly stopped working — you caught a live bug while adding a feature.
  • tests/test-setup-ai.sh running the script against a fake toolchain is exactly the right way to test a bootstrap script. That pattern is going to get reused.
  • Wiring the capability-gating hints in main.js to point at ./setup-ai.sh closes the loop on the gating work from v0.3.2 nicely. Good instinct.

Heads-up so it doesn't look like I'm silently rewriting your work: I'm pushing some follow-up hardening on top, mostly around failure modes that only show up on real networks and real .env files:

  • Model download goes to a temp path and gets renamed on success — right now an interrupted 1.5 GB download leaves a truncated file that later runs accept as valid
  • Reading just the LLM_* keys out of .env instead of sourcing it, since real secrets with $ or spaces in them break under set -u
  • Sorting out the .gitignore / gitlink situation, which is a pre-existing mess in this repo that your PR happened to land in the middle of

None of that detracts from the contribution — it's the kind of polish that comes from running a thing against a hostile network a few times. Thanks again for the patience and for the work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants