A command-line tool to search through Star Trek episode transcripts (TOS, TNG, DS9, Voyager, Enterprise) for any word or phrase -- with flexible filtering and fast local lookup.
- Search lines from all major Star Trek series -- \n- Supports word and phrase search -- \n- Filter by series, season, episode, character --
- Automated transcript downloading --
- Fast local searching using JSON files
Prerequisites
- Python 3.x
Installation
- Clone the repository:
git clone https://github.com/ComputerMachine/script-search.git
cd script-search- Install requirements:
pip install -r requirements.txtOptional
a. If you need to redownload the raw transcripts:
python download_transcripts.pyb. Parse transcripts into JSON:
python parse_episodes.pyRun the search tool:
python search.pyYou'll be prompted to enter a word or phrase.
Optional filters include:
- Series (TNG, DSY, VOY, etc.)
- Season
- Episode
- Character
Example input:
live long and prosper
- Some two-part episodes are merged into a single transcript file --
- Episode numbers may appear incorrect for multi-part episodes
- The parser may skip the final line of certain transcripts
- It's been awhile since I've touched this project, just scan it for efficiency and make sure that the JSON is all in one file, no point in it being in multiple
This tool was created as a modern, local, and scriptable replacement for scriptsearch.dxdy.name, enabling fast offline full-text searching of Star Trek transcripts.
- Web-based search UI
- Use ML or AI
- Support for newer series (Discovery, Picard, SNW)
- Fuzzy / approximate search
- Statistics (character usage, phrase frequency)
- Export search results to CSV or Markdown
- License See the LICENSE file for full details.
- Transcript Source: chakoteya.net
- Author: ComputerMachine