Conversation
|
This comment has been minimized.
This comment has been minimized.
Closes 1jehuang#1230 as built, exactly the agreed boundary: read-only provider, never core, never default-on. Regex grammar sets (Rust, TS/JS, Python; unlisted extensions yield nothing, never fail), file-reference graph (unique-owner edges only, ambiguous names carry none), hand-rolled PageRank with seed personalization, token-budgeted stubs without bodies. No tree-sitter, no petgraph, no new dependencies. Cache under .jcode/cache/repomap.json keyed per file by mtime+size; stale files rebuild alone. Tool registers only when repomap_token_budget > 0 (default 2000, 0 disables); env JCODE_REPOMAP_TOKEN_BUDGET wins over file, registered in the CONFIG_ENV_KEYS fingerprint, documented in the default file. Tests: 13 engine (extraction rs/ts/py, skip dirs, hub rank, seed personalization, ambiguous/unique edges, budget truncation, budget-0 disable, cache rebuild + byte-identical warm hit, seeds end to end, empty tree) + 3 tool (stubs, budget-0 notice, missing dir errors). Clippy clean, fmt clean.
…ardening - Default budget 2000 -> 0: the provider is opt-in, so the default must not register the tool. Opt in via file or JCODE_REPOMAP_TOKEN_BUDGET. - Symlink confinement (both security findings): the walker never follows file/dir symlinks and every candidate is canonicalized under the root; the cache writer refuses symlinked .jcode/cache components and destination. Reads bounded at 2MB per file (no-symbol skip above). - First block over budget yields no map (was: always emitted). - Fingerprint mtime millis -> nanos plus size (same-ms equal-length edits no longer reuse stale symbols). - Dropped the export-specific fn patterns overlapping the general optional-export ones (ts/js emitted every exported fn twice). - Renamed DEFAULT_TOKEN_BUDGET to DEFAULT_REPOMAP_TOKEN_BUDGET (a different 200_000 const of the same name already exists).
Dedicated research pass (Aider RepoMap pipeline, 2025-26 refinements: multi-anchor personalization, co-change signals for the base-module blind spot): - Seeds accept symbol names, not just path prefixes: naming an identifier personalizes the teleport toward the files defining it. Case-insensitive substring; documented on the tool schema. - Recent-history co-change pairs (>=2 shared commits in the last 200) become bidirectional reference edges, so dependents boost their base even though no reference edge points back. Single shared commits ignored (bulk adds/renames are noise). Fail-soft outside git repos; repo-nested roots rebased via show-toplevel. - Synthetic-graph tests point at isolated roots so they never inherit real co-change edges from the checkout the suite runs in.
SK-DEV-AI
force-pushed
the
feat/repomap-provider
branch
from
September 20, 2026 11:39
8053699 to
93d8747
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #1230 as built, exactly the agreed boundary: read-only provider, never core, never default-on.
Regex grammar sets (Rust, TS/JS, Python; unlisted extensions yield nothing, never fail), file-reference graph (unique-owner edges only, ambiguous names carry none), hand-rolled PageRank with seed personalization, token-budgeted stubs without bodies. No tree-sitter, no petgraph, no new dependencies.
Cache under .jcode/cache/repomap.json keyed per file by mtime+size; stale files rebuild alone. Tool registers only when repomap_token_budget > 0 (default 2000, 0 disables and the tool is unregistered so models never see a dead tool); env JCODE_REPOMAP_TOKEN_BUDGET wins over file, registered in the CONFIG_ENV_KEYS fingerprint, documented in the default file. Measured prototype numbers from the thread (1350 files / 4.6s cold / 0.066s warm at 61x) carry over: same graph shape, per-file invalidation preserved.
Tests: 13 engine + 3 tool, all green. Clippy and fmt clean.