Not sure which client SDK language you are using, but I have a few examples of setting and overriding the language in an AMS Transform for Audio Analyzer here.
You can first create transform and set it up with a specific default language. Then you can use the presetOverride feature shown here to swap the language code used on a per-job basis if needed.
https://github.com/Azure-Samples/media-services-v3-node-tutorials/blob/40514b6339c6cd9542a9cfdb8aa339da149aca3e/AudioAnalytics/index.ts#L131
Let me know if that is what you had in mind.
UPDATE:
As noted, AMS does not support custom speech models to be defined and used in processing. AMS only supports the built-in speech to text models provided by our speech services team.
You can either continue to use the Video Indexer custom speech support, or you can look at integrating directly with the custom speech API here:
https://learn.microsoft.com/en-us/azure/cognitive-services/speech-service/custom-speech-overview