Script AI Needs Track Mapping
I need a little guidance with getting the Script AI assistant to do what I need. Maybe I'm not asking correctly so it understands what I want.
I've been trying a while now to get it to change a bunch of soundboard controlCommands I currently have have that are using the old track number format to the new filename format.
For example I want it to change all of these commands in a script from
controlCommand("Dr_Smith", "Track_2")
to
ControlCommand("Dr_Smith", "Play", "Evil purpose.mp3");
I've already waisted 200 credits trying to figure this out. Oddly sometimes the AI will convert the commands like I want but it will only do about 8 out of 50 I have scripted. Other times it will tell me I need to give it the mapping to the file names. I thought this Script AI knew my project? If I provide mapping I could do this replacement myself.
This is kinda frustrating and expensive on waisted credits. Any suggestions on how I can talk to this AI to get it to do what I want?
Below is an example of one of the conversations I've had with the scripting AI assent trying to get it to simply replace my track numbers with the corresponding track names (file names) listed in the soundboard:
You:
replace all Track_# with Play + filename from that soundboard.
AI:
Which function(s) do you want me to update first (e.g., doDr_Smith, doR2D2, etc.), and do you already have the exact filenames for each Track_# in those soundboards?
You:
Update all functions. The exact file names for each track_# are the track titles corsponding to the track_# in thouse soundboards.
AI:
I can update every Track_# to Play "filename" but I need the actual file name for each track number in each soundboard (e.g., Dr_Smith Track_1 = "DrSmith.mp3", Track_2 = "Evil purpose.mp3", etc.).
Can you provide the track-number filename mapping for each soundboard (Dr_Smith, R2D2, Will, Don, Maureen, John, Tufeld, Judy, Wall_e, Penny, Hal9000, Bender, Robby, SFX, Soundboard v4), or confirm you want me to use index-based play (e.g., controlCommand("Dr_Smith", "Play", 1)) instead?
Related Hardware (view all EZB hardware)
Related Robot Skills (view all robot skills)

