Skip to content

Commit

Permalink
fix error parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
berkingurcan committed Jun 28, 2024
1 parent 4e80d3f commit 87b49f5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/tools/demoSearch.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ async function formatResults(matches: ScoredPineconeRecord[]) {
async function runTool(args: { query: string }): Promise<string> {
try {
const embeddings = await getEmbeddings(args.query)
const matches = await getMatchesFromEmbeddings(embeddings, 15, VECTOR_TYPE, true)
const matches = await getMatchesFromEmbeddings(embeddings, 15, VECTOR_TYPE, undefined, true)

return formatResults(matches)
} catch (e) {
Expand Down
2 changes: 1 addition & 1 deletion lib/tools/utils/pinecone.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ const getMatchesFromEmbeddings = async (
embeddings: number[],
topK: number,
vector_type: string,
project_name?: string,
isDiscord: boolean = false,
project_name?: string
): Promise<ScoredPineconeRecord<Metadata>[]> => {
const pinecone = new Pinecone({
environment: process.env.PINECONE_ENVIRONMENT as string,
Expand Down

0 comments on commit 87b49f5

Please sign in to comment.