Project 1 · Nodes and Edges by Hand
Difficulty: Beginner Time: 15–20 minutes Concepts: node, edge, direction, label specificity Maps to: Step 2 (Part 1 of the course) — the page that defines a node and a directed, labeled edge. The course-wide index links straight to it.
Throwaway repo, small data first. No script, no library, not even a text editor plugin — this one is a single JSON file you type by hand, small enough to read in full at a glance.
The scenario
You keep a running list of books you mean to read — nothing fancy, just titles you've jotted down somewhere. A friend asks who wrote the one at the top of your list, and you realize the list itself doesn't say. You know the answer, but only because it's in your head, not because anything you wrote down captures it.
This project asks you to fix that for exactly one book: write down, as a tiny graph, the one fact your list is missing.
Your task
- Create an empty file called
reading-list.jsonin a throwaway repo. - Pick one book from a reading list of your own — real or invented, doesn't matter — and write down, in plain English first, the fact you want the graph to hold. It should sound like something you'd say out loud: "[Book] was written by [Author]."
- Turn that sentence into JSON by hand: one node for the book, one node for the author, and one directed edge connecting them with a specific label — not
"related_to", something you could actually check against a copyright page. - Add a second book to the file as its own node, with no edge yet. Leave it that way on purpose — you haven't looked up who wrote it, and the graph should say exactly that, not guess.
- Do not write any code. If you find yourself reaching for a script to generate the JSON, stop — the point of this project is producing the graph with your own hands, one node and one edge at a time.
Done when
reading-list.jsonhas at least oneBooknode, oneAuthornode, and one directed edge from the book to the author.- The edge's label is specific enough that you could picture proving it wrong —
written_bypasses;related_toorconnected_todoesn't. - A second book sits in the file with no edge attached to it, and you can say in one sentence why that's not the same thing as "this book has no author."
- Nothing in the file was generated by a script, a template, or an AI tool asked to "just write the whole thing" — you typed every field yourself.
Reference solution
solutions/01-nodes-and-edges-by-hand.md — a worked example against an invented two-book reading list, with the full JSON and a walkthrough of why each field is shaped the way it is.