Visualizers
Learn by moving things
Interactive explainers for the ideas behind retrieval, embeddings, and agents. A formula tells you what is true; dragging a vector shows you why. Each one also appears inside the article it belongs to, and runs entirely in your browser, so drag, poke, and break it.

Did it answer the question you asked?
From: How to Judge a RAG System →Response relevancy (historically answer relevancy): generate questions the answer would fit, then measure how close they are to the original question. A tight answer implies questions that cluster on the original; a padded, off-topic answer implies questions that drift away.
The question: 'how long do I have to return a defective laptop?' Relevancy asks whether the answer actually addresses this.
Same copies. Different readers.
From: A document’s permissions must travel with it. →Change Maya’s or Arun’s identity and inspect which copied passages keep the source document’s grants.
Send D2 through the copy room.
Fictional records. Browser simulation. No live model call.
D2
Engineering incident note
tenant: sachin
groups: ["engineering"]
users: []Sign-in requests time out under peak load.
Parent D2 · Sachin · policy v1Maya: No matching permission
The identity team is fixing the session refresh path.
Parent D2 · Sachin · policy v1Maya: No matching permission
0 of 2 copies allowed for Maya. Each copy is evaluated using its inherited company and grants.
Inspect the input, rule, and output
Input / state
{
"principal": {
"id": "maya",
"name": "Maya",
"role": "Support",
"tenantId": "sachin",
"groups": [
"support"
]
},
"source": {
"id": "D2",
"title": "Engineering incident note",
"team": "Engineering",
"tenantId": "sachin",
"allowedGroups": [
"engineering"
],
"allowedUsers": [],
"match": 98,
"fact": "Sign-in requests time out under peak load. The identity team is fixing the session refresh path."
},
"paragraphs": [
"Sign-in requests time out under peak load.",
"The identity team is fixing the session refresh path."
]
}Decision rule
validate permission metadata
copy tenant + grants onto each chunk
allow = sameCompany && (directGrant || groupGrant)Output
{
"chunks": [
{
"id": "D2.1",
"title": "Engineering incident note",
"team": "Engineering",
"tenantId": "sachin",
"allowedGroups": [
"engineering"
],
"allowedUsers": [],
"match": 98,
"fact": "Sign-in requests time out under peak load.",
"parentId": "D2",
"aclVersion": 1
},
{
"id": "D2.2",
"title": "Engineering incident note",
"team": "Engineering",
"tenantId": "sachin",
"allowedGroups": [
"engineering"
],
"allowedUsers": [],
"match": 98,
"fact": "The identity team is fixing the session refresh path.",
"parentId": "D2",
"aclVersion": 1
}
],
"decisions": [
{
"id": "D2.1",
"hasIdentity": true,
"sameCompany": true,
"directGrant": false,
"groupGrant": false,
"matchingGroups": [],
"allowed": false,
"reason": "No matching permission"
},
{
"id": "D2.2",
"hasIdentity": true,
"sameCompany": true,
"directGrant": false,
"groupGrant": false,
"matchingGroups": [],
"allowed": false,
"reason": "No matching permission"
}
]
}This view runs the same deterministic functions as the downloadable example. The short rule above summarizes the operation; the download contains the complete implementation.
Move the retrieval cutoff
From: Find the best evidence this person may read. →Recover two of Maya’s five target passages, then widen the candidate set. The cutoff changes search reach, never permission.
Move the cutoff through the ranked pile.
Fictional records. Browser simulation. No live model call.
The complete ranked pile
- 1D2.1× Denied98 pts
- 2D4.1× Denied96 pts
- 3D1.1✓ Allowed94 pts
- 4D2.2× Denied92 pts
- 5D3.1✓ Allowed90 ptscutoff
- 6D1.2✓ Allowed88 pts
- 7D3.2✓ Allowed86 pts
- 8D1.3✓ Allowed84 pts
- 9D4.2× Denied82 pts
- 10D3.3✓ Allowed80 pts
2 passages returned
5 target passages
40% recall2 of 5 target passages recovered.
The cutoff changes reach, never permission. Still missed: D1.2, D3.2, D1.3.
Inspect the input, rule, and output
Input / state
{
"principal": {
"id": "maya",
"name": "Maya",
"role": "Support",
"tenantId": "sachin",
"groups": [
"support"
]
},
"k": 5,
"fetchCount": 5,
"ranking": [
{
"id": "D2.1",
"title": "Engineering incident note",
"team": "Engineering",
"tenantId": "sachin",
"allowedGroups": [
"engineering"
],
"allowedUsers": [],
"match": 98,
"fact": "Sign-in requests time out under peak load.",
"parentId": "D2",
"aclVersion": 1
},
{
"id": "D4.1",
"title": "Launch cost review",
"team": "Finance",
"tenantId": "sachin",
"allowedGroups": [
"finance"
],
"allowedUsers": [],
"match": 96,
"fact": "The delay adds $24,000 to the internal launch budget.",
"parentId": "D4",
"aclVersion": 1
},
{
"id": "D1.1",
"title": "Customer launch update",
"team": "Shared",
"tenantId": "sachin",
"allowedGroups": [
"support",
"engineering"
],
"allowedUsers": [],
"match": 94,
"fact": "Orion’s launch has moved to 14 October.",
"parentId": "D1",
"aclVersion": 1
},
{
"id": "D2.2",
"title": "Engineering incident note",
"team": "Engineering",
"tenantId": "sachin",
"allowedGroups": [
"engineering"
],
"allowedUsers": [],
"match": 92,
"fact": "The identity team is fixing the session refresh path.",
"parentId": "D2",
"aclVersion": 1
},
{
"id": "D3.1",
"title": "Customer support FAQ",
"team": "Support",
"tenantId": "sachin",
"allowedGroups": [
"support"
],
"allowedUsers": [],
"match": 90,
"fact": "Existing workspaces stay available.",
"parentId": "D3",
"aclVersion": 1
},
{
"id": "D1.2",
"title": "Customer launch update",
"team": "Shared",
"tenantId": "sachin",
"allowedGroups": [
"support",
"engineering"
],
"allowedUsers": [],
"match": 88,
"fact": "The team is completing reliability checks.",
"parentId": "D1",
"aclVersion": 1
},
{
"id": "D3.2",
"title": "Customer support FAQ",
"team": "Support",
"tenantId": "sachin",
"allowedGroups": [
"support"
],
"allowedUsers": [],
"match": 86,
"fact": "Customers do not need to take any action.",
"parentId": "D3",
"aclVersion": 1
},
{
"id": "D1.3",
"title": "Customer launch update",
"team": "Shared",
"tenantId": "sachin",
"allowedGroups": [
"support",
"engineering"
],
"allowedUsers": [],
"match": 84,
"fact": "The launch update will be revised after the next readiness review.",
"parentId": "D1",
"aclVersion": 1
},
{
"id": "D4.2",
"title": "Launch cost review",
"team": "Finance",
"tenantId": "sachin",
"allowedGroups": [
"finance"
],
"allowedUsers": [],
"match": 82,
"fact": "Finance will reconcile launch costs after release.",
"parentId": "D4",
"aclVersion": 1
},
{
"id": "D3.3",
"title": "Customer support FAQ",
"team": "Support",
"tenantId": "sachin",
"allowedGroups": [
"support"
],
"allowedUsers": [],
"match": 80,
"fact": "Support will share the next approved launch update.",
"parentId": "D3",
"aclVersion": 1
}
]
}Decision rule
target = rank(all).filter(allowed).slice(0, k)
returned = rank(all).slice(0, fetchCount)
.filter(allowed).slice(0, k)
recall = recoveredTargetCount / target.lengthOutput
{
"target": [
"D1.1",
"D3.1",
"D1.2",
"D3.2",
"D1.3"
],
"returned": [
"D1.1",
"D3.1"
],
"recall": 0.4
}This view runs the same deterministic functions as the downloadable example. The short rule above summarizes the operation; the download contains the complete implementation.