refactor: drop redundant Pilot experienceTracker param + tracker access cleanup#85
Merged
Conversation
…ss cleanup - Pilot: same redundancy as Navigator — its only caller passed the shared ExperienceTracker and Pilot holds `explorer`. Drop the param and the field; derive lazily in getExperienceToc() (avoids touching explorer at construction, which the duck-typed test explorer lacks). - Captain.getKnowledgeTracker(): use explorBot.knowledgeTracker() (the owned instance) instead of getExplorer().getKnowledgeTracker() — works before the explorer is started. - Convert now-type-only tracker imports to `import type` (state-manager, captain, historian, navigator) — trims runtime import edges. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Explorbot Self-RegressionCommit
Attempt details
Session analysis — basic (native): Session AnalysisThe Issues list page functionality was explored: creating issues, searching by text, filtering by status, filtering by label, and clearing filters. All core flows work correctly. Coverage
What works
|
…ence flag createAgentTools took experienceTracker + a getState closure purely to build the learnExperience tool — redundant for Pilot/Tester/Captain/Navigator (all derived them identically from explorer), and Rerunner encoded "no experience tool" by omitting them. Replace both params with a single `withExperience` flag (default on); derive the tracker + state lazily inside the tool's execute (so registering tools never touches getExperienceTracker — safe for minimal test explorers). Rerunner passes withExperience: false to keep excluding it. Drops the duplicated getState closure from all four call sites. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
e3d5b8f to
930d6c5
Compare
DenysKuchma
approved these changes
Jul 13, 2026
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.
Follow-up to #84 (merged). Removes the remaining redundant tracker plumbing and tidies access.
Changes
ExperienceTrackerand Pilot already holdsexplorer, so the optionalexperienceTracker?param +|| nullwas pure redundancy. Dropped the param and the field;getExperienceToc()derives it lazily fromexplorer.createAgentTools: tookexperienceTracker+ agetStateclosure solely to build thelearnExperiencetool — redundant for Pilot/Tester/Captain/Navigator (all derived them identically fromexplorer), while Rerunner encoded "no experience tool" by omitting them. Replaced both with a single explicitwithExperienceflag (default on); the tracker + state are derived lazily inside the tool'sexecute(registering tools never touchesgetExperienceTracker, so minimal test explorers are safe). Rerunner passeswithExperience: false. Removes the duplicatedgetStateclosure from all four call sites.explorBot.knowledgeTracker()(owned instance; works before the explorer starts).import type(state-manager, captain, historian, navigator); deadActionResultimports removed (explorbot, web-mode).Verification
bun run lintclean;bunx tsc --noEmitat baseline (no new src errors); full unit 765/0 (incl. a newwithExperience: falsecase); integration 63/0.Deliberately not changed
Knowledge mid-session-refresh TTL stays removed per the "knowledge is persistent" decision.
🤖 Generated with Claude Code