fix(ai-search): fix linting errors for deployment
Some checks failed
Build & Deploy / 🔍 Prepare (push) Successful in 11s
Build & Deploy / 🧪 QA (push) Successful in 1m30s
Build & Deploy / 🏗️ Build (push) Successful in 6m41s
Build & Deploy / 🚀 Deploy (push) Failing after 11s
Build & Deploy / 🧪 Post-Deploy Verification (push) Has been skipped
Build & Deploy / 🔔 Notify (push) Successful in 2s
Some checks failed
Build & Deploy / 🔍 Prepare (push) Successful in 11s
Build & Deploy / 🧪 QA (push) Successful in 1m30s
Build & Deploy / 🏗️ Build (push) Successful in 6m41s
Build & Deploy / 🚀 Deploy (push) Failing after 11s
Build & Deploy / 🧪 Post-Deploy Verification (push) Has been skipped
Build & Deploy / 🔔 Notify (push) Successful in 2s
This commit is contained in:
@@ -5,7 +5,7 @@ import { z } from 'zod';
|
|||||||
import * as Sentry from '@sentry/nextjs';
|
import * as Sentry from '@sentry/nextjs';
|
||||||
import { generateText } from 'ai';
|
import { generateText } from 'ai';
|
||||||
import { createOpenAI } from '@ai-sdk/openai';
|
import { createOpenAI } from '@ai-sdk/openai';
|
||||||
// @ts-ignore
|
// @ts-expect-error - Local version of @mintel/payload-ai/tools/mcpAdapter might not have types published yet
|
||||||
import { createMcpTools } from '@mintel/payload-ai/tools/mcpAdapter';
|
import { createMcpTools } from '@mintel/payload-ai/tools/mcpAdapter';
|
||||||
|
|
||||||
export const dynamic = 'force-dynamic';
|
export const dynamic = 'force-dynamic';
|
||||||
@@ -180,7 +180,7 @@ ${teamContextStr}
|
|||||||
try {
|
try {
|
||||||
const { tools } = await createMcpTools({
|
const { tools } = await createMcpTools({
|
||||||
name: 'kabelfachmann',
|
name: 'kabelfachmann',
|
||||||
url: mcpUrl
|
url: mcpUrl,
|
||||||
});
|
});
|
||||||
mcpTools = tools;
|
mcpTools = tools;
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
@@ -196,8 +196,8 @@ ${teamContextStr}
|
|||||||
content: typeof m.content === 'string' ? m.content : JSON.stringify(m.content),
|
content: typeof m.content === 'string' ? m.content : JSON.stringify(m.content),
|
||||||
})),
|
})),
|
||||||
tools: mcpTools,
|
tools: mcpTools,
|
||||||
// @ts-ignore
|
// @ts-expect-error - maxSteps might be missing in some versions of generateText types
|
||||||
maxSteps: 3, // Allow the model to call the tool and then respond
|
maxSteps: 5,
|
||||||
temperature: 0.3,
|
temperature: 0.3,
|
||||||
maxTokens: MAX_RESPONSE_TOKENS,
|
maxTokens: MAX_RESPONSE_TOKENS,
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user