Extension for Graphify
Make your knowledge graph time-aware — without any LLM cost
Enrich a Graphify knowledge graph with temporal metadata from filesystem timestamps. Adds file_mtime, file_birthtime, dir_mtime to nodes and deterministic preceded_by edges — pure filesystem, zero API calls.
What timestamps can you see?
Three distinct timestamps — one filesystem
graphify-temporal resolves three independent timestamps from the filesystem. They are often different, giving you a timeline: created → arrived in this directory → last modified.
file_mtime
defaultLast content modification time. The default timestamp applied to every node with a source_file. Can optionally use --use-ctime for inode metadata change (Unix) or creation time (Windows), or --use-birthtime for true creation time.
dir_mtime
--include-dir-mtimeParent directory modification time. The best proxy for "when did this file arrive here?" — set with a single flag.
file_birthtime
--use-birthtimeTrue creation time — when the file was born on disk. Supported on Linux kernel ≥ 4.11 (ext4/btrfs/xfs via statx), macOS ≥ 10.4, and Windows natively. When unavailable, falls back to None — never a crash.
$ graphify-temporal enrich
Enrichment is idempotent — run it anytime
After every graphify build, run graphify-temporal enrich. It reads the graph, stats the filesystem, adds timestamps and edges, then regenerates output. Re-run with different flags anytime — timestamps update in-place and edges are deduplicated.
$ pip install
One command to install
Requires Python ≥ 3.10 and an existing graphify-out/graph.json (run graphify . first).
$ pip install git+https://github.com/todotge/graphify-temporal.git
$ git clone https://github.com/todotge/graphify-temporal.git $ cd graphify-temporal $ pip install .
If graphify-temporal is not found after install, use python -m graphify_temporal instead — the binary lives in your venv's bin/ directory.
$ graphify-temporal enrich
Usage — the enrich subcommand
A separate CLI from graphify. The enrichment subcommand is graphify-temporal enrich, not graphify enrich. After every /graphify build, run graphify-temporal enrich — the graph is not complete without temporal stamps.
# Basic: add file_mtime to all nodes + intra-file preceded_by edges $ graphify-temporal enrich # Cross-file temporal edges + filter by date $ graphify-temporal enrich --cross-file --since 2026-05-01 # Use true creation time (birthtime) instead of modification time $ graphify-temporal enrich --use-birthtime # Full timeline: birthtime as primary + directory arrival time $ graphify-temporal enrich --use-birthtime --include-dir-mtime # All flags combined: birthtime + dir arrival + cross-file edges $ graphify-temporal enrich --use-birthtime --include-dir-mtime --cross-file # Preview on a subdirectory without modifying $ graphify-temporal enrich --include "your/archive/**" --dry-run
Switching timestamp modes: Enrichment is idempotent — re-run with different flags anytime. It updates file_mtime in-place and deduplicates edges, so you never get double edges or corrupted data. No need to rebuild the graph.
Options reference
Every flag, one table
| Flag | Description |
|---|---|
PATH | Project root (default .) |
--use-ctime | Use st_ctime instead of st_mtime (metadata-change on Unix, creation on Windows) |
--use-birthtime | Use st_birthtime (true creation time). Mutually exclusive with --use-ctime |
--include-dir-mtime | Also add dir_mtime (parent directory mtime) to nodes — arrival proxy |
--cross-file | Create preceded_by edges across different files |
--dry-run | Show stats without modifying graph.json |
--since DATE | Only process files modified after DATE (YYYY-MM-DD) |
--include GLOB | Only process files matching glob (repeatable) |
--exclude GLOB | Exclude files matching glob (repeatable) |
--no-regenerate | Skip regenerating HTML/wiki |
--quiet, -q | Minimal output |
$ graphify-temporal query & timeline
Filter and explore by time
Once enriched, query nodes by name, filter by date range, and walk chronological preceded_by chains. All time filters require explicit dates (YYYY-MM-DD).
# Find nodes by name (one per file) $ graphify-temporal query "auth" # Filter by date range $ graphify-temporal query "auth" --since 2026-05-01 --before 2026-06-01 --order newest-first # Walk the preceded_by chain $ graphify-temporal timeline # See temporal coverage stats $ graphify-temporal stats
Team setup
Auto-detects your AI coding assistant
graphify-temporal install detects which AI client you're using and injects instructions so your agent knows how to run temporal enrichment automatically. graphify-temporal uninstall removes them cleanly.