This Python MCP server extracts and analyzes Python code structures, focusing on import/export relationships between files. It intelligently navigates codebases to identify related files, prioritizes the most relevant code sections to stay within token limits, and automatically includes README files for better context. The implementation features a CodeGrapher class that builds a comprehensive graph of code references, making it ideal for AI assistants that need to understand Python projects holistically without exceeding context windows.
暂无评论. 成为第一个评论的人!
登录以参与讨论
Return the code of a target Python file and related files based on import/export proximity. Parameters: target_file (string) - Path to the Python file to analyze, root_repo_path (optional string) - Root directory of the repository.