factcircuit
FactCircuit는 불변 출처와 단계별 검증, 제한된 검색, 재현 가능한 평가를 제공하는 감사 가능한 주장·증거 검증 루프입니다
두 GTFS 피드 버전을 비교해 노선·편성·시간·정류장 변화를 자동으로 파악
2世代の GTFS フィードを比較し、路線・便数・時刻・停留所の変化を自動で読み解きます。GTFSデータリポジトリの公開フィードにも対応。/ Compare two GTFS feed versions and see what changed — routes, trips, times, stops.
데이터HTML · PythonGitHub @niyalist온라인운영자 미확인
써 보셨어요? 한 번만 눌러 주세요. 로그인은 필요 없어요.
아직 감지된 업데이트가 없습니다. GitHub 릴리스가 나오면 여기에 보입니다.
개인 계정의 공개 저장소 소유자는 GitHub로 로그인해 운영자를 확인하고 소개를 직접 관리할 수 있습니다. 관리자 승인은 필요하지 않습니다.
로그인한 뒤 확인 파일을 만들어 이 저장소의 기본 브랜치에 30분 안에 커밋해 주세요. 다른 브랜치나 포크의 파일은 인정하지 않습니다. 파일을 올린 뒤 아래에서 확인하면 관리자 승인 없이 관리할 수 있습니다. 자격을 유지하려면 파일을 남겨 두세요.
로그인이 필요하면 로그인 화면으로 이동합니다. 로그인 후 이곳으로 돌아와 원하는 확인 버튼을 다시 눌러 주세요.
프로젝트 폴더에서 /nomorevibe verify를 실행하면 소유권을 확인하고 소개를 직접 관리할 수 있습니다.
1분 만에 확인하기Semantic diff for GTFS feeds — compares two versions and reports the changes as human-recognizable events (routes discontinued, service reduced, stops renamed) | 複数世代の GTFS フィードを比較し、ダイヤ改正を人間が認識できる意味的な変化として抽出・レポートする
저장소 README에서 가져옴
README 전체를 불러오는 중입니다. 아래는 저장된 발췌입니다.
gtfs-semantic-diff compares two versions of a GTFS feed and reports the
differences as human-recognizable, semantic changes — a route discontinued,
evening service cut, a stop renamed or relocated, departures shifted — instead
of thousands of changed rows. Every raw field-level difference is structurally
accounted for: it either becomes evidence for a change event or is reported as
an unexplained residual, and the coverage ratio is measured on every run.README 전문 보기 ↗日本語版: README.ja.md
gtfs-semantic-diff compares two versions of a GTFS feed and reports the differences as human-recognizable, semantic changes — a route discontinued, evening service cut, a stop renamed or relocated, departures shifted — instead of thousands of changed rows. Every raw field-level difference is structurally accounted for: it either becomes evidence for a change event or is reported as an unexplained residual, and the coverage ratio is measured on every run.
Try it: diff.gtfs.jp — upload any two GTFS zips, free, no sign-up. The site and reports are bilingual (English / Japanese, following your browser language).
explained_ratio, typically 1.0 on our verification feeds).stop_id / route_id / trip_id
are reassigned between versions, entities are re-identified from content —
names, coordinates, stop sequences, times. The resulting old↔new ID mapping
is itself an output (mapping.json), usable as a backbone for longitudinal
analysis across feed versions.config/default.toml. Same input, same output.The hosted service exposes every layer of a comparison result:
| Layer | URL pattern | Content |
|---|---|---|
| Digest | r/{pair}.digest.en.md (English) / .digest.md (Japanese) / .digest.json | Summary for LLMs and humans — numbers identical in both languages |
| Route detail | r/{pair}.routes.digest.json | Per-route changed trips (old/new trip_ids), counts by time band |
| ID mapping | r/{pair}.mapping.json | Adopted old↔new correspondences for stops / routes / trips |
| Full events | see r/{pair}/index.json | All 44 event types with evidence, plus raw diffs |
https://diff.gtfs.jp/mcp — register it as a connector in
Claude or ChatGPT (no auth) and query comparisons conversationally,
including running new comparisons.Python 3.11+ (developed on 3.14).
uv venv .venv.nosync --python 3.14 # .nosync needed if the repo is under iCloud sync (see note)
ln -s .venv.nosync .venv
uv pip install -e '.[dev]' --python .venv.nosync/bin/python
Note (macOS + iCloud): if the repository lives under an iCloud-synced directory (e.g.
~/Documents), a venv at.venvbreaks: iCloud keeps restoring a hidden flag on.pthfiles in site-packages, and Python 3.14 ignores hidden.pthfiles. Directories named*.nosyncare excluded from iCloud sync, hence the layout above.
# Compare two local GTFS zips (older one first) into a self-contained HTML report
gtfs-semantic-diff compare old.zip new.zip --html report.html
# Also emit ChangeEvent JSON / Markdown / raw diffs
gtfs-semantic-diff compare old.zip new.zip \
-o events.json --report report.md --rawdiffs rawdiffs.json
# Lightweight HTML (same "core" bundle as the web service) or app+data split output
gtfs-semantic-diff compare old.zip new.zip --html-lite lite.html --html-dir out/
# AI-oriented digest (Markdown / JSON, numbers guaranteed identical to the report)
gtfs-semantic-diff compare old.zip new.zip --digest digest.md --digest-json digest.json
# Japanese feeds: fetch generations directly from gtfs-data.jp
gtfs-semantic-diff fetch --org nagai-unyu --feed Nagaibus
gtfs-semantic-diff compare --org chitetsu --feed chitetsubus \
--old prev_2 --new prev_1 --html report.html
# Run only the L1 identity stage and inspect match confidence
gtfs-semantic-diff identity --org chitetsu --feed chitetsubus
--config swaps the threshold TOML (default: config/default.toml).infra/, AWS CDK; S3 + CloudFront + Lambda) powers
diff.gtfs.jp and can be deployed to your own AWS
account.Events fall into 6 groups (routes, stop patterns, trips/times, stops, calendars, fares/metadata), 44 types in total. The exhaustive detection specification is docs/spec/detection.md (Japanese): L0 enumeration rules, L1 identity scoring, and per-rule detection conditions, evidence consumption and thresholds.
zip ×2 | gtfs-data.jp API
→ load/ normalized loading (day_type normalization, all .txt kept as strings)
→ diff0/ L0: exhaustive RawDiff enumeration (the ledger's denominator)
→ identity/ L1: cross-version identity — stop clusters / route families /
stop patterns / route groups
→ events/ L2: rule cascade + residual accounting → ChangeEvent JSON (canonical)
→ report/ presentation model (cognitive units) → HTML / Markdown / digest
Date-based CalVer (YYYY.M.D.N — release date plus a same-day sequence
number, e.g. 2026.7.11.1). pyproject.toml is the single source of the
version; it is embedded in generated reports alongside generated_at.
All roadmap milestones are complete. On the Japanese verification feeds
explained_ratio is 1.0000; the international verification set (TriMet,
MBTA, STM Montréal, Rome, national-scale Swiss and Netherlands feeds) runs to
completion with explained_ratio 0.98–1.0. 287 tests. The largest Japanese
verification pair (30,700 raw diffs) takes ~2 seconds; national-scale feeds
finish in minutes (docs/perf/).
Development documentation is in Japanese (development happens in Japanese). The external API guide and reference (docs/api/) are English-first with Japanese companions.
| Document | Content |
|---|---|
| docs/articles/internals_1_core.md | Internals, part 1: RawDiff, MatchGraph, TripDelta, ChangeEvent — the ledger core |
| docs/articles/internals_2_presentation.md | Internals, part 2: the presentation layer — from ledger units to cognitive units |
| docs/spec/detection.md | Detection specification (implementation-accurate, exhaustive) |
| docs/design/presentation.md | Report display requirements and invariants |
| docs/design/ontology.md | Event catalog (design) |
| docs/design/architecture.md | Architecture and JSON schemas |
| docs/design/roadmap.md | Milestones and Definitions of Done |
| docs/api/ | External API guide and reference — English, with Japanese companions (served at diff.gtfs.jp/docs/) |
| docs/verification/ | Real-data verification logs |
This repository is developed as a human + AI collaboration using Claude Code. CLAUDE.md is the standing instruction file (design principles, development rules); progress is driven by per-milestone Definitions of Done — nothing is recorded as "done" without an execution record on the verification feeds. Design decisions, review findings and rejected alternatives are kept in docs/verification/ and the revision histories of the design documents.
.venv.nosync/bin/python -m pytest -q
.venv.nosync/bin/ruff check src tests
config/default.toml.| docs/perf/ |
| Performance measurement records |
| CLAUDE.md | Design principles and development rules (instructions for AI agents) |