pinecone-io / chatbot-demo

278 stars 174 forks source link

[Bug] Missing File: ./embeddings #11

Open josiahbryan opened 1 year ago

josiahbryan commented 1 year ago

Is this a new bug?

Current Behavior

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 |

https://nextjs.org/docs/messages/module-not-found

Expected Behavior

Works

Steps To Reproduce

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 |

https://nextjs.org/docs/messages/module-not-found


### Relevant log output

_No response_

### Environment

```markdown
- **OS**: Mac
- **Language version**: Node 18
- **Pinecone client version**: `"@pinecone-database/pinecone": "^0.1.5",`

Additional Context

Found this demo from: https://www.pinecone.io/learn/javascript-chatbot/

rohitashPrajapati commented 1 year ago

4cecoder mentioned a workaround in BugId #10 fix the import error in chat.tsx './embedded' to './matches'

josiahbryan commented 1 year ago

Oh beautiful, yes that fixes it. There are other problems that make it not work, but at least changing that file import does fix the execution problem in this bug.

On Fri, May 19, 2023, 5:21 AM rohitashPrajapati @.***> wrote:

4cecoder mentioned a workaround in BugId #10 https://github.com/pinecone-io/chatbot-demo/issues/10 fix the import error in chat.tsx './embedded' to './matches'

— Reply to this email directly, view it on GitHub https://github.com/pinecone-io/chatbot-demo/issues/11#issuecomment-1554357478, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABEZELEQZ6HXUAMQFKMDSZ3XG5CSFANCNFSM6AAAAAAYHHI6JM . You are receiving this because you authored the thread.Message ID: @.***>

FrackinFamous commented 1 year ago

Not a work around, just a correction because ./matches imports from matches.ts where the items you are importing comes from. I am still having issues with the Ably Auth setup. I'll mention here if I get it fixed but most likely I am just going to build a NextAuth setup bypassing the need for Ably which I'll also post.