Skip to content

Tool Optimizations & Linked Issues Detection + CI/CD Pipelining#2

Merged
BurakKTopal merged 16 commits intomainfrom
optimization/tools
Dec 27, 2025
Merged

Tool Optimizations & Linked Issues Detection + CI/CD Pipelining#2
BurakKTopal merged 16 commits intomainfrom
optimization/tools

Conversation

@BurakKTopal
Copy link
Owner

Tool Optimizations & Linked Issues Detection

This PR consolidates and optimizes the CTM tooling, adds automatic origin detection, and fixes linked issue detection via GraphQL.

Key Changes

Tool Consolidation (35 → 32 tools)

  • Merged pickaxe_search into get_local_line_context for automatic origin detection
  • Merged explain_directory into list_github_tree via include_activity parameter
  • Merged get_recent_activity into get_activity_summary with path filtering
  • Removed redundant get_code_context (functionality in get_line_context)

Automatic Origin Detection

  • get_local_line_context now auto-detects when code was first introduced using pickaxe
  • Distinguishes between "last modified" (blame) and "origin" (first introduction)
  • Follows file renames to find true origin even after refactoring
  • Strips comment markers to find origin even if comment style changed

Linked Issues via GraphQL

  • Fixed: Issues linked via GitHub's Development sidebar are now detected
  • Switched from REST Timeline API (doesn't return issue numbers) to GraphQL closingIssuesReferences
  • PR number is filtered from issue_numbers to avoid false positives

Agent Improvements

  • Added html_url and pr_url to all commit responses for reliable linking
  • Updated system prompt to prevent URL construction errors (use provided URLs)
  • Removed emojis from console logs
  • Multi-tab support in VSCode extension

Caching Enhancements

  • GraphQL linked issues cached with 1-hour TTL
  • File rename chains cached for faster repeated lookups

Files Changed

Area Files
MCP Server stdio_server.py, github_client.py, cache.py, git_repo.py
VSCode Extension agent.ts, factStore.ts, contextPanel.ts, extension.ts
Documentation README.md, CLAUDE.md, SYSTEM_PROMPT.md

Test Plan

  • Verify get_local_line_context returns origin field with true introduction commit
  • Test linked issues detection on PR with Development sidebar links
  • Confirm list_github_tree with include_activity=true returns contributor info
  • Check pickaxe_search follows file renames correctly
  • Verify all tool responses include html_url for commits

@BurakKTopal BurakKTopal changed the title Optimization/tools Tool Optimizations & Linked Issues Detection + CI/CD Pipelining Dec 27, 2025
@BurakKTopal BurakKTopal merged commit cb195aa into main Dec 27, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant