Open
Conversation
Otherwise, if no npm install was run before this, it would give
cryptic errors such as:
```
node:internal/modules/run_main:107
triggerUncaughtException(
^
Error [ERR_MODULE_NOT_FOUND]: Cannot find package '@sinclair/typebox' imported from /root/auto-pi-lot/packages/ai/src/index.ts
at Object.getPackageJSONURL (node:internal/modules/package_json_reader:301:9)
at packageResolve (node:internal/modules/esm/resolve:768:81)
at moduleResolve (node:internal/modules/esm/resolve:859:18)
at defaultResolve (node:internal/modules/esm/resolve:991:11)
at nextResolve (node:internal/modules/esm/hooks:785:28)
at resolveBase (file:///root/.npm/_npx/fd45a72a545557e9/node_modules/tsx/dist/esm/index.mjs?1773506629695:2:3744)
at resolveDirectory (file:///root/.npm/_npx/fd45a72a545557e9/node_modules/tsx/dist/esm/index.mjs?1773506629695:2:4243)
at resolveTsPaths (file:///root/.npm/_npx/fd45a72a545557e9/node_modules/tsx/dist/esm/index.mjs?1773506629695:2:4984)
at async resolve (file:///root/.npm/_npx/fd45a72a545557e9/node_modules/tsx/dist/esm/index.mjs?1773506629695:2:5355)
at async nextResolve (node:internal/modules/esm/hooks:785:22) {
code: 'ERR_MODULE_NOT_FOUND'
}
```
Otherwise it would fail with an error like this:
```
node:internal/modules/run_main:107
triggerUncaughtException(
^
Error [ERR_MODULE_NOT_FOUND]: Cannot find module '/root/auto-pi-lotWIP/node_modules/@mariozechner/pi-ai/dist/index.js' imported from /root/auto-pi-lotWIP/packages/coding-agent/src/cli.ts
at finalizeResolution (node:internal/modules/esm/resolve:275:11)
at moduleResolve (node:internal/modules/esm/resolve:865:10)
at defaultResolve (node:internal/modules/esm/resolve:991:11)
at nextResolve (node:internal/modules/esm/hooks:785:28)
at resolveBase (file:///root/.npm/_npx/fd45a72a545557e9/node_modules/tsx/dist/esm/index.mjs?1773566639549:2:3744)
at resolveDirectory (file:///root/.npm/_npx/fd45a72a545557e9/node_modules/tsx/dist/esm/index.mjs?1773566639549:2:4243)
at resolveTsPaths (file:///root/.npm/_npx/fd45a72a545557e9/node_modules/tsx/dist/esm/index.mjs?1773566639549:2:4984)
at resolve (file:///root/.npm/_npx/fd45a72a545557e9/node_modules/tsx/dist/esm/index.mjs?1773566639549:2:5361)
at nextResolve (node:internal/modules/esm/hooks:785:28)
at AsyncLoaderHooksOnLoaderHookWorker.resolve (node:internal/modules/esm/hooks:269:30) {
code: 'ERR_MODULE_NOT_FOUND',
url: 'file:///root/auto-pi-lotWIP/node_modules/@mariozechner/pi-ai/dist/index.js'
}
Node.js v24.14.0
```
Placed models.json in the repo root, but it should go to `~/.pi/agent/` dir. It is configured to read API key from `PPQ_API_KEY` env. var.
Made `generate-models.ts` include PPQ.ai models in the generated models list. Supposedly all auto-generated models should have tool support, but PPQ.ai doesn't provide such information. Also no information if the model is reasoning. That property is set to false for all models.
Otherwise it might give an error such as:
```
packages/coding-agent/src/cli.ts:11:10 - error TS2305: Module '"@mariozechner/pi-ai/bedrock-provider"' has no exported member 'bedrockProviderModule'.
11 import { bedrockProviderModule } from "@mariozechner/pi-ai/bedrock-provider";
~~~~~~~~~~~~~~~~~~~~~
Found 1 error in packages/coding-agent/src/cli.ts:11
```
Which might not be immediately obvious to people that are changing
non TypeScript sources (which don't really need the build to be
checked), e.g. changing docs.
We don't mind that it gets generated on the fly at CI time, and this might help us maintaining this fork.
dc68757 to
ad0861c
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.