Skip to content

Commit

Permalink
feat: Quick fix.
Browse files Browse the repository at this point in the history
  • Loading branch information
vasilecampeanu committed May 29, 2023
1 parent d460a92 commit adc336c
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 8 deletions.
2 changes: 1 addition & 1 deletion manifest.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"id": "obsidian-weaver",
"name": "Weaver",
"version": "0.5.2",
"version": "0.5.3",
"minAppVersion": "1.0.0",
"description": "Weaver is a useful Obsidian plugin that integrates ChatGPT/GPT-3 into your note-taking workflow. This plugin makes it easy to access AI-generated suggestions and insights within Obsidian, helping you improve your writing and brainstorming process.",
"author": "Vasile Câmpeanu",
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "obsidian-weaver",
"version": "0.5.2",
"version": "0.5.3",
"description": "Weaver is a useful Obsidian plugin that integrates ChatGPT/GPT-3 into your note-taking workflow. This plugin makes it easy to access AI-generated suggestions and insights within Obsidian, helping you improve your writing and brainstorming process.",
"main": "main.js",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion src/components/Conversation/ConversationDialogue.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ export const ConversationDialogue: React.FC<ConversationDialogueProps> = ({
const handleModeChange = async (newMode: string) => {
setActiveMode(newMode as "creative" | "balanced" | "precise");

let systemPromptContent = ""
let systemPromptContent = plugin.settings.systemRolePrompt;

if (newMode === "creative") {
systemPromptContent = plugin.settings.creativeSystemRolePrompt;
Expand Down
2 changes: 1 addition & 1 deletion src/components/Conversation/ConversationMessageBubble.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ export const ConversationMessageBubble: React.FC<ConversationMessageBubbleProps>
return (
message.role === 'info' ? (
<div className="ow-message-info-bubble">
{message.model === "gpt-3.5-turbo" ? (
{((message && message.model) || plugin.settings.engine) === "gpt-3.5-turbo" ? (
<>
<div className="ow-icon">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" strokeLinecap="round" strokeLinejoin="round" className="lucide lucide-zap"><polygon points="13 2 3 14 12 14 11 22 21 10 12 10 13 2"></polygon></svg>
Expand Down
2 changes: 1 addition & 1 deletion src/utils/api/OpenAIRequestFormatter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ export default class OpenAIRequestFormatter {
const bodyParameters: BodyParameters = {
frequency_penalty: parameters.frequencyPenalty,
max_tokens: parameters.maxTokens,
model: conversation.model,
model: conversation.model ? conversation.model : parameters.engine,
temperature: parameters.temperature,
stream: true
};
Expand Down
3 changes: 2 additions & 1 deletion versions.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,6 @@
"0.3.2": "1.0.0",
"0.4.0": "1.0.0",
"0.5.0": "1.0.0",
"0.5.2": "1.0.0"
"0.5.2": "1.0.0",
"0.5.3": "1.0.0"
}

0 comments on commit adc336c

Please sign in to comment.