(smollerGraph)

Episodes

  1. Packaging a C++ library for CMake FetchContent

    smollerGraph as a library another CMake project fetches, with its tests, tools and docs kept to its own build, its headers in include/smollergraph, a query in one call, a consumer project built in CI, and a version to pin.

    15 min

  2. Active Directory attack paths in a graph database

    A made-up company's Active Directory as a graph, and Cypher that follows several relationship types at once, so smollerGraph finds the paths from an account to Domain Admins, the way BloodHound does, in the browser too.

    25 min

  3. Graph database in a browser

    smollerGraph's library compiled to WebAssembly with Emscripten, unchanged, so the explorer runs in a browser tab on a graph it builds from Wikidata's facts as the page opens, published with the API docs on GitHub Pages.

    23 min

  4. Architecture decision records for our graph database

    Architecture decision records for smollerGraph, from its first episode's adjacency to last time's docs, each with what forced the choice, what lost to it and what it costs, and how a team proposes, accepts and supersedes them.

    13 min

  5. API docs from comments we already wrote

    smollerGraph's API docs, made by Doxygen from the comments already in its headers, built in Docker as CI builds them, and published on GitHub Pages from the public repository.

    10 min

  6. A graph neural network on a graph database

    A small graph neural network for smollerGraph, a GraphSAGE in PyTorch that learns which species are threatened from their relatives, trained on the graph sg export writes, with its predictions loaded back for Cypher to ask about.

    21 min

  7. FastRP node embeddings in a graph database

    Node embeddings in smollerGraph with FastRP, as Neo4j's Graph Data Science library computes them, the most similar nodes by cosine, embeddings kept on disk, and a page that draws a node's nearest.

    22 min

  8. Dijkstra's algorithm in a graph database

    Weighted relationships and cheapest paths in smollerGraph, with Dijkstra's algorithm and a priority queue, then from both ends, Kùzu's WSHORTEST in Cypher, and weights on the page.

    28 min

  9. Shortest paths in a graph database

    Shortest paths in smollerGraph, with a breadth-first search that keeps each node's parent, then two of them that meet in the middle, shortestPath in Cypher as Neo4j writes it, and a path drawn on the page.

    34 min

  10. Reverse traversal and query planning

    Relationships followed both ways in smollerGraph, with labels and types as tokens to make room for a second chain, Cypher that points left, plans that start from a name, and a fair benchmark in Cypher.

    40 min

  11. Canvas vs SVG for drawing a Wikidata graph

    Mammals and birds from Wikidata in smollerGraph, with room in its records for real names and a label, and a page that draws what a query returns on a canvas, measured against SVG.

    42 min

  12. Property graph storage and WHERE in C++

    Properties for smollerGraph's nodes and relationships, in a chain of records on disk, loaded from facts, asked about with WHERE, and shown in the inspector.

    38 min

  13. Deploying a graph database to a VPS with Docker

    smollerGraph on a VPS, sent over SSH and run with Docker Compose, with Caddy serving the page in front of the database.

    9 min

  14. Writing a Cypher query parser and planner in C++

    A subset of Cypher for smollerGraph, from tokens to a parser, a plan and its rows, in sg query and in the UI.

    28 min

  15. B+ tree index in C++ to find a node by name

    An index on names for smollerGraph, a B+ tree in pages through the buffer pool, so opening a graph no longer reads each node.

    21 min

  16. Database buffer pool in C++ to keep pages in memory

    A buffer pool for smollerGraph, with frames, a page table, pins, dirty pages and the clock, and what it does to a million relationships.

    22 min

  17. Graph visualization in the browser with D3.js

    cpplint, clang-tidy and Abseil's Status for smollerGraph, then a UI, with sg serve answering HTTP and a page that draws the graph with D3, walks it a hop at a time, and shows each node's record on disk.

    49 min

  18. Graph database benchmark of Neo4j vs Kùzu

    A first benchmark on a million relationships, with the same two-hop question asked of smollerGraph, Neo4j and Kùzu.

    20 min

  19. Graph database in C++ with pages on disk

    The graph moves from memory into files of 4 KiB pages, with fixed-size records for nodes and relationships, so it outlives the program.

    29 min

  20. How graph databases like Neo4j and Kùzu work

    Before we build one in C++, why graphs, where the series is heading, and how Neo4j and Kùzu store a graph and run a query.

    33 min