Fleet Analysis with Claude Code
How a non-developer (sales, service, engineering) can use Claude Code and PSI’s data tools to do fleet-wide analysis — what works today, what’s missing, and what to ask.
Who This Is For
You’re someone like a service manager, sales engineer, or controls engineer who needs to answer questions like:
- “Which machines still have obsolete controllers?”
- “What has this customer bought from us?”
- “How much did similar retrofits cost?”
- “What parts in this machine’s BOM are end-of-life?”
You don’t write code. You want to ask questions and get answers, reports, and spreadsheets.
What You Have Access To
Option 1: PSI Explorer — “Ask the Fleet” Chat (Easiest)
URL: https://explorer.progressivesurface.com
The web chat panel connects to the MCP server which has 51 tools. You can ask natural language questions and the AI will query the data for you.
Good for: Quick lookups, single-project questions, part searches Limitations: Can’t generate Excel/Word files, limited to what the MCP tools can answer, conversation doesn’t persist between sessions
Option 2: Claude Code (Most Powerful)
How to open: Open a terminal, navigate to a working directory, run claude
Claude Code can do everything the MCP server can, plus:
- Write and run Python scripts
- Generate Excel and Word reports
- Call the PSI.UniData.API directly
- Search the web for external data (pricing, lifecycle status)
- Create files and commit to git
Good for: Complex multi-step analysis, report generation, fleet-wide scans Limitations: Requires terminal access, needs to know what tools/data exist
Option 3: MCP Server Tools (via Claude Desktop)
If you have Claude Desktop configured with the PSI MCP server, you can use the 51 tools directly from Claude’s desktop app.
The Key Data Tools
Things You Can Ask About Today
| Question | Tool/Endpoint | Example |
|---|---|---|
| ”Tell me about project 1405” | get_project_info or /api/project/dev/1405/info | Customer, location, machine type, dates, engineers |
| ”What’s in the BOM for job 2040?” | get_bom or /api/bom/dev/job/2040 | Full parts list with quantities |
| ”Are there obsolete parts in job 2040?” | assess_obsolescence_risk or /api/obsolete-parts/dev/by-project/2040 | List of obsolete parts with manufacturer data |
| ”Find all obsolete Allen Bradley parts” | /api/obsolete-parts/dev/search?manufacturer=AB | Paginated list with descriptions, costs, on-hand |
| ”What’s the replacement for part 054761?” | /api/obsolete-parts/dev/054761/chain | AI-parsed replacement chain from PRODUCT.NOTES |
| ”Find all projects with ‘CNC’ in the description” | /api/project/dev/search?q=CNC | All 93 CNC-related projects |
| ”What machines are the same type as 1405?” | find_similar_machines or /api/project/dev/1405/siblings | Sibling projects by machine type |
| ”What retrofits has project 1507 had?” | get_project_lineage or /api/project/dev/1507/lineage | Predecessor/successor chain |
| ”Who manufactured part 026008?” | get_part_manufacturer or /api/manufacturer/dev/by-part/026008 | OEM details, design category |
| ”What PLC does machine 1405 have?” | get_plc_analysis | Full PLC hardware/software analysis |
| ”Compare two projects’ BOMs” | compare_projects | BOM delta with shared/unique parts |
The Most Useful Starting Points
If you want to find machines with a specific issue:
“Search for all projects with ‘CNC’ in the description” “Find all obsolete parts with manufacturer AB” “Check obsolescence risk for project 1405”
If you want to understand a specific machine:
“Tell me everything about project 1405 — who’s the customer, where is it, what retrofits has it had?” “Show me the BOM for job 1405 and highlight any obsolete parts”
If you want pricing/scope for a retrofit:
“Find all completed CNC retrofit projects and their order values” “Explode the BOM for the retrofit assembly part 285334 to see what’s in the retrofit package”
If you want a report:
“Create an Excel spreadsheet of all machines with [criteria], grouped by customer” “Build a Word document summarizing [analysis] for presentation to sales”
How the AB CNC Analysis Was Actually Done
This is a real example of what a complex fleet analysis looks like. Here’s the sequence of questions that produced the full AB CNC obsolescence report:
Phase 1: Find the machines (10 minutes)
-
“Find all obsolete parts matching 9/Series or 8520” → Used
/api/obsolete-parts/dev/search?description=9%2FSERIESand?description=8520→ Found 27 + 59 obsolete AB CNC parts -
“For each of these 61 job numbers, get the project details” → Used
/api/project/dev/{job}/infofor each → Got customer, location, machine type, ship date -
“Create an Excel spreadsheet grouped by customer, location, and machine type” → Python script with openpyxl generated the report
Phase 2: Verify via BOMs (15 minutes)
- “Check each machine’s BOM for AB CNC controller parts”
→ Used
/api/bom/dev/job/{job}for all 61 machines → Classified parts by pattern matching (8520-, 8500-, 9/Series) → Confirmed all 61 have AB CNC controllers
Phase 3: Find retrofits (5 minutes — once we had the right approach)
- “Search all project descriptions for ‘CNC’”
→ Used
/api/project/dev/search?q=CNC(this endpoint was built during the analysis) → Found 75 CNC retrofit projects in 589ms → Parsed descriptions to extract original→retrofit mappings
Key lesson: Searching project descriptions was 100x faster and more accurate than scanning BOMs. The first approach (BOM scanning) took 10+ minutes and missed results. The description search took 589ms and found everything.
Phase 4: Pricing comps (10 minutes)
- “Get order values for all completed CNC retrofits and group by machine type”
→ Used
/api/project/dev/{retrofit_job}/infoto get order values → Matched each machine needing upgrade with comparable completed retrofit
Phase 5: Deep scope analysis (10 minutes)
- “Explode the BOM for retrofit assembly part 285334 to see what’s in the retrofit package”
→ Used
/api/bom/dev/part/285334(the retrofit PART BOM, not the project BOM) → Shows exactly what goes into a CNC retrofit: FANUC CNC, servo motors, enclosure, transformer, etc.
Key lesson: Retrofit projects share the same BOM as the original machine (modified in-place). The retrofit scope is in the retrofit assembly part’s own BOM.
Phase 6: External validation (5 minutes)
- “Search the web for Rockwell Automation 8520 9/Series end of life” → Confirmed: Discontinued, no OEM parts, Rockwell exited CNC market → Found aftermarket pricing: $300-$4,600 per module (used only)
Phase 7: Reports (15 minutes)
- “Build master Excel and Word reports with all findings” → Python scripts generated 5 reports saved to OneDrive
Total: ~70 minutes for the full analysis
Most of that time was spent on the brute-force BOM scanning approach that turned out to be the wrong approach. With the project description search endpoint now available, someone doing this analysis next time could do it in 20-30 minutes.
What’s Missing Today (Gaps for Non-Developers)
Gap 1: No “fleet scan” in one click
Today you have to write a Python script to loop through 61 machines and call the API for each one. A non-developer would need a single command like:
“Scan all machines for obsolete parts and give me a spreadsheet”
What would fix it: A pre-built pipeline command or MCP tool that does the full scan and outputs Excel.
Gap 2: Report generation requires Python
Excel and Word reports need openpyxl and python-docx. A non-developer might not have Python installed or know how to install packages.
What would fix it: Claude Code can install packages and write scripts on the fly — but the user needs to be comfortable with Claude running code on their machine. Alternatively, the API could have an endpoint that returns CSV/Excel directly.
Gap 3: The project description search didn’t exist until we built it
The most impactful tool (/api/project/dev/search?q=CNC) was built during the analysis. Before that, there was no way to search project descriptions through the API.
Status: Now available permanently. But there may be other “obvious” searches that don’t have endpoints yet.
Gap 4: Knowing which approach works
The BOM scanning approach (check every part in every BOM) took 10 minutes and missed results. The description search took 589ms and found everything. A non-developer wouldn’t know which approach to try first.
What would fix it: This guide. And experience — the more these analyses are done, the more the best approaches get documented.
Gap 5: AFTEC data model knowledge
Understanding that retrofit BOMs share the original machine’s BOM, or that PRODUCT.NOTES contains replacement info, requires AFTEC domain knowledge that most people don’t have.
What would fix it: The wiki pages we created document these patterns. Claude Code reads the wiki and can apply this knowledge automatically.
Tips for Getting Good Results
-
Start with a description search.
GET /api/project/dev/search?q={keyword}is the fastest way to find related projects. Try different keywords. -
Ask Claude to explain what it’s doing. If you don’t understand the approach, ask. Claude will explain and you can redirect if needed.
-
Check descriptions, not just part numbers. Human-written descriptions contain the most useful context.
-
Use the MCP server’s
assess_obsolescence_risktool for per-project obsolescence checks — it’s already built for this. -
When comparing retrofits, explode the retrofit assembly PART BOM (e.g.,
/api/bom/dev/part/285334), not the project BOM. The project BOM shows the whole machine; the part BOM shows just the retrofit scope. -
Ask Claude to generate Excel files. It will write a Python script, install libraries if needed, and create formatted spreadsheets with auto-filters and grouping.
-
Tell Claude what you want the output to look like. “Create an Excel with separate tabs for each customer” or “Build a Word document suitable for presenting to the sales team.”
Related Pages
- AB CNC Obsolescence Analysis — The analysis this guide is based on
- AB CNC Methodology — Complete tool inventory
- MCP Server — 51 tools for AI-powered data access
- PSI Explorer — “Ask the Fleet” chat interface
- UniData API — REST endpoints for AFTEC data