Back to Skills

hpc-runtime-doctor

HeshamFS
Updated Yesterday
3 views
40
3
40
View on GitHub
Designaiapi

About

This Claude Skill diagnoses runtime and scheduler issues for High-Performance Computing (HPC) materials simulations. It analyzes problems like MPI/OpenMP layout, GPU usage, environment modules, and resource mismatches when jobs fail or underperform on a cluster. Use it to get a diagnosis, environment checklist, and a safe retry plan for portability and performance issues.

Quick Install

Claude Code

Recommended
Primary
npx skills add HeshamFS/materials-simulation-skills -a claude-code
Plugin CommandAlternative
/plugin add https://github.com/HeshamFS/materials-simulation-skills
Git CloneAlternative
git clone https://github.com/HeshamFS/materials-simulation-skills.git ~/.claude/skills/hpc-runtime-doctor

Copy and paste this command in Claude Code to install this skill

Documentation

HPC Runtime Doctor

Goal

Turn cluster symptoms into a resource-layout diagnosis, environment checklist, and safe retry plan.

Requirements

  • Python 3.10+
  • No external dependencies
  • Works on Linux, macOS, and Windows

Inputs to Gather

InputDescriptionExample
SchedulerSLURM, PBS, LSF, localslurm
Nodes/tasks/threadsRuntime layout2 nodes, 128 tasks, 2 threads
GPUsGPUs requested4
SymptomsObserved failureoom,killed,slow-gpu
MPI/OpenMP/GPU useParallel modesmpi+openmp+gpu
WalltimeRequested time12:00:00
ScratchWhether scratch is usedtrue

Decision Guidance

  • Check resource layout before changing physics settings.
  • Confirm module/compiler/MPI/CUDA consistency before debugging solver behavior.
  • Treat missing restart files and scratch cleanup as workflow failures, not physics failures.
  • For GPU jobs, confirm the executable was built with the requested accelerator backend.

Script Outputs

scripts/hpc_runtime_doctor.py emits:

  • resource_layout
  • diagnoses
  • environment_checks
  • retry_plan
  • scheduler_notes

Workflow

python3 skills/hpc-deployment/hpc-runtime-doctor/scripts/hpc_runtime_doctor.py \
  --scheduler slurm \
  --nodes 2 \
  --tasks 128 \
  --cpus-per-task 2 \
  --gpus 4 \
  --symptoms oom,slow-gpu \
  --uses-mpi \
  --uses-openmp \
  --uses-gpu \
  --json

Error Handling

Invalid resource counts stop with exit code 2. Unknown symptoms are preserved as custom items for human review.

Limitations

This skill does not query a live scheduler. It diagnoses from the submitted layout and symptoms.

Security

  • Inputs are scalar CLI values and booleans only.
  • The script does not execute scheduler commands or inspect environment variables.
  • The skill uses Bash only to run its bundled script.

References

  • See references/hpc_runtime_patterns.md for scheduler and runtime diagnosis patterns.

Version History

  • 1.0.0: Initial HPC runtime diagnosis skill.

GitHub Repository

HeshamFS/materials-simulation-skills
Path: skills/hpc-deployment/hpc-runtime-doctor
0
agent-skillsagentscli-toolscomputational-sciencellmmaterials-science

Related Skills

executing-plans

Design

Use the executing-plans skill when you have a complete implementation plan to execute in controlled batches with review checkpoints. It loads and critically reviews the plan, then executes tasks in small batches (default 3 tasks) while reporting progress between each batch for architect review. This ensures systematic implementation with built-in quality control checkpoints.

View skill

requesting-code-review

Design

This skill dispatches a code-reviewer subagent to analyze code changes against requirements before proceeding. It should be used after completing tasks, implementing major features, or before merging to main. The review helps catch issues early by comparing the current implementation with the original plan.

View skill

connect-mcp-server

Design

This skill provides a comprehensive guide for developers to connect MCP servers to Claude Code using HTTP, stdio, or SSE transports. It covers installation, configuration, authentication, and security for integrating external services like GitHub, Notion, and custom APIs. Use it when setting up MCP integrations, configuring external tools, or working with Claude's Model Context Protocol.

View skill

web-cli-teleport

Design

This skill helps developers choose between Claude Code Web and CLI interfaces based on task analysis, then enables seamless session teleportation between these environments. It optimizes workflow by managing session state and context when switching between web, CLI, or mobile. Use it for complex projects requiring different tools at various stages.

View skill