|
<< Click to Display Table of Contents >> Navigation: 3. Script Language > AI - Artificial Intelligence Commands > LMS. - LM-Studio Commands > LMS. - LM Studio Interface |
MiniRobotLanguage (MRL)
LMS.SetURL Command
Sets the Chat Completions API URL
Intention
This command sets the specific URL endpoint for sending "chat completions" requests (i.e., LMS.ask commands).
By default, this is set to http://localhost:1234/v1/chat/completions. You should only use this command if your LM Studio server is running on a different port, a different machine on your network, or behind a reverse proxy.
If you omit the parameter, the URL is reset to the default value.
Syntax
LMS.SetURL|[P1]
Parameter Explanation
P1 - (Optional) The full URL string for the chat completions API. If omitted, resets to the default.
Example
'**********************************************
' LMS.seturl - Sample
'**********************************************
'
' Set to a server running on a different port (e.g., 8000)
LMS.seturl|http://localhost:8000/v1/chat/completions
'
' Set to a server on another computer on the network
LMS.seturl|http://192.168.1.100:1234/v1/chat/completions
'
' Reset to the default URL
LMS.seturl
ENR.
Remarks
This setting is persistent. It will remain active for all subsequent AI queries until it is changed again.
This command is separate from LMS.setmodelurl, which sets the URL for fetching the *list of models*.
See also:
• LMS.ask
• LMS.Ping - Checks if the LM Studio server is online and reachable.