Skip to content

Conversation

Copy link

Copilot AI commented Nov 11, 2025

Pull Request Check List

Resolves: #issue-number-here

  • Added tests for changed code.
  • Updated documentation for changed code.

Description

Implements a capability discovery API to answer "你能做什么?" (What can you do?). Users can now programmatically explore EasyGraph's features without reading extensive documentation.

Changes

Core API

  • easygraph/capabilities.py: New module exposing three functions:
    • show_capabilities(): Formatted console output covering 14 feature categories (centrality, community detection, structural holes, graph embedding, hypergraph, GPU acceleration, etc.)
    • get_capabilities_dict(): Returns structured dict with ~50 algorithms organized by category
    • 能做什么(): Chinese language alias for show_capabilities()

Integration

  • easygraph/__init__.py: Added capabilities module to exports

Testing & Documentation

  • easygraph/tests/test_capabilities.py: 8 unit tests covering all API functions
  • test_capabilities_standalone.py: Standalone test script for environments without C++ extension
  • examples/capabilities_example.py: Usage examples demonstrating all three functions

Usage

import easygraph as eg

# Display formatted overview
eg.show_capabilities()

# Programmatic access
caps = eg.get_capabilities_dict()
print(caps['centrality'])  
# ['degree_centrality', 'betweenness_centrality', 'closeness_centrality', ...]

# Chinese language support
eg.能做什么()

Impact

  • Zero breaking changes, fully backward compatible
  • Reduces onboarding friction for new users
  • Provides programmatic feature introspection for tooling
  • Supports Chinese-speaking users natively
Original prompt

你能做什么?


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI and others added 4 commits November 11, 2025 14:54
Co-authored-by: eggpig <108142838+eggpig@users.noreply.github.com>
Co-authored-by: eggpig <108142838+eggpig@users.noreply.github.com>
Co-authored-by: eggpig <108142838+eggpig@users.noreply.github.com>
Co-authored-by: eggpig <108142838+eggpig@users.noreply.github.com>
Copilot AI changed the title [WIP] Add new features to the application Add capability discovery API for EasyGraph (你能做什么?) Nov 11, 2025
Copilot AI requested a review from eggpig November 11, 2025 15:03
Copilot finished work on behalf of eggpig November 11, 2025 15:03
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.

2 participants