Install And Remove DiagramPilot
Use the package install path for repositories that consume DiagramPilot. Source checkout setup is contributor workflow, not the public installation path.
Package installation does not create llms.txt, docs/diagrampilot.md, or
diagrampilot.config.yaml. Those files are not required to use DiagramPilot.
Agents can read https://diagrampilot.com/llms.txt, the public docs,
repository instructions, or other configured context providers instead.
Normal diagrampilot init does not create or update local agent docs or Repo
Workflow Configuration.
diagrampilot init --docs creates or updates the managed local agent docs in
llms.txt and docs/diagrampilot.md.
diagrampilot init --config creates a minimal diagrampilot.config.yaml and
fails with repair guidance when the config already exists.
Use diagrampilot init --docs only when the repository intentionally wants
managed local agent docs checked into the project.
Use diagrampilot init --config only when the repository intentionally wants
Repo Workflow Configuration checked into the project.
Do not copy DiagramPilot public docs into a consuming repository as part of installation. Keep repository docs for project-owned guidance.
Release Status
Section titled “Release Status”DiagramPilot 0.2.0 is the first Public Alpha Release. The install commands
below use the current npm latest release unless a consuming repository pins a
specific package version.
One-Off Use
Section titled “One-Off Use”Run DiagramPilot without adding it to the repository:
npx diagrampilot checknpx diagrampilot validate docs/architecture.dp.yamlnpx diagrampilot render docs/architecture.dp.yaml --out docs/architecture.svgnpx diagrampilot render docs/architecture.dp.yaml --format png --out docs/architecture.pngVerified package-manager equivalents:
pnpm dlx diagrampilot checkyarn dlx diagrampilot checkbunx diagrampilot checkUse one-off commands for quick local checks, demos, or repair loops where the repository should not gain a package dependency.
Repository And CI Use
Section titled “Repository And CI Use”Add DiagramPilot as a dev dependency when the repository should run the same version in scripts and CI:
npm install --save-dev diagrampilotAdd a script to the consuming repository:
{ "scripts": { "diagrams:check": "diagrampilot check" }}Run it in local review and CI after dependencies are installed:
npm run diagrams:checkVerified package-manager equivalents:
pnpm add -D diagrampilotyarn add -D diagrampilotbun add -D diagrampilotKeep the package manager lockfile committed for repeatable repository workflows.
Global Local Use
Section titled “Global Local Use”Install globally only when you want diagrampilot available as a local shell
tool across repositories:
npm install --global diagrampilotdiagrampilot checkPrefer a repository dev dependency for CI and other repeatable workflows.
MCP Client Configuration
Section titled “MCP Client Configuration”MCP support is alpha. DiagramPilot includes a local Model Context Protocol server for MCP clients that can launch stdio commands.
Use the main CLI command when the client can run project binaries:
diagrampilot mcpUse the dedicated package executable when an MCP client expects a direct server command:
diagrampilot-mcpExample client configuration:
{ "mcpServers": { "diagrampilot": { "command": "diagrampilot", "args": ["mcp"] } }}The MCP server exposes read-only resources, Stable ID suggestions, validation,
repo workflow check, export, render, and prompt helpers. Its write tools are
explicit: source creation writes one *.dp.yaml file from structured input, and
repo output generation refreshes configured Derived Artifacts for explicit
scopes.
Package Removal
Section titled “Package Removal”Remove a repository dev dependency with npm:
npm uninstall diagrampilotVerified package-manager equivalents:
pnpm remove diagrampilotyarn remove diagrampilotbun remove diagrampilotRemove a global npm install:
npm uninstall --global diagrampilotOne-off npx, pnpm dlx, yarn dlx, and bunx usage does not add a project
dependency to uninstall.
Repository Cleanup
Section titled “Repository Cleanup”Package uninstall removes the package dependency. It does not remove repository content that DiagramPilot created or that the project adopted.
If an earlier diagrampilot init run added support sections, remove only the
managed section between these markers from llms.txt and
docs/diagrampilot.md:
<!-- diagrampilot:init:start --><!-- diagrampilot:init:end -->Delete llms.txt or docs/diagrampilot.md only if DiagramPilot created the
file and it contains no other project content.
Do not delete adopted *.dp.yaml, SVG, Mermaid, D2, DOT, PNG, or Markdown
embed artifacts by default. Once a repository uses those files for its
architecture docs, they are project-owned source and derived artifacts. Legacy
*.dp.json source files are not supported by current DiagramPilot commands;
convert them to *.dp.yaml instead of deleting project-owned content during
package cleanup.