Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] Module not found error when running 'npm run dev' #8

Open
2 tasks done
raulm090 opened this issue May 17, 2023 · 2 comments
Open
2 tasks done

[Bug] Module not found error when running 'npm run dev' #8

raulm090 opened this issue May 17, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@raulm090
Copy link

Is this a new bug?

  • I believe this is a new bug
  • I have searched the existing issues, and I could not find an existing issue for this bug

Current Behavior

When running 'npm run dev' command in the chatbot-demo project, a "Module not found" error occurs in the file src/pages/api/chat.ts at line 15. The import statement import { Metadata, getMatchesFromEmbeddings } from './embeddings' fails to resolve the './embeddings' module.

Expected Behavior

The import statement should successfully resolve the './embeddings' module and no "Module not found" error should occur.

Steps To Reproduce

  1. Clone the chatbot-demo project from the Pinecone repository.
  2. Run 'npm install' to install dependencies.
  3. Run 'npm run dev' command to start the development server.

Relevant log output

error - ./src/pages/api/chat.ts:15:0
Module not found: Can't resolve './embeddings'
  13 |
  14 | import { ConversationLog } from './conversationLog';
> 15 | import { Metadata, getMatchesFromEmbeddings } from './embeddings';
  16 | import { templates } from './templates';
  17 |
  18 |

Environment

- **OS**: Darwin Kernel Version 21.6.0
- **Language version**: node v19.8.1
- **Pinecone client version**:

Additional Context

No response

@raulm090 raulm090 added the bug Something isn't working label May 17, 2023
@bennkingy
Copy link

Did you work out a fix for this?

@nahumdam
Copy link

@bennkingy i did

as mentioned by another reply, you need to change on the file src\pages\api\chat.ts this:
import { Metadata, getMatchesFromEmbeddings } from './embeddings';

to...
import { Metadata, getMatchesFromEmbeddings } from './matches';

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants