chore(wolf): update session memory, anatomy, and token ledger

This commit is contained in:
Rongsong Shen 2026-07-31 09:29:48 +00:00
parent d4b80010b1
commit d968bbd722
4 changed files with 87757 additions and 439 deletions

View file

@ -1,12 +1,37 @@
# anatomy.md
> Auto-maintained by OpenWolf. Last scanned: 2026-07-23T08:56:01.886Z
> Files: 788 tracked | Anatomy hits: 0 | Misses: 0
> Auto-maintained by OpenWolf. Last scanned: 2026-07-31T09:01:40.540Z
> Files: 840 tracked | Anatomy hits: 0 | Misses: 0
## ../../../../../../tmp/claude-1000/
- `capture_single_job.sh` — Deploys a 3-node cluster from a given repo root's freshly-built binaries, (~544 tok)
## ../../../../../../tmp/claude-1000/-home-rshen-projects-xce-worktrees-config/c8633ffb-8da0-40a7-9811-48f1830c37b4/scratchpad/
- `cross-spec-gap-analysis.md` — Cross-Spec Gap Analysis: admin-config-tool × config-upgrade-snapshot × clusterconfig-schema-split (2 (~2057 tok)
## ../../../../../../tmp/claude-1000/-home-rshen-projects-xce-worktrees-config/d3f40b2e-8c73-4820-8ad3-1400be8761ac/scratchpad/
- `update_bug1471.py` (~439 tok)
- `update_bug1474.py` (~1227 tok)
## ../../../../../../tmp/claude-1000/-home-rshen-projects-xce-worktrees-config/d6d1f70d-af0b-465b-9cd6-e719e38692ce/scratchpad/
- `configpush_baddriver.c` — include <stdio.h> (~847 tok)
- `impostor.py` — serve (~207 tok)
- `manual_ha_deploy.sh` (~381 tok)
- `verify_decode_reply.py` — Verify the actual decode_reply() implementation (mirrors the planned (~783 tok)
- `verify_envelope.py` — Throwaway script to verify the Request/RequestReply envelope wrap+unwrap (~937 tok)
## ../../../../../../tmp/claude-1000/-home-rshen-projects-xce-worktrees-config/d6d1f70d-af0b-465b-9cd6-e719e38692ce/scratchpad/ha-configpush-replydecode/
- `reject_reply_decode_driver.py` — Throwaway driver for raft-adapter-conformance task 7.3 remediation. (~1375 tok)
## ../../../../../../tmp/claude-1000/-home-rshen-projects-xce-worktrees-config/d6d1f70d-af0b-465b-9cd6-e719e38692ce/scratchpad/ha-vote-postconnect/
- `impostor_peer.py` — serve, main (~584 tok)
## ../../../../../../tmp/claude-1000/-home-rshen-projects-xce-worktrees-raft-tla/00c9b3f1-df3c-4ce0-a997-5c6a316be4ec/scratchpad/
- `hammer.sh` — Tight repro loop for bug-1436: hammer verify_no_loss-style REPL sessions (~570 tok)
@ -54,17 +79,20 @@
## ../../../../../claude/.claude/projects/-home-rshen-projects-xce-xce/memory/
- `MEMORY.md` — Memory Index (~2126 tok)
- `MEMORY.md` — Memory Index (~2345 tok)
- `project_bug1306_hook_rc_clobber.md` (~693 tok)
- `project_bug1417_vote_index_mapping.md` — Bug-1417: Real-vote reply index mapping mismatch (~784 tok)
- `project_bug1418_prework_decision.md` (~724 tok)
- `project_bug1418_prework_decision.md` (~628 tok)
- `project_bug1418_term_desync_apply_divergent.md` — Bug-1418: Term desync + apply-divergence promotion block → chaotic liveness stall (~743 tok)
- `project_bug1419_wal_dup_submit_false_divergent.md` — Declares occurrence (~955 tok)
- `project_bug1462_config_replication_fixed.md` — Declares client (~620 tok)
- `project_bug847_wal_batch_payload_loss.md` (~1213 tok)
- `project_raft_election_resonance.md` (~556 tok)
- `project_resource_distribution_mapping_scoping.md` (~571 tok)
- `project_scheduler_core_design_invariant.md` (~406 tok)
- `reference_nix_capnpc_pin_fix.md` (~485 tok)
- `reference_nonoverlay_fs_soak.md` (~371 tok)
- `reference_xce_build_shared_dir_clobber.md` (~415 tok)
## ../../../../../claude/tmp/gdbwrap/
@ -284,8 +312,8 @@
## .claude/skills/xce-test-ha/
- `run-ha-soak.sh` — run-ha-soak.sh — driver for /xce-test-ha: deploy a 3-node XCE HA cluster, then (~30050 tok)
- `SKILL.md` — XCE HA Failover Soak Test (~6970 tok)
- `run-ha-soak.sh` — run-ha-soak.sh — driver for /xce-test-ha: deploy a 3-node XCE HA cluster, then (~41761 tok)
- `SKILL.md` — XCE HA Failover Soak Test (~9766 tok)
- `soak-verdict-selftest.sh` — soak-verdict-selftest.sh — deterministic unit test for the verdict parser in (~2637 tok)
- `soak-verdict.sh` — soak-verdict.sh — pure (side-effect-free) verdict helpers for run-ha-soak.sh. (~2781 tok)
@ -345,8 +373,8 @@
- `design.md` — Technical Design: admin-config-tool (~13515 tok)
- `requirements.md` — Requirements Document (~5992 tok)
- `research.md` — Research & Design Decisions: admin-config-tool (~6829 tok)
- `spec.json` (~332 tok)
- `tasks.md` — Implementation Plan (~7241 tok)
- `spec.json` (~573 tok)
- `tasks.md` — Implementation Plan (~9380 tok)
## .kiro/specs/clusterconfig-schema-split/
@ -367,9 +395,11 @@
## .kiro/specs/config-upgrade-snapshot/
- `brief.md` — Brief: config-upgrade-snapshot (~1108 tok)
- `requirements.md` — Requirements Document (~3658 tok)
- `research.md` — Gap Analysis — config-upgrade-snapshot (2026-06-24) (~5335 tok)
- `spec.json` (~269 tok)
- `design.md` — Design Document: config-upgrade-snapshot (~13143 tok)
- `requirements.md` — Requirements Document (~7093 tok)
- `research.md` — Gap Analysis — config-upgrade-snapshot (2026-06-24) (~9323 tok)
- `spec.json` (~136 tok)
- `tasks.md` — Implementation Plan (~12616 tok)
## .kiro/specs/controller-status/
@ -531,7 +561,7 @@
- `design.md` — Design Document (~11209 tok)
- `requirements.md` — Requirements Document (~4240 tok)
- `research.md` — Research & Design Decisions (~5375 tok)
- `spec.json` (~666 tok)
- `spec.json` (~785 tok)
- `tasks.md` — Implementation Plan (~14377 tok)
- `TLA-gap-analysis.md` — Gap Analysis: XCE HA implementation vs `raft/raft.tla` (~2070 tok)
@ -562,6 +592,14 @@
- `spec.json` (~787 tok)
- `tasks.md` — Implementation Plan (~4086 tok)
## .kiro/specs/raft-adapter-conformance/
- `design.md` — Design Document: raft-adapter-conformance (~9311 tok)
- `requirements.md` — Requirements Document (~4577 tok)
- `research.md` — Gap Analysis: raft-adapter-conformance (~8747 tok)
- `spec.json` (~230 tok)
- `tasks.md` — Implementation Plan (~4416 tok)
## .kiro/specs/raft-apply-decoupling/
- `brief.md` — Brief: raft-apply-decoupling (~2239 tok)
@ -639,6 +677,11 @@
- `spec.json` — Declares is (~226 tok)
- `tasks.md` — Implementation Tasks: resval-id-decoupling (~2424 tok)
## .kiro/specs/scheduler-allocation/
- `requirements.md` — Requirements Document (~9034 tok)
- `spec.json` (~210 tok)
## .kiro/specs/scheduler-controller-msg-gap/
- `design.md` — Design: scheduler-controller-msg-gap (~5006 tok)
@ -647,11 +690,23 @@
- `spec.json` (~230 tok)
- `tasks.md` — Tasks: scheduler-controller-msg-gap (~4650 tok)
## .kiro/specs/scheduler-core/
- `brief.md` — Brief: scheduler-core (~1988 tok)
- `requirements.md` — Requirements Document (~24180 tok)
- `spec.json` (~202 tok)
## .kiro/specs/scheduler-framework/
- `brief.md` — Brief: scheduler-framework (~5679 tok)
- `requirements.md` — Requirements Document (~6317 tok)
- `spec.json` (~138 tok)
- `brief.md` — Brief: scheduler-framework (~6115 tok)
- `requirements.md` — Requirements Document (~17160 tok)
- `spec.json` (~211 tok)
## .kiro/specs/scheduler-preemption/
- `brief.md` — Brief: scheduler-preemption (~2910 tok)
- `requirements.md` — Requirements Document (~2285 tok)
- `spec.json` (~213 tok)
## .kiro/specs/worker-join-refactor/
@ -739,6 +794,7 @@
- `jul-06-jul-11.md` — Jul 6 → Jul 11 Progress Report (~2311 tok)
- `jul-13-jul-18.md` — Jul 13 → Jul 18 Progress Report (~3919 tok)
- `jul19-jul26-2026.md` — Work Summary: Jul 19 – Jul 26, 2026 (~3482 tok)
- `jun29-jul04-2026.md` — Work Summary: June 30 – July 4, 2026 (~857 tok)
## scripts/
@ -1035,63 +1091,71 @@
## src/controller/
- `apiserver.c` — include <errno.h> (~5962 tok)
- `CLAUDE.md` — XCE Controller (~3491 tok)
- `cluster.c` — include "config.h" (~19620 tok)
- `CLAUDE.md` — XCE Controller (~4527 tok)
- `cluster.c` — include "config.h" (~20931 tok)
- `commit.c` — Declares is (~12825 tok)
- `config_repl.c` — define _GNU_SOURCE (~32202 tok)
- `config_repl.h` — pragma once (~6155 tok)
- `config_repl.c` — define _GNU_SOURCE (~33995 tok)
- `config_repl.h` — pragma once (~6467 tok)
- `ha_convergence.c` — Declares char (~7830 tok)
- `ha.c` — define _GNU_SOURCE (~111827 tok)
- `ha.h` — ifndef HA_H (~29766 tok)
- `ha.c` — define _GNU_SOURCE (~124295 tok)
- `ha.h` — ifndef HA_H (~34070 tok)
- `job.c` — include <errno.h> (~24947 tok)
- `join.c` — include "config.h" (~2795 tok)
- `main.c` — include <argp.h> (~4682 tok)
- `meson.build` (~2391 tok)
- `myapp.c` — define _GNU_SOURCE (~5215 tok)
- `myconf.c` — define _GNU_SOURCE (~1088 tok)
- `persist.c` — define _GNU_SOURCE (~72815 tok)
- `main.c` — include <argp.h> (~4767 tok)
- `meson.build` (~2535 tok)
- `myapp.c` — define _GNU_SOURCE (~5868 tok)
- `myconf.c` — define _GNU_SOURCE (~1101 tok)
- `persist.c` — define _GNU_SOURCE (~85714 tok)
- `repl.c` — include <assert.h> (~8624 tok)
- `sched.c` — include <errno.h> (~5719 tok)
- `worker.c` — include <errno.h>; worker_from_capnp hook_detail-aware existing-worker apply (bug-1472 fix) (~7228 tok)
## src/controller/include/
- `cluster.h` — if !defined(_CLUSTER_H_) (~3203 tok)
- `commit.h` — pragma once (~3635 tok)
- `worker.h` — if !defined(_WORKER_H_) (~199 tok)
## src/controller/testsuite/
- `controller_test.c` — include <argp.h> (~2071 tok)
- `configcompare.c` — define _GNU_SOURCE (~2122 tok)
- `configcompare.h` — pragma once (~1107 tok)
- `controller_test.c` — include <argp.h> (~2156 tok)
- `snapdiff.c` — define _GNU_SOURCE (~833 tok)
- `snapdiff.h` — pragma once (~569 tok)
- `snapverify.c` — define _GNU_SOURCE (~2505 tok)
- `snapverify.h` — pragma once (~645 tok)
- `test_apply_committed_entry.c` — Declares directly (~7622 tok)
- `snapverify.c` — define _GNU_SOURCE (~4034 tok)
- `snapverify.h` — pragma once (~1250 tok)
- `test_apply_committed_entry.c` — Declares directly; +3 WAL_WORKER_CTRL/UPDATE tests (bug-1472 fix: applies-to-existing, replace-not-or, JOIN-duplicate regression guard) (~12391 tok)
- `test_apply_correctness_verification.c` — Declares driving (~16906 tok)
- `test_apply_pump_integration.c` — Declares hook (~16913 tok)
- `test_apply_pump.c` (~19569 tok)
- `test_apply_reapply_idempotency.c` — Declares xce_job_t (~4026 tok)
- `test_apply_seam.c` (~2936 tok)
- `test_apply_seam.c` — raft-apply-decoupling task 2.1: calls apply_job_start/finish/fail/update_transition() directly on a bare jobmgr+job_t (no cluster_t), bypassing on_job_start/finish/fail, to prove the extracted guard cores work outside the receipt path (~2900 tok)
- `test_commit_barrier_reply.c` — Declares uint8_t (~41011 tok)
- `test_commit_barrier_rollout.c` — Declares explicitly (~26488 tok)
- `test_bug857_regression.c` — Declares void (~6090 tok)
- `test_commit_barrier_reply.c` — Declares uint8_t (~43215 tok)
- `test_commit_barrier_rollout.c` — Declares explicitly (~27677 tok)
- `test_commit_durability.c` — define _GNU_SOURCE (~32879 tok)
- `test_commit_resolve.c` (~14018 tok)
- `test_config_repl.c` — define _GNU_SOURCE (~45079 tok)
- `test_convergence_verification.c` — define _GNU_SOURCE; pre-existing ha_walack_on_ack/ha_catchup_continuation_fn fixture, NO slowlane_init — the surface that broke when catchup offload defaulted ON (see bug-1451) (~18715 tok)
- `test_config_repl.c` — define _GNU_SOURCE (~87209 tok)
- `test_configcompare.c` — define _GNU_SOURCE (~2076 tok)
- `test_convergence_verification.c` — define _GNU_SOURCE (~18893 tok)
- `test_demotion_convergence.c` — define _GNU_SOURCE; dc_setup +slowlane_init, +test_demotion_offload_task_returns_promptly / test_demotion_inline_task_blocks_RED (2026-07-18, bug-1450 RED/GREEN) (~18600 tok)
- `test_e2e_capnp.c` — include <stdint.h> (~3729 tok)
- `test_e2e_checkpoint.c` — define _GNU_SOURCE (~3544 tok)
- `test_e2e_gc.c` — define _GNU_SOURCE (~1678 tok)
- `test_e2e_hooks.c` — define _GNU_SOURCE (~2184 tok)
- `test_egress_filter.c` — Declares xce_job_t (~5072 tok)
- `test_ha_core_safety.c` — Declares char (~36309 tok)
- `test_ha_core_safety.c` — Declares char; HA/raft-adapter core-safety suite; includes task 5.1's test_5_1_wal_catchup_reject_sends_nack_reply (WAL catch-up reject -> ha_send_wal_ack_reply_ex NACK regression-lock) (~41000 tok)
- `test_ha_elect_ctx_lifecycle.c` — Declares char (~2900 tok)
- `test_ha_election.c` — Declares char (~16377 tok)
- `test_ha_liveness.c` — Declares directly (~24748 tok)
- `test_ha_partition.c` (~5459 tok)
- `test_ha_rdhup_integration.c` — Declares char (~7341 tok)
- `test_ha_role.c` — include <signal.h> (~11466 tok)
- `test_ha_vep_teardown.c` (~6218 tok)
- `test_ha_vote_gate.c` — define _GNU_SOURCE (~14165 tok)
- `test_ha_vote_send.c` — define _GNU_SOURCE (~6961 tok)
- `test_ha_vote_send.c` — define _GNU_SOURCE (~9950 tok)
- `test_job_array_apiserver_push.c` — Declares uint8_t (~3366 tok)
- `test_job_array_apply.c` — Declares from (~10687 tok)
- `test_job_array_fence.c` (~6110 tok)
@ -1100,17 +1164,26 @@
- `test_persist_checkpoint.c` — define _GNU_SOURCE (~2415 tok)
- `test_persist_hooks.c` — define _GNU_SOURCE (~4305 tok)
- `test_persist_recovery.c` — define _GNU_SOURCE (~3778 tok)
- `test_persist_snapshot_entities.c` — unsigned: queue (~14897 tok)
- `test_persist_snapshot_entities.c` — unsigned: queue (~25632 tok)
- `test_persist_truncate.c` — define _GNU_SOURCE (~5311 tok)
- `test_repl_unit.c` — include <assert.h> (~6230 tok)
- `test_repl_unit.c` — include <assert.h>; +2 bug-1474 slot-allocation guard tests (~9760 tok)
- `test_replay_apply_seam.c` — Declares through (~3707 tok)
- `test_snapdiff.c` — define _GNU_SOURCE (~1033 tok)
- `test_snapverify.c` — define _GNU_SOURCE (~2008 tok)
- `test_snapverify.c` — define _GNU_SOURCE (~4696 tok)
- `test_term_safety_adapter.c` — define _GNU_SOURCE (~28939 tok)
- `test_upgrade_snapshot_apply.c` — Declares char (~12444 tok)
- `test_upgrade_snapshot_restore.c` — Declares char (~3581 tok)
- `test_walcompare.c` — define _GNU_SOURCE (~6845 tok)
- `test.c` — include <argp.h> (~30294 tok)
- `test_waldump.c` — define _GNU_SOURCE (~4292 tok)
- `test.c` — include <argp.h> (~31907 tok)
- `walcompare.c` — define _GNU_SOURCE (~5176 tok)
- `walcompare.h` — pragma once (~1474 tok)
- `waldump.c` — define _GNU_SOURCE (~5516 tok)
- `waldump.c` — define _GNU_SOURCE (~6488 tok)
- `waldump.h` — pragma once (~1150 tok)
## src/docs/
- `deployment.md` — XCE Deployment Guide (~4942 tok)
## src/frontend/apiserver/backend/
@ -1123,6 +1196,10 @@
- `wire_dispatch_support.go` — go:build cgo (~2254 tok)
- `wire_dispatch_test.go` — go:build cgo (~1337 tok)
## src/frontend/apiserver/config/
- `auth.yaml` — Authentication provider: config_file | pam | ldap | oauth2 (~187 tok)
## src/frontend/xcecli/cmd/auth/
- `logon.go` — NewLogonCmd (~1388 tok)
@ -1186,16 +1263,19 @@
## src/include/
- `client.h` — if !defined(_CLIENT_H_) (~1707 tok)
- `client.h` — if !defined(_CLIENT_H_) (~1899 tok)
- `clusterconfig.h` — if !defined(_CLUSTERCONFIG_H_) (~248 tok)
- `config.h` — if !defined(_CONFIG_H_) (~1257 tok)
- `delay.h` — if !defined(_DELAY_H_) (~414 tok)
- `kvmgr.h` — if !defined(__KVMGR_H__) (~631 tok)
- `myconf.h` — if !defined(_MYCONF_H_) (~874 tok)
- `myconf.h` — if !defined(_MYCONF_H_) (~1055 tok)
- `netio.h` — if !defined(_NETIO_H_) (~2608 tok)
- `persist.h` — pragma once (~24030 tok)
- `typemap.h` — if !defined(_TYPEMAP_H_) (~5207 tok)
- `persist.h` — pragma once (~24145 tok)
- `repl.h` — pragma once (~2331 tok)
- `request.h` — if !defined(_REQUEST_H_) (~2738 tok)
- `typemap.h` — if !defined(_TYPEMAP_H_) (~5497 tok)
- `wal_types.h` — pragma once (~2076 tok)
- `xceapi.h` — if !defined(_XCEAPI_H_) (~650 tok)
- `zarray.h` — if !defined(_ZARRAY_H_) (~1286 tok)
## src/include/xce/
@ -1205,15 +1285,16 @@
## src/lib/
- `client_internal.h` — if !defined(_CLIENT_INTERNAL_H_) (~4475 tok)
- `client.c` — include <errno.h> (~6767 tok)
- `client.c` — include <errno.h> (~7163 tok)
- `cluster.c` — include <errno.h> (~1526 tok)
- `delay.c` — include <errno.h> (~1520 tok)
- `jobj.c` — include <errno.h> (~6090 tok)
- `kvmgr.c` — include <errno.h> (~3053 tok)
- `meson.build` (~1703 tok)
- `netio.c` — include <arpa/inet.h> (~9456 tok)
- `request.c` — include <errno.h> (~17130 tok)
- `request.c` — include <errno.h> (~18036 tok)
- `vtaskmgr.c` — include <errno.h> (~3822 tok)
- `xceapi.c` — include <errno.h> (~4190 tok)
- `zarray.c` — include <assert.h> (~5924 tok)
## src/lib/raft/
@ -1238,7 +1319,7 @@
## src/nixSupport/
- `xce.nix` (~573 tok)
- `xce.nix` (~727 tok)
## src/scheduler/include/
@ -1259,7 +1340,7 @@
## src/schema/
- `controller.capnp` — Declares OPCode (~9442 tok)
- `controller.capnp` — Declares OPCode (~10085 tok)
## src/tools/
@ -1285,7 +1366,7 @@
- `__init__.py` — xceadmin: CLI for building and deploying XCE cluster configuration. (~22 tok)
- `build.py` — ``config build`` orchestration for xceadmin (design.md, ``xceadmin.build``; (~1578 tok)
- `cli.py` — xceadmin command-line entry point (design.md, ``xceadmin.cli``; (~1127 tok)
- `discovery.py` — Generic, opcode-agnostic redirect-following for xceadmin (design.md, (~1021 tok)
- `discovery.py` — Generic, opcode-agnostic redirect-following for xceadmin (design.md, (~1775 tok)
- `push.py` — ``config push`` orchestration for xceadmin (design.md, ``xceadmin.push``; (~1818 tok)
## src/xceadmin/src/xcecommon/
@ -1299,13 +1380,17 @@
## src/xceadmin/tests/
- `conftest.py` — Shared pytest fixtures for xceadmin's test suite. (~412 tok)
- `test_cli.py` — Tests for the xceadmin CLI (design.md, ``xceadmin.cli``; task 1.1's (~2609 tok)
- `_live_e2e_common.py` — Shared helpers for xceadmin's live E2E test suite (task 6.2's (~1206 tok)
- `conftest.py` — Shared pytest fixtures for xceadmin's test suite. (~699 tok)
- `test_cli.py` — Tests for the xceadmin CLI (design.md, ``xceadmin.cli``; task 1.1's (~2616 tok)
- `test_config_build.py` — Golden-file-style build tests for ``xceadmin.build`` (design.md, (~3661 tok)
- `test_config_push_mock.py` — Mock-controller tests for ``xceadmin.push`` (design.md, ``xceadmin.push``; (~3564 tok)
- `test_discovery.py` — Unit tests for ``xceadmin.discovery`` (design.md, ``xceadmin.discovery``; (~1259 tok)
- `test_config_push_mock.py` — Mock-controller tests for ``xceadmin.push`` (design.md, ``xceadmin.push``; (~3873 tok)
- `test_discovery.py` — Unit tests for ``xceadmin.discovery`` (design.md, ``xceadmin.discovery``; (~2177 tok)
- `test_e2e_live_ha_push.py` — Live 3-node HA E2E coverage for `config push` -- success path + the standby-redirect-gap regression lock; round-2 fixture adds _wait_for_standbys + settle + port recheck (still flaky -- bug-1485, primary crashes post-promotion) (~7600 tok)
- `test_e2e_live_push.py` — Live single-node E2E coverage for `config push` (task 6.2; Requirements (~2779 tok)
- `test_errors.py` — Tests for the xcecommon.errors exception hierarchy (task 1.2). (~2221 tok)
- `test_mapping.py` — Unit tests for ``xcecommon.mapping`` (design.md, ``xcecommon.mapping``; (~6323 tok)
- `test_repro_bug1485.py` — THROWAWAY repro for bug-1485 -- NOT part of the real test suite. (~1910 tok)
- `test_schema_bundling.py` — Cross-cutting bundling tests for ``xcecommon.schema`` and (~1526 tok)
- `test_schema.py` — Tests for xcecommon.schema (task 2.2). (~3150 tok)
- `test_validation.py` — Tests for xcecommon.validation (task 2.1). (~5022 tok)