plexus.cli.shared.plexus_tool module

Implementation of the Plexus tool for Claude to interact with scores and scorecards.

This module implements the Plexus tool protocol for Claude to: 1. List available scorecards 2. List scores within a scorecard 3. Pull score versions as YAML 4. Push score version updates from YAML

class plexus.cli.shared.plexus_tool.PlexusTool

Bases: object

Tool for Claude to interact with Plexus scores and scorecards.

Initialize the Plexus tool with an API client.

__init__()

Initialize the Plexus tool with an API client.

list_scorecards() List[Dict[str, Any]]

List all available scorecards.

Returns:
List of scorecard dictionaries containing:
  • id: Scorecard ID

  • name: Scorecard name

  • key: Scorecard key

  • externalId: External ID

list_scores_by_scorecard(scorecard: str) List[Dict]

List all scores within a specific scorecard.

Args:

scorecard: Scorecard identifier (ID, name, key, or external ID)

Returns:
List of score dictionaries containing:
  • id: Score ID

  • name: Score name

  • key: Score key

  • type: Score type

  • order: Score order

  • externalId: External ID

  • section: Section name and order

pull_score(scorecard: str, score: str) str | None

Pull a score’s current champion version as YAML.

push_score(scorecard: str, score: str, yaml_path: str) str | None

Push a score version from YAML.