fix settings

pull/4355/head
yann300 11 months ago
parent 91cac87432
commit 21d9904ff0
  1. 14
      libs/remix-ui/settings/src/lib/remix-ui-settings.tsx

@ -436,10 +436,16 @@ export const RemixUiSettings = (props: RemixUiSettingsProps) => {
}
const isCopilotActivated = props.config.get('settings/copilot/suggest/activate') || false
const copilotMaxnewToken = props.config.get('settings/copilot/suggest/max_new_tokens')
if (!copilotMaxnewToken) props.config.set('settings/copilot/suggest/max_new_tokens', 5)
const copilotTemperatureValue = (props.config.get('settings/copilot/suggest/temperature')) * 100
if (!copilotTemperatureValue) props.config.set('settings/copilot/suggest/temperature', 0.5)
let copilotMaxnewToken = props.config.get('settings/copilot/suggest/max_new_tokens')
if (!copilotMaxnewToken) {
props.config.set('settings/copilot/suggest/max_new_tokens', 5)
copilotMaxnewToken = 5
}
let copilotTemperatureValue = (props.config.get('settings/copilot/suggest/temperature')) * 100
if (!copilotTemperatureValue) {
props.config.set('settings/copilot/suggest/temperature', 0.5)
copilotTemperatureValue = 0.5
}
if (isCopilotActivated) props.plugin.call('copilot-suggestion', 'init')
const copilotSettings = () => (

Loading…
Cancel
Save