Skip to main content
Glama
enkiEng

Fortran Companion MCP Server

by enkiEng

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault

No arguments

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{
  "listChanged": true
}
logging
{}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
extensions
{
  "io.modelcontextprotocol/ui": {}
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
explain_best_practicesA

Returns a comprehensive guide of modern Fortran coding standards, design patterns, and practices.

lint_codeA

Statically analyzes a string of Fortran code for legacy syntax, implicit typing, missing intents, and bad practices.

lint_fileA

Statically analyzes a local Fortran source file for legacy syntax, implicit typing, missing intents, and bad practices.

format_codeB

Auto-formats a string of Fortran code using fprettify to enforce modern indentation and spacing.

format_fileA

Auto-formats a local Fortran file in-place using fprettify to enforce modern indentation and spacing.

initialize_projectA

Initializes a new, modern Fortran project at the specified path. Uses fpm if available, or bootstraps a standard layout with a Makefile.

compile_projectA

Compiles the Fortran project. Automatically detects and runs 'fpm build' or 'make' depending on layout.

run_testsA

Runs tests for the project. Automatically detects and runs 'fpm test' or 'make test' depending on layout.

suggest_design_patternA

Provides boilerplate templates and architectural explanations for modern Fortran design patterns mapping to GoF / Refactoring.Guru.

suggest_refactoringA

Analyzes a block of Fortran code and suggests modern design patterns and refactoring options mapped to Refactoring Guru.

suggest_refactoring_fileA

Analyzes a local Fortran file and suggests modern design patterns and refactoring options mapped to Refactoring Guru.

modernize_fileC

Performs automated syntax replacements to jumpstart modernizing a legacy Fortran file. Updates obsolete operators, converts legacy types, and formats spacing.

verify_regressionA

Runs a legacy binary and a modernized binary, comparing their outputs to verify that the refactoring has no regressions.

rename_legacy_identifiersA

Safely renames legacy variables to descriptive modern names across a file scope. Validates scope rules, renames variables in code while preserving comments, and builds using compiler flags to verify correctness.

convert_common_to_moduleB

Extracts a legacy COMMON block and generates an encapsulated modern Fortran module. Comments out the legacy COMMON statement and inserts matching module imports.

analyze_pure_candidatesA

Scans procedures in a file and identifies subprograms suitable for 'pure' or 'elemental' attributes. Helps promote parallelization, vectorization, and side-effect-free code design.

audit_implicit_interfacesA

Audits the project and lists all subroutine/function calls lacking an explicit interface. Prevents runtime memory crashes and type mismatches.

scaffold_unit_testB

Generates unit testing templates for a specific module procedure. Inspects dummy arguments, intents, and shapes, and registers the test target.

scaffold_hpc_gridB

Bootstraps a modern HPC template for grid/stencil calculations using Coarrays or OpenMP. Sets up stencil iteration loops and ghost cell exchange wrappers.

generate_c_bindingsB

Auto-generates a standard C binding layer module for a modern Fortran module. Maps Fortran types to C-compatible types using iso_c_binding, and generates bind(c) wrapper interfaces.

generate_python_interfaceA

Auto-generates ctypes/numpy binding wrapper scripts for Python integration. Also calls generate_c_bindings first to ensure the C-binding Fortran code is present.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/enkiEng/fortran-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server