How to Use AI to Analyze Scripts

December 13, 2024
Admin Admin

This article is written for FileMaker developers (or any programmers) about how to use ChatGPT and Lucidchart to analyze a programming script and create a flowchart to diagram the script.

Sometimes we are tasked with discovering what a previous developer did. Often, amateur developers do an inadequate job of commenting and describing their scripts.  So, it can be a time-consuming process to decipher an unlabeled script. But ChatGPT and Lucid Chart working together can speed up the process of analyzing any scripts.

You may wonder what is the Lucid application in ChatGPT, and I did too. So I asked it a question about itself: What is Lucid in ChatGPT?

HPDS employee, Charlie Maitland, wrote these steps for creating and modifying an editable Flowchart created with the ChatGPT and  Lucidchart AI modeler.

Steps to follow:

1. Open your FileMaker solution and print the key functional scripts to a PDF file. (It isn’t possible to select all the commands in a script, copy them, and paste them somewhere else. For some reason, Claris, doesn’t allow this simple, intuitive step. Instead, the script must be exported as a PDF, using the Print command under the File menu, and then copied.)
2. Go to ChatGPT and use the Lucidchart AI model, https://chatgpt.com/g/g-bHwQjRxeg-lucid , sign in
3. Copy the text from any script previously printed to PDF
4. Paste that content into the ChatGPT prompt line
5. The resulting ChatGPT summary will be shown and an edit link will be provided to the LucidChart application.
6. Tweak the process by continuing the conversation with ChatGPT to refine the process
7. Click on the edit link to open LucidChart and login with a free-tier or premium account
8. Begin making changes to the first draft of your diagram. 
9. Save the diagram to a folder or repository as a versioned document so that it can be shared with your team. When completed, it can be exported as a PDF or image file.
10. Build a knowledge base of your business processes – keep them up-to-date

To test this process, I copied this script from the program FREELANCE created by HPDS.

DASHBOARD: ( 248 ) FIND Top Clients

Then an editable flowchart was created with LucidChart.

This looks like an accurate flowchart of the script.

Of course, the real benefit of this AI process is to get a flowchart created of a complicated process that is hard to visualize. This tool could be used to analyze a script that’s been written by someone else. This is a common process for developers who take over a project created by a different person.

Or, you could share this analysis and flowchart with others on your team to work on a project together. The ChatGPT and LUCID modeler provide links to invite others to the project and also also for exporting the flowchart as a graphic to be shared.

Do you have a script or program you’d like analyzed?
Contact HighPower Data Solutions at HighPowerData.com.