Skip to content

Commit 6165e4d

Browse files
Josh JurssGitHub Enterprise
authored andcommitted
Update README.md (#7)
* Update README.md * Update README.md * Update README.md remove excess colon
1 parent 656d0cc commit 6165e4d

1 file changed

Lines changed: 53 additions & 73 deletions

File tree

README.md

Lines changed: 53 additions & 73 deletions
Original file line numberDiff line numberDiff line change
@@ -2,31 +2,29 @@
22

33
Run Polyspace® as You Code™ static code analysis on your C/C++ code using AI applications with the official Polyspace Agentic Toolkit from MathWorks®.
44

5-
With the Polyspace MCP Server and its companion skills, you can ask your AI assistant to:
6-
7-
**Polyspace as You Code** — static analysis for C/C++ code:
8-
- **"Make this file compliant with MISRA C:2012"** — run analysis, fix violations, and re-run until the file is clean.
9-
- **"Check that my changes are compliant"** — analyze a modified file and address any new findings.
10-
- **"Fix these findings"** — understand each finding, apply a code fix, and re-run analysis to confirm.
11-
- **"Justify this finding"** — insert a correctly formatted Polyspace annotation comment, optionally using pre-approved texts from a team justification catalog.
12-
- **"Set up MISRA C:2012 checking"** — create or modify the checkers XML file to enable specific coding standards.
13-
- **"Configure build options for my project"** — generate a build options file from a build command or `compile_commands.json`.
14-
- **"What does the `-target` option do?"** — look up documentation for any Polyspace option, checker, or coding rule.
15-
16-
**Polyspace Test™** — unit test generation:
17-
- **"Generate unit tests for this function"** — write tests using the Polyspace XUnit framework (PSTUnit).
5+
## What It Does
6+
The Polyspace Agentic Toolkit gives your agent the knowledge and context to work with Polyspace efficiently. With the Polyspace MCP Server and its companion skills, you can ask your AI assistant to perform Polyspace as You Code and Polyspace Test workflows. For example:
7+
8+
- **"Make this file compliant with `<coding standard>`"** — Run a Polyspace as You Code analysis, fix violations, and re-run analysis until the file is clean.
9+
- **"Check that my changes are compliant"** — Analyze a modified file and address any new findings.
10+
- **"Fix these findings"** — Understand each finding, apply a code fix, and re-run analysis to confirm.
11+
- **"Justify this finding"** — Insert a correctly formatted Polyspace annotation comment, optionally using pre-approved texts from a team justification catalog.
12+
- **"Set up `<coding standard>` checking"** — Create or modify the checkers XML file to enable specific coding standards.
13+
- **"Configure build options for my project"** — Generate a build options file from a build command or `compile_commands.json`.
14+
- **"What does the `-target` option do?"** — Look up documentation for any Polyspace option, checker, or coding rule.
15+
- **"Generate unit tests for this function"** — Write tests using the Polyspace XUnit framework (PSTUnit).
1816

1917
## How It Works
2018

2119
```
2220
+-------------------+
23-
| AI Assistant |
21+
| AI Assistant |
2422
| (Claude, Copilot,|
2523
| Amp, Cursor...) |
2624
+--------+----------+
2725
|
28-
reads skills | calls tools
29-
(markdown) | (MCP protocol)
26+
reads skills | calls tools
27+
(markdown) | (MCP protocol)
3028
|
3129
+----------------------+----------------------+
3230
| |
@@ -43,48 +41,63 @@ With the Polyspace MCP Server and its companion skills, you can ask your AI assi
4341
+------------------+
4442
```
4543

46-
The AI assistant reads **skills** (instructional markdown files) for domain knowledge and calls **MCP tools** for execution. Skills work with or without the MCP server — each skill includes both the MCP tool path and a direct binary fallback.
44+
The AI assistant reads **skills** (instructional markdown files) for domain knowledge and calls **MCP tools** for execution. Skills work with or without the MCP server. Each skill includes both the MCP tool path and a direct binary fallback.
4745

4846
## Supported Platforms
4947

50-
| Agent | Linux | macOS | Windows | Setup |
51-
|-------|-------|-------|---------|-------|
52-
| [Claude Code](https://claude.ai/code) | Yes | Yes | Yes | Automated |
53-
| [GitHub&reg; Copilot](https://github.com/features/copilot) | Yes | Yes | Yes | Automated |
54-
| [OpenAI&reg; Codex](https://openai.com/codex) | Yes | Yes | Yes | Automated |
55-
| [Gemini&trade; CLI](https://github.com/google-gemini/gemini-cli) | Yes | Yes | Yes | Automated |
56-
| [Sourcegraph Amp](https://ampcode.com/) | Yes | Yes | Yes | Automated |
57-
| [Cursor](https://www.cursor.com/) | Yes | Yes | Yes | Automated |
48+
| Agent | Setup |
49+
|-------|-------|
50+
| [Claude Code](https://claude.ai/code) | Automated |
51+
| [GitHub&reg; Copilot](https://github.com/features/copilot) | Automated |
52+
| [OpenAI&reg; Codex](https://openai.com/codex) | Automated |
53+
| [Gemini&trade; CLI](https://github.com/google-gemini/gemini-cli) | Automated |
54+
| [Sourcegraph Amp](https://ampcode.com/) | Automated |
55+
| [Cursor](https://www.cursor.com/) | Automated |
5856

5957
Polyspace as You Code R2026a recommended. Previous versions back to R2024b are supported.
6058

59+
The Polyspace Agentic Toolkit is supported on Linux, macOS, and Windows operating systems.
60+
6161
## Quick Start
6262

6363
**Prerequisites:**
64-
* [Polyspace as You Code](https://www.mathworks.com/products/polyspace.html) R2024b+
64+
* [Polyspace as You Code](https://www.mathworks.com/products/polyspace.html) R2024b or later
6565
* Supported AI coding agent
6666
* Git&trade;
6767

68+
The Polyspace Agentic Toolkit helps you install and configure the Polyspace MCP Core Server, or can be configured to use your existing installation.
69+
6870
### Full Setup (recommended)
6971

72+
Clone the repository to a permanent location.
73+
7074
```
7175
git clone https://github.com/polyspace/polyspace-agentic-toolkit.git
7276
cd polyspace-agentic-toolkit
7377
```
7478

75-
Launch your AI agent and ask: **"Set up the Polyspace Agentic Toolkit"**
79+
Launch your agent from the toolkit directory, and ask it to set up the toolkit.
7680

77-
The agent reads the setup skill, detects your platform, downloads the MCP server binary, registers it with your agent, and installs skills — all automatically.
81+
```
82+
Set up the Polyspace Agentic Toolkit
83+
```
7884

79-
> **Claude Code — no clone required**: If you already have the MCP server binary, add skills directly:
85+
The agent:
86+
* Reads the setup skill
87+
* Detects your platform
88+
* Locates your Polyspace installation
89+
* Downloads and registers the MCP server binary with your agent
90+
* Installs skills from the toolkit
91+
92+
> **Claude Code — no clone required**: If you already have the MCP server binary configured, you can add the skills directly without cloning:
8093
> ```
8194
> claude plugin marketplace add "https://github.com/polyspace/polyspace-agentic-toolkit"
8295
> claude plugin install polyspace-as-you-code@polyspace-agentic-toolkit
8396
> ```
8497
8598
### Already Have the MCP Server Binary?
8699
87-
If you installed the binary manually, you just need skills. Clone this repo and ask your agent: "Set up the Polyspace Agentic Toolkit" — it will skip the download and configure skills only.
100+
If you installed the binary manually, you just need skills. Clone this repo and ask your agent: "Set up the Polyspace Agentic Toolkit" to skip the download and configure skills only.
88101
89102
### Verify
90103
Ask your agent:
@@ -93,9 +106,11 @@ Ask your agent:
93106
Run Polyspace on a sample file and show me the results.
94107
```
95108
109+
The agent searches the current directory for a C or C++ file to run an analysis on. If no file is found, the agent creates a sample file with some existing defects, runs an analysis on the file, and displays Polyspace results.
110+
96111
## MCP Tools
97112
98-
The AI assistant automatically discovers tools via the MCP protocol:
113+
The Polyspace Agentic Toolkit provides the following tools:
99114
100115
| Tool | Description |
101116
| --- | --- |
@@ -113,13 +128,13 @@ Skills are instructional markdown guides in [`skills-catalog/`](skills-catalog/)
113128
114129
| Skill | Description |
115130
| --- | --- |
116-
| [run-analysis](skills-catalog/polyspace-as-you-code/run-analysis/) | Run analysis on a C/C++ source file |
131+
| [run-analysis](skills-catalog/polyspace-as-you-code/run-analysis/) | Run an analysis on a C/C++ source file |
117132
| [fix-findings](skills-catalog/polyspace-as-you-code/fix-findings/) | Understand, fix, or justify findings after analysis |
118-
| [justify-findings](skills-catalog/polyspace-as-you-code/justify-findings/) | Annotation syntax, format rules, and writing guidelines |
133+
| [justify-findings](skills-catalog/polyspace-as-you-code/justify-findings/) | Annotation syntax, formatting, and writing guidelines |
119134
| [query-justification-catalog](skills-catalog/polyspace-as-you-code/query-justification-catalog/) | Catalog JSON schema and matching rules |
120135
| [configure-build-options](skills-catalog/polyspace-as-you-code/configure-build-options/) | Create a build options file |
121136
| [configure-checkers](skills-catalog/polyspace-as-you-code/configure-checkers/) | Create or modify the checkers XML file |
122-
| [find-checker-documentation](skills-catalog/polyspace-as-you-code/find-checker-documentation/) | URL patterns for checker and coding rule documentation |
137+
| [find-checker-documentation](skills-catalog/polyspace-as-you-code/find-checker-documentation/) | Find documentation for defects and coding standards |
123138
| [find-option-documentation](skills-catalog/polyspace-as-you-code/find-option-documentation/) | Find documentation for Polyspace analysis options |
124139
| [documentation-entry-points](skills-catalog/polyspace-as-you-code/documentation-entry-points/) | Top-level Polyspace documentation URLs |
125140
@@ -133,15 +148,15 @@ Skills are instructional markdown guides in [`skills-catalog/`](skills-catalog/)
133148
134149
| Skill | Description |
135150
| --- | --- |
136-
| [polyspace-agentic-toolkit-setup](skills-catalog/polyspace-agentic-toolkit-setup/) | Automated setup for any supported AI agent |
151+
| [polyspace-agentic-toolkit-setup](skills-catalog/polyspace-agentic-toolkit-setup/) | Automated setup for supported AI agents |
137152
138153
## Team Configuration Files
139154
140-
Several Polyspace MCP Server tools accept paths to configuration files that are typically shared across a team or organization. These files can live anywhere accessible to the AI assistant checked into the repository alongside the source code, stored on a shared network drive, or maintained in a central location by your team.
155+
Several Polyspace MCP Server tools accept paths to configuration files that are typically shared across a team or organization. These files can live anywhere accessible to the AI assistant. For example, they can be checked into the repository alongside the source code, stored on a shared network drive, or maintained in a central location by your team.
141156
142157
| File | Used by | Description |
143158
| --- | --- | --- |
144-
| Checkers XML | `run_polyspace_as_you_code`, `configure_checkers_for_polyspace` | Defines which coding standards and checkers are enabled. |
159+
| Checkers XML | `run_polyspace_as_you_code`, `configure_checkers_for_polyspace` | Defines which defects and coding standards are enabled during a Polyspace analysis. |
145160
| Build options file | `run_polyspace_as_you_code`, `configure_build_options_for_polyspace` | Specifies include paths, defines, and compiler settings. |
146161
| Options file | `run_polyspace_as_you_code` | Additional Polyspace as You Code analysis options. |
147162
| Justification catalog | `query_justification_catalog` | Pre-approved justification texts for known findings. |
@@ -175,48 +190,13 @@ Customize the behavior of the server by providing arguments in the `args` array
175190

176191
| Argument | Description | Example |
177192
| ------------- | ------------- | ------------- |
178-
| polyspace-root | Root directory of the Polyspace as You Code installation. If not set, the server auto-discovers the installation from the installer registry (`polyspace_products.prf`). | `"--polyspace-root=/usr/local/Polyspace/R2026a"` |
193+
| polyspace-root | Root directory of the Polyspace as You Code installation. If not set, the server automatically detects the installation from the installer registry (`polyspace_products.prf`). | `"--polyspace-root=/usr/local/Polyspace/R2026a"` |
179194
| log-folder | Directory where server log files are written. | `"--log-folder=/tmp/polyspace-logs"` |
180195
| log-level | Log verbosity level. Default: `info`. | `"--log-level=debug"` |
181196
| disable-telemetry | To disable anonymized data collection, set this argument to `true`. For details, see [Data Collection](#data-collection). | `"--disable-telemetry=true"` |
182197

183198
Arguments can also be set via environment variables: `POLYSPACE_ROOT`.
184199

185-
## Repository Structure
186-
187-
```
188-
polyspace-agentic-toolkit/
189-
├── .agents/plugins/ # Codex marketplace registry
190-
├── .claude-plugin/ # Claude Code marketplace manifest
191-
├── .claude/ # Claude Code project settings
192-
├── .codex-plugin/ # Codex plugin manifest
193-
├── .cursor-plugin/ # Cursor plugin manifest
194-
├── AGENTS.md # Amp agent instructions
195-
├── CLAUDE.md # Claude Code agent instructions
196-
├── README.md # This file
197-
├── gemini-extension.json # Gemini CLI extension metadata
198-
├── scripts/
199-
│ ├── install-global-skills.sh # Symlink skills (Linux/macOS)
200-
│ └── install-global-skills.ps1 # Symlink skills (Windows)
201-
├── skills-catalog/
202-
│ ├── README.md
203-
│ ├── polyspace-as-you-code/ # 9 static analysis skills
204-
│ │ ├── run-analysis/
205-
│ │ ├── fix-findings/
206-
│ │ ├── justify-findings/
207-
│ │ ├── query-justification-catalog/
208-
│ │ ├── configure-build-options/
209-
│ │ ├── configure-checkers/
210-
│ │ ├── find-checker-documentation/
211-
│ │ ├── find-option-documentation/
212-
│ │ └── documentation-entry-points/
213-
│ ├── polyspace-test/ # 1 test generation skill
214-
│ │ └── generate-xunit-tests/
215-
│ │ └── reference/ # C and C++ API docs
216-
│ └── polyspace-agentic-toolkit-setup/ # Setup skill
217-
│ └── reference/ # Per-agent setup guides
218-
```
219-
220200
## Data Collection
221201

222202
The Polyspace MCP Server may collect fully anonymized information about your usage of the server and send it to MathWorks. This data collection helps MathWorks improve products and is on by default. To opt out of data collection, set the argument `--disable-telemetry` to `true`.

0 commit comments

Comments
 (0)