cohere-ai / cohere-typescript

The Cohere TypeScript SDK
https://docs.cohere.ai
MIT License
127 stars 18 forks source link

Cannot find module 'aws-utils' or its corresponding type declarations. #186

Closed zlederman closed 3 months ago

zlederman commented 4 months ago

Hi! I am trying out the reranker model on node with typescript. Upon installing cohere-ai and building, I get

node_modules/cohere-ai/AwsClient.d.ts:1:26 - error TS2307: Cannot find module 'aws-utils' or its corresponding type declarations.

1 import { AwsProps } from 'aws-utils';
                           ~~~~~~~~~~~

Found 1 error in node_modules/cohere-ai/AwsClient.d.ts:1

Upon changing import { AwsProps } from 'aws-utils'; to import { AwsProps } from './aws-utils'; the error resolves.

For reference this is my tsconfig

{
  "compilerOptions": {
    "module": "commonjs",
    "target": "es6",
    "outDir": "dist",
    "rootDir": ".",
    "sourceMap": true,
    "strict": true,
  }
}
billytrend-cohere commented 3 months ago

Thanks for flagging this @zlederman this should be fixed in 7.11.2 no idea why this didn't get detected in our ci. Will review this!