Skip to content

There can be more than Notion and Miro. AFFiNE(pronounced [ə‘fain]) is a next-gen knowledge base that brings planning, sorting and creating all together. Privacy first, open-source, customizable and ready to use.

feat(server): update search model (#10475)

darkskygit1fd3d618be60
diff --git a/packages/backend/server/src/plugins/copilot/prompt/prompts.ts b/packages/backend/server/src/plugins/copilot/prompt/prompts.ts
index e21a9334f2..0dc0160638 100644
--- a/packages/backend/server/src/plugins/copilot/prompt/prompts.ts
+++ b/packages/backend/server/src/plugins/copilot/prompt/prompts.ts
@@ -982,7 +982,7 @@ When referencing information from the provided documents in your response:
},
{
name: 'Search With AFFiNE AI',
- model: 'sonar',
+ model: 'sonar-reasoning-pro',
messages: [],
},
// use for believer plan
diff --git a/packages/backend/server/src/plugins/copilot/providers/perplexity.ts b/packages/backend/server/src/plugins/copilot/providers/perplexity.ts
index f9ebed93b5..100a75d814 100644
--- a/packages/backend/server/src/plugins/copilot/providers/perplexity.ts
+++ b/packages/backend/server/src/plugins/copilot/providers/perplexity.ts
@@ -187,7 +187,7 @@ export class PerplexityProvider implements CopilotTextToTextProvider {
async generateText(
messages: PromptMessage[],
- model: string = 'llama-3.1-sonar-small-128k-online',
+ model: string = 'sonar',
options: CopilotChatOptions = {}
): Promise<string> {
await this.checkParams({ messages, model, options });
@@ -237,7 +237,7 @@ export class PerplexityProvider implements CopilotTextToTextProvider {
async *generateTextStream(
messages: PromptMessage[],
- model: string = 'llama-3.1-sonar-small-128k-online',
+ model: string = 'sonar',
options: CopilotChatOptions = {}
): AsyncIterable<string> {
await this.checkParams({ messages, model, options });