GetGenAIPrompt(PromptCode)
Purpose
The GetGenAIPrompt(PromptCode) function retrieves the full assembled prompt text from a PromptManager record.
Syntax
Dim variable As String = GetGenAIPrompt(PromptCode)
Arguments
| Part | Description |
|---|---|
| PromptCode | The code of the PromptManager record from which the prompt text is retrieved.
Note: The PromptCode must match a valid PROMPT_CODE in the FSPROMPTMANAGER table.
|
Return Value
If a valid code is specified in the function, a string containing the assembled prompt text is returned.
If the PromptManager code is empty or an invalid code is specified, an empty string is returned to the function.
Description
The function retrieves the prompt text by combining configured fields in the PromptManager record.
Note:
The PromptManager object is loaded for a specified PromptCode and the prompt text is assembled from these fields, in this order:
- Goal
- Prompt
- SECURITY & TRUST BOUNDARIES (from PROMPT_BOUNDRY)
- OUTPUT CONTRACT (from PROMPT_OUTPUT_CONTRACT)
- NORMALIZATION (from PROMPT_NORMALIZATION)
Example
Dim promptText As String = GetGenAIPrompt("MY_PROMPT")