r/mainframe • • 11d ago

Claude prompts for mainframe code conversion modernization

How would you prompt Claude to analyze a large enterprise dependency graph and
I'm building a Claude Code skill for automation testing for a large modernization program.

Think:
- 100+ applications
- 1,500+ shared backend components/services/SPs
- 5,000+ business use cases
- Multiple business capabilities, products, and customer journeys
- Application chains and service/SP chains
- Lots of shared dependencies and hidden coupling

The challenge is that this is not a hierarchy (Capability → Application → Service). It's a complex graph where a single journey may traverse multiple apps, services, and channels.

I need Claude to:
- Build dependency and impact graphs
- Identify direct, indirect, and transitive dependencies
- Calculate blast radius
- Build business-to-technical traceability
- Find coverage gaps
- Rationalize testing (minimum tests for maximum confidence)
- Avoid hallucinating relationships from incomplete data

Data sources include architecture repositories, Jira/Atlassian application inventories, source code repositories, dependency metadata, and legacy analysis tools.

Has anyone built prompts/agents for:
- Enterprise architecture analysis?
- Modernization programs?
- Dependency mapping?
- Test optimization/rationalization?
- Knowledge graph generation?

Looking for ideas on system prompts, reasoning frameworks, MCP orchestration, and graph-based analysis approaches that worked well at enterprise scale.

0 Upvotes

12 comments sorted by

8

u/mastercoder123 11d ago

First thing i would do is copy it all to make sure the data isnt destroyed if claude goes on a rampage. After that its just gonna be a lot of brainstorming.

-2

u/Agreeable-Oven-476 11d ago

Haha! Second step

4

u/SeriousGrab6233 11d ago

This is a lot more than a couple prompts that will magically do this and if you think your gonna be able to just hand it off to claude and have it modernize everything i guarantee its not going to work

0

u/Agreeable-Oven-476 11d ago

I am just focusing on analyzing, no modernization

5

u/CLopes1987 11d ago

That's the neat part. You dont!

0

u/No_Specialist_5493 11d ago

Check out wndsoftware’s terminal emulator (wndsoftware.com). It has MCP connectivity to connect the terminal into Claude or ChatGPT. By defaulr, ai can only use arrow keys, but it’s easy enough to set up navigation. Then AI can look through the app at the terminal level and get a better understanding of how it works to be able to modernize. not sure of your use case, but it could speed things up. Their free version may work for this, but not sure.

1

u/Agreeable-Oven-476 11d ago

Let me check that and it’s feasibility

1

u/LuckyRaptor21 10d ago

Can Claude access =3.4 using just arrow keys?

1

u/QPGMR_de 10d ago

Is it really "Mainframe" - aka IBM z? Or are we talking about IBM i?

In both cases it's probably better to start with IBM Bob and the respective Premium Package for the platform. It's not cheap, but you probably don't need it so long, but both packages have "mechanical" support to generate context for your modernization efforts.

They can build dependency graphs of your application without using AI as this is part of the OS (IBM i) or can be simply done by normal source analytics.

An AI is not the best solution to build dependency graphs and such things. They can do it - but it's not a 100% sure thing.

So if you don't want the IBM Bob way - let Claude create a program, that analyzes the dependencies and stores them in a database. Then let Claude write a program that takes this database and creates a Mermaid source for the diagram.

This diagram can then be context for your analytics - as AI is more comfortable with text.

2

u/Ihaveaboot 10d ago

It's not cheap

BobCoin street value is around 50c/coin, not including the licensing fee for the Z architect agent option.

For perspective, I did a trial POC to convert one of my shops simplest batch jos from COBOL/JCL to AWS ready Python. I used 400 coins, or USD $200. That's 1 out of thousands of jobs in our cycles, and doesn't even touch CICS..

Don't get me wrong, it was a very impressive tool. And, I am a newb who probably made non-optimal requests to the tool. But my original impression is that the cost seems staggering for an endeavor thay may or may not succeed.

1

u/QPGMR_de 10d ago

Yes - Bobcoins are expensive - but e.g. the "Understand Dashboard" of Bob Premium for i doesn't use a single Bobcoin to generate all program/file/procedure dependencies as context.

I don't know if the IBM z premium package has something similar.

It not - I would try to create a program that finds those dependencies - AI can generate this quickly. Then run this program (not the AI) to generate the context for the AI runs. So AI doesn't have to read thousands of sources just to find out that program AB123XYZ is called 3 times.

Dependencies on IBM z and i are more or less a mechanical task - not an AI task.