14B.3 GitHub Presence and Project READMEs

Ship & get hiredLesson 3 of 913,254 wordsOptional7 parts
Module 14B · all lessons optional
  1. 1
  2. 2
  3. 3
  4. 4
  5. 5
  6. 6
  7. 7
  8. 8
  9. 9

Your GitHub profile is the first link on your résumé, the thing a hiring manager opens before the interview, and the shelf where your portfolio lives. This lesson treats it as what it is: a landing page with engineering standards. You will learn how to make your profile README, pinned repositories, contribution graph and settings work for you rather than against you; what an excellent project README contains, section by section, for a portfolio piece and for a tool other people might actually use; how to document an AI project specifically — evals, prompts, models, costs, system cards — so a reviewer can verify your claims instead of trusting them; the repository hygiene checklist that separates "student repo" from "professional repo"; how to wire GitHub Actions so your portfolio proves itself on every push; and when a README stops being enough and you need docs, notebooks or a package. Everything checkable is checked against GitHub's own documentation as of November 2026; where GitHub changes features often, you will learn where to look rather than memorise a screenshot.

What you'll learn

  • How a reviewer actually reads your GitHub in the first minute, and what your profile README, bio, avatar, pinned repositories and settings should each say
  • What the contribution graph counts (and the many things people wrongly believe it counts), what stars, forks, watchers and organisations really mean, and the privacy settings that keep your personal email and private work out of view
  • The anatomy of an excellent project README: pitch, visuals, a five-minute quickstart, architecture diagram, design trade-offs, evaluation table, limitations, cost, security, structure, testing, licence — plus three before-and-after rewrites
  • AI-project documentation: the system card, prompt and version documentation, eval methodology and golden-set description, model/provider choices, reproducibility notes, and responsible-use and known-bias notes
  • The repository hygiene checklist: .gitignore, .env.example, secrets in history, licence choice, governance files, releases and changelog, commit history, branch protection, badges and security features
  • A portfolio CI workflow (lint, type-check, test, a keyless eval smoke test), publishing docs with GitHub Pages, dependency update bots, and when a docs site or notebook beats a README
  • career_kit/readme_template.md, the full copy-ready README template, and career_kit/readme_lint.py, a standard-library linter that checks your own README — with real output

What you don't need

  • A GitHub account with repos already. Everything here is design and checklist work you can do on paper; the exercises need only a text editor and one repo you own (or a scratch repo you create).
  • API keys or model access. The CI examples use fakes and the standard library; nothing in this lesson calls a provider.
  • Deep git knowledge. Lesson 00.3 covers commits, branches and history; lesson 00.4 covers GitHub itself — this lesson goes deeper on the portfolio side of both.

Setup

This lesson needs no installation and no API keys. The only code is career_kit/readme_lint.py, pure standard library on Python 3.11+:

bash
python3 --version    # needs 3.11 or newer; the script uses only stdlib

Keep the script inside the Module 14B career_kit package (it grows one file per lesson; 14B.2 introduced portfolio_audit.py the same way):

bash
mkdir -p career_kit && touch career_kit/__init__.py

Then save the code from Part 7 as career_kit/readme_lint.py and run python3 career_kit/readme_lint.py README.md. The README template from 2.7 is a Markdown file you copy into any project — it is not executed.


What you must be able to do after this lesson#

  • Set up a GitHub profile README, bio and pinned repositories that work as a landing page
  • Explain what the contribution graph and stars do and do not prove
  • Write a project README with a pitch, a five-minute quickstart, architecture and evaluation
  • Document an AI project with a system card, prompt versions and eval methodology
  • Apply the repository hygiene checklist: .gitignore, .env.example, licence and no secrets in history

Why this matters for an AI engineer#

You'll hear... You'll understand it after...
"Send me your GitHub." Part 1: what they see in the first minute
"Pin your best work." 1.4 Pinned repositories
"Your contribution graph looks dead." 1.5 The contribution graph: what counts and what doesn't
"Write a README people actually read." Part 2
"It clones and runs? Prove it." 2.3 The five-minute quickstart and 5.2 The portfolio CI workflow
"Where are your evals?" 3.4 Evaluation methodology
"Is this a toy or a product?" 3.2 The system card and 3.7 Responsible use
"Did you commit a secret?" 4.2 Secrets in history
"Why does the README link 404?" 7.3 Real output — readme_lint.py finds exactly this

Part 1: Your GitHub profile is a landing page#

1.1 What a reviewer actually sees#

Be honest about the evidence here: GitHub does not publish "how hiring managers read profiles" statistics, and most advice on this topic is anecdote dressed as data. What is verifiable is the sequence of screens a motivated reviewer performs, because it's the same sequence for any public profile:

  1. Your name and avatar — do you look like a person or a default identicon?
  2. Your bio line — one sentence; does it say what you do?
  3. Your profile README — the top of your profile page, if you've created the special repository (below).
  4. Pinned repositories — up to six items; the reviewer clicks the most relevant one or two.
  5. The repository page itself — README first, then the file tree, the commit history, the "About" sidebar (description, website, topics), stars/forks, and the CI badge if there is one.
  6. Deeper, if interested — contribution graph, activity timeline, other repos, your issues and PRs on other projects.
flowchart LR
    A["Reviewer opens<br/>your profile"] --> B["Bio + avatar<br/>(5 seconds)"]
    B --> C["Profile README<br/>(if present)"]
    C --> D["Pinned repos<br/>(pick 1-2)"]
    D --> E["Repo README + quickstart<br/>(the real test)"]
    E --> F["CI badge, evals,<br/>commit history"]
    F --> G["Contribution graph,<br/>activity, other repos"]

The lesson this diagram teaches: everything before the repo README is a filter, and the repo README is the audition. A beautiful profile README cannot rescue a pinned repo whose README is a stub; a great repo README can survive a mediocre profile. Spend effort in that order.

1.2 The profile README#

GitHub will render a README at the top of your profile if all of these are true (verified against GitHub Docs, as of November 2026):

  • You have a public repository whose name exactly matches your username (e.g. octocat/octocat for user octocat).
  • The repository's root contains a README.md with any content.

Create it from the "+" menu → New repository, name it your username, make it Public, and toggle Add README on. Edge case worth knowing: if you created such a repo before July 2020, GitHub doesn't auto-display it — you can share it manually via Share to profile on the repo page.

What belongs in a profile README, in priority order:

  1. Who you are in one line — "Applied AI engineer. I build LLM features with evals, not vibes." Specific beats humble-brag.
  2. What you're building or learning now — one or two lines, updated occasionally. This is the highest-signal "is this person alive and growing" indicator.
  3. Your best 2–4 projects with one-line pitches and links — the pins below do the visual work; the README adds the why.
  4. How to reach you — email or a contact link, plus links to LinkedIn/portfolio if you have them.
  5. Optional flavour — a small table of skills, a "currently reading" line, an honest note about what you're looking for. Keep it short: under ~60 lines renders well; GitHub truncates rendered Markdown beyond 500 KiB anyway (more on that in 2.1).

What does not belong: follower counts, "500+ connections", engagement-bait, badges you didn't earn, a wall of every technology you've touched, or anything you wouldn't say in an interview. GitHub itself warns that anything on a public profile is visible worldwide, including in regions where expressing your identity may carry risk — a real consideration if you live somewhere that matters to you.

The profile README is the billboard; these are the fixtures around it. All verified against GitHub's profile reference (as of November 2026):

  • Profile picture: PNG, JPG or GIF, under 1 MB and under 3000×3000 px; ~500×500 px renders best. A real photo or a clean, professional graphic — not a meme, not a default identicon. Your identicon is generated from a hash of your user ID; you can't choose it, so upload something.
  • Name field: your real name (or the name you want professionally associated). It shows next to your comments on private org repos too.
  • Bio: one line under your name. Write it for the reviewer: "Applied AI engineer — LLM APIs, RAG, evals" not "Building the future with AI".
  • Pronouns: optional; visible only to signed-in users.
  • Location and time zone: shows your local time to viewers. Include a coarse location if you're open to relocation or remote work in that region; omit it if privacy matters more. It's a judgement call, not a requirement.
  • Status: a short "what's happening" line with optional emoji, an expiry, a Busy flag (which shows a "busy" note next to your name when people @mention you, assign you an issue or pull request, or request your review, and which also excludes you from automatic review assignment for your teams), and visibility control (public or per-organisation). Useful for "open to work" or "heads-down on capstone until March". Don't leave a stale status up — an expired-looking status reads as abandoned.
  • Links: social/account links on your profile. Link your portfolio site, LinkedIn, and the repos you most want seen.
  • Organisations: if you belong to orgs (a college club, an open-source org, a company), they appear on your profile. Join only orgs you'd mention in an interview.

Badges appear automatically for some programmes — the Developer Program Member badge (for building with the GitHub API), the PRO badge (paid plan), Security Bug Bounty Hunter, GitHub Campus Expert and a security-advisory credit badge (for accepted GitHub Advisory Database submissions). Achievements are small badges in the profile sidebar for milestones such as pull requests merged or discussions answered; GitHub's docs describe them as a public-preview feature subject to change as of November 2026, and you can show or hide them individually or entirely in settings, so check your profile rather than memorising a list (profile reference).

1.4 Pinned repositories: six slots, zero wasted#

Your profile shows a Pinned section once you pin anything — up to six repositories and gists combined (verified as of November 2026). You can drag them into order, and pinned items replace the "Popular repositories" section. Eligibility: you can pin a public repo you own, or one you've contributed to within the last year — and commits to forks you don't own don't count, so you can't pin a random fork. Any public gist you own can be pinned too.

Order matters because reviewers read left to right and top to bottom. A sane ordering for an AI-engineering candidate:

Slot What to pin Why
1 Your flagship (capstone or best project) The repo you most want judged
2 A depth piece (evals, RAG, agents) Shows the skill the job tests
3 A breadth/utility piece (CLI, small service) Shows range and engineering taste
4 An open-source contribution you made (a PR, not your fork) Social proof you work with others
5 A write-up, gist or notebook that explains something Communication skill, if it's good
6 A personal/utility repo or second project Rotation slot — refresh as work improves

Each pin shows live star/fork counts, the language bar and the repo description — which is why the "About" description matters (set it in repo Settings or gh repo edit --description). A pin with 0 stars and a stub README is a wasted slot; six mediocre pins are worse than four excellent ones — you don't have to fill all six.

1.5 The contribution graph: what counts, what it doesn't#

The green grid on your profile is the most misunderstood object on GitHub. Here is what the docs actually say (verified as of November 2026):

What counts as a contribution — on your profile page:

  • Always: creating a new repository, forking an existing repository.
  • Sometimes: opening an issue, proposing a pull request, submitting a PR review, opening a discussion, answering a discussion, making a commit.

