Date: 2026-03-08
We added an inverted index over routing snapshots to pre-filter judgment-node retrieval. A debug counter (guarded by env var) prints the reduction ratio: candidates scored / total nodes.
This file records the first measured ratios from a live UCS state file.
Enable debug output:
export UCS_DEBUG_INDEX=1Control strictness of the structural pre-filter:
# default
export UCS_INDEX_MIN_SIGNALS=1
# tighter
export UCS_INDEX_MIN_SIGNALS=2UCS_DEBUG_INDEX=1 UCS_INDEX_MIN_SIGNALS=1 \
python3 /home/k/.openclaw/workspace/skills/ucs/bridge.py \
--workspace /home/k/.ucs consult \
--context "researching retrieval architecture and web fetch patterns" \
2>&1 | rg "\[UCS index\]"We tested two datasets:
- Random baseline (100 nodes): varied cursors/top_paths/energy.
- Clustered dataset (99 nodes): 3 clusters of 33 nodes each:
-
Cluster A
- cursor =
browser - top_paths = [
web_fetch,analysis] - context_energy = {
web_fetch,analysis}
- cursor =
-
Cluster B
- cursor =
exec - top_paths = [
foundry_research,nodes] - context_energy = {
foundry_research}
- cursor =
-
Cluster C
- cursor =
draft - top_paths = [
message,read] - context_energy = {
message,read}
- cursor =
For each cluster, query routing_state matched the cluster signature. Example (Cluster A):
{
"cursor": "browser",
"top_paths": [{"to":"web_fetch","score":1.2},{"to":"analysis","score":1.0}],
"context_energy": {"web_fetch": 1.2, "analysis": 1.0},
"active_artifacts": [],
"t": 2000
}- min_signals=1: 79/100 candidates scored (79%)
Each targeted query isolated its corresponding cluster:
- Query A (matches Cluster A): 33/99 (33%) candidates scored
- Query B (matches Cluster B): 33/99 (33%) candidates scored
- Query C (matches Cluster C): 33/99 (33%) candidates scored
min_signals=1is intentionally high-recall and will admit many candidates in mixed/random datasets.min_signals=2(or stronger structural requirements) is where the index begins to sharply isolate clusters.