Watches Brian Bird's course materials at Lane Community College (CS 212, AI Programming 1, and his other courses) for consistency problems and blind spots.
Joshua Evans, 2026-11-10 (written with Claude Opus 5.5)
Birdwatcher runs static checks over a local clone of one of Brian Bird's course repositories, such as lcc-cit/CS212-CourseMaterials, and shows each problem it finds in an interactive terminal app: open the exact file and line in an editor, fix it, and re-run the checks to confirm the fix.
A course's site is published by GitHub Pages either from its docs/ folder (CS 212, CIS 195, CS 112) or from the repository's top folder (CS 133JS, CS 233JS, CS 246, CS 297); Birdwatcher checks docs/ when there is one, and the whole repository otherwise, leaving out what Jekyll leaves out (node_modules/, vendor/, folders starting with _ or .) and saved copies of other sites' pages (a page saved with its Page_files/ or Page.fld/ folder).
Some of the courses already check that their links resolve, using lychee in GitHub Actions. Birdwatcher checks links too, inside the site and out, in every course, and looks for what a link checker can't see: links to sections that don't exist, files left over from renumbering, accessibility problems, spelling, and code that breaks the course's own style rules.
Status: all ten checks below work, with fixing, ignoring, filtering and a demo mode, and an AI model can judge the spelling errors the dictionary cannot settle (see Asking the AI). Version v0.1.0 is the CS 212 Lab 6 submission; v0.2.0 is the Lab 7 beta. Birdwatcher grows into the term project, which adds simulated students.
With uv installed, one command runs Birdwatcher straight from this repository, with nothing to download or install by hand:
uvx --from git+https://github.com/TheJoshuaEvans/Birdwatcher birdwatcherAdd @ and a tag, branch or commit to run that version instead of the latest, for example ...Birdwatcher@v0.2.0 (the Lab 7 beta), ...Birdwatcher@v0.1.0 (the Lab 6 submission) or ...Birdwatcher@main. Anything after birdwatcher is passed on, so ... birdwatcher check --list-checks works too. To keep it installed as a birdwatcher command, use uv tool install git+https://github.com/TheJoshuaEvans/Birdwatcher.
Requires uv, which installs Python 3.12 itself.
uv sync
uv run pytestuv run birdwatcher # open the app
uv run birdwatcher check # check once and print a summary
uv run birdwatcher check --verbose # ... with progress and every finding
uv run birdwatcher check --course-dir C:\path\to\CS212-CourseMaterials
uv run birdwatcher check --list-checksThe first time the app opens, it asks for the folder of your local clone of a course repository (the folder that holds its pages, in docs/ or at the top) and remembers it. Type or paste the path, or press Browse… (Ctrl+O) to pick it in your system's folder picker. The setup page (s) also lists your recent course folders, so switching between courses is one click, and lets you choose the editor that opens files and the color theme (by default, light or dark to match your system; any theme picked with Ctrl+P is remembered too). On the setup page, Ctrl+T switches between its COURSE and AI MODEL tabs and Ctrl+S saves, from anywhere on the page; Tab moves between everything else. Escape in a text box leaves the box, keeping what you typed; elsewhere, Escape or q goes back to the course (on a first run, with no course yet, q quits). birdwatcher check uses the same folder unless --course-dir names another.
Try the demo on the setup page looks around without a clone of your own: Birdwatcher downloads the CS 212 course materials (about 34 MB) into its cache folder, with the course's word list, and opens them with DEMO in the title. The demo is a fixed snapshot of the course (one commit, from November 2026), so it keeps its findings however the real course improves. It is never saved as your course; later demos open the downloaded copy at once, and Refresh demo downloads a clean copy again (after trying out fixes in it, say).
Reset settings… on the setup page forgets what Birdwatcher keeps (all but its activity log) (see What Birdwatcher keeps), after asking, and starts again as on a first run; course folders are not touched.
Findings appear as each check finishes, so the quick checks show at once while a slow one is still running. When checking again, each check's previous findings stay in the list until its new results arrive.
In the app, mouse and keyboard both work. The bottom bar shows the keys for what is selected; ? lists every key, marking the ones that do not apply right now:
| Do | To |
|---|---|
Click a finding, or n / p (next / previous finding) |
Show it: check, location, message, and the source lines around it |
Click it again, or press Enter or o |
Open the file at that line in your editor |
| Click a branch, or the arrow keys and Enter | Fold or unfold it (folded branches stay folded when the checks run again) |
- / + |
Fold or unfold one level of branches at a time: from everything open, - folds the deepest level, down to one line per check (or the top folder); + opens the list back up a level at a time |
z, then z or Escape to go back |
Show the finding's detail filling the window (in a window narrower than 120 columns, the detail is shown this way instead of beside the list) |
| Drag the bar between the panes | Change the split; Birdwatcher remembers it |
The Check / Folder tabs, or g |
Group the findings by check or by folder |
The SHOW chips, or 1 / 2 / 3 |
Show or hide errors, warnings and info (each chip shows how many are open; Birdwatcher remembers the choice, and starts with errors and warnings) |
| The FIXED and IGNORED chips | Show or hide fixed and ignored findings (each chip shows how many) |
The FIND box, or / |
Show only findings whose file, message or check contains the text, as you type (F401, Lab05, lanecc...); Enter goes back to the list keeping the search, Escape clears it |
f, the FIX button, or a row's [F] FIX marker |
Apply the suggested fix to the file, then check again (fixable rows end in the marker; long messages end in "…" and show in full in the detail) |
| Highlight a branch (a check, folder or file) | Show a summary of its findings (how many of each severity, by check, and how many can be fixed), the FIX ALL button, and every finding in it under its file, with its line, message and suggested fix, to review before fixing them all |
f, FIX ALL, or a branch's [F] FIX N marker (shown from 2 fixes up) |
Fix every fixable finding showing in that branch, after a confirmation, then check again once. A fix that fails (its line changed since the check) is skipped and listed in the branch's summary; the rest still apply |
e, or View in editor |
For a fixed finding: open the fixed line in VS Code |
w, or View on site |
For a fixed finding: open the section the fixed link leads to, on the published site |
u, or Undo |
Put the original text back, then check again |
c, or Clear |
Forget a fixed finding (the file keeps the fix) |
C |
Forget every fixed finding of this course |
i, or Ignore / Un-ignore |
Ignore a finding (with an optional reason), or bring back an ignored one |
a, or Add to dictionary |
For a spelling finding: add the word to the course's cspell.json, so it is never reported again |
m, or Ask AI |
For a spelling error: ask the AI model whether the word is a typo or a word to keep. On a branch: ask about its spelling errors that have no verdict yet, after showing the cost (see Asking the AI) |
h |
Show or hide ignored findings (the IGNORED chip) |
r |
Run the checks again, after fixing something |
ctrl+r |
Hard refresh: run the checks again, asking every web site afresh instead of reusing the day's answers |
x, or STOP |
Stop a slow check while it runs (its progress shows at the bottom of the list); findings from the checks that finished stay, and r checks again |
s |
Choose another course folder, the AI model (the AI MODEL tab), try the demo, or reset the settings |
? |
List every key, marking the ones that do not apply right now |
q |
Quit |
When a check knows the fix, the finding's panel shows it as a before and after, with a FIX button. Fixing edits the lines shown and nothing else (usually one; moving a language label onto its code block changes two, all or nothing), then checks again. Fixed findings stay in the list, marked FIXED, with the change and whether the re-check still reports the problem, so you can confirm each fix with View in editor or View on site and undo it if it is wrong. Birdwatcher remembers fixed findings per course folder, in fixes.json next to its settings, until you clear them. Birdwatcher never commits; git diff shows every change it made.
Any finding can be ignored, with an optional reason ("kept for last term's students"); ignoring an error asks for confirmation first, because readers are affected. Ignored findings leave the list, and the subtitle counts them; h shows them again, with their reasons, and i brings one back. Ignores are remembered per course folder in ignored.json next to the settings. An ignore matches a finding by its check, file and message rather than its line, so it still applies after lines are added or removed above it.
You decide when the AI model is used. Birdwatcher never sends anything to a model on its own: checking a course, opening a finding and fixing all work without one. A model is asked only when you press m.
The spelling check knows its dictionaries, not your course: it flags names, terms and code words. When it has exactly one suggestion (a warning) or the word is British (info), it offers the fix itself. The rest are errors: words with several suggestions or none, which only judgement can settle. The AI is asked about those errors only, never about a finding that already has a fix. m sends the flagged word, with the line it is on, to the model chosen on the AI MODEL tab, which answers with a verdict:
- typo, with the correction. In prose, the correction becomes the finding's fix, shown as a before and after like any other (AI fix):
fapplies it, and Undo takes it back. In code, or inside a longer name, no fix is offered, because renaming one use of a name could break the code; fix it by hand. - keep: the word is spelled as meant (a name, a technical term, a word from code), and
aadds it to the course'scspell.json.
Each verdict shows its reason and the model that gave it. A verdict belongs to a word in its line, not to the word: the same misspelling can mean different things in different places, so each line gets its own verdict, and editing a line clears its verdict (m asks again about the new wording). On a branch (the Spelling check, a folder, a file), m first shows what asking will cost: how many errors (each is asked about, even when the same line appears in several places), in how many requests (40 each), and roughly how many tokens. Models that think before they answer use several times more; the notification afterwards gives the real count. Only errors without a verdict are asked about, so asking twice never pays twice. Verdicts are remembered per course folder, in spelling-verdicts.json next to the settings; m on a single finding asks again, for a second opinion.
While the model is asked, the strip at the bottom of the list says so: ASKING, the request being waited for ("request 2 of 3") and a running clock. A request can take a minute or more with a thinking model. x (or STOP) stops asking after the request already sent. When a model fails on its own (it answers without text, the provider has an error, or it takes too long), that request is sent once more, since a router may pick another model; failing again, it is skipped and asking carries on. A refused key, a rate limit or an unreachable provider stops asking. Afterwards the branch's detail keeps the outcome: verdicts on how many words, the tokens and time, anything skipped or stopped, and how many words still have no verdict (m asks about them).
The default model, openrouter/free, sends each request to whichever free model is available, often a small one, so verdicts can differ between requests and between runs. The AI MODEL tab and the cost dialog say so; for steadier verdicts, choose a model with Pick….
Files open in the editor chosen on the setup page:
- VS Code opens at the exact line. It needs its
codecommand on the PATH: the Windows installer adds it; on a Mac, run VS Code's command Shell Command: Install 'code' command in PATH once. - Typora opens the file at the top, and Birdwatcher says which line to look at. It is found wherever its installer or the Microsoft Store put it (and in
/Applicationson a Mac). - The file's default app opens it with whatever your system uses for that file type.
The setup page's AI MODEL tab chooses the chat completion API that Birdwatcher's AI features use. Every provider is reached with the openai Python SDK, as in the CS 212 notes on calling a chat completion API, so any model a provider offers works:
| Provider | Key | Notes |
|---|---|---|
| OpenRouter (the default) | OPENROUTER_API_KEY |
One key for models from every company. The default model, openrouter/free, routes to whichever free model is available. |
| Gemini | GEMINI_API_KEY |
Google's models, through Google's OpenAI-compatible address. |
| OpenAI | OPENAI_API_KEY |
OpenAI's own models. |
| Local | none | Ollama on this computer (http://localhost:11434/v1). |
| Custom URL | optional | Any other address that speaks OpenAI's format, such as LM Studio (http://localhost:1234/v1). |
The key comes from the provider's environment variable, set as the course notes describe, or from Set key…, which keeps it in your system's keyring (Credential Manager on Windows, Keychain on a Mac), never in Birdwatcher's settings file. A key saved in Birdwatcher wins over the environment variable; the tab says which one is in use without showing it, and Forget saved key removes a saved one.
Pick… lists the provider's models to choose from, with a filter (type free, claude, gemma...) and, on OpenRouter, each model's price per million tokens and context length. The TEST CHAT below sends messages to the chosen model, keeping the conversation, and shows each answer with the model that wrote it (a router names the model it chose), the tokens it read and wrote, and how long it took. Clear starts a new conversation. Changes on the tab are saved with Save, like the rest of the setup page.
Birdwatcher reads the course from a local clone, so it sees edits before they are committed: fix a problem, press r, and the finding is gone. The chosen folder is saved in config.json in your user config folder (on Windows, under %LOCALAPPDATA%\birdwatcher).
Pages sometimes link to their own sections with the published site's full address (https://lcc-cit.github.io/...). Birdwatcher works out that address from the clone's origin remote on GitHub, reading the git config directly, so git itself is not needed. Submodule checkouts work too, and the demo's copy (which has no git folder) names its repository in a small .birdwatcher-repo file.
Everything Birdwatcher keeps is in its own folders, never in a course (except the words you add to a course's cspell.json):
| What | Where |
|---|---|
| Settings: the course folder, recent courses, editor, theme, split, shown severities, AI provider and model | config.json in your user config folder (on Windows, %LOCALAPPDATA%\birdwatcher) |
| API keys saved with Set key…, one per provider | The system keyring, under the service name birdwatcher |
| Fixed findings, per course folder | fixes.json, next to the settings |
| Ignored findings and their reasons, per course folder | ignored.json, next to the settings |
| Answers from web sites, for a day | links.json, next to the settings |
| The AI's spelling verdicts, per course folder | spelling-verdicts.json, next to the settings |
| The activity log (see below) | birdwatcher.log, next to the settings, with up to two older copies (.1, .2) |
| The downloaded demo course | demo/ in your user cache folder (on Windows, %LOCALAPPDATA%\birdwatcher\Cache) |
Reset settings… on the setup page deletes all of these except the activity log. API keys in environment variables are yours, and stay.
Birdwatcher writes what it does to birdwatcher.log, one event per line with the time to the millisecond, so a session can be followed afterwards (when something looks wrong, the log says what happened): its start (version, Python, system), each key action and button, each check (its time and how many findings), every fix, undo, ignore and added word, every notification it showed, every setting saved, and any crash with its traceback. Requests to the AI model are logged in full: the model, the prompt, the answer, the time taken and the tokens used, or the error.
API keys are never logged: a saved key is logged only as "a key was saved", keystrokes are not logged (actions are), and other libraries' logs, which can carry request headers, are left out. The log can hold course text (the lines sent to the model); it stays on your computer.
When the log reaches about 1 MB it is renamed birdwatcher.log.1 and a new one begins, so it never grows past about 3 MB. The setup page shows where it is and how large; DELETE LOG deletes it and its copies. birdwatcher check writes to the same log.
Checks produce findings as plain data: the check, the severity, the file and line, a message, and a fix when the check knows one. The app and birdwatcher check are two views of the same findings, built with Textual and Rich. In birdwatcher check --verbose, each file and line number is a vscode:// link that opens it in VS Code.
- Broken section links: links to a
#sectionthat doesn't exist on the target page. Section ids follow the site generator's rules, which turn "Architect & Planner" intoarchitect--planner; tables of contents generated by other tools often expectarchitect-planner. Fixable when a section with a close id exists. - Renumbering leftovers: files named for a different lab or group than the folder they are in (warnings), and lab folders that share a number (info). Opening a folder finding shows it in your file browser.
- Stray language labels: a line reading only "Python" (or "Bash", "PowerShell"...) directly above a code block, left over from pasting code out of an editor or a chat assistant. Fixable: the label moves onto the code block's opening fence (
```becomes```python), so the block gets syntax highlighting; when the fence already names a language, the label is just removed. - Skipped heading levels: a heading more than one level below the previous one, which breaks navigation for screen-reader users. Markdown headings are fixable (moved up to one level below the previous heading).
- Images without alt text: images that screen readers cannot describe. An HTML
alt=""(a decorative image) is fine. - Incomplete front matter: published pages missing a
title,descriptionorauthor(README files are skipped; the site doesn't publish them). Only for a site set up for Jekyll pages (with a_config.yml). - Dead links: links and images, in Markdown and HTML pages, that lead to nothing on the published site: missing pages and files (with a "did you mean" when a file has a close name), paths outside the published site, and paths whose letter case only works on Windows and macOS, because the site's server tells
Images/andimages/apart (fixable: the path is spelled as the file is). - Spelling: words in the pages (prose and code) and the course's code files (
.py,.js,.css) that are not in the dictionary, leaving out minified code (.min.js, or any line over 1,000 characters) and whatever the course'scspell.jsonlists inignorePaths(such as a library the course ships), with identifiers split into their words as VS Code's Code Spell Checker does (maxLengthandmax_lengthare checked as "max" and "length"); links, HTML, file names and words with letters outside English are left out. A word with one obvious correction (a known typo, or the only word one letter away) is a warning, fixable in prose (never in code, where it could rename an identifier); a word with none or several is an error; a British spelling is info, fixable to the American one. Code and software words (Python, JavaScript, HTML, CSS, data science, companies' names) are built in, from the MIT-licensed dictionaries Code Spell Checker itself uses, plus a short list of Birdwatcher's own (seebirdwatcher/checks/words/). A course's own words (people's names, its terms and variable names) live in itscspell.json, the file Code Spell Checker reads too;aadds a word to it. - Dead links to other sites: asked about over the network, in the background with progress at the bottom of the list (
xstops it). Errors: pages that are gone (404, 410), server errors (5xx), and addresses nothing answers. Info: sites that turn automated checks away (401, 403, 429, other 4xx; open them in a browser to be sure), and pages that moved permanently to a different address (fixable: the link gets the new address; moves that only addhttps,www.or a trailing/are skipped). Addresses in the course's.lycheeignoreorlychee.tomlexcludelist are skipped, as arelocalhostaddresses. Birdwatcher asks each server about at most two pages at a time, identifies itself as a link checker, and keeps answers for a day inlinks.jsonnext to its settings (server errors and failures are asked again on the next run). - Python style: Ruff over the
.pyfiles and Jupyter notebooks in the published site, with the course's own rules (GradingAssistant/ruff.toml, the ones the labs are graded on; otherwise aruff.tomlat the repository root, or whatever settings Ruff finds near the files). Unused imports, undefined names and syntax errors are warnings; the rest is style (info). Notebook findings name the cell. Fixable when Ruff's own fix is safe and changes one line of a.pyfile (on CS 212 today: stray whitespace). Ruff comes with Birdwatcher, and leaves no cache in the course folder.
- A view of all your courses at once (which ones need attention), and a word list for each course.
- Python code blocks that don't parse, ignoring
>>>prompts and deliberate placeholders such as???. - Lab self-numbering: page titles and main headings that name a different lab than their folder.
- Lab completeness: every lab has its instructions, code review form and rubric, and none of them only as a draft.
- License notices on pages that agree with each other and with the repository's
LICENSEfile. - Analysis of the materials by a large language model (Lab 7).
- Simulated students who attempt a lab using only the published materials (term project).
| Command | Does |
|---|---|
uv run pytest |
Runs the tests. Tests sit next to their module, named *_test.py. |
uv run ruff check |
Lints with the course style rules (configured in pyproject.toml). |
uv run ruff format |
Formats the code. |
uv run python tools/update_word_lists.py |
Refreshes the built-in spelling word lists from Code Spell Checker's dictionaries on npm. |
uv run python -m birdwatcher |
Runs Birdwatcher from the source, the same as uv run birdwatcher. |
$env:TEXTUAL_DEBUG = "1"; uv run birdwatcher |
Runs the app in Textual's debug mode, which reloads birdwatcher.tcss whenever it is saved (PowerShell; in bash, TEXTUAL_DEBUG=1 uv run birdwatcher). Debug mode also logs every key and mouse event to keys.log in the current folder; it is git-ignored. |
| Folder | Holds |
|---|---|
birdwatcher/core/ |
Findings and fixes, the check interface, running checks over a course folder, the saved settings, a course's word list, asking web sites about links, the demo download, and talking to chat completion APIs (core/ai.py). No user interface code. |
birdwatcher/checks/ |
One module per check, and the registry of all checks; checks/words/ holds the built-in spelling word lists. |
birdwatcher/ui/ |
Console output for birdwatcher check, desktop integrations (VS Code, the folder picker, the keyring), and the Textual app in ui/tui/, one module per screen or dialog, styled by birdwatcher.tcss. |
tools/ |
Development scripts, such as refreshing the built-in word lists. |
Dependencies point inward, from ui to checks to core, and a test enforces it. AGENTS.md has the full working rules: the layers, test-first development, and where new checks, screens and settings go.
The course materials belong to Brian Bird and carry their own license notices. Birdwatcher reads them, and changes a file only when you fix a finding.