The "sometimes" items have conditions: issues, PRs and discussions only count if opened in a standalone repository, not a fork; commits only count if all of these hold — the commit email is associated with your account, the commit is in a standalone repo (not a fork), it's on the default branch or the gh-pages branch, and at least one of: you're a collaborator/org member, you forked the repo, or you opened a PR/issue there. GitHub's own docs are slightly inconsistent about when the day boundary falls: the contributions-on-your-profile page says contributions are timestamped in UTC, while the profile-contributions reference says commits use the time zone in the commit timestamp and issues/PRs opened on github.com use your browser's time zone (ones opened via the API use the API call's). Either way, work done late at night can land on an adjacent day — don't over-read a boundary square.

What people wrongly believe:

  • ❌ "A green square means productive work." It means some qualifying action happened that day — one commit or forty. It's a presence indicator, not a productivity metric. Commit a typo fix at 23:59 and the day goes green.
  • ❌ "Activity on my fork counts." Fork commits don't count unless conditions above are met; that's why the graph looks empty while you're learning on forks.
  • ❌ "Private work can be hidden from the graph." By default the graph shows public activity only; you can opt in to showing private contributions anonymised (counts, no details). Either way, understand what you're displaying.
  • ❌ "I can game it with empty commits." You can — daily empty commits turn the graph green — and reviewers who check git log will see it. Honest sparse history beats performative greenness. If you're job hunting, a gap is normal; a suspiciously perfect year of green with thin repos is a red flag.
  • ❌ "Missing squares mean missing work." Commits authored with an email not linked to your account don't count — the classic "my commits don't show" bug. Fix: add the commit email in Settings → Emails (a noreply address works too).

The activity overview (opt-in in contribution settings) shows viewers the types of contributions and which repos/orgs you're active in — more informative than the raw grid, and it lets viewers filter by organisation. The contribution activity timeline below the graph lists commits, PRs and issues with highlights for milestones (first PR, joined an org).

Quality over quantity, operationalised: for a portfolio, what matters is that your graph shows sustained, real work on real repos — your own projects and genuine contributions. Ten meaningful weeks beat a year of bot commits.

1.6 Stars, forks, organisations, topics and labels#

Honest meanings, verified against GitHub docs:

  • Stars are bookmarks: "I found this interesting." Per GitHub's own docs, starring shows appreciation and helps discovery — it does not subscribe you to notifications and does not appear in anyone's activity feed. A star count is a weak popularity signal, easily inflated, and reviewers know it. Don't optimise for it; don't buy it (astroturfing is detectable and career-negative, as 00.4 warns).
  • Forks are copies for your own work. A fork count on your repo means people intend to modify — mildly positive. Your own forks of other projects are normal and fine; they just don't feed your contribution graph (see 1.5).
  • Watching/subscribing is the notification mechanism — the API's subscribers_count. (Historical quirk: the API's watchers_count field actually reports stars, a leftover from before GitHub split the concepts in 2012.)
  • Organisations are shared accounts for teams/projects. For a portfolio, org membership signals collaboration; don't join one just for the badge.
  • Topics classify your repo for discovery: lowercase letters, numbers and hyphens, max 50 characters each, max 20 topics (verified). GitHub suggests topics for public repos based on content — accept the good ones, add your own (llm, rag, python, fastapi, evaluation). Good topics help strangers find you; they're also a small signal that you understand classification.
  • Labels organise issues/PRs/discussions within a repo (bug, good first issue, documentation). If you run a repo others might contribute to, seed a few sensible labels.

The repo's About sidebar — description, website link, topics — is prime real estate: one sentence that says what the project is, not what it is made of. "Document Q&A with citations and abstention over your own files" beats "A python project using LLMs".

1.7 Privacy and security settings#

Ten minutes here prevents real problems. All verified against GitHub Docs (as of November 2026):

On your account:

  • Emails (Settings → Emails): enable Keep my email addresses private so web-based Git operations use your noreply address, and Block command line pushes that expose my email so a git push fails if your latest commit's author email is a private one. This is the single most important privacy toggle — your commit email is how GitHub links commits to you, and you do not want your personal address harvested from public commit metadata.
  • Commit attribution: commits only count on your profile if the author email is connected to your account (or is your noreply address). Set git config --global user.email to the address you want associated — see 00.4, §3 and Git's own docs.
  • Two-factor authentication: non-negotiable; 00.4, §2.2 covers it.
  • Signed commits: a "Verified" badge on commits proves authorship cryptographically. Awareness level is enough — setup is in 00.4, §8.4; it's increasingly expected in security-conscious repos.
  • Push protection for users: on by default — it blocks you from accidentally pushing recognised secrets to public repos you don't own. Leave it on.

On each public repo (Settings → Code security and analysis; verified availability):

  • Dependency graph — enables Dependabot alerts; recommended minimum per GitHub's own guidance.
  • Dependabot alerts / security updates / version updates — free vulnerability alerts and bump PRs (00.4, §8.2).
  • Secret scanning + push protection — free on public repos; scanning watches history/issues/PRs for credential shapes, push protection blocks them before they land. On private repos these need paid plans — another reason portfolio repos should be public.
  • Private vulnerability reporting + SECURITY.md — a "Report a vulnerability" button for public repos; pair with a SECURITY.md telling reporters where to go (00.4, §8.3, and 4.8 below).
  • Code scanning — free on public repos; deeper analysis (CodeQL etc.). Worth enabling on a serious portfolio repo; optional for learning repos.

Profile-level privacy: you can set your whole profile to private — but note the documented limitations: private profiles can't receive GitHub Sponsors, past activity stays visible where it happened, and activity on public repos remains visible on those repos. For a portfolio, public is the point; use the granular controls (email privacy, private-contribution anonymisation, status visibility) instead of going fully dark.


Part 2: Anatomy of an excellent project README#

2.1 What GitHub says a README is for#

GitHub's own documentation (verified as of November 2026) says a README tells visitors what the project does, why it is useful, how to get started, where to get help, and who maintains it. It also notes the practical mechanics worth knowing:

  • GitHub surfaces a README found in the .github/ directory first, then the repository root, then docs/. For portfolio repos, keep it at the root — one canonical file, no guessing.
  • Rendered Markdown is truncated beyond 500 KiB. A README is a front page, not a manual; when it grows, move detail into docs/ and link it.
  • GitHub auto-generates a table of contents for rendered Markdown files, so deep ##/### structure is navigable for free — use real headings, not bold text.
  • The repo's About description, website and topics sit beside the README; write them as a team, not as an afterthought.

For an AI-engineering portfolio, the README has one job above all others: let a stranger verify your claims in under five minutes. "It works" is a claim; a quickstart they can run, an eval table with a date, and a limitations section are evidence.

2.2 The anatomy, section by section#

Here is the full skeleton, with the reasoning for each block. The copy-ready version is in 2.7; the linter in Part 7 checks for the non-negotiables.

1. Title and one-line pitch. # docs_qa then one sentence: what it does and for whom. "Document Q&A with citations and abstention over your own files — a Python package, not a chatbot wrapper." If the name doesn't say it, the pitch must.

2. Visual proof above the fold. A screenshot, a short GIF/asciinema-style recording, or an architecture diagram within the first screen. Reviewers decide in seconds whether to keep reading; a wall of text before any evidence loses them. For CLI tools, a terminal capture; for services, the demo or an architecture Mermaid diagram (renders natively — 2.4).

3. Badges — only meaningful ones. CI status, licence, Python version, maybe an eval score. See 2.5. A row of fifteen decorative shields is noise.

4. Why this exists. Two or three sentences: the problem, why existing approaches fell short for your case, and what you built instead. This is where judgement shows. "I needed citations my manager could audit" beats "I wanted to learn RAG" — though honesty about being a learning project is also fine if labelled: "Portfolio project: built to demonstrate X".

5. Features. A tight bullet list of capabilities — what it does, not what it's made of. "Answers questions with verbatim citations" not "uses embeddings and a vector store" (the stack belongs in architecture, not features).

6. Quickstart — under five minutes. Copy-paste commands that work on a clean machine: git clone, uv sync, cp .env.example .env, run. No "first, install Python and configure your editor" preamble — link prerequisites briefly and move on. Detail in 2.3.

7. Architecture diagram. One Mermaid diagram showing the pipeline: ingest → chunk → embed → retrieve → generate → cite. For an AI project this is the highest-value diagram — it proves you know how the pieces connect. Keep it to ~10 nodes.

8. Design decisions and trade-offs. A short table or list: "Chose hybrid BM25+vector retrieval over pure vector because…", "Abstains below confidence 0.4 because…", "Used a workflow not an agent because…". Every entry: decision, alternatives considered, what would change your mind. This section is where senior engineers' READMEs differ from tutorials — it shows judgement, the thing interviews test.

9. Evaluation results. If the project has evals (and AI projects should — 14B.2 makes them the upgrade recipe), publish the table: dataset, size, metric, score, date and model versions. "n=120 golden set, answer-correctness 0.86 ±0.04, run 2026-10-30 on gpt-6-luna" beats "accuracy: 90%". Methodology details live in 3.4.

10. Limitations and failure modes. The most honest and most convincing section. "Fails on scanned PDFs without OCR", "citations can be wrong when retrieval misses", "English-only", "costs ~$0.002/query at this traffic". Reviewers trust you more when you name your own failure modes — it demonstrates the self-awareness the job requires.

11. Cost notes. For anything calling a model: rough cost per request and per month at a stated assumption, with the pricing page and date cited. Module 11B owns the economics; the README just needs the headline numbers.

12. Security and privacy notes. One paragraph: what data leaves the machine, what keys are needed, what the threat model is ("prompt injection via uploaded documents is mitigated by X; see docs/security.md"). Link 12.7 depth if relevant.

13. Project structure. A commented tree of the important directories — not every file. docs_qa/ (the package directory at the repo root, as Module 07 builds it; src/docs_qa/ if you moved it into a src layout) with one-line descriptions.

14. Testing. How to run tests, what they cover, the CI badge proving they pass. For AI projects, say what the tests can't cover (non-determinism) and what you do instead (evals, fakes).

15. Deployment / usage beyond quickstart. Config options, environment variables table (.env.example documents them), Docker awareness if applicable (link 11C.1).

16. Roadmap. Honest "what's next": known gaps, the next experiment. Signals self-awareness; also gives interviewers an easy follow-up question you want asked.

17. Licence. LICENSE file + one line in the README ("MIT"). Choice guidance in 4.3.

18. Acknowledgements and contact. Credits (datasets, libraries, people who reviewed), and how to reach you — issues are fine for public repos.

Sections 4–10 are the ones tutorials skip and reviewers notice. Sections 1–3 decide whether they ever scroll that far.

2.3 The five-minute quickstart#

The quickstart is the most-tested part of your README — reviewers will run it, often in a clean environment, often on a call. Rules that make it survive:

  1. Assume nothing. No "assuming you have Python" — link or state the minimum version. uv users get uv sync && uv run ...; pip users get the alternative. 01B.10 covers packaging if your project is installable.
  2. clone → sync → env → run in four commands, each copy-pasteable, each expected to produce visible output within a minute.
  3. .env.example committed, .env ignored. The example file lists variable names with placeholder values (OPENAI_API_KEY=sk-...), never real-looking keys — and your README says where to get keys (provider console links) without embedding them.
  4. A keyless path if one exists. For AI projects especially: "no API key? uv run python smoke.py runs ten canned questions through the pipeline against a bundled corpus with a fake model" — reproducibility without secrets is a portfolio superpower (your Module packages already work this way with fakes; say so).
  5. Expected output shown. Paste what the command prints so the reviewer knows it worked.
  6. Test it yourself in a clean environment. Clone to a mktemp -d directory, follow your own README literally, time it. Every typo you find is one a reviewer would have found.
