-
Notifications
You must be signed in to change notification settings - Fork 40
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
Getting Started code not runnable #162
Comments
Thank you for pointing out the missing import in the documentation, this will be addressed in the next release. I just tried the same example from quick-start with that import added in and it seems to be working fine. Could you share the versions of the library and dependencies you are using? Code tried -
Output (with debug logs enabled) -
Note: You need to await the add loader commands for it to complete. They are async functions. |
This issue is stale because it has been open for 14 days with no activity. |
🐛 Describe the bug
First, SIMPLE_MODEL is not properly imported in the given starter code.
Second, I'm having an issue to run addLoader function in paid model section. The error message is shown below.
Argument of type 'WebLoader' is not assignable to parameter of type 'BaseLoader<Record<string, string | number | boolean>, Record<string, unknown>>'.
The types returned by 'getUnfilteredChunks().next(...)' are incompatible between these types.
Type 'Promise<IteratorResult<{ pageContent: string; metadata: { type: "WebLoader"; source: string | undefined; }; }, void>>' is not assignable to type 'Promise<IteratorResult<UnfilteredLoaderChunk<Record<string, string | number | boolean>>, void>>'.
Type 'IteratorResult<{ pageContent: string; metadata: { type: "WebLoader"; source: string | undefined; }; }, void>' is not assignable to type 'IteratorResult<UnfilteredLoaderChunk<Record<string, string | number | boolean>>, void>'.
Type 'IteratorYieldResult<{ pageContent: string; metadata: { type: "WebLoader"; source: string | undefined; }; }>' is not assignable to type 'IteratorResult<UnfilteredLoaderChunk<Record<string, string | number | boolean>>, void>'.
Type 'IteratorYieldResult<{ pageContent: string; metadata: { type: "WebLoader"; source: string | undefined; }; }>' is not assignable to type 'IteratorYieldResult<UnfilteredLoaderChunk<Record<string, string | number | boolean>>>'.
Type '{ pageContent: string; metadata: { type: "WebLoader"; source: string | undefined; }; }' is not assignable to type 'UnfilteredLoaderChunk<Record<string, string | number | boolean>>'.
Types of property 'metadata' are incompatible.
Type '{ type: "WebLoader"; source: string | undefined; }' is not assignable to type 'LoaderMetadata<Record<string, string | number | boolean>>'.
Type '{ type: "WebLoader"; source: string | undefined; }' is not assignable to type 'Record<string, string | number | boolean>'.
Property 'source' is incompatible with index signature.
Type 'string | undefined' is not assignable to type 'string | number | boolean'.
Type 'undefined' is not assignable to type 'string | number | boolean'.ts(2345)
The text was updated successfully, but these errors were encountered: