Logotipo de PowerMCP

PowerMCP

Organización
Power-Agent

PowerMCP is an open-source collection of MCP servers for power system software like PowerWorld, PSSE and OpenDSS. These tools enable LLMs to directly interact with power system applications, facilitating intelligent coordination, simulation, and control in the energy domain.

EditorPower-Agent
RepositorioPowerMCP
IdiomaPython
Forks
65
Estrellas
218
Herramientas disponibles
0
Tipo de transportestdio
LicenciaMIT
Enlaces
  • Conecta herramientas a flujos de trabajo con IA

    PowerMCP ofrece funciones MCP que pueden usar los clientes y agentes de IA compatibles.

  • 0 herramientas disponibles

    Explora a continuación las acciones que se pueden invocar, con sus nombres y descripciones cuando el servidor los proporcione.

  • Configuración lista para copiar

    Usa los ejemplos de instalación para configurar este servidor en tu cliente MCP preferido.

  • Indicadores de interés en el código abierto

    218 estrellas y 65 forks en el repositorio enlazado.

PowerMCP ⚡

License: MIT Python Version

PowerMCP is an open-source collection of MCP servers for power system software like PowerWorld and OpenDSS. These tools enable LLMs to directly interact with power system applications, facilitating intelligent coordination, simulation, and control in the energy domain.

🌟 What is MCP?

The Model Context Protocol (MCP) is a revolutionary standard that enables AI applications to seamlessly connect with various external tools. Think of MCP as a universal adapter for AI applications, similar to what USB-C is for physical devices. It provides:

  • Standardized connections to power system software and data sources
  • Secure and efficient data exchange between AI agents and power systems
  • Reusable components for building intelligent power system applications
  • Interoperability between different AI models and power system tools

🤝 Our Community Vision

We're building an open-source community focused on accelerating AI adoption in the power domain through MCP. Our goals are:

  • Collaboration: Bring together power system experts, AI researchers, and software developers
  • Innovation: Create and share MCP servers for various power system software and tools
  • Education: Provide resources and examples for implementing AI in power systems
  • Standardization: Develop best practices for AI integration in the energy sector

🚀 Getting Started with MCP

📖 Quick start

🚀 New to PowerMCP? Start here!

The recommended way to get started is the powermcp package and its installer (see the Installation section below):

bash
pip install powermcp
powermcp install        # pick tools, capture local paths, write your MCP client config

📋 The PowerMCP Tutorial PDF documents the original low-code / manual setup — cloning the repo and hand-editing the Claude Desktop config. It predates the powermcp installer and is not the recommended path; use it only if you specifically want the manual approach.

Video Demos

Check out these demos showcasing PowerMCP in action:

  • Contingency Evaluation Demo: An LLM automatically operates power system software, such as PowerWorld and pandapower, to perform contingency analysis and generate professional reports.

  • Loadgrowth Evaluation Demo: An LLM automatically operates power system software, such as PowerWorld, to evaluate different load growth scenarios and generate professional reports with recommendations.

Useful MCP Tutorials

MCP follows a client-server architecture where:

  • Hosts are LLM applications (like Claude Desktop or IDEs) that initiate connections
  • Clients maintain 1:1 connections with servers, inside the host application
  • Servers provide context, tools, and prompts to clients

Check out these helpful tutorials to get started with MCP:

📦 Installation

PowerMCP installs as a single Python package with an interactive CLI. Python 3.10 through 3.14 is supported.

bash
pip install powermcp

The base install includes the open-source engines that need no extra setup — pandapower, PyPSA, and PowerIO (the cross-server case-conversion substrate). Every other tool is opt-in via an extra:

bash
pip install powermcp[psse]              # add PSS/E support
pip install powermcp[andes,opendss]     # add several tools at once
pip install powermcp[opensource]        # all open-source tools (ANDES, Egret, OpenDSS, surge, HOPE, LTSpice, GenX)
pip install powermcp[all]               # everything (closed-source tools still need the local software)

Set up with the interactive installer

bash
powermcp install

The wizard lets you pick tools (pandapower + PyPSA + PowerIO pre-selected), captures the local install path for any closed-source/EXE-based tools you choose (PSS/E, PSLF, PowerFactory, PSCAD, LTSpice), installs the right extras, and writes the MCP client configuration for Claude Desktop, Claude Code, and the Codex CLI. Use --dry-run to preview the changes, or --yes for a non-interactive core install.

In the interactive picker, move with ↑/↓ and press SPACE to toggle each tool before ENTER (ENTER alone keeps only the preselected tools). Prefer not to use the checkbox? Choose tools directly:

bash
powermcp install --tools psse,andes      # core + the listed tools
powermcp install --all                   # every tool available on this platform

Re-running powermcp install pre-checks the tools you've already installed or configured, so it preserves and updates your setup instead of resetting to the core tools. Paths for tools like LTSpice are auto-detected and pre-filled, so you can usually just press Enter.

CLI commands

CommandDescription
powermcp installSetup wizard — interactive, or --tools <ids> / --all (also --dry-run, --yes, --clients)
powermcp run <tool>Launch a server over stdio (used by the generated client config)
powermcp listList the available tools, extras, and Windows-only flags
powermcp doctorCheck each tool's dependencies and configured paths
powermcp config show / config set <tool>.<key> <path>Inspect / set local software paths

Closed-source / EXE-based tools

These tools wrap commercial or locally-installed software, so PowerMCP stores the local path in ~/.powermcp/config.toml (captured by powermcp install, or set manually with powermcp config set):

ToolConfig keysExample
PSS/Epsse.python_lib, psse.binpowermcp config set psse.python_lib "C:\Program Files\PTI\PSSE36\36.2\PSSPY311"
PSLFpslf.python_libpowermcp config set pslf.python_lib "C:\Program Files\GE PSLF\PSLF_PYTHON"
PowerFactorypowerfactory.python_pathpowermcp config set powerfactory.python_path "...\DIgSILENT\PowerFactory 2024\Python\3.11"
LTSpiceltspice.exe (auto-detected)Found automatically in standard locations — usually no setup needed. Override: powermcp config set ltspice.exe "C:\Program Files\ADI\LTspice\LTspice.exe"
HOPEhope.repo_root, hope.julia_binpowermcp config set hope.repo_root "C:\src\HOPE"
GenXgenx.repo_rootpowermcp config set genx.repo_root "/home/me/GenX.jl" — the GenX.jl checkout; GENX_DIR overrides it
PowerWorld(none)esa auto-discovers a running, licensed Simulator via COM; the powerworld extra also installs numba (required by esa)
PSCAD(none)pip install powermcp[pscad-windows] provides mhi-pscad; PSCAD must be installed

The Codex Desktop app on Windows has been reported to overwrite ~/.codex/config.toml; the Codex CLI is unaffected. If you use both, re-run powermcp install after Desktop edits.

Case compilation between servers (PowerIO)

PowerIO IR is the exchange format of this repository. PowerMCP runs the server shipped in PowerIO 0.11.2 (powermcp run powerio is python -m powerio.mcp); that server parses every grid exchange format, emits every target, summarizes, diagnoses, normalizes, lowers multiconductor networks, and calculates matrices. Its parse tool returns serialized PowerIO IR generation 2 ("schema": "pio-ir", "version": 2), a typed module carrying the electrical value, its provenance and its diagnostics. Every other server here consumes that document: the pandapower, PyPSA, ANDES and Egret adapters turn it into their own model with PowerIO's writers. PowerMCP itself never re-parses, re-validates, or recomputes what PowerIO states; it routes a declared value to a consumer that accepts it and owns only the final step into one simulator.

python
parsed = parse(path="case9.raw")                     # powerio server
ir = parsed["powerio_ir"]
summarize(powerio_ir=ir)
calc_matrix(matrix="ptdf", powerio_ir=ir)            # rows and columns carry bus ids and branch identities
diagnostics(powerio_ir=ir)
import_case_from_json(powerio_ir=ir, output_path="case9.nc")  # PyPSA
load_network_from_json(powerio_ir=ir)                         # pandapower
load_model_from_json(powerio_ir=ir)                           # Egret
load_network_from_json(powerio_ir=ir, out_path="case9.m")     # ANDES
emit(format="psse", destination="case9.raw", powerio_ir=ir)

powerio_ir is the argument every adapter takes; network_json remains an alias for the same document. A ScenarioSet requires scenario_id; a TimeSeries requires time_index; nested collections require both. An operating point entry reaches the solver as the network it states. The operating_point argument remains an alias for time_index.

python
import_case_from_json(
    powerio_ir=ir, output_path="dispatch.nc",
    scenario_id="high-demand", time_index=3,
)

Every adapter response carries the same tail: value_type (the PowerIO structural type that was selected), selection, diagnostics (full PowerIO records with code, severity, target, spans and suggested action) and warnings. The powerio adapters add the emission fidelity (exact_same_format when PowerIO echoed retained source bytes, canonical for fresh output) and the typed edits report described below, because they own the conversion into their own model. The package key keeps the IR context earlier clients read.

