Model Parameter Values by LLM in NetSuite 2026.1
Updated for NetSuite 2026.1, featuring expanded support for LLM customization.
FEATURE: Model Parameter Values by LLM in NetSuite 2026.1 CATEGORY: SuiteScript
Starting in NetSuite 2026.1, the SuiteScript 2.1 N/llm module introduces the ability to customize responses from large language models (LLMs), particularly the Cohere Command A model (cohere.command-a-03-2025). By providing specific model parameter values, developers can influence the characteristics of generated responses, such as creativity and precision. This feature is essential for enhancing user interactions and automating complex tasks effectively.
Key Features of N/llm Module
The N/llm module makes use of the following methods that accept model parameter values:
llm.generateText(options)llm.generateText.promise(options)llm.generateTextStreamed(options)llm.generateTextStreamed.promise(options)
Customizing Model Responses
By adjusting model parameters, developers can tailor how the LLM responds:
- Temperature: Affects creativity; higher values lead to more diverse outputs. The accepted range is between 0 and 1 with a default of 0.2.
- Max Tokens: Defines the maximum number of tokens in the response (1 - 4,000, default: 2,000). Average tokens per word are approximately 3 (or about 4 characters per token).
- Frequency Penalty: Deters frequent token appearances (0 - 1, default: 0).
- Presence Penalty: Similar to frequency but focuses on new token introduction (0 - 1, default: 0).
- Top K: Limits selections from among the top K tokens (0 - 500, default: 500).
- Top P: Controls cumulative probability for token selection (0 - 1, default: 0.7).
Example Syntax
Here's a basic example of using the llm.generateText.promise() method:
llm.generateText.promise({
prompt: "What are the benefits of using LLM in business?",
modelParameters: {
maxTokens: 150,
temperature: 0.5,
topK: 100,
topP: 0.9,
frequencyPenalty: 0.1,
presencePenalty: 0
}
});
Supported Features and Governance
This module is available for server scripts and requires a governance limit of 100.
Who This Affects
This new feature primarily impacts the following roles in NetSuite:
- Developers: Customizing LLM functionalities in applications.
- NetSuite Administrators: Managing LLM configurations and usage.
- Data Analysts: Utilizing tailored responses for analytical objectives.
Key Takeaways
- The new N/llm module allows for custom model responses in NetSuite 2026.1.
- Key parameters like temperature and tokens can be adjusted to suit specific use cases.
- The module supports various methods for generating and streaming text, enhancing application versatility.
- Ideal for developers looking to implement generative AI solutions in business processes.
- Understanding parameter effects can lead to significantly improved user interactions.
Version History
- 2024.1: Introduced the N/llm module with support for customization of responses and model parameters.
- 2025.1: Added support for the Cohere Command A model and extended capabilities for input handling.
- 2026.1: The N/llm module now officially supports the Cohere Command A model (cohere.command-a-03-2025) and reinforces customization options for developers with detailed parameter descriptions.
Frequently Asked Questions (4)
Does the N/llm module in NetSuite 2026.1 support customization of model responses for both server scripts and client scripts?
What are the default values for the model parameters 'temperature' and 'maxTokens' in the N/llm module?
How does the 'frequencyPenalty' and 'presencePenalty' parameters affect the LLM's generated text?
Is there any specific module support for the Cohere Command A model in NetSuite 2026.1?
Weekly Update History (2)
Updated Model Parameter Values by LLM to include the input token limit for Cohere Command A (256,000 tokens).
View Oracle DocsUpdated Model Parameter Values by LLM to remove interdependency statements for the frequencyPenalty and presencePenalty parameters, which were confusing. This topic has also been moved to appear under N/llm Module instead of under llm.generateText(options).
View Oracle DocsWas this article helpful?