Improve JSdocs
| @@ -5708,7 +5708,7 @@ function parseAndSaveLogprobs(data, continueFrom) { | |||
| 5708 | /** | 5708 | /** |
| 5709 | * Extracts the message from the response data. | 5709 | * Extracts the message from the response data. |
| 5710 | * @param {object} data Response data | 5710 | * @param {object} data Response data |
| 5711 | * @param {string | null} activeApi if it's set, ignores active API | 5711 | * @param {string} activeApi If it's set, ignores active API |
| 5712 | * @returns {string} Extracted message | 5712 | * @returns {string} Extracted message |
| 5713 | */ | 5713 | */ |
| 5714 | export function extractMessageFromData(data, activeApi = null) { | 5714 | export function extractMessageFromData(data, activeApi = null) { |
| @@ -319,8 +319,9 @@ export function validateTextGenUrl() { | |||
| 319 | } | 319 | } |
| 320 | 320 | ||
| 321 | /** | 321 | /** |
| 322 | * @param {string | null} type if it's set, ignores active API | 322 | * Gets the API URL for the selected text generation type. |
| 323 | * @returns | 323 | * @param {string} type If it's set, ignores active type |
| 324 | * @returns {string} API URL | ||
| 324 | */ | 325 | */ |
| 325 | export function getTextGenServer(type = null) { | 326 | export function getTextGenServer(type = null) { |
| 326 | const selectedType = type ?? settings.type; | 327 | const selectedType = type ?? settings.type; |
| @@ -1221,11 +1222,12 @@ function isDynamicTemperatureSupported() { | |||
| 1221 | } | 1222 | } |
| 1222 | 1223 | ||
| 1223 | /** | 1224 | /** |
| 1224 | * @param {string | null} type if it's set, ignores active API | 1225 | * Gets the number of logprobs to request based on the selected type. |
| 1225 | * @returns {number} | 1226 | * @param {string} type If it's set, ignores active type |
| 1227 | * @returns {number} Number of logprobs to request | ||
| 1226 | */ | 1228 | */ |
| 1227 | export function getLogprobsNumber(type = null) { | 1229 | export function getLogprobsNumber(type = null) { |
| 1228 | const selectedType = type || settings.type; | 1230 | const selectedType = type ?? settings.type; |
| 1229 | if (selectedType === VLLM || selectedType === INFERMATICAI) { | 1231 | if (selectedType === VLLM || selectedType === INFERMATICAI) { |
| 1230 | return 5; | 1232 | return 5; |
| 1231 | } | 1233 | } |