Description
The officially published v0.7.0 release artifact fails at runtime for the amazon-bedrock provider:
Error: Cannot find module '/opt/homebrew/lib/node_modules/prime-agent/dist/bundle/amazon-bedrock.js' imported from
/opt/homebrew/lib/node_modules/prime-agent/dist/bundle/chunk-ALQBG3TN.js
Root cause
dist/bundle/chunk-ALQBG3TN.js dynamically imports the bedrock provider chunk:
bedrockProviderModulePromise ||= importNodeOnlyProvider("./amazon-bedrock.js").then(...)
but dist/bundle/amazon-bedrock.js is not present in the shipped package. Every other provider entry point exists as its own chunk (anthropic-JMWPKDC4.js, google-vertex-SQF6LM63.js, mistral-OBA3N6GZ.js, openai-completions-5PBGGQ35.js, etc.) — only the bedrock one is missing.
This affects both distribution channels, which serve byte-identical artifacts:
- The R2 CDN URL used by
prime-agent update (https://pub-728493de92a943e2a9b2d17b4719f318.r2.dev/releases/v0.7.0/prime-agent-0.7.0.tgz)
- The GitHub release asset
prime-agent-0.7.0.tgz on the v0.7.0 release
Both have SHA256 88b6578518c72cd51a825bc80f28e0fef9a64c67de4a7d6fd7afd7ca1b34da0b, confirming it's the same build, not a corrupted local install.
Likely tie-in to #651
I believe this was caused by the same underlying issue reported in #651: @aws-sdk/core@^3.977.6 did not exist on the npm registry at the time v0.7.0 was built in CI. That issue was closed because the npm package now exists and a fresh npm install succeeds — but the already-published v0.7.0 tarball was never rebuilt/republished, so it still ships without the bedrock bundle chunk. It looks like the build step for that entry point failed silently (e.g. esbuild couldn't resolve the then-missing @aws-sdk/core) without failing the overall build/release.
Note: dist/bun/register-bedrock.js (used by the Bun-based path) is present and looks fine — this appears to be specific to the Node bundle output.
Reproduction
curl -fsSL https://app.primeintellect.ai/prime-agent/install.sh | sh
# settings.json: { "defaultProvider": "amazon-bedrock", ... }
prime-agent
# -> Error: Cannot find module '.../dist/bundle/amazon-bedrock.js'
prime-agent update --force does not help since it re-fetches the same pinned, broken v0.7.0 tarball.
Suggested fix
Rebuild and republish the v0.7.0 tarball (or cut v0.7.1) now that @aws-sdk/core@3.977.6 is available, and add a CI check that fails the build if any provider chunk referenced by chunk-*.js's importNodeOnlyProvider calls is missing from the published dist/bundle/ output.
Environment
- OS: macOS (Apple Silicon, /opt/homebrew)
- Install method:
install.sh / prime-agent update --force
prime-agent --version: 0.7.0
Description
The officially published v0.7.0 release artifact fails at runtime for the
amazon-bedrockprovider:Root cause
dist/bundle/chunk-ALQBG3TN.jsdynamically imports the bedrock provider chunk:but
dist/bundle/amazon-bedrock.jsis not present in the shipped package. Every other provider entry point exists as its own chunk (anthropic-JMWPKDC4.js,google-vertex-SQF6LM63.js,mistral-OBA3N6GZ.js,openai-completions-5PBGGQ35.js, etc.) — only the bedrock one is missing.This affects both distribution channels, which serve byte-identical artifacts:
prime-agent update(https://pub-728493de92a943e2a9b2d17b4719f318.r2.dev/releases/v0.7.0/prime-agent-0.7.0.tgz)prime-agent-0.7.0.tgzon the v0.7.0 releaseBoth have SHA256
88b6578518c72cd51a825bc80f28e0fef9a64c67de4a7d6fd7afd7ca1b34da0b, confirming it's the same build, not a corrupted local install.Likely tie-in to #651
I believe this was caused by the same underlying issue reported in #651:
@aws-sdk/core@^3.977.6did not exist on the npm registry at the time v0.7.0 was built in CI. That issue was closed because the npm package now exists and a freshnpm installsucceeds — but the already-published v0.7.0 tarball was never rebuilt/republished, so it still ships without the bedrock bundle chunk. It looks like the build step for that entry point failed silently (e.g. esbuild couldn't resolve the then-missing@aws-sdk/core) without failing the overall build/release.Note:
dist/bun/register-bedrock.js(used by the Bun-based path) is present and looks fine — this appears to be specific to the Node bundle output.Reproduction
prime-agent update --forcedoes not help since it re-fetches the same pinned, broken v0.7.0 tarball.Suggested fix
Rebuild and republish the v0.7.0 tarball (or cut v0.7.1) now that
@aws-sdk/core@3.977.6is available, and add a CI check that fails the build if any provider chunk referenced bychunk-*.js'simportNodeOnlyProvidercalls is missing from the publisheddist/bundle/output.Environment
install.sh/prime-agent update --forceprime-agent --version: 0.7.0