Skip to content

Commit

Permalink
Fix for InAnYan#120
Browse files Browse the repository at this point in the history
  • Loading branch information
InAnYan committed Aug 7, 2024
1 parent 79acddf commit 72e90ad
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion src/main/java/org/jabref/gui/preferences/ai/AiTab.fxml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@
<HBox alignment="CENTER_LEFT" spacing="10.0">
<children>
<Label alignment="BASELINE_CENTER" text="%API base URL (used only for LLM)" />
<TextField fx:id="apiBaseUrlTextField" maxWidth="1.7976931348623157E308" HBox.hgrow="ALWAYS" />
<TextField fx:id="apiBaseUrlTextField" disable="true" maxWidth="1.7976931348623157E308" HBox.hgrow="ALWAYS" />
<Button fx:id="apiBaseUrlHelp" prefWidth="20.0" />
</children>
</HBox>
Expand Down
18 changes: 9 additions & 9 deletions src/main/java/org/jabref/gui/preferences/ai/AiTabViewModel.java
Original file line number Diff line number Diff line change
Expand Up @@ -298,21 +298,21 @@ public void storeSettings() {

aiPreferences.setAiProvider(selectedAiProvider.get());

aiPreferences.setOpenAiChatModel(openAiChatModel.get());
aiPreferences.setMistralAiChatModel(mistralAiChatModel.get());
aiPreferences.setHuggingFaceChatModel(huggingFaceChatModel.get());
aiPreferences.setOpenAiChatModel(openAiChatModel.get() == null ? "" : openAiChatModel.get());
aiPreferences.setMistralAiChatModel(mistralAiChatModel.get() == null ? "" : mistralAiChatModel.get());
aiPreferences.setHuggingFaceChatModel(huggingFaceChatModel.get() == null ? "" : huggingFaceChatModel.get());

aiPreferences.setOpenAiApiToken(openAiApiToken.get());
aiPreferences.setMistralAiApiToken(mistralAiApiToken.get());
aiPreferences.setHuggingFaceApiToken(huggingFaceApiToken.get());
aiPreferences.setOpenAiApiToken(openAiApiToken.get() == null ? "" : openAiApiToken.get());
aiPreferences.setMistralAiApiToken(mistralAiApiToken.get() == null ? "" : mistralAiApiToken.get());
aiPreferences.setHuggingFaceApiToken(huggingFaceApiToken.get() == null ? "" : huggingFaceApiToken.get());

aiPreferences.setCustomizeExpertSettings(customizeExpertSettings.get());

aiPreferences.setEmbeddingModel(selectedEmbeddingModel.get());

aiPreferences.setOpenAiApiBaseUrl(openAiApiBaseUrl.get());
aiPreferences.setMistralAiApiBaseUrl(mistralAiApiBaseUrl.get());
aiPreferences.setHuggingFaceApiBaseUrl(huggingFaceApiBaseUrl.get());
aiPreferences.setOpenAiApiBaseUrl(openAiApiBaseUrl.get() == null ? "" : openAiApiBaseUrl.get());
aiPreferences.setMistralAiApiBaseUrl(mistralAiApiBaseUrl.get() == null ? "" : mistralAiApiBaseUrl.get());
aiPreferences.setHuggingFaceApiBaseUrl(huggingFaceApiBaseUrl.get() == null ? "" : huggingFaceApiBaseUrl.get());

aiPreferences.setInstruction(instruction.get());
aiPreferences.setTemperature(temperature.get());
Expand Down

0 comments on commit 72e90ad

Please sign in to comment.