Typed edits before a solver import

The powerio adapters accept edits, a JSON list of what-if changes PowerIO applies as typed updates before the conversion. The whole list is validated first, then applied in list order; consecutive updates of one class apply as one atomic batch, and a bus load reallocation sees the values produced by the edits before it. The response reports the changed components, in application order, under edits.

opkeys
set_load_active_powerload, mw, terminal?
set_load_reactive_powerload, mvar, terminal?
set_generator_active_powergenerator, mw, terminal?
set_generator_reactive_powergenerator, mvar, terminal?
set_generator_voltage_magnitudegenerator, vm_pu
set_generator_in_servicegenerator, in_service
set_branch_in_servicebranch, in_service
set_transformer_tap_ratiotransformer, tap_ratio
set_transformer_phase_shifttransformer, shift_degrees
set_switch_closedswitch, closed
set_branch_thermal_ratingbranch, mva, terminal?
set_bus_load_active_powerbus, mw, allocation (proportional_to_current_active_power or equal)

Component ids are the stable identities PowerIO reports (loads:0, branches:3, or the source uid). A bus demand edit names an allocation rule because PowerIO never assigns aggregate demand to an arbitrary load.

python
load_network_from_json(
    powerio_ir=ir,
    edits='[{"op": "set_load_active_power", "load": "loads:0", "mw": 91.5},'
          ' {"op": "set_branch_in_service", "branch": "branches:3", "in_service": false}]',
)

Distribution networks

A multiconductor value is rejected by a balanced solver until the caller asks for the transformation: pass to_balanced=True (and base_mva) and the response carries PowerIO's readiness report under lowering, or call the powerio server's to_balanced_report and to_balanced tools first. Retaining a component does not establish that the selected solver models it. Use emit for a backend that needs files: OpenDSS output is a directory bundle whose master DSS artifact compile_opendss_file accepts; bmopf-json@0.1.0 and bmopf-json@0.2.0 select the BMOPF schema version (the latter writes draft BMOPF 0.2, subject to Task Force approval); geo-json writes a geographic layer.

The retired Package, model-json, package_json and package study_commit formats require migration: re-parse the original case and pass its powerio_ir.

PowerIO MCP paths support local files and file:// URIs. Set POWERIO_MCP_ALLOWED_ROOTS to an os.pathsep separated directory list to constrain the shared path policy. With no root variable set, paths stay beneath the directory the server process started in, which is rarely the directory an operator means. Legacy single-root environment aliases remain supported. Directory inputs check every descendant, and generated directories install from private sibling staging paths. Place POWERMCP_HOME under an allowed root for solver run artifacts. These checks cannot prevent another process from replacing a path after validation.

Running from a clone (without installing)

Every bundled server is still a standalone script. Clone the repo and run any server directly for use in Claude Desktop:

bash
python pandapower/panda_mcp.py
python PSSE/psse_mcp.py          # uses ~/.powermcp/config.toml if present, else legacy default paths
python -m powerio.mcp            # powerio ships its own server; the clone holds no copy

Testing with your LLMs

Note: All MCPs should be tested via an MCP client (Claude Desktop, Claude Code, or Codex) before submitting a PR to ensure consistency.