bash
# The shape every quickstart should have
git clone https://github.com/you/docs-qa.git
cd docs-qa
uv sync                       # or: pip install -e .
cp .env.example .env          # fill in keys, or skip for the keyless demo
uv run python smoke.py        # keyless: ten canned questions, FakeLLM
# real provider: put a key in .env and wire it behind the LLM seam (see "Configuration")

2.4 Visuals: screenshots, GIFs and Mermaid diagrams#

  • Screenshots: crop tightly, annotate the interesting part, keep under ~200 KB where possible, give them descriptive filenames (architecture.png, not image1.png) and always write alt text — ![Architecture: ingest to retrieval to generation](https://raw.githubusercontent.com/OWNER/REPO/main/docs/architecture.png) (a relative path like docs/architecture.png works too — descriptive alt text is the point). Alt text is accessibility and shows up when images fail to load.
  • GIFs/screen recordings: for demos, a 10–30 second loop of the actual product beats ten static screenshots. Keep them small (a few MB max); GitHub renders them inline. Tools: any screen recorder; vhs/terminalizer-class tools for terminal demos (awareness only — pick what you have).
  • Mermaid: GitHub renders Mermaid diagrams in fenced mermaid code blocks natively in READMEs, issues, PRs, discussions and wikis (verified as of November 2026). Use it for architecture and flow diagrams — it stays in sync with the code because it's text. Caveats from experience and GitHub's docs: GitHub controls the Mermaid version (it can lag the latest release), stick to stable diagram types (flowchart, sequenceDiagram, erDiagram, gantt, pie), avoid %%{init}%% theme hacks that fight GitHub's light/dark themes, and keep diagrams small enough to read in the README's column width. Check yours before you rely on it: preview the README on a scratch branch on GitHub, or paste the diagram into the Mermaid Live Editor, which reports syntax errors immediately.

2.5 Badges that earn their pixels#

A badge should answer "did something verifiable happen?" Badges that do:

  • CI status — ![CI](https://github.com/OWNER/REPO/actions/workflows/ci.yml/badge.svg) linked to the Actions run. Proven format (verified); note that badges on private repos aren't accessible externally, so this only works on public repos — another reason portfolio repos are public. Build it via repo → Actions → your workflow → "Create status badge", or by hand with the documented URL pattern.
  • Licence — shields.io license-MIT-blue style, or just write "MIT" in text. Either is fine; the LICENSE file matters more than the badge.
  • Python version — only if you actually test multiple versions in CI.
  • Release/version — if you do real versioning (4.5).
  • Eval score — only if it links to the eval report with method and date. A badge saying "accuracy 94%" with no methodology is worse than no badge.

Badges that don't: star/fork counters (vanity), "100% uptime" on a toy, download counts on a package nobody downloads, language-percentage bars (GitHub already shows those in the sidebar). If a badge can't be traced to a check someone can run, cut it.

Real portfolio READMEs fail in recognisable ways. Three fictional before→after rewrites below cover distinct project shapes — an AI extraction tool, a command-line utility and a small library — plus one anti-pattern that needs no rewrite. All names and projects are invented:

Example A — the stub. Project: invoice-parser, a student's invoice-extraction tool.

markdown
# invoice-parser

A tool that parses invoices using AI.

## Setup
pip install -r requirements.txt
python main.py

Problems: no what/why, no example output, no evals, no limitations, requirements.txt unpinned, no licence, no idea if it works. A reviewer closes the tab in ten seconds.

Example B — the rewrite.

markdown
# invoice-parser

Extract structured line items from invoice PDFs/ scans with per-field
confidence scores — built as a portfolio project for evaluated extraction.

![Demo: PDF in, JSON out](docs/demo.gif)

[![CI](https://github.com/maya-osei/invoice-parser/actions/workflows/ci.yml/badge.svg)](https://github.com/maya-osei/invoice-parser/actions/workflows/ci.yml)

## Why this exists

I needed to know whether a small, cheap hosted model could replace a paid
OCR+LLM pipeline for invoices. Short answer: yes for clean scans, no for handwriting —
the eval table below shows exactly where it breaks.

## Quickstart

~~~bash
git clone https://github.com/maya-osei/invoice-parser.git
cd invoice-parser
uv sync
uv run python -m invoice_parser demo.pdf   # bundled sample + recorded model output, no key needed
~~~

## Architecture

~~~mermaid
flowchart LR
    A["PDF / image"] --> B["Parse + OCR"]
    B --> C["LLM extraction<br/>(schema-constrained)"]
    C --> D["Validate + confidence"]
    D --> E["JSON output"]
~~~

## Evaluation (2026-10-28, gemini-3.8-flash)

| Split | n | Field accuracy | Notes |
|---|---|---|---|
| Clean digital PDFs | 60 | 0.94 | near-perfect |
| Scanned, good quality | 40 | 0.81 | OCR errors dominate |
| Handwritten | 20 | 0.52 | below usable threshold |

Full method and per-field breakdown: `docs/eval-report.md`.
Golden set: 120 invoices I generated/labelled myself — see
`docs/dataset.md` for provenance and licence.

## Limitations

- English invoices only; multi-column layouts degrade accuracy
- Confidence is self-reported by the model — calibrated on 30 held-out
  cases, not guaranteed (see eval report §4)
- Costs ~$0.0011/page at flash pricing (Nov 2026)

## Project structure
...

## Testing
`uv run pytest` — 48 tests; CI runs them plus an eval smoke test
against a scripted fake model (no key needed).

## Licence
MIT — see LICENSE.

What changed: a stranger can run it keylessly, see measured limits, and check the claims. Every number has a date, a model and a method.

Example C — the --help dump. Project: logpeek, a student's log-inspection CLI.

markdown
# logpeek

A command-line tool for inspecting log files.

## Installation

pip install logpeek

## Usage

logpeek --help

usage: logpeek [-h] [--tail TAIL] [--grep GREP] [--since SINCE]
               [--json] path

positional arguments:
  path                  log file to read

options:
  -h, --help            show this help message and exit
  --tail TAIL           only the last TAIL lines (default: 100)
  --grep GREP           keep lines matching PATTERN (regex)
  --since SINCE         drop lines older than SINCE (ISO date)
  --json                emit JSONL instead of plain text

That is the whole tool. See `--help` for details.

Problems: the --help dump is the documentation — it lists flags but never says what the tool is for, when you'd reach for it, or what it can't do. No real example, no expected output, no licence, and "see --help" asks the reader to do the author's job. Ten seconds later the tab is closed.

Example D — the rewrite.

markdown
# logpeek

Inspect log files from the shell: tail, regex-filter and date-cut
in one command, with JSONL out — a portfolio CLI in Python.

[![CI](https://github.com/maya-osei/logpeek/actions/workflows/ci.yml/badge.svg)](https://github.com/maya-osei/logpeek/actions/workflows/ci.yml)
[![Licence: MIT](https://img.shields.io/badge/licence-MIT-blue)](LICENSE)

## Why this exists

`tail -f app.log | grep ERROR` covers the common case, but real
inspection chains three or four tools. logpeek does the pipeline —
last N lines, regex keep, ISO-date cutoff, JSONL out — with sane
defaults and one file argument. Scope is deliberately narrow; see
Limitations before you expect more.

## Quickstart

~~~bash
git clone https://github.com/maya-osei/logpeek.git
cd logpeek
uv sync
uv tool install .          # puts `logpeek` on your PATH
logpeek --tail 20 app.log
~~~

**No install?** `uv run logpeek --tail 20 app.log` works from the
repo root. Requires Python 3.11+.

**Expected output:**

~~~text
[2026-10-31 09:14:02] INFO  worker-3 picked job 4812
[2026-10-31 09:14:07] ERROR worker-3 retry 2/3 on job 4812
... (18 more lines)
~~~

## Examples

~~~bash
logpeek --tail 50 app.log                    # last 50 lines
logpeek --grep 'ERROR|WARN' --tail 200 app.log
logpeek --since 2026-10-01 --json app.log    # JSONL, one event per line
cat app.log | logpeek --grep 'timeout' -     # stdin
~~~

## Options

| Flag | Default | Meaning |
|---|---|---|
| `path` (or `-`) | required | log file; `-` reads stdin |
| `--tail N` | `100` | last N lines |
| `--grep PAT` | — | keep lines matching regex PAT |
| `--since DATE` | — | drop lines before ISO date |
| `--json` | off | JSONL output |

Exit codes: `0` ok, `2` bad usage, `1` file/read error.

## Limitations

- Line-oriented text logs only — no multi-line stack traces, no binary
- `--since` filters on the leading timestamp; lines without one are kept
- One file per run; no `--follow`/tailing yet (see Roadmap)

## Project structure

~~~text
logpeek/
├── src/logpeek/      # argparse CLI + filter pipeline
├── tests/            # pytest over synthetic log fixtures
└── pyproject.toml    # uv-build backend, `logpeek` console script
~~~

## Testing

~~~bash
uv run pytest     # 61 tests; CI runs them on Python 3.11-3.13
~~~

Covers filter composition, flag parsing and malformed input. No model
calls, so the suite is fully deterministic — no fakes needed.

## Roadmap

- `--follow` mode for live tailing
- Multi-line record grouping (stack traces)

## Licence

MIT — see LICENSE.

What changed: the pitch says what it's for before the flags appear; the quickstart produces visible output in four commands; an Options table replaces the raw --help dump and adds exit codes the help text never mentioned; limitations name the real edges (stdin, timestamps, single file). Notice what it doesn't have: no evaluation table, no cost section, no system card — a pure-Python CLI has no model to evaluate, and deleting inapplicable sections is the rule from 2.7, not a failure.

Example E — the abandoned-looking library. Project: tokbudget, a small text-chunking library.

markdown
# tokbudget

Split long text into pieces that fit a token budget. Pure Python,
no tokenizer dependency.

## Install

pip install tokbudget

## Usage

~~~python
from tokbudget import pack

chunks = pack(my_long_text, budget=2000)
print(len(chunks))
~~~

## API

- `pack(text, budget)` → `list[str]`
- `estimate_tokens(text)` → `int` (chars ÷ 4 heuristic)

Latest release: v0.4.1 (March 2023). Python 3.8+.

Read the README alone and it's... fine. That's the trap. Around it the repo signals abandonment: no LICENSE file (so all rights reserved — ironic for a library), dependencies unpinned, no CI, five issues unanswered since 2024, a pinned "TODO: rewrite this README" commit from 2023, and no CONTRIBUTING.md, SECURITY.md or issue templates. A reviewer asking "is this maintained?" gets the answer before they finish the README — and pip install tokbudget may not even resolve.

Example F — the rewrite.

markdown
# tokbudget

Split long text into chunks that fit a token budget — pure
Python, ~200 lines, no tokenizer dependency.

[![CI](https://github.com/maya-osei/tokbudget/actions/workflows/ci.yml/badge.svg)](https://github.com/maya-osei/tokbudget/actions/workflows/ci.yml)
[![Licence: MIT](https://img.shields.io/badge/licence-MIT-blue)](LICENSE)
[![Python 3.11+](https://img.shields.io/badge/python-3.11%2B-blue)]

> **Maintenance status:** sporadic — fixes ship when they matter.
> Release cadence and known gaps: [CHANGELOG.md](CHANGELOG.md).
> Issues are read; see [CONTRIBUTING.md](CONTRIBUTING.md) before a PR.

## Why this exists

Provider tokenizers are accurate but heavy; a `tiktoken`-class
dependency doesn't belong in every pipeline. tokbudget is the
deliberately simple option: a documented chars÷4 estimate plus a
greedy packer, for cases where an approximate budget is fine and
auditable.

## Quickstart

~~~bash
uv add tokbudget        # or: pip install tokbudget
~~~

~~~python
from tokbudget import pack, estimate_tokens

chunks = pack(long_text, budget=2000)
print(estimate_tokens(long_text), "->", len(chunks), "chunks")
~~~

## API

| Function | Returns | Notes |
|---|---|---|
| `pack(text, budget)` | `list[str]` | greedy word-boundary packing |
| `estimate_tokens(text)` | `int` | chars ÷ 4 heuristic — see Limitations |

## Limitations

- `estimate_tokens` is a heuristic, not a real token count — for
  exact budgets use your provider's tokenizer (`tiktoken`, etc.)
- No overlap or semantic-boundary awareness
- Budgets are per-chunk, not per-request

## Development

- Tests: `uv run pytest` — CI runs them on Python 3.11-3.13
- Contributing and security reports: [CONTRIBUTING.md](CONTRIBUTING.md),
  [SECURITY.md](SECURITY.md); issue forms in `.github/ISSUE_TEMPLATE/`
- Dependencies pinned in `uv.lock`; Dependabot enabled

## Licence

MIT — see [LICENSE](LICENSE).

What changed: the README gained an honest maintenance banner instead of looking abandoned, a real LICENSE (MIT, chosen deliberately per 4.3), a CI badge backed by an actual workflow, and pointers to CONTRIBUTING.md, SECURITY.md, templates and a changelog — all of which had to be created for the links to work. The prose tightened too: pitch, quickstart, API table, limitations. For a library, the repo's files are part of the README's argument — which is also why Part 7's broken-link check matters: the CHANGELOG.md link only convinces if the file exists.

Example G — the AI-brochure. Project: smart-notes, claims everything, proves nothing.

markdown
# SmartNotes AI

The future of note-taking, powered by cutting-edge LLMs!

## Features
- Revolutionary AI that understands your notes
- Blazing fast responses
- Enterprise-grade security
- Supports all languages

Contact us at founder@smartnotes-example.com for enterprise pricing.

Every sentence is unfalsifiable. No quickstart (does it even run?), no evals, "enterprise-grade security" on a repo with no tests, a real-looking contact for a fictional product. This is the README equivalent of a résumé that says "results-driven professional" — it commits to nothing checkable.

The pattern across all three: weak READMEs ask to be trusted; strong ones ask to be checked.

2.7 The full template: career_kit/readme_template.md#

Save this as career_kit/readme_template.md — it is the annotated skeleton from 2.2, with <placeholders> for you to fill. It is a template, not code; copy it into a project and replace every <...>.

markdown
# <project-name>

<One sentence: what it does and for whom. Lead with the capability, not the stack.>

<!-- Optional: a demo GIF or screenshot, then meaningful badges only -->
![Demo](docs/demo.gif)
[![CI](https://github.com/<you>/<repo>/actions/workflows/ci.yml/badge.svg)](https://github.com/<you>/<repo>/actions/workflows/ci.yml)
[![Licence: MIT](https://img.shields.io/badge/licence-MIT-blue)](LICENSE)

## Why this exists

<2-3 sentences: the problem, what you tried or compared, what you built and why.
Honest framing: portfolio project / learning build / real tool — say which.>

## Features

- <Capability, not implementation>
- <Capability>
- <Capability>

## Quickstart

<!-- Must work on a clean machine in under five minutes. Test it yourself. -->

~~~bash
git clone https://github.com/<you>/<repo>.git
cd <repo>
uv sync                     # or: pip install -e .
cp .env.example .env        # fill in keys — or skip, see "No key?" below
uv run python -m <package> "<example input>"
~~~

**No API key?** `<the keyless path: demo mode, bundled sample data, fake model>`

**Expected output:**

~~~text
<what the command prints, so the reader knows it worked>
~~~

## Usage

<The two or three commands or API calls people use after the quickstart, one
short example each. Link docs/ for the rest.>

## Architecture

~~~mermaid
flowchart LR
    A["<stage>"] --> B["<stage>"]
    B --> C["<stage>"]
~~~

## Design decisions

| Decision | Chose | Considered | Would change if |
|---|---|---|---|
| <e.g. retrieval strategy> | <choice> | <alternatives> | <new evidence> |

## Evaluation

| Dataset | n | Metric | Score | Date / model |
|---|---|---|---|---|
| <golden set name> | <size> | <metric> | <score ± interval> | <date>, <model> |

<One line on method + link to the full eval report. If no evals yet, say so honestly
and link your eval plan — an honest "not yet measured" beats a vague claim.>

## Limitations and failure modes

- <Known failure 1 — specific, not "it can make mistakes">
- <Known failure 2>
- <Scope limit: languages, domains, scale>

## Cost

<Rough cost per request and per month at a stated assumption, with pricing page + date.
"Not measured" is an acceptable honest answer for a learning project.>

## Security and privacy

<What data leaves the machine, what keys are needed, the main threat model and what
defends it. Link docs/security.md or Module 12 concepts if relevant.>

## Project structure

~~~text
├── src/<package>/     # <one-line description>
├── tests/             # <what's covered>
├── docs/              # <eval report, dataset card, decisions>
├── .env.example       # <all config variables, placeholder values only>
└── pyproject.toml     # <packaging metadata>
~~~

## Testing

~~~bash
uv run pytest
~~~

<What the tests cover; what they can't (non-determinism) and what you do instead.>

## Configuration

| Variable | Required | Purpose |
|---|---|---|
| `OPENAI_API_KEY` | for live calls | <provider key — see .env.example> |
| `<OTHER_VAR>` | no | <default and effect> |

## Roadmap

- <Next honest improvement>
- <Known gap you intend to close>

## Licence

MIT — see [LICENSE](LICENSE). <Or your chosen licence; see lesson 4.3.>

## Acknowledgements

<Built with / datasets / libraries / reviewers. Credit what you used.>

## Contact

Issues welcome: <link>. Otherwise find me via the links on my profile.

Two usage notes. First, delete sections that genuinely don't apply (a pure-Python CLI has no "cost" section) rather than leaving empty headers — but never delete Limitations; that's the section reviewers trust most. Second, the template is a ceiling, not a quota: a focused 120-line README beats a padded 400-line one. Part 7 lints for the essentials.


Part 3: Documenting an AI project#

3.1 Why an AI project README needs more#

A conventional app can be verified by running it: does the button work? An LLM app has extra dimensions a README must address, because the model is a moving, non-deterministic component:

  • It costs money per call — reviewers want the unit economics.
  • It changes without you changing code — which model, which version, pinned how?
  • Its quality is measured, not assumed — evals, not screenshots of happy paths.
  • Its inputs can attack it — prompt injection, PII in documents, unsafe outputs.
  • Its outputs can mislead — hallucination, stale knowledge, overconfident citations.
  • Its data has provenance questions — where did the corpus/eval set come from, under what licence?

The sections below map each of those to concrete documentation. The principle: every claim about model behaviour in your README should be traceable to a method a reviewer could re-run — an eval report, a system card, a pinned prompt version, a dataset card.

3.2 The system card#

A system card is a structured document describing what your AI system does, what it's for, what it was evaluated on, and what its known limits are. Model providers publish model and system cards for their models (the "model card" idea comes from Mitchell et al., "Model Cards for Model Reporting", 2019); for your application you write the app-level version. 12.9, §7.6 covers the responsible-AI framing and even ships a generator (llm_guard_kit/responsible.py renders a markdown card); the Module 13B capstone's shipping lesson (13B.6) ships an ai_product/system_card.py doing the same from a Pydantic model — see Module 13A. Either way, the content is the same:

  • Intended use — what the system is for, and as importantly, out-of-scope uses it must not be used for.
  • The model(s) and version(s) — provider, model ID, snapshot/date, and how they're pinned or swapped.
  • Data — what goes to the model, what stays local, retention, whether inputs/outputs are logged and where.
  • Evaluations — what you measured, on what data, with what results, and what you did not measure.
  • Known limitations — failure modes, bias notes, domains where it shouldn't be trusted.
  • Safeguards and human oversight — guardrails, approval gates, escalation paths, who can pull the plug.
  • Contact — how to report problems.

For a portfolio project the card can be one honest page in docs/system-card.md, linked from the README. It's a differentiator: very few junior portfolios document intended use and known limits as rigorously as a frontier lab does for its models — and it's exactly the artefact a responsible-AI-minded reviewer looks for.

3.3 Prompts and prompt versioning#

If your project contains prompts (it almost certainly does), document them as versioned artefacts, not string literals lost in code:

  • Where prompts live: a prompts/ directory with one file per prompt, named for the task (prompts/extract_invoice.v3.md), or your provider's prompt-management feature where relevant. 04.10 owns the full discipline — templates, metadata, aliases, diffs.
  • What to document per prompt: purpose, inputs/variables, the model it's tested on, version, and its eval result. A prompt change is a behaviour change; treat it like a code change (review, test, changelog).
  • In the README: one paragraph — "Prompts are versioned in prompts/; prompts/aliases.yaml pins which version serves production; eval results per version are in docs/evals/". A reviewer who wants to check prompt quality can then actually find it.
  • Few-shot examples and system prompts deserve the same treatment — they're the highest-leverage files in an LLM project and the most often undocumented.

3.4 Evaluation methodology and the golden set#

This is the section that separates an AI portfolio piece from a chatbot screenshot. Document:

  • The dataset: what it is (hand-labelled golden set? production logs? synthetic?), how big, how it was built, who labelled it, and its licence/provenance — "120 invoices I created and labelled myself" is clean; "scraped from the web" needs justification (10A.2, §2.6 covers dataset licences).
  • The metrics: what you measured and why — answer correctness, citation precision, extraction field accuracy, task success. Define them precisely enough to re-implement.
  • The method: model versions, decoding settings, number of runs (LLM evals are stochastic — say how many samples per case), how you scored (human, judge model, code).
  • The uncertainty: confidence intervals or at least "±" ranges; 10A.2, §5 explains why n=30 can't distinguish 90% from 75%.
  • The failures: link your failure analysis — the eval table plus "here are the 14 cases that failed and why" is the most credible thing in the repo.

If the eval set itself is shareable, publish it (or a sample) as evals/golden.jsonl with a dataset card — the same schema discipline 10A.2, Part 8 teaches for evalkit. A reviewer who can re-run your eval is a reviewer who believes your numbers.

3.5 Model and provider choices: document the seams#

Your README should make the provider abstraction visible:

  • Which models you use and why — "default gpt-6-luna for cost; claude-haiku-5-5 fallback; evals run on X". Name real model IDs as of your writing date, and say they age.
  • How to swap them — "all calls go through llm_client.py, a thin adapter over the provider SDKs; change MODEL in .env or config.yaml to switch". Show the seam; don't hide it.
  • What breaks on a swap — "prompts tuned for provider A may need rework on B; the eval suite is the check". This sentence proves you understand model churn (02.9 covers the landscape; 03.11 the abstraction pattern).
  • Recorded outputs — where outputs are captured for tests or demos, label them: "outputs in tests/cassettes/ were recorded on 2026-10-15 with gpt-6-luna; they are fixtures, not live calls". Honesty about what's recorded vs live is a trust signal.

3.6 Reproducibility notes#

AI outputs are non-deterministic by nature (02.5 explains sampling; 02.1, §7.5 the determinism question). Your README should say how you handled it:

  • Pinned versions: Python, dependencies (uv.lock committed), model IDs and snapshot dates, prompt versions. "Reproduce with uv sync --locked".
  • Seeds where applicable: where the stack supports seeding (local models, some samplers), document it; where it doesn't, say temperature/top-p settings used.
  • Recorded outputs labelled: fixtures and cassettes marked with date + model + settings, so nobody mistakes a recording for a live result.
  • Environment: OS-agnostic where possible; note platform-specific bits (API keys, GPU requirements for local models).
  • Run count: for evals, "3 runs per case, mean reported" — the honest answer to non-determinism is repetition, and saying so shows rigour.

3.7 Responsible use and known biases#

One honest paragraph — or a docs/responsible-use.md linked from the README — covering:

  • Intended users and misuse cases: who this is for, and the obvious ways it could be misused (a document-Q&A tool could be pointed at confidential docs; a classifier could be used to profile people).
  • Known biases/harms: what your evals showed about performance across groups/domains/languages, or "not evaluated for fairness — here's why and what I'd do". 12.9 owns the frameworks; the README needs the headline.
  • Data handling: what user data the system sees, whether it's sent to third parties, retention, how to delete.
  • Human oversight: where a human must review output (high-stakes fields, irreversible actions), matching whatever approval gates your project implements (13A.3 territory).
  • Reporting: how to flag a harmful output or privacy issue.

This section doesn't need to be long. Its presence signals you build AI systems the way the industry is expected to — and its absence is increasingly conspicuous.


Part 4: Repository hygiene checklist#

The difference between a repo that looks professional and one that looks like a homework dump is mostly files that should exist and shouldn't. Work through this checklist for every portfolio repo. Items marked ↗ are covered in depth elsewhere; this is the index, not the re-teaching.

4.1 The files every repository should have#

File Purpose Portfolio standard
README.md Front page Part 2 anatomy; lint it (Part 7)
.gitignore Keep junk out Python template + your own additions (.env, data/, *.db, .venv/, __pycache__/). 00.3, §4.1
.env.example Document config Every variable, placeholder values only
LICENSE Legal clarity Pick deliberately — 4.3
CHANGELOG.md What changed per release Keep a Changelog format — 4.5
CONTRIBUTING.md How to contribute Short version is fine — 4.4
SECURITY.md How to report vulns One paragraph + contact — 4.4
.github/ISSUE_TEMPLATE/, .github/PULL_REQUEST_TEMPLATE.md Structured reports Optional but cheap — 4.4
.github/workflows/ci.yml Prove it builds/tests Part 5
pyproject.toml Packaging metadata Pinned deps, project metadata — 01B.10, Part 4
docs/ Depth: evals, system card, decisions Linked from README — Part 3
AGENTS.md (optional) Instructions for AI coding agents: commands to run, conventions, what not to touch Short and true; also say in the README how AI tools were used (4.6, 08A.15 §3.3)

4.2 Secrets in history: check first, rotate first, rewrite carefully#

The order is always rotate → remove → assess → maybe clean history (00.4, §8.5 and 12.7, §3.5):

  1. Check: did a secret get committed? git log -p --all -S 'sk-' or GitHub's secret scanning alerts (free on public repos). readme_lint.py scans README files for secret shapes; 00.4, §8.6 has a local scanner for whole repos.
  2. Rotate immediately — assume the key is compromised the moment it's pushed to a public repo. Revoke/regenerate at the provider first; a dead key in history is harmless, a live one is an open door. For LLM provider keys specifically, 03.1, §3.7 is the hour-by-hour playbook.
  3. Remove going forward: untrack the file (git rm --cached .env — .gitignore alone doesn't untrack committed files), commit the removal.
  4. Assess exposure: public repo? how long? forked/cloned? Private repos that never left your machine are lower risk — still rotate.
  5. History rewrite is optional and disruptive: git filter-repo rewrites every commit SHA — anyone with a clone must re-clone, open PRs break, and it only helps after rotation (old commits persist in caches/forks). Most teams rotate and move on.

4.3 Choosing a licence#

A public repo without a licence is not open source — legally, nobody may reuse your code (GitHub's own docs say this plainly). For portfolio work, a licence signals professionalism; for anything you might want to keep proprietary, choose accordingly. Awareness, not legal advice:

Licence What it means Choose when
MIT Permissive: use, modify, sell, with attribution Default for portfolio/learning code; maximum reuse
Apache-2.0 MIT-like + explicit patent grant Similar to MIT; slightly heavier; common in industry
BSD (2/3-clause) Permissive like MIT Fine alternative; clause count differs in attribution requirements
GPL-3.0 Copyleft: derivatives must also be GPL You want derivatives to stay open; know it "infects" combined work
AGPL-3.0 GPL extended to network use Server-side copyleft; strong stance, rare for portfolios
Proprietary / no licence All rights reserved Portfolio pieces you might commercialise, or employers' code (never publish that anyway)

Practicalities: put the licence text in LICENSE at the root (use the SPDX canonical text — spdx.org lists them), name it in the README, and if you reuse other people's code, keep their copyright notices (00.4, §6.6). For Module packages with fake clients and teaching code, MIT is the conventional choice.

4.4 Governance files#

You don't need the full open-source apparatus on a learning repo, but the awareness is the point — 00.4, §6.1 has the file-by-file table. The portfolio-standard subset:

  • CONTRIBUTING.md — even "issues and small PRs welcome; see README quickstart; keep commits conventional" is enough. Its existence says "this is a real project, not a dump".
  • CODE_OF_CONDUCT.md — adopt the Contributor Covenant verbatim if you'll accept outside contributions; skip it on pure personal repos.
  • SECURITY.md — how to report vulnerabilities privately (enable private vulnerability reporting on public repos — verified feature). One paragraph: scope, contact, response expectation.
  • Issue/PR templates — .github/ISSUE_TEMPLATE/bug_report.md etc. with name:/about: frontmatter (the community-profile checklist requires valid frontmatter, verified). Cheap to add, makes you look like you run the project.
  • CODEOWNERS — optional for solo repos; maps paths to reviewers.

4.5 Releases, changelog and versioning#

When your project has users (even just future-you), mark stable points:

  • Semantic versioning (MAJOR.MINOR.PATCH): breaking / features / fixes — the social contract; state it in the README if you follow it (00.4, §6.3, spec at semver.org).
  • Annotated tags for releases: git tag -a v0.2.0 -m "..." && git push origin v0.2.0.
  • GitHub Releases — Draft a new release on the Releases page; auto-generate notes from merged PRs or write them; mark pre-releases; attach binaries if any (verified workflow as of November 2026). Immutable releases exist as an opt-in feature.
  • CHANGELOG.md — Keep a Changelog format is the de-facto standard; for AI projects, record behaviour-relevant changes too: "v0.3.0 — switched default model gpt-6-luna → gpt-6.1-terra, evals re-run". Model changes are releases in an LLM project.

For portfolio repos, one or two real releases ("v0.1.0 — first working version") demonstrate you version deliberately; you don't need continuous releases.

4.6 Commit history that reads well#

Reviewers do scroll git log. What they want to see: small, honest, descriptive commits — not "fix", "fix2", "asdf", or one giant "initial commit" containing the whole project.

  • Commit messages: imperative mood, say why where useful ("add abstention threshold to reduce unsupported answers"). 00.3, §3.6 covers the craft.
  • Squash vs preserve: merging a PR by squash gives main one clean commit per change; merge commits preserve the full branch history. For portfolio repos squash-merge your own feature branches — main reads like a changelog. (Merge strategies in 00.4, §4.6.)
  • Meaningful history for AI projects: commits that show iteration — "baseline eval 0.71", "fix retrieval filter, eval 0.78", "add abstention, eval 0.83" — are better than a single polished commit, because they show the engineering loop. Don't fake it, but don't squash your learning process away either.
  • Co-authorship: if AI tools helped, Co-authored-by trailers or a README note is honest; fabricated solo authorship of AI-written code is the misrepresentation Module 14B's rules warn against.

4.7 CI and branch protection#

  • CI on every push/PR: lint, type-check, tests — Part 5 builds the portfolio version. A green badge is the cheapest credibility signal in software.
  • Branch protection on main: require PRs (or at least require status checks), no force-push, no deletion — 00.4, §6.2 has the sensible set. Free on public repos.
  • PRs even for solo work: a PR per feature with a description forces you to write down what/why/how-tested — the same discipline a team needs. Reviewers see the PR history as evidence of process.

4.8 Security features to enable#

Recap of the verified-availability list from 1.7, as a checklist per public repo:

  • Dependency graph on (enables Dependabot alerts)
  • Dependabot alerts + security updates (version updates optional via dependabot.yml)
  • Secret scanning + push protection (free on public repos)
  • Private vulnerability reporting + SECURITY.md
  • Code scanning (recommended on serious repos)
  • .gitignore actually ignoring .env, keys, data dumps — verify with git status that no sensitive file is tracked
  • No secrets anywhere in history (check per 4.2)
  • Pinned GitHub Actions to commit SHAs or major versions, not floating @main (00.4, §7.4; deeper supply-chain thinking in 12.7, §5)

Part 5: GitHub Actions for portfolio repositories#

Deep-dive

5.1 What CI proves to a reviewer#

A README claims; CI demonstrates. For a portfolio repo, a green Actions badge says three things a reviewer cares about: the code is real (it compiles and tests pass on a clean machine, not just yours), you work like a team (CI is table stakes professionally), and you're not hiding failures (a public Actions history shows red runs too — and a history of fixing red runs is a plus, not a minus). 11C.2 owns CI/CD for LLM systems in depth — eval gates, tiered suites, model-change management. This part is the portfolio-sized subset.

5.2 The portfolio CI workflow#

A minimal but honest workflow for a uv-based Python project — lint, type-check, test — verified syntax as of November 2026 (on 11 November 2026 the latest releases were actions/checkout v7.0.1, which still publishes a floating v7 tag, and astral-sh/setup-uv v10.3.3, which publishes only full version tags, so a bare @v10 does not resolve; for supply-chain hardening pin both to commit SHAs per 00.4, §7.4):

yaml
# .github/workflows/ci.yml
name: ci

on:
  push:
    branches: [main]
  pull_request:

jobs:
  test:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v7
      - uses: astral-sh/setup-uv@v10.3.3
        with:
          enable-cache: true
      - run: uv sync --locked          # fails if lockfile is stale — good
      - run: uv run ruff check .       # lint  (swap for your linter)
      - run: uv run ruff format --check .
      - run: uv run mypy src/          # type-check (or pyright)
      - run: uv run pytest             # tests

Notes a reviewer will check:

  • Dev tools must be in the lockfile. ruff, mypy and pytest are not installed by magic: add them once with uv add --dev ruff mypy pytest so uv sync --locked installs them in CI. Swap in your own linter and type checker (for example pyright) if you prefer.
  • uv sync --locked proves your committed lockfile is reproducible — a detail juniors miss and seniors insist on.
  • Secrets: CI needs API keys only for live evals — don't put them there. Use fakes/cassettes for the smoke test (5.3); live evals belong in a scheduled workflow with secrets, if at all (11C.2, §4.2 covers the safe pattern).
  • The badge: after the first green run, add ![CI](https://github.com/<you>/<repo>/actions/workflows/ci.yml/badge.svg) to the README — or use Actions → workflow → "Create status badge" (verified path; badges on private repos don't render externally).
  • Keep it fast: under ~5 minutes. A 40-minute CI on a toy repo signals bad engineering, not rigour.

5.3 An eval smoke test that needs no API key#

The trap: your eval suite calls a real model → needs a key → can't run in CI for free/securely. The professional pattern (your Module 08A and 10A packages already embody it): a scripted fake that returns canned, schema-valid responses, so CI verifies the pipeline — retrieval, prompting, parsing, validation, metrics — deterministically, while the real evals run on demand.

yaml
# extra job in ci.yml — proves the eval harness end-to-end, keyless
  eval-smoke:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v7
      - uses: astral-sh/setup-uv@v10.3.3
      - run: uv sync --locked
      - run: uv run python scripts/eval_smoke.py   # uses the fake model; asserts schema + metrics shape

scripts/eval_smoke.py is project-specific, but the contract is universal: run N golden cases through the full pipeline against a ScriptedModel-style fake (Module 08A owns the pattern), assert outputs validate against your schema, and assert the metric report has the expected shape. It catches wiring bugs — a broken retriever, a malformed prompt template, a schema drift — without spending a cent or leaking a key. Say so in the README: "CI runs an eval smoke test against a fake; the real eval suite is uv run eval and needs a key".

5.4 Publishing docs with GitHub Pages#

When does a README stop being enough? When your project has real docs: eval reports, API references, tutorials, a system card that grew legs. Options, in order of effort:

  1. README + docs/ folder of Markdown — zero tooling, GitHub renders it, links work. Right answer for most portfolio projects.
  2. GitHub Pages site — hosts a static site from your repo. Verified availability (as of November 2026): free for public repos on the Free plan; private-repo Pages needs Pro; and critically, a Pages site is publicly accessible on the internet even if the repo is private — don't publish sensitive docs. Deployment is now Actions-based; entry file index.html, index.md or README.md. Typical URL: https://<user>.github.io/<repo>/.
  3. A docs generator — MkDocs (with Material theme), Sphinx, Docusaurus and similar turn docs/ Markdown into a navigable site with search (awareness only; all are real, widely used tools — pick one, don't install five). This is the right move when docs/ exceeds ~10 pages.

The decision rule: README is the front page; docs/ is the back office; Pages is the front office you build when strangers actually visit. For a portfolio, a linked docs/ folder covers 90% of cases — a Pages site is a nice-to-have that also gives you a URL to put on your résumé.

5.5 Dependency update bots#

  • Dependabot (built into GitHub, verified): alerts on vulnerable deps, security-update PRs, and version-update PRs via .github/dependabot.yml. Free on all plans. For uv projects it reads pyproject.toml/uv.lock (00.4, §8.2).
  • Renovate (awareness): the more configurable open-source alternative — smarter grouping, monorepo support, automerge rules. Worth knowing by name; Dependabot is enough for portfolio repos.

Review bot PRs like human PRs: read the changelog, check CI, don't rubber-stamp majors. A dependency bot that opens 30 PRs you ignore is worse than none — configure weekly cadence and grouping if you enable version updates.

5.6 The badge wall, done honestly#

Recap from 2.5: CI status, licence, maybe Python version, maybe a methodology-linked eval score. Everything else is decoration. If you want coverage badges, make them true: "tests pass on 3.11–3.13" only if CI actually runs those versions (matrix builds are one strategy: block away — worth it once, it demonstrates rigour).


Part 6: Beyond the README#

Reference

6.1 When a README is enough — and when you need a docs site#

Situation Right artefact
Portfolio project, < ~10 pages of docs README + docs/ folder
Multi-package project or real users Docs site (MkDocs/Sphinx/Docusaurus-class) on Pages
Library others will pip install README (PyPI renders it) + docs site for depth
Long-form thinking Blog post (that's 14B.4's job)
API reference Auto-generated from docstrings/type hints where possible

The meta-rule: documentation is part of the product, and its quality is evidence of yours. A stale docs site is worse than none — whatever you publish, date it or keep it current.

6.2 Notebooks as portfolio pieces#

Jupyter notebooks (.ipynb) render natively on GitHub with outputs — instant visual artefacts. Honest assessment for a portfolio:

  • Pros: narrative + code + output in one scrollable artefact; great for exploration write-ups, data analysis, "how I built the eval set" posts; zero build tooling.
  • Cons: easy to produce un-reproducible slop (outputs baked in, hidden state, execution order matters); reviewers can't tell live output from stale screenshots unless you say so; not a substitute for a tested package.
  • If you use them: state the kernel/env at the top, run top-to-bottom before committing, commit with outputs (that's the point on GitHub), label recorded vs live outputs, and link the reproducible package/script for anything a reviewer might want to re-run. A notebook is a story; the repo is the evidence.

6.3 Packaging and distribution as a signal#

An installable package says "this is real software" louder than any badge:

  • pyproject.toml done properly: project metadata (name, version, description, licence, authors), pinned-or-bounded dependencies, console-script entry points for CLIs, [build-system] with uv_build/hatchling/setuptools. 01B.10, Part 4 teaches the full packaging flow (uv build, uv publish, PyPI vs private indexes).
  • Version it: version = "0.1.0" in pyproject, matching your git tags — one source of truth.
  • PyPI vs private: publishing to PyPI is optional; a clean uv pip install git+https://... or uv sync path in the README is enough for reviewers. If you do publish, TestPyPI first, and prefer trusted publishing (OIDC via GitHub Actions — no API tokens in CI) as 01B.10 notes.
  • Docker awareness: a Dockerfile is a nice signal for deployable services (11C.1 owns deployment); for learning repos, "runs via uv" is sufficient — don't containerise for its own sake.

6.4 Community presence: issues, discussions and maintenance honesty#

GitHub is a community surface, not just a portfolio wall:

  • Issues: enable them (default). Label a few (bug, documentation, good first issue). Respond to issues on your repos promptly and kindly — how you treat a stranger's bug report is itself portfolio evidence.
  • Discussions: an alternative/complement for open-ended questions (verified: enable via repo Settings → Features → Discussions; works on public and private repos). Enable it when your project attracts usage questions that aren't bugs; skip it on repos nobody visits — an empty Discussions tab looks worse than none.
  • good first issue labels: on repos you maintain, labelling approachable issues invites contributors — a real open-source behaviour, and a talking point ("I triaged my own repo's issues") in interviews.
  • Being a contributor: PRs to other projects — docs fixes, tests, small features — are portfolio gold if they're genuine (14B.2 covers contribution strategy; etiquette is in 00.4, Part 4). Check each project's AI-contribution policy before using AI tools on a PR.
  • Maintaining vs archiving: projects die; that's normal. When you stop maintaining, say so honestly: a pinned "⚠️ Unmaintained — see docs/maintenance.md" notice or archive the repo (archived repos are read-only — a clear signal, not a shameful one). A silently rotting repo with broken quickstart is the worst outcome; an honestly archived one with a final-state README is professional.

Part 7: career_kit/readme_lint.py#

Deep-dive

7.1 What the linter checks#

readme_lint.py is a standard-library script that lints one README.md for the things a reviewer notices in the first minute — the same checklist this lesson teaches:

  • Required structure: an h1 title, a quickstart-style heading with a shell code fence under it, and a licence mention.
  • Recommended sections (warning if absent): why/usage, limitations, testing, licence file reference.
  • Broken relative links and images — resolved against the README's directory, so docs/demo.png must exist. Badge-wrapped links — an image nested inside a link, the usual licence-badge pattern pointing at LICENSE — are checked at their outer target, not just the badge image.
  • Fenced code is ignored for prose checks — # comments, example links and fake headings inside code blocks can't create phantom findings or satisfy section checks. Secrets are the deliberate exception: they're scanned in the raw text too, because a key inside a snippet is still a key.
  • Image alt text — every image needs descriptive alt text in its ![alt text] part.
  • Badge count — informational: zero badges is fine for a learning repo; a wall of 15+ is flagged.
  • Length heuristics — under ~30 lines is thin; over ~500 lines probably belongs in docs/.
  • Secret-looking strings — credential-shaped patterns (sk-…, ghp_…, AKIA…, private-key blocks, api_key = "…") reported by line number. The match itself is never printed — a scanner that echoes secrets into your terminal is itself a leak (same rule as 00.4, §8.6).

It is a heuristic linter, not a spec: it catches the mechanical failures; judgement (is the quickstart actually good?) stays yours. Fence tracking is a line-based approximation of CommonMark — exotic nesting may still confuse it.

7.2 The complete file#

Save as career_kit/readme_lint.py (the package folder was created in Setup; add career_kit/__init__.py if it doesn't exist yet). Python 3.11+, standard library only:

python
# career_kit/readme_lint.py — lint a README.md for portfolio hygiene.
# Stdlib only. Usage: python3 career_kit/readme_lint.py README.md [--strict]
# Exit status: 1 if any ERROR finding (or any finding with --strict), else 0.

from __future__ import annotations

import argparse
import re
import sys
from dataclasses import dataclass
from pathlib import Path

SEVERITY_RANK = {"error": 0, "warning": 1, "info": 2}


@dataclass
class Finding:
    severity: str  # "error" | "warning" | "info"
    line: int      # 1-based; 0 means "whole file"
    message: str

    def render(self) -> str:
        where = f"line {self.line:>4}" if self.line else "     -"
        return f"{self.severity.upper():7} {where}  {self.message}"


# --- secret shapes ---------------------------------------------------------
# Each pattern matches a credential *shape*. The matched text is never printed;
# obvious placeholders (sk-..., your-key-here, <...>) are ignored.

SECRET_PATTERNS = [
    ("OpenAI-style API key", re.compile(r"\bsk-(?:proj-|svcacct-)?[A-Za-z0-9_-]{20,}")),
    ("GitHub token", re.compile(r"\b(?:ghp|gho|ghu|ghs|ghr)_[A-Za-z0-9]{20,}")),
    ("GitHub fine-grained PAT", re.compile(r"\bgithub_pat_[A-Za-z0-9_]{20,}")),
    ("AWS access key id", re.compile(r"\bAKIA[0-9A-Z]{16}\b")),
    ("Google API key", re.compile(r"\bAIza[0-9A-Za-z_-]{30,}")),
    ("Slack token", re.compile(r"\bxox[baprs]-[A-Za-z0-9-]{10,}")),
    ("Private key block", re.compile(r"-----BEGIN [A-Z0-9 ]*PRIVATE KEY-----")),
    ("Generic credential assignment",
     re.compile(r"(?i)\b(?:api[_-]?key|secret|token|password)\s*[:=]\s*['\"][^'\"\s]{8,}['\"]")),
]

PLACEHOLDER_RE = re.compile(
    r"(?i)(your|example|sample|placeholder|changeme|redacted|xxx|\.\.\.|<|\{|\$|\[)"
)


def looks_like_placeholder(text: str) -> bool:
    return bool(PLACEHOLDER_RE.search(text))


def _prose_lines(lines: list[str]) -> list[str]:
    """Return *lines* with fenced-code contents blanked (marker lines kept).

    Headings, links, images and badges are scanned on the result so `#`
    comments, example URLs and fake headings inside code blocks can't
    create phantom findings. Secret scanning deliberately still uses the
    raw text — a credential inside a code block is still a credential.
    """
    out = list(lines)
    in_fence = False
    fence_char, fence_len = "`", 3
    for i, line in enumerate(lines):
        if not in_fence:
            m = re.match(r"^ {0,3}(`{3,}|~{3,})", line)
            if m:
                in_fence = True
                fence_char = m.group(1)[0]
                fence_len = len(m.group(1))
        elif re.match(r"^ {0,3}" + re.escape(fence_char)
                      + "{" + str(fence_len) + ",}[ \t]*$", line):
            in_fence = False
        else:
            out[i] = ""
    return out


def _blank_match(m: re.Match[str]) -> str:
    """Blank a regex match to spaces, preserving newlines so offsets hold."""
    return "".join("\n" if c == "\n" else " " for c in m.group(0))


# --- markdown helpers ------------------------------------------------------

LINK_RE = re.compile(r"!?\[[^\]]*\]\(\s*([^\s)]+)(?:\s+\"[^\"]*\")?\s*\)")
IMAGE_RE = re.compile(r"!\[([^\]]*)\]\(\s*([^\s)]+)")
HEADING_RE = re.compile(r"^(#{1,6})\s+(.+?)\s*$", re.M)
FENCE_RE = re.compile(r"^(?:`{3,}|~{3,})(\w*)", re.M)

QUICKSTART_RE = re.compile(r"quick\s?start|getting started|installation|setup", re.I)
SHELL_FENCE_RE = re.compile(r"^(bash|sh|shell|console|zsh)$", re.I)

RECOMMENDED_SECTIONS = [
    ("usage/how it works", re.compile(r"usage|how it works|what it does", re.I)),
    ("limitations/failure modes", re.compile(r"limitation|known issues|failure", re.I)),
    ("testing", re.compile(r"test|ci\b", re.I)),
    ("licence", re.compile(r"licen[cs]e", re.I)),
]

BADGE_RES = [
    re.compile(r"img\.shields\.io"),
    re.compile(r"badge\.svg"),
    re.compile(r"travis-ci|circleci\.com|codecov\.io", re.I),
]


def lint(path: Path) -> list[Finding]:
    findings: list[Finding] = []
    text = path.read_text(encoding="utf-8", errors="replace")
    raw_lines = text.splitlines()
    lines = _prose_lines(raw_lines)
    prose = "\n".join(lines)

    # --- secrets (never print the match) ----------------------------------
    # Raw text on purpose: a credential inside a code block is still a
    # credential — this is the one check with no blind spots.
    for i, line in enumerate(raw_lines, 1):
        for name, pattern in SECRET_PATTERNS:
            m = pattern.search(line)
            if m and not looks_like_placeholder(m.group(0)):
                findings.append(Finding(
                    "error", i,
                    f"possible {name} — if real, rotate it now, then remove it",
                ))
                break

    # --- structure ----------------------------------------------------------
    headings = [(len(m.group(1)), m.group(2), prose[: m.start()].count("\n") + 1)
                for m in HEADING_RE.finditer(prose)]
    h1s = [h for h in headings if h[0] == 1]
    if not h1s:
        findings.append(Finding("warning", 0, "no level-1 title (`# name`)"))

    # quickstart heading + a shell fence within the next 60 lines
    qs = next((h for h in headings if QUICKSTART_RE.search(h[1])), None)
    if qs is None:
        findings.append(Finding(
            "warning", 0,
            "no quickstart-style heading (quickstart / getting started / setup)"))
    else:
        window = "\n".join(lines[qs[2]: qs[2] + 60])
        fences = FENCE_RE.findall(window)
        if not any(SHELL_FENCE_RE.match(f) for f in fences):
            findings.append(Finding(
                "warning", qs[2],
                f"'{qs[1]}' has no bash/sh/console code fence — "
                "the quickstart must be copy-pasteable"))

    # recommended sections (search all headings)
    heading_text = "\n".join(h[1] for h in headings)
    for label, rx in RECOMMENDED_SECTIONS:
        if not rx.search(heading_text):
            findings.append(Finding("warning", 0, f"no section about {label}"))

    # licence: a heading OR the word "licence"/"license" anywhere near the end
    if not re.search(r"licen[cs]e", prose, re.I):
        findings.append(Finding("info", 0, "no licence mentioned anywhere"))

    # --- links and images ---------------------------------------------------
    # Images are blanked before the link pass so badge-wrapped links
    # [![alt](img)](target) resolve to their OUTER target — LINK_RE alone
    # would only ever see the inner image URL.
    link_text = IMAGE_RE.sub(_blank_match, prose)
    for m in LINK_RE.finditer(link_text):
        if link_text[m.start()] == "!":
            continue  # images are checked separately below
        target = m.group(1).split("#", 1)[0]
        if not target or target.startswith(("http://", "https://", "mailto:", "#")):
            continue
        if target.startswith("<") or target.endswith(">"):  # autolink-ish
            continue
        resolved = (path.parent / target).resolve()
        if not resolved.exists():
            line_no = link_text[: m.start()].count("\n") + 1
            findings.append(Finding(
                "warning", line_no, f"broken relative link: {target}"))

    for m in IMAGE_RE.finditer(prose):
        alt, target = m.group(1).strip(), m.group(2).split("#", 1)[0]
        line_no = prose[: m.start()].count("\n") + 1
        if not alt:
            findings.append(Finding("info", line_no, "image with empty alt text"))
        if not target.startswith(("http://", "https://")):
            resolved = (path.parent / target).resolve()
            if not resolved.exists():
                findings.append(Finding(
                    "warning", line_no, f"missing image file: {target}"))

    # --- badges ---------------------------------------------------------------
    badge_count = sum(len(rx.findall(prose)) for rx in BADGE_RES)
    if badge_count == 0:
        findings.append(Finding("info", 0, "no badges found (fine, but a CI badge helps)"))
    elif badge_count > 12:
        findings.append(Finding("info", 0,
                                f"{badge_count} badges — a badge wall is noise; keep the meaningful ones"))

    # --- length ----------------------------------------------------------------
    n = len(raw_lines)
    if n < 30:
        findings.append(Finding("warning", 0,
                                f"only {n} lines — too thin for a portfolio README"))
    elif n > 500:
        findings.append(Finding("warning", 0,
                                f"{n} lines — consider moving detail into docs/"))

    # --- TODO density ------------------------------------------------------------
    todos = sum(1 for l in raw_lines if re.search(r"\b(TODO|FIXME|XXX)\b", l))
    if todos > 3:
        findings.append(Finding("info", 0, f"{todos} TODO/FIXME markers"))

    findings.sort(key=lambda f: (SEVERITY_RANK[f.severity], f.line))
    return findings


def main(argv: list[str] | None = None) -> int:
    ap = argparse.ArgumentParser(description="Lint a README.md for portfolio hygiene.")
    ap.add_argument("readme", type=Path, help="path to README.md")
    ap.add_argument("--strict", action="store_true",
                    help="treat warnings as failures too")
    args = ap.parse_args(argv)

    if not args.readme.is_file():
        print(f"error: {args.readme} is not a file", file=sys.stderr)
        return 2

    findings = lint(args.readme)
    for f in findings:
        print(f.render())

    counts = {s: sum(1 for f in findings if f.severity == s)
              for s in ("error", "warning", "info")}
    print(f"\n{args.readme.name}: {counts['error']} errors, "
          f"{counts['warning']} warnings, {counts['info']} info")

    failed = counts["error"] > 0 or (args.strict and counts["warning"] > 0)
    return 1 if failed else 0


if __name__ == "__main__":
    sys.exit(main())

Run it on any README: python3 career_kit/readme_lint.py README.md. --strict also fails on warnings, for use in CI if you want the linter as a gate.

7.3 Real output on a fixture#

To see every finding type, lint a deliberately flawed README. Save this script as make_readme_fixture.py in your project folder (not inside career_kit) and run it; it writes an 18-line fixture/README.md with an h1 and a ## Usage section whose bash fence contains a # comment and a fake link (both should be ignored, because fenced code is not prose), two broken relative links in one prose line, a badge-wrapped link to a missing LICENSE, an image with empty alt text, and a planted key. The key is built at run time from a repeating pattern, so no key-shaped text sits in this lesson:

python
"""make_readme_fixture.py: write an 18-line, deliberately flawed README."""
from pathlib import Path

key = "sk-" + "abcd1234efgh5678" * 2          # built at run time, obviously fake
lines = [
    "# demo-rag",                                                         # 1
    "",                                                                   # 2
    "Answers questions about a small handbook.",                          # 3
    "",                                                                   # 4
    "## Usage",                                                           # 5
    "",                                                                   # 6
    "```bash",                                                            # 7
    "# a comment inside a fence is not a heading",                        # 8
    "python -m demo 'leave policy?'   # see [guide](" + "gone.md)",        # 9: a fake link
    "```",                                                                # 10
    "",                                                                   # 11
    "Results: [eval report](evals/report.md), [diagram](docs/architecture.png).",  # 12
    "",                                                                   # 13
    "[![Licence: MIT](https://img.shields.io/badge/licence-MIT-blue)](LICENSE)",   # 14
    "",                                                                   # 15
    "![](assets/banner.png)",                                             # 16
    "",                                                                   # 17
    f"Demo key: {key}",                                                   # 18
]
Path("fixture").mkdir(exist_ok=True)
Path("fixture/README.md").write_text("\n".join(lines) + "\n", encoding="utf-8")
print("wrote fixture/README.md with", len(lines), "lines")
bash
python3 make_readme_fixture.py
python3 career_kit/readme_lint.py fixture/README.md
echo $?

This output is real: it was produced by running exactly the files above on Python 3.14 (standard library only, no network; any 3.11+ prints the same):

text
$ python3 career_kit/readme_lint.py fixture/README.md
ERROR   line   18  possible OpenAI-style API key — if real, rotate it now, then remove it
WARNING      -  no quickstart-style heading (quickstart / getting started / setup)
WARNING      -  no section about limitations/failure modes
WARNING      -  no section about testing
WARNING      -  no section about licence
WARNING      -  only 18 lines — too thin for a portfolio README
WARNING line   12  broken relative link: evals/report.md
WARNING line   12  broken relative link: docs/architecture.png
WARNING line   14  broken relative link: LICENSE
WARNING line   16  missing image file: assets/banner.png
INFO    line   16  image with empty alt text

README.md: 1 errors, 9 warnings, 1 info
$ echo $?
1

Four things to notice. First, the secret finding names the type and the line but never the key — a scanner that echoes credentials is itself a leak. Second, the badge-wrapped licence link is checked at its outer target — LICENSE is flagged even though the badge image is a perfectly good https URL — while the link and # comment inside the bash fence produce nothing at all. Third, findings sort errors first, then by line; whole-file findings show - for the line. Fourth, exit status is 1 because an error exists — which is what makes --strict usable as a CI gate. If line 18's key were real, 4.2 applies: rotate first, scrub second.

7.4 The career_kit package so far#

career_kit grows one file per lesson in Modules 14A and 14B; this lesson adds two:

text
career_kit/
├── __init__.py                  # package marker
├── job_decoder.py               # 14B.1 — classify job-description lines
├── skills_matrix.py             # 14A.8 — competency matrix + gap scorer
├── portfolio_audit.py           # 14B.2 — repo hygiene audit
├── readme_lint.py               # 14B.3 — this lesson: README linter
└── readme_template.md           # 14B.3 — this lesson: the README template

(The consolidated listing of the whole package ships in 14B.9.)


Common misconceptions#

Misconception Reality
"A green contribution graph means I'm a productive engineer." It records qualifying actions (commits on default/gh-pages branches of standalone repos, PRs, issues, reviews, forks, new repos) — one typo-fix commit greens a day. It's a presence signal, not a productivity metric.
"Forks and stars prove my work is good." Stars are bookmarks with no notification or feed effect; forks mean "I want to modify". Neither measures quality — repo contents do.
"My commit email is private anyway, so my address is safe." Commit author emails are public metadata on every commit. Use GitHub's noreply address or enable "keep my email private" + "block command-line pushes that expose my email".
"A private profile hides everything." Private profiles can't receive Sponsors, past activity remains visible where it happened, and activity on public repos stays public on those repos. Use granular controls instead.
"The profile README is the most important GitHub feature." It's the top of your profile, but reviewers click through to pinned repos — the repo README is the audition. Profile README is the billboard; repo READMEs are the evidence.
"A README is just documentation; anyone can write one." The best READMEs are verification surfaces: runnable quickstarts, dated eval tables, named limitations. They let a stranger check your claims instead of trusting them.
"Mermaid diagrams don't work on GitHub." GitHub renders Mermaid diagrams in fenced mermaid code blocks in READMEs, issues, PRs, discussions and wikis (verified). Stick to stable diagram types and avoid theme hacks.
"JSON/markdown in a README proves the project works." Only runnable evidence proves it: a quickstart you tested in a clean clone, a CI badge on a real workflow, eval numbers with method and date.
"More badges and sections = more professional." Badge walls and padded READMEs read as noise. Every badge must trace to something checkable; every section must earn its place.
"If a secret got committed, deleting the file fixes it." It's in history forever. Rotate the credential first, then decide whether history rewriting is worth the disruption — 4.2.
"No LICENSE means it's free to use." The opposite: no licence means all rights reserved — nobody may legally reuse your code.
"AI projects don't need licences/docs because they're toys." Portfolio projects are judged as if real — evals, system cards, licences and honest limitations are what make a toy credible.
"CI needs API keys to test an LLM app." The professional pattern is fakes/cassettes for PR CI (deterministic, keyless) and live evals in scheduled/manual workflows with secrets.
"GitHub Pages is required for a docs site." docs/ folders of Markdown render fine on GitHub; Pages is for when you need a real site URL. Decide by audience, not fashion.
"An unmaintained repo should just be deleted." Archive it with an honest notice — deleted history helps nobody; an archived repo with a final-state README is professional.

Key takeaways#

  • Your profile is a landing page with engineering standards. Profile README (username/username repo, public, README.md at root), bio, avatar, pinned repos (up to six, ordered deliberately), status, email privacy and security settings — all verified GitHub features as of November 2026.
  • The contribution graph is a presence signal, not a productivity score. Know exactly what counts (commits need a linked email, standalone repo, default/gh-pages branch) and don't game it — honest sparse history beats performative green.
  • Stars bookmark, forks copy, watching notifies — none of them measure quality. Topics (≤20, lowercase-hyphen, ≤50 chars) and the About description are free discovery and signal.
  • The repo README is the audition. Pitch + visual + five-minute quickstart + architecture + trade-offs + dated eval table + honest limitations + cost/security notes + licence. Sections 4–10 of the anatomy are what reviewers remember.
  • Quickstarts are tested, not written. Clone to a scratch dir, follow your own README literally, ship the expected output. .env.example documents names; .env never ships.
  • AI projects need extra documentation: system card (intended use, models, data, evals, limits, safeguards), versioned prompts, eval methodology + golden-set provenance, model seams and swap instructions, reproducibility notes (pins, seeds, labelled recordings), responsible-use notes. Every claim traceable to a re-runnable method.
  • Hygiene is a checklist, not a vibe: .gitignore, .env.example, LICENSE (MIT default; SPDX text), governance files, changelog/releases, readable commit history (squash-merge your own branches), CI + branch protection, security features on (secret scanning, push protection, Dependabot, private vuln reporting — all free on public repos).
  • Secrets: rotate first, always. Deleting the file doesn't remove history; git filter-repo rewrites SHAs — rehearse in a scratch clone, never on your only copy.
  • CI proves, READMEs claim. A keyless eval smoke test with a fake model gives you a green badge without secrets; live evals belong in scheduled workflows (11C.2).
  • career_kit/readme_template.md is the skeleton; career_kit/readme_lint.py checks the mechanics. Lint your READMEs, fix errors first, and remember the linter catches shape, not quality.

Terms introduced in this lesson#

Term One-line definition
Profile README The README.md in a public repo named exactly your username, rendered at the top of your GitHub profile
Pinned repositories Up to six repos/gists you choose to feature on your profile; replace the "Popular repositories" section
Contribution graph The green calendar on your profile recording qualifying contributions (commits, PRs, issues, reviews, forks, new repos)
noreply email GitHub-provided commit email that attributes commits to you without exposing your real address
Push protection (for users) Personal setting blocking pushes containing recognised secrets to public repos; on by default
Private vulnerability reporting "Report a vulnerability" button on public repos for coordinated disclosure; pairs with SECURITY.md
Secret scanning GitHub's detector for credential shapes in repos; free on public repositories
Social preview image The PNG/JPG/GIF (<1 MB) shown when your repo link is shared on social platforms
Repository topics Up to 20 lowercase-hyphen labels (≤50 chars) classifying a repo for discovery
Community profile GitHub's checklist (README, LICENSE, CoC, CONTRIBUTING, templates) scoring a public repo's health
System card Structured doc of an AI system's intended use, models, data, evaluations, limits and safeguards
Golden set / eval dataset The labelled examples you measure your system against; its provenance and licence matter
Dataset card Documentation of a dataset's contents, method, licence and limitations
Recorded outputs / cassettes Captured model responses stored as test fixtures; must be labelled with date, model and settings
Prompt versioning Treating prompts as versioned artefacts (files, aliases, evals per version) rather than string literals
.env.example Committed template listing config variable names with placeholder values; .env itself is never committed
SPDX licence identifier Standard short licence names (MIT, Apache-2.0, GPL-3.0) used in metadata and licence files
Keep a Changelog The de-facto CHANGELOG.md format; for AI projects, model changes are releases too
Semantic versioning MAJOR.MINOR.PATCH versioning contract: breaking / features / fixes
Squash merge Collapsing a PR's commits into one on main; keeps history readable for portfolio repos
GitHub Pages Free static-site hosting from a repo (public repos on Free plan; site is public even if repo is private)
Eval smoke test A keyless CI check running the eval pipeline against a fake model to catch wiring bugs deterministically
Dependabot / Renovate Dependency update bots: alerts, security-update PRs and version-update PRs (Renovate is the configurable alternative)
Archived repository A read-only repo state; the honest way to mark a project unmaintained
readme_lint.py This lesson's stdlib README checker: structure, links, images, badges, length, secret shapes

All terms are also collected in the glossary.


Exercises#

Everything below needs only a text editor, python3, and one repo you own (create a scratch one with git init if needed).

  1. Profile audit. Open your GitHub profile in a private window. List what a reviewer sees in order (avatar → bio → README → pins → graph). Write the bio line and profile README you'd want them to see — under 60 lines, honest, specific.
  2. Pin review. For each of your pinned repos (or candidates), write one sentence: what it proves. If a pin has no sentence, it's a wasted slot. Re-order so your flagship is first.
  3. Contribution-graph truth. Find one commit of yours that does not appear on your contribution graph (check Settings → Emails for the cause, or the "why are my contributions missing" docs). Fix the email association and verify.
  4. README rewrite. Take the weakest README in your repos and rewrite it with career_kit/readme_template.md. Run python3 career_kit/readme_lint.py README.md before and after; paste both outputs in your notes.
  5. Five-minute test. Clone one of your repos into mktemp -d, follow your README literally with a timer. Record every stumble; fix the README (not your memory) for each.
  6. AI-docs pass. For one AI project, write docs/system-card.md (one page: intended use, models+versions, data, evals, limits, safeguards, contact) and a docs/eval-report.md stub with dataset/method/metric/date. Link both from the README.
  7. Hygiene sweep. Run through the 4.8 checklist on a public repo; enable what's missing. Then run the secret-history check from 4.2 step 1.
  8. CI smoke test. Add the 5.2 workflow to a repo with tests; push and confirm the badge appears green in the README.
  9. This week's action list. Do, in order: (a) profile README + bio + email-privacy settings; (b) pin your best repo and rewrite its README quickstart; (c) run readme_lint.py on every portfolio repo and fix errors; (d) enable secret scanning + Dependabot on each public repo; (e) write the system card for your flagship. That is one focused week — everything else in this lesson is refinement.

Check yourself#

  1. What are the exact conditions for your profile README to render?
  2. How many items can you pin, and what determines whether you can pin a repo you don't own?
  3. Name three things people wrongly believe the contribution graph measures, and one real condition a commit must meet to count.
  4. What's the difference between starring and watching a repository?
  5. Which GitHub settings keep your personal email out of public commit metadata?
  6. List the sections of an excellent project README in priority order — which three decide whether a reviewer keeps reading?
  7. Why must a quickstart be tested in a clean environment, and what does .env.example contain that .env must not?
  8. What does a system card document that a README alone doesn't?
  9. A secret was committed to a public repo yesterday. What's the correct first action, and why not just delete the file?
  10. When does a docs/ folder stop being enough and you need GitHub Pages?
  11. Why does an eval smoke test in CI use a fake model rather than a real one?
  12. Which free security features should every public portfolio repo enable?
  13. Your repo has no LICENSE. What does that legally mean for someone who wants to reuse your code?
  14. readme_lint.py reports possible OpenAI-style API key at line 21 — what does it print, and what must you do first if it's real?
  15. A project you stopped maintaining last year still looks alive. What's the honest way to mark it?

Further resources#


← 14B.2 — Portfolio Strategy: Choosing and Shaping Projects | Module 14B overview | 14B.4 — Writing and Learning in Public →

Esc
02.2Tokens and TokenizationHow LLMs Work · 21k wordsLesson
02.3EmbeddingsHow LLMs Work · 18k wordsLesson
07Retrieval-Augmented Generation (RAG)11 lessons · Everyone who will build LLM features that must answer from knowledge the model doesn't have in its weights: internal handbooks and help centres, contracts, ticket histories, product docs, or any corpus that changes faster than a training run. The module covers the full RAG stack — architecture, retrieval strategy, query understanding, grounded generation, citations, conversation, managed services, advanced patterns, evaluation, debugging and production operation — and shows where each major provider's managed retrieval and citation features fit (OpenAI, Anthropic, Google Gemini and OpenRouter). All code is Python.Overview
08E.1The Model Context Protocol (MCP)Protocols and Extensibility · 12k wordsLesson
↑ ↓ navigate↵ openesc close