A Fortran Standards MCP Server

Announcing a new tool available for those of you adopting GenAI coding tools. It would violate ISO copyright (I think) for me to distribute a vector database containing the contents of the Fortran Standards directly, but what I can do is give you the tools to create and run your own MCP server on your own machine with whichever revisions of the Fortran standard you have available to you. Instructions are provided for creating the needed vector database from pdfs of the standard, configuring claude code to use the included MCP server, and a skill file to make your agents more efficient at using it. I welcome any feedback or contributions if anybody has them.

8 Likes

I wonder, would it make sense to combine with this project somehow Fortran MCP – Local MCP server providing curated Fortran documentation for AI-assisted development ?

1 Like

Almost certainly.

@everythingfunctional this is excellent. Does it speedup how quickly the AI agent can lookup things?

I’ve been making it search the pdf document directly in Grok and that works, but I notice that every time it searches the pdf, it’s quite slow and sometimes not always precise.

I also tried translating the standards pdf document to Markdown, for an easy search / analysis by AI, but it’s hard too to do that to make the formatting look good.

Do you know if there is a way to also generate the standards document as Markdown (or LaTeX) instead of just a pdf? It could be any of the drafts, not the final product.

1 Like

In a perfect world, the latex source that produces the pdf files would be available publicly, maybe from Overleaf.

2 Likes

You mean like how they do exactly that for C++?

Why doesn’t Fortran do this?

@sblionel, do you know if it would be possible to put the LaTeX sources of the standard online? It seems that ISO allows that if C++ can do it. This would be really helpful so that it’s easier to deal with (both for AI as well as just be able to write various scripts like extracting all intrinsic functions and their signatures, or extracting the grammar etc.). One can do it from the pdf, but it takes longer and it’s not perfect, so requires various fixes, so it adds friction.