@polygraph/claude-plugin 0.4.28 → 0.4.29

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "polygraph",
3
- "version": "0.4.28",
3
+ "version": "0.4.29",
4
4
  "description": "AI agent skills and subagents for Polygraph multi-repo coordination",
5
5
  "author": {
6
6
  "name": "Narwhal Technologies Inc",
@@ -22,7 +22,7 @@ These tools are available via MCP and CLI. Use whichever is available in your en
22
22
 
23
23
  | MCP Tool | CLI Equivalent | Description |
24
24
  | --- | --- | --- |
25
- | `list_repos` | `polygraph repo list` | Discover candidate repositories with descriptions and graph relationships |
25
+ | `list_repos` | `polygraph repo list` | Discover candidate repositories. |
26
26
  | `start_session` | `polygraph session start --repo <ids>` | Initialize a NEW session with selected repositories. Only use when no `sessionId` was provided. |
27
27
  | `add_repo` | — | Attach repositories to an EXISTING session. Use when `sessionId` was provided and the session has no repos yet, or when the user wants to add more. |
28
28
  | `show_session` | `polygraph session show <id> [--details]` | Get full session details including URL, and use details when session summary, repo IDs, PR URLs, and PR descriptions are needed |
@@ -65,16 +65,22 @@ Call `list_repos` to discover available candidate repositories:
65
65
  list_repos()
66
66
  ```
67
67
 
68
+ `list_repos` accepts these optional parameters; set whichever apply. Refer to the tool schema for each parameter.
69
+
70
+ - `connectedTo`: repo ID, name, or full name (e.g. `nrwl/ocean`); pair with `connectionType`
71
+ - `connectionType`: `directly-upstream` | `directly-downstream` | `directly-both` (default) | `upstream` | `downstream` | `both`
72
+ - `publishedPackages`, `consumedPackages`, `publishedApis`, `consumedApis`: arrays of package names / API paths
73
+ - `nameFilter`: array of repo name patterns (e.g. `nrwl/*`)
74
+ - `semanticQuery`: free-text description of the repositories you want
75
+
68
76
  This returns:
69
77
 
70
- - **`initiator`**: The current repository, or `null` if not running from a specific repo
71
- - **`candidates`**: Candidate account repositories, each with:
78
+ - **`repos`**: Candidate account repositories, each with:
72
79
  - `id`: Repository ID
73
80
  - `name`: Repository name
81
+ - `repository`: Full repo name (e.g., `org/repo`)
82
+ - `provider`: VCS provider (e.g., `GITHUB`)
74
83
  - `description`: AI-generated description of what the repository does (may be null)
75
- - `vcsConfiguration.repositoryFullName`: Full repo name (e.g., `org/repo`)
76
- - `graphRelationship`: How this repository relates to the initiator (`distance`, `direction`, `path`), or `null` if the repository is not in the dependency graph. When `initiator` is null, `graphRelationship` will be null for all candidates.
77
- - **`dependencyGraph`**: Graph of repository dependency `edges` (always available, independent of initiator)
78
84
 
79
85
  ### Step 2: Select Relevant Repos
80
86
 
@@ -84,14 +90,11 @@ If `selectedRepoIds` or exact repo refs were provided by the main agent, use tho
84
90
 
85
91
  Otherwise, analyze the candidates using the `userContext` to determine which repos are relevant:
86
92
 
87
- 1. Read each candidate's `description` and `graphRelationship`
88
- 2. Match against the `userContext` consider:
89
- - Repository descriptions that mention relevant functionality
90
- - Graph relationships (closer repos are more likely relevant); note that `graphRelationship` may be `null` for repositories not in the dependency graph — use their `description` to assess relevance
91
- - When `graphRelationship` is null for all candidates (no initiator), rely on `description` fields and the raw `dependencyGraph` edges for selection instead
92
- - Direction (upstream/downstream based on the nature of the change)
93
- 3. Select only the repos that are clearly relevant to the task
94
- 4. If uncertain which repos are relevant, include all candidates (safe default)
93
+ 1. Read each repo's `description`
94
+ 2. Match repo descriptions against the `userContext` to identify relevant repos
95
+ 3. Select the repos that are relevant to the task
96
+ 4. When uncertain, include all candidates
97
+ 5. When the user described the task in natural language and the result is large, re-query with `semanticQuery` set to that description
95
98
 
96
99
  ### Step 3: Initialize Polygraph Session or Attach Repos
97
100
 
@@ -147,11 +150,6 @@ Return a structured summary in this format:
147
150
  | Repo | Repository ID | Description | Selected |
148
151
  | --- | --- | --- | --- |
149
152
  | REPO_FULL_NAME | REPOSITORY_ID | DESCRIPTION | Yes/No |
150
-
151
- ### Initiator
152
- (Only include this section if `list_repos` was called and `initiator` is non-null)
153
- - **Name:** <initiator name>
154
- - **Repo:** <initiator repo full name>
155
153
  ```
156
154
 
157
155
  ## Important Notes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@polygraph/claude-plugin",
3
- "version": "0.4.28",
3
+ "version": "0.4.29",
4
4
  "description": "AI agent skills and subagents for Polygraph multi-repo coordination",
5
5
  "license": "UNLICENSED",
6
6
  "private": false,
@@ -21,7 +21,7 @@ Polygraph functionality is available via both MCP tools and CLI commands. Use wh
21
21
 
22
22
  | MCP Tool | CLI Equivalent | Description |
23
23
  | --- | --- | --- |
24
- | `list_repos` | `polygraph repo list` | Discover candidate repositories with descriptions and graph relationships |
24
+ | `list_repos` | `polygraph repo list` | Discover candidate repositories. |
25
25
  | `start_session` | `polygraph session start --repo <ids>` | Initialize a Polygraph session with selected repositories |
26
26
  | `spawn_agent` | — | Start a new child task or send a follow-up to an active task in another repository. Input: `{ sessionId, repo, instruction, context? }`. Output: `{ taskId, message, status: 'delegated' }`. Follow-up routing is automatic: if the repo already has an active child task, the instruction is delivered to it as a follow-up message; otherwise a new child run starts. A repo has at most one active child at a time. A session resume or reconstruction is read-only context restoration; after resuming, do not use `spawn_agent` to continue changes unless the user explicitly asks for changes. |
27
27
  | `show_agent` | — | Poll flat per-child status for the session. Output: `{ children: PolygraphChildStatusItem[] }` where each item exposes `repositoryId`, `repoFullName`, `status`, `lastOutputLines`, `durationMs`, `instruction`, `agentType?`, `inputRequiredQuestion?`. `status` is an AcpRunStatus: `'created' \| 'in-progress' \| 'input-required' \| 'permission-required' \| 'completed' \| 'failed' \| 'cancelled'` (British double-L on `'cancelled'`). `inputRequiredQuestion` is populated only when `status === 'input-required'`. |