Understand any codebase.
Ask questions about a public GitHub repository and get answers that point to the exact lines they came from.
How does TimestampSigner reject expired signatures?
What the evidence did not show: The implementations of get_timestamp and timestamp_to_datetime, and how sign embeds the timestamp, are not shown in the evidence.
88try:89result = super().unsign(signed_value)90sig_error = None91except BadSignature as e:92sig_error = e93result = e.payload or b""9495sep = want_bytes(self.sep)9697# If there is no timestamp in the result there is something98# seriously wrong. In case there was a signature error, we raise99# that one directly, otherwise we have a weird situation in100# which we shouldn't have come except someone uses a time-based101# serializer on non-timestamp data, so catch that.102if sep not in result:103if sig_error:104raise sig_error105106raise BadTimeSignature("timestamp missing", payload=result)107108value, ts_bytes = result.rsplit(sep, 1)109ts_int: int | None = None110ts_dt: datetime | None = None111112try:113ts_int = bytes_to_int(base64_decode(ts_bytes))114except Exception:115pass116117# Signature is *not* okay. Raise a proper error now that we have118# split the value and the timestamp.119if sig_error is not None:120if ts_int is not None:121try:122ts_dt = self.timestamp_to_datetime(ts_int)123except (ValueError, OSError, OverflowError) as exc:124# Windows raises OSError125# 32-bit raises OverflowError126raise BadTimeSignature(127"Malformed timestamp", payload=value128) from exc129130raise BadTimeSignature(str(sig_error), payload=value, date_signed=ts_dt)131132# Signature was okay but the timestamp is actually not there or133# malformed. Should not happen, but we handle it anyway.134if ts_int is None:135raise BadTimeSignature("Malformed timestamp", payload=value)136137# Check timestamp is not older than max_age138if max_age is not None:139age = self.get_timestamp() - ts_int140141if age > max_age:142raise SignatureExpired(143f"Signature age {age} > {max_age} seconds",144payload=value,145date_signed=self.timestamp_to_datetime(ts_int),146)147148if age < 0:149raise SignatureExpired(150f"Signature age {age} < 0 seconds",151payload=value,152date_signed=self.timestamp_to_datetime(ts_int),153)
claude-opus-5-5, 6 claims, all 7 citations checked against the retrieved code, $0.052, 13.1 s
Ask it liveNeither search found it alone.
The code behind that answer is the body of TimestampSigner.unsign. Vector search ranked it 14th and BM25 16th, and an answer reads the top 12 chunks. Turbopuffer runs both as one hybrid query and fuses the rankings, which put it 12th: just inside. Each fused row carries the rank it had in each list.
Recomputing RRF from the two lists reproduces all 12 of Turbopuffer's fused scores, in the same order (largest difference 1.8e-9, float rounding).
Vector
cosine distance, 20 of 20 shown
- 1timed.py:53-54
- 2test_timed.py:29-93
- 3timed.py:22-27
- 4test_timed.py:78-85
- 5test_timed.py:1-15
- 6test_timed.py:34-43
- 7test_timed.py:49-57
- 8timed.rst:1-28
- 9timed.py:170-228
- 10test_timed.py:87-93
- 11test_timed.py:45-47
- 12test_timed.py:59-67
- 13test_timed.py:69-76
- 14timed.py:72-158
- 15timed.py:64-70
- 16timed.py:185-220
- 17timed.py:1-19
- 18timed.py:56-62
- 19exc.py:60-63
- 20test_timed.py:96-115
Fused by Turbopuffer
one multi-query, RRF k = 60, top 12
BM25
full-text score, 20 of 20 shown
- 1timed.py:22-27
- 2timed.rst:1-28
- 3timed.py:53-54
- 4timed.py:170-228
- 5timed.py:185-220
- 6__init__.py:1-17
- 7test_timed.py:1-15
- 8timed.py:177-180
- 9timed.py:29-33
- 10test_timed.py:30-32
- 11timed.py:56-62
- 12timed.py:64-70
- 13test_timed.py:29-93
- 14timed.py:35-43
- 15timed.py:45-51
- 16timed.py:72-158
- 17test_timed.py:78-85
- 18exc.py:60-63
- 19test_timed.py:34-43
- 20timed.py:160-167
- 1timed.py:22-27V3 B1
- 2timed.py:53-54V1 B3
- 3timed.rst:1-28V8 B2
- 4test_timed.py:1-15V5 B7
- 5timed.py:170-228V9 B4
- 6test_timed.py:29-93V2 B13
- 7test_timed.py:78-85V4 B17
- 8timed.py:185-220V16 B5
- 9test_timed.py:34-43V6 B19
- 10timed.py:64-70V15 B12
- 11timed.py:56-62V18 B11
- 12timed.py:72-158V14 B16
timed.py:72-158TimestampSigner.unsignfused rank 12
- Vector
- rank 14, 1/(60+14) = 0.013514
- BM25
- rank 16, 1/(60+16) = 0.013158
- Sum
- 0.026671 Turbopuffer returned 0.026671
Recorded from the live API on 22 Oct 2026 for the same question. Ticked rows are chunks the answer cites.Try other questions and weights in the lab
Understand how it fits together. Module and import graphs are parsed from the source, so every edge points at a real import statement.
Investigate with citations. Each claim in an answer links to a file and line range. Anything the code doesn't show is labelled as inference.
Measure retrieval, not prose. Score search against hand-labelled questions to see whether the right code was found before you trust an answer.
What works today
RepoKnit is early. The API, indexing worker and Turbopuffer index are live, with one repository indexed so far: pallets/itsdangerous. The demo workspace runs offline on a bundled fixture, and How it works explains the design.
Working
- Questions about an indexed repository, answered by Claude with every citation checked
- Vector, keyword and hybrid search in Turbopuffer
- A retrieval lab that scores those search modes against hand-labelled questions and shows how hybrid fuses them
- Daily limits per visitor and an overall daily cap on answers
- A demo workspace and architecture explorer over a bundled fixture
Not built yet
- Indexing a repository from this site (the operator queues it with an admin token)
- Accounts and per-user quotas
- Multi-step investigations for questions one search can't answer
- Symbol graphs for TypeScript