powermcp install writes the client configuration for you. The generated entries look like the example in config.json. (The PowerMCP Tutorial PDF covers the older manual / low-code setup and isn't needed for the package install.)

📚 Documentation

For detailed documentation about MCP, please visit:

🤝 Contributing

We welcome contributions! Please see our Contributing Guidelines for details.

📄 License

This project is licensed under the MIT License - see the LICENSE file for details.

🙏 Acknowledgments

Core Team

Special Thanks

Usa el MCP de PowerMCP con varios modelos de IA

TypingMind conecta las herramientas MCP a nivel del espacio de trabajo, por lo que, una vez conectado PowerMCP, puedes usarlo con distintos modelos de IA en TypingMind sin tener que configurarlo por separado para cada modelo. Esta integración MCP se ejecuta localmente en tu dispositivo a través del conector MCP de TypingMind.

Guía de configuración para usar el conector local

Usa esta opción si el servidor MCP necesita acceder a archivos locales, aplicaciones o recursos privados de tu ordenador.

1

Abre los ajustes de MCP

En TypingMind, ve a Ajustes, luego a Ajustes avanzados y a Model Context Protocol, y elige Configurar conector.

  1. Abre TypingMind en tu navegador.
  2. Haz clic en el icono de Ajustes.
  3. Ve a Ajustes avanzados.
  4. Abre la sección Model Context Protocol.
  5. Haz clic en Configurar conector y elige Este dispositivo.
Pantalla de configuración del conector MCP de TypingMind con «Este dispositivo» seleccionado
2

Ejecuta el comando del conector

Elige Este dispositivo, copia el comando de TypingMind y ejecútalo en Terminal. Mantén el proceso en ejecución mientras uses MCP.

  1. Copia el comando de configuración que muestra TypingMind.
  2. Abre Terminal en macOS o Windows Terminal en Windows.
  3. Pega y ejecuta el comando.
  4. Acepta la instalación del paquete si Terminal te pide confirmación para continuar.
  5. Mantén el proceso en ejecución en la ventana de Terminal mientras uses las herramientas MCP.
3

Añade PowerMCP como servidor

Cuando el estado del conector sea «Listo», haz clic en «Edita servidores» y pega la configuración del servidor MCP.

  1. Espera hasta que el estado del conector indique «Listo».
  2. Haz clic en Edita servidores.
  3. Pega la configuración del servidor MCP de PowerMCP.
  4. Guarda la lista de servidores.
  5. Actualiza para comprobar que el conector sigue listo.
Ajustes de MCP de TypingMind con un servidor activo y el botón «Edita servidores»
{
  "mcpServers": {
    "powermcp": {
      "command": "npx",
      "args": [
        "-y",
        "<mcp-server-package>"
      ]
    }
  }
}
4

Úsala con distintos modelos

Guarda la lista de servidores, abre Plugins, activa las herramientas MCP de PowerMCP y selecciona cualquier modelo de IA compatible en TypingMind para usar las herramientas en el chat o asignárselas a un agente de IA.

  1. Abre la página Plugins en TypingMind.
  2. Activa las herramientas MCP de PowerMCP.
  3. Inicia un chat y elige el modelo de IA que quieras usar.
  4. Usa las herramientas MCP en el chat o asígnalas a un agente de IA.
  5. Cambia a otro modelo de IA cuando lo necesites sin volver a conectar MCP.
Chat de TypingMind que usa herramientas MCP activadas con un modelo de IA seleccionado
¿Puedes usar PowerMCP para ayudarme con esta tarea?
PowerMCP
Claro. Lo he leído.
Esto he encontrado usando PowerMCP.

Preguntas frecuentes

¿Para qué sirve el servidor MCP PowerMCP?

PowerMCP es un servidor MCP que permite a los clientes de IA compatibles conectarse a herramientas y contexto externos. En TypingMind, basta con añadir este servidor MCP una vez para que sus herramientas estén disponibles en tu espacio de trabajo de IA.

¿Puedo usar el servidor MCP PowerMCP con varios modelos de IA en TypingMind?

Sí. TypingMind conecta las herramientas MCP a nivel del espacio de trabajo, por lo que puedes usar PowerMCP con distintos modelos de IA, como Claude, ChatGPT, Gemini u otros que hayas configurado en TypingMind, sin configurar el servidor MCP por separado para cada modelo.

¿Por qué usar el conector MCP de PowerMCP con TypingMind?

TypingMind es una de las mejores interfaces de chat con LLM porque reúne varios modelos de IA, prompts, plugins, agentes de IA, claves de API y herramientas MCP en un solo espacio de trabajo. Con PowerMCP conectado, puedes usar sus herramientas MCP con tus modelos preferidos y mantener organizado tu flujo de trabajo de chat en TypingMind.

¿Cómo conecto el servidor MCP PowerMCP a TypingMind?

PowerMCP funciona a través del conector MCP local de TypingMind. Es la mejor opción cuando el servidor MCP necesita acceder a archivos locales, aplicaciones de escritorio, herramientas de línea de comandos o recursos privados de tu ordenador.

¿Qué herramientas ofrece el servidor MCP PowerMCP en TypingMind?

PowerMCP ofrece funciones MCP que puedes activar desde la página Plugins de TypingMind y usar en el chat o asignar a agentes de IA.

¿Tengo que compartir mis claves de API con TypingMind para usar el servidor MCP PowerMCP?

No. TypingMind prioriza el funcionamiento local y te permite mantener el control de tus proveedores de modelos, claves de API, prompts y configuración MCP. Si PowerMCP requiere autenticación, añade las cabeceras, los ajustes de OAuth o la configuración local necesarios para ese servidor MCP al crear la conexión.

Servidores MCP relacionados

Ver todos

Crea ya tu propio espacio de trabajo IA

Suscríbete a nuestro boletín para recibir avisos sobre nuevas funciones y próximos sorteos 👇