Yes - what you’re seeing is expected behavior, and the missing piece is not the filename format, it’s that the AI needs explicit track mappings or a better project description to safely rewrite every call.
Why it’s asking for mappings
ARC’s AI assistant can see your project context, but it does not automatically infer every soundboard track name from the old
Track_#calls unless those tracks are clearly described in the skill and the project metadata is rich enough.So when you say:
the AI knows you want a change, but it may not reliably know that Track 2 = "Evil purpose.mp3" unless:
The key limitation
The assistant can rewrite code, but it can’t guess the correct filename for every track number if that mapping is not clearly available to it. That’s why you only get partial conversions or a request for track mapping.
Best way to ask it
Instead of:
use a very specific request like:
Even better, if you want it to succeed in one pass, give it the mapping in a structured way.
Example prompt
That gives the assistant an unambiguous conversion table.
A better workflow to avoid wasting credits
Because you’ve already spent a lot of credits, I’d suggest this approach:
Option 1: Convert one soundboard at a time
Ask it to only update one soundboard name per run:
That reduces ambiguity and lets you verify the pattern before doing the next one.
Option 2: Use a script-aware search/replace yourself
If the filenames are already visible in ARC’s Soundboard skill, it may be faster to:
controlCommand("Dr_Smith", "Track_2")manually with the correctPlaycommandFor large scripts, though, the ARC AI Assistant can still be useful if you feed it the exact mappings.
Important: make the AI assistant work with your project setup
Per the ARC AI Assistant workflow, it helps a lot if you:
That way the assistant has better context when rewriting code.
See:
One more thing: use filename-based Play exactly
For Soundboard (EZB), the filename-based command should look like:
If you want scripts embedded in the audio timeline to run, you’d use the 4-parameter form:
My recommendation
If you want, paste one soundboard’s full track list and I can help you craft the exact prompt that will make the ARC AI Assistant do a clean full conversion without wasting more credits.
Or, if you paste one of your scripts here, I can help you convert the
Track_#calls into a proper JavaScript version using the filename-basedPlaycommands.Where are you asking this question? In the AI Chat Agent or the AI Script Agent?
And, are you asking to edit an existing script? If so, you'd want to use the AI Script Agent (the one in every script editor). It would also help to be a bit more specific. Something like...
Something like that is a bit more specific because otherwise it doesn't really know what you're asking. That's the thing about AI: prompt engineering is super important. Think of the AI as a human person that you're delegating a task to. If you do not provide enough information or correct information, you're not going to get a great result. It takes a bit of getting used to because we're not used to talking to computers like humans hahaha.. Trust me, it took me a while as well! And I'm still getting used to it.
If you find you're not getting a good result and need assistance with the prompt, just post here, and even I, support, or Athena can give a bit of guidance to help format the prompt.
Here's an example....
Prompt...
And result...
@DJ and @Athena, Thanks for the guidance and suggestions. I appreciate the coaching and examples.
To answer your first question, I using the AI Script Agent within the scripting skill that holds the script I am asking to be edited.
I was getting frustrated by my mixed success with getting all my soundboard commands changed over from the old format to the new that include the filename in the command. I don't blame ARC or the AI assistant. I guess like you mentioned, talking to this new AI thing is a learning process. Garbage in Garbage out I guess. Sometimes my request to convert the soundboard commands got the proper results and other times I got a total disaster like the wrong file names being inserted or the AI refusing to even try. Again, my fault I'm sure as I am in the process of trying to communicate with what seems to me to be an alien being. LOL.
Just to be clear why I'm doing this, as I wrote these soundboard scripts in the old formatt I tried to make comments as to the file name it pointed to. However in some of the bigger scripts with lots of commands triggering sound files I got lazy and didn't do it. That's a pain in the butt when I want to go back and do any maintenance. I have over 400 to 500 sound clips in my project being triggered by many different scripts and having the file name right in the command line is so helpful on so many levels.
Here's a partial screenshot of one of the pages in my project holding just a few of the soundboards I have installed holding anywhere from 20 to 100 files:
And here's a snip-it of one of the scripts in the old format that trigger the clips that I'm trying to convert with AI. This one script has over 1000 lines that trigger sound clips in a random pattern that are stored in different soundboards, one soundboard for each character. So you can see why changing these commands manually is a daunting process. I was very excited to let AI give it a try. Note that each one has a sleep() command that lets the robot play the whole clip so it's important to match up the proper file with the timing pause that I had tested and figured out for it.
I did consider using the ControlCommand("Soundboard 2", "Track_Random"); command but most soundboards I have setup have on or two clips I don't want played along with the rest in most animations. I did ask the script Ai to help using this command and it did come back with a useable script.to excluded the ones I didn't want but it did not use the Track_Random command and looked a lot like my current script.
I'll take your advice to heart and try again using more concise language. Thanks again.
Did it work when you asked it using my prompt example?
@DJ, I'll be retrying your suggestions in a little while. I'll keep you posted. Thanks for staying with me on this.
Thing is, big scripts require lots of tokens because they’re hungry. I’d recommend trying only one time and tell me the results.
We have a lot of tools in development to enhance the local AI which haven’t been released yet. I have some ideas that might help your particular question
@DJ, Apologies for the delay getting back to this topic. I did work with your suggestions for hours yesterday but had "life" obligations kick in and I had to stop.
So I had mixed results. I'll try to outline them.
First I backed up my scripts before I started letting AI make changes. Good thing I did.
I used both of your suggested wording for telling the Script AI Assistant how I wanted my commands converted that trigger sound clip files,stored in various soundboards, Your first suggested wording, shown below, did a pretty good job but each command started with "Playfile" instead of controlCommand. When I tried to play any sound clip by triggering the script nothing worked. I had to reinstall my backup script and start over.
Then I used the wording you used to make your successful conversation.you showed above.Take note that I was trying to convert over 800 lines of command lines at once..However all the commands I wanted converted were commands like I posted above, They simply triggered track numbers from different soundboards. That seemed to overwhelm the AI as It only converted about 20 lines and gave up.saying the script was very large and it needed me to give it mapping.if I wanted it to continue and do the rest. It also got confused and mixed up the sleep() delays for each sound clip I had placed in the script to give the clip time to run. I had to go back and retime each clip sleep() command to get the delays correct again. Below is your wording suggestion that seemed to format the conversation properly, even though the AI wouldn't do the whole script and mixed up the sleep() commands. :
Then I decided to try to convert smaller sections of the script, one at a time, to see if the AI could do any better and not get confused or irritated with me asking for too much (reminded me of when my kids were teenagers. LOL). This seemed to work so I started converting one or two Functions at a time.The shorter the script, the cleaner the conversation was. Anything above 100 lines and the AI started making mistakes or seemingly getting confused. Mostly by getting the sleep() commands properly placed.
One more thing. I found out quickly that this kind of work with the AI, especially working with larger scripts, needs to be done in the "Expert" mode.
So, I am pretty much done with converting this one big script. I still need to go back and check some of the AI's work, mostly the sleep() command timing.it screwed up. I do have a few others scripts needing some work but am a bit appreciative to turn the task over to AI. It seems to be just as much work to do it all manually. LOL. In the end I'm glad I tried this as it is worth it to me to have the learning experience. Still, I'm looking forward to seeing where this new tech in ARC goes and how it progresses. You say you guys are still developing this assistant. Knowing the talent you all at Synthiam has, I'm excited to see how it advances. I'm keeping my mind and eyes open. Exciting times, Thanks!