Repository navigation
feat(priority): add dependency centrality ranking for LLM context packing (fixes #255) - #260
Closed
Adeolu5678 wants to merge 2 commits into
Closed
Adeolu5678 wants to merge 2 commits into
Adeolu5678 wants to merge 2 commits into
Conversation
Member
|
Codex Closing as out of scope. We’re keeping Yek focused and aren’t expanding its feature set. |
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.
Problem
Fixes #255.
When packing repository contents to fit within strict LLM context budgets (--tokens, --max-size), \yek\ previously relied solely on Git commit recency (\compute_recentness_boost). While recency is a helpful heuristic for ongoing work, it introduces a severe bias against stable, foundational architectural hub files (\lib.rs, \models.rs, \schema.prisma, \ ypes.ts, \main.go). These core interfaces rarely change and receive a near-zero boost, causing \yek\ to evict the most critical architectural context when token budgets are tight in favor of peripheral recent edits.
Solution: In-Degree Dependency Centrality
This PR implements an in-degree dependency centrality engine that computes structural importance alongside Git commit recency:
ecency_weight = 0.4). Gracefully falls back if Git history is unavailable.
Verification (\prove-it-works)