{"_id":"@astro-minimax/ai","_rev":"15-b9fc74f003fb9d62ea10f0037ea70988","name":"@astro-minimax/ai","dist-tags":{"latest":"0.9.3"},"versions":{"0.2.0":{"name":"@astro-minimax/ai","version":"0.2.0","author":{"name":"Souloss"},"license":"MIT","_id":"@astro-minimax/ai@0.2.0","maintainers":[{"name":"souloss","email":"826245622@qq.com"}],"bin":{"astro-ai-dev":"dist/server/dev-server.js"},"dist":{"shasum":"70758648fa8f4a9f30269c4216d765c9fa2ff239","tarball":"https://registry.npmjs.org/@astro-minimax/ai/-/ai-0.2.0.tgz","fileCount":159,"integrity":"sha512-K3Ux13retSKtnyNalobQlpAvnSHbGGbpab0wrOxt8LcePJhCGe6smeOzp6FxMmuY2tYxPUX3QOZ3xRUbCUWGMw==","signatures":[{"sig":"MEUCIHtJ47pTJ2v2Q+O/rO0xU3JiLvqVll2PUh0NpTxwsj9uAiEAoYDeWsbvYnFyr0RvxRyHtIhz1JmOJT+L32ytOmFG9Co=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":290306},"type":"module","engines":{"node":">=22.12.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./data":{"types":"./dist/data/index.d.ts","import":"./dist/data/index.js"},"./prompt":{"types":"./dist/prompt/index.d.ts","import":"./dist/prompt/index.js"},"./search":{"types":"./dist/search/index.d.ts","import":"./dist/search/index.js"},"./server":{"types":"./dist/server/index.d.ts","import":"./dist/server/index.js"},"./stream":{"types":"./dist/stream/index.d.ts","import":"./dist/stream/index.js"},"./providers":{"types":"./dist/providers/index.d.ts","import":"./dist/providers/index.js"},"./middleware":{"types":"./dist/middleware/index.d.ts","import":"./dist/middleware/index.js"},"./components/*":"./src/components/*","./intelligence":{"types":"./dist/intelligence/index.d.ts","import":"./dist/intelligence/index.js"},"./package.json":"./package.json","./styles/source.css":"./src/styles/source.css"},"gitHead":"ee0846be72b5411f74f94e37e8b2e3a37393f0e2","scripts":{"build":"tsc -p tsconfig.build.json","clean":"rm -rf dist","build:watch":"tsc -p tsconfig.build.json --watch","prepublishOnly":"pnpm run clean && pnpm run build"},"_npmUser":{"name":"souloss","email":"826245622@qq.com"},"_npmVersion":"10.9.0","description":"Vendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs.","directories":{},"sideEffects":false,"_nodeVersion":"23.2.0","dependencies":{"ai":"^6.0.116","undici":"^6.0.0","workers-ai-provider":"^3.1.2","@astro-minimax/notify":"workspace:*","@ai-sdk/openai-compatible":"^2.0.35"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.9.3","@types/node":"^22.0.0","@cloudflare/workers-types":"^4.0.0"},"peerDependencies":{"preact":"^10.0.0","@ai-sdk/react":"^3.0.0","@cloudflare/workers-types":"^4.0.0"},"peerDependenciesMeta":{"preact":{"optional":true},"@ai-sdk/react":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/ai_0.2.0_1773729268270_0.9637165295782102","host":"s3://npm-registry-packages-npm-production"}},"0.5.0":{"name":"@astro-minimax/ai","version":"0.5.0","keywords":["astro","ai","llm","rag","openai","cloudflare-ai","vector-search","streaming","chatbot"],"author":{"name":"Souloss"},"license":"MIT","_id":"@astro-minimax/ai@0.5.0","maintainers":[{"name":"souloss","email":"826245622@qq.com"}],"homepage":"https://github.com/souloss/astro-minimax#readme","bugs":{"url":"https://github.com/souloss/astro-minimax/issues"},"bin":{"astro-ai-dev":"dist/server/dev-server.js"},"dist":{"shasum":"7944ca327025c0a4d00e1dea8ce56f3f540eabb7","tarball":"https://registry.npmjs.org/@astro-minimax/ai/-/ai-0.5.0.tgz","fileCount":160,"integrity":"sha512-az2vincM+RUlMkTLGHDr9VnywzFo1ex+UUA2QkDVTHybXASxS3vOmiPah0eM1zinq/+XzrI7h8I4vNMrkJKjnw==","signatures":[{"sig":"MEUCIQCIgkB16qoYnGN8w7lLVQ3yelz1RsSUDeW5rIKQB9cw8wIgevubujXWNhxZyxvLdg8uRtG967SXav07t8o1sOYiYGY=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":292932},"type":"module","_from":"file:astro-minimax-ai-0.5.0.tgz","engines":{"node":">=22.12.0","pnpm":">=9.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./data":{"types":"./dist/data/index.d.ts","import":"./dist/data/index.js"},"./prompt":{"types":"./dist/prompt/index.d.ts","import":"./dist/prompt/index.js"},"./search":{"types":"./dist/search/index.d.ts","import":"./dist/search/index.js"},"./server":{"types":"./dist/server/index.d.ts","import":"./dist/server/index.js"},"./stream":{"types":"./dist/stream/index.d.ts","import":"./dist/stream/index.js"},"./providers":{"types":"./dist/providers/index.d.ts","import":"./dist/providers/index.js"},"./middleware":{"types":"./dist/middleware/index.d.ts","import":"./dist/middleware/index.js"},"./components/*":"./src/components/*","./intelligence":{"types":"./dist/intelligence/index.d.ts","import":"./dist/intelligence/index.js"},"./package.json":"./package.json","./styles/source.css":"./src/styles/source.css"},"scripts":{"build":"tsc -p tsconfig.build.json","clean":"rm -rf dist","typecheck":"tsc --noEmit","build:watch":"tsc -p tsconfig.build.json --watch"},"_npmUser":{"name":"souloss","email":"826245622@qq.com"},"_resolved":"/tmp/ac7ef4a231f3cad362459db8f20e424b/astro-minimax-ai-0.5.0.tgz","_integrity":"sha512-az2vincM+RUlMkTLGHDr9VnywzFo1ex+UUA2QkDVTHybXASxS3vOmiPah0eM1zinq/+XzrI7h8I4vNMrkJKjnw==","repository":{"url":"git+https://github.com/souloss/astro-minimax.git","type":"git","directory":"packages/ai"},"_npmVersion":"10.9.0","description":"Vendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs — supports OpenAI, Cloudflare AI, and custom providers.","directories":{},"sideEffects":false,"_nodeVersion":"23.2.0","dependencies":{"ai":"^6.0.116","workers-ai-provider":"^3.1.2","@astro-minimax/notify":"0.5.0","@ai-sdk/openai-compatible":"^2.0.35"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.9.3","@types/node":"^22.0.0","@cloudflare/workers-types":"^4.0.0"},"peerDependencies":{"preact":"^10.0.0","@ai-sdk/react":"^3.0.0","@cloudflare/workers-types":"^4.0.0"},"optionalDependencies":{"undici":"^6.0.0"},"peerDependenciesMeta":{"preact":{"optional":true},"@ai-sdk/react":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/ai_0.5.0_1773744064370_0.013393265944908306","host":"s3://npm-registry-packages-npm-production"}},"0.7.0":{"name":"@astro-minimax/ai","version":"0.7.0","keywords":["astro","ai","llm","rag","openai","cloudflare-ai","vector-search","streaming","chatbot"],"author":{"name":"Souloss"},"license":"MIT","_id":"@astro-minimax/ai@0.7.0","maintainers":[{"name":"souloss","email":"826245622@qq.com"}],"homepage":"https://github.com/souloss/astro-minimax#readme","bugs":{"url":"https://github.com/souloss/astro-minimax/issues"},"bin":{"astro-ai-dev":"dist/server/dev-server.js"},"dist":{"shasum":"f43ddf508ead7adf22931c4e43da01bcac5045e8","tarball":"https://registry.npmjs.org/@astro-minimax/ai/-/ai-0.7.0.tgz","fileCount":163,"integrity":"sha512-5QJelXMjYt0iBEgh6piYXcWwR8j9mQ/JUxWUYs68fEF/AfVcUgdeW4dQMYuqrSC8jSEEDQkk3X+jEaOoMqB0EQ==","signatures":[{"sig":"MEQCIEu9VJn/0fqlwZ60cBVK7y7ckIYnffpSJzveMss87ZFzAiAhc1rWKyI3W9YQT3wUCszoWoSGsEshNMBi4CQCqZ7oPQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":310775},"type":"module","_from":"file:astro-minimax-ai-0.7.0.tgz","engines":{"node":">=22.12.0","pnpm":">=9.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./data":{"types":"./dist/data/index.d.ts","import":"./dist/data/index.js"},"./prompt":{"types":"./dist/prompt/index.d.ts","import":"./dist/prompt/index.js"},"./search":{"types":"./dist/search/index.d.ts","import":"./dist/search/index.js"},"./server":{"types":"./dist/server/index.d.ts","import":"./dist/server/index.js"},"./stream":{"types":"./dist/stream/index.d.ts","import":"./dist/stream/index.js"},"./providers":{"types":"./dist/providers/index.d.ts","import":"./dist/providers/index.js"},"./middleware":{"types":"./dist/middleware/index.d.ts","import":"./dist/middleware/index.js"},"./components/*":"./src/components/*","./intelligence":{"types":"./dist/intelligence/index.d.ts","import":"./dist/intelligence/index.js"},"./package.json":"./package.json","./styles/source.css":"./src/styles/source.css"},"scripts":{"build":"tsc -p tsconfig.build.json","clean":"rm -rf dist","typecheck":"tsc --noEmit","build:watch":"tsc -p tsconfig.build.json --watch"},"_npmUser":{"name":"souloss","email":"826245622@qq.com"},"_resolved":"/tmp/607ce892bbba94bb22fd764d7207fcf8/astro-minimax-ai-0.7.0.tgz","_integrity":"sha512-5QJelXMjYt0iBEgh6piYXcWwR8j9mQ/JUxWUYs68fEF/AfVcUgdeW4dQMYuqrSC8jSEEDQkk3X+jEaOoMqB0EQ==","repository":{"url":"git+https://github.com/souloss/astro-minimax.git","type":"git","directory":"packages/ai"},"_npmVersion":"10.9.0","description":"Vendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs — supports OpenAI, Cloudflare AI, and custom providers.","directories":{},"sideEffects":false,"_nodeVersion":"23.2.0","dependencies":{"ai":"^6.0.116","workers-ai-provider":"^3.1.2","@astro-minimax/notify":"0.7.0","@ai-sdk/openai-compatible":"^2.0.35"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.9.3","@types/node":"^22.0.0","@cloudflare/workers-types":"^4.0.0"},"peerDependencies":{"preact":"^10.0.0","@ai-sdk/react":"^3.0.0","@cloudflare/workers-types":"^4.0.0"},"optionalDependencies":{"undici":"^6.0.0"},"peerDependenciesMeta":{"preact":{"optional":true},"@ai-sdk/react":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/ai_0.7.0_1773782263801_0.6109696436571976","host":"s3://npm-registry-packages-npm-production"}},"0.7.1":{"name":"@astro-minimax/ai","version":"0.7.1","keywords":["astro","ai","llm","rag","openai","cloudflare-ai","vector-search","streaming","chatbot"],"author":{"name":"Souloss"},"license":"MIT","_id":"@astro-minimax/ai@0.7.1","maintainers":[{"name":"souloss","email":"826245622@qq.com"}],"homepage":"https://github.com/souloss/astro-minimax#readme","bugs":{"url":"https://github.com/souloss/astro-minimax/issues"},"bin":{"astro-ai-dev":"dist/server/dev-server.js"},"dist":{"shasum":"01ed82a69d82eaa2749d40204e2f4a5f130f6ce0","tarball":"https://registry.npmjs.org/@astro-minimax/ai/-/ai-0.7.1.tgz","fileCount":169,"integrity":"sha512-trg8pvZvCb6CLgNmu1GUkpBWQcyIi43vBc518bS7U3MAzmPisBWW7CSZxP2cRN1S9BDVgCM21il3qvLfTu0rCw==","signatures":[{"sig":"MEUCIAdrV/PFGuMn2uL2e7C0pKo754Fvj+SakJxquwrHFGKvAiEAsiCEL/jC1hlkJklp6qWgIAKGsfyrAiuncTe7FnypKfY=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":322200},"type":"module","_from":"file:astro-minimax-ai-0.7.1.tgz","engines":{"node":">=22.12.0","pnpm":">=9.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./data":{"types":"./dist/data/index.d.ts","import":"./dist/data/index.js"},"./prompt":{"types":"./dist/prompt/index.d.ts","import":"./dist/prompt/index.js"},"./search":{"types":"./dist/search/index.d.ts","import":"./dist/search/index.js"},"./server":{"types":"./dist/server/index.d.ts","import":"./dist/server/index.js"},"./stream":{"types":"./dist/stream/index.d.ts","import":"./dist/stream/index.js"},"./providers":{"types":"./dist/providers/index.d.ts","import":"./dist/providers/index.js"},"./middleware":{"types":"./dist/middleware/index.d.ts","import":"./dist/middleware/index.js"},"./components/*":"./src/components/*","./intelligence":{"types":"./dist/intelligence/index.d.ts","import":"./dist/intelligence/index.js"},"./package.json":"./package.json","./styles/source.css":"./src/styles/source.css"},"scripts":{"build":"tsc -p tsconfig.build.json","clean":"rm -rf dist","typecheck":"tsc --noEmit","build:watch":"tsc -p tsconfig.build.json --watch"},"_npmUser":{"name":"souloss","email":"826245622@qq.com"},"_resolved":"/tmp/f3cd31e15bd6efafde3a47a8e44880e7/astro-minimax-ai-0.7.1.tgz","_integrity":"sha512-trg8pvZvCb6CLgNmu1GUkpBWQcyIi43vBc518bS7U3MAzmPisBWW7CSZxP2cRN1S9BDVgCM21il3qvLfTu0rCw==","repository":{"url":"git+https://github.com/souloss/astro-minimax.git","type":"git","directory":"packages/ai"},"_npmVersion":"10.9.0","description":"Vendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs — supports OpenAI, Cloudflare AI, and custom providers.","directories":{},"sideEffects":false,"_nodeVersion":"23.2.0","dependencies":{"ai":"^6.0.116","workers-ai-provider":"^3.1.2","@astro-minimax/notify":"0.7.1","@ai-sdk/openai-compatible":"^2.0.35"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.9.3","@types/node":"^22.0.0","@cloudflare/workers-types":"^4.0.0"},"peerDependencies":{"preact":"^10.0.0","@ai-sdk/react":"^3.0.0","@cloudflare/workers-types":"^4.0.0"},"optionalDependencies":{"undici":"^6.0.0"},"peerDependenciesMeta":{"preact":{"optional":true},"@ai-sdk/react":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/ai_0.7.1_1773828729863_0.4574124732778915","host":"s3://npm-registry-packages-npm-production"}},"0.7.2":{"name":"@astro-minimax/ai","version":"0.7.2","keywords":["astro","ai","llm","rag","openai","cloudflare-ai","vector-search","streaming","chatbot"],"author":{"name":"Souloss"},"license":"MIT","_id":"@astro-minimax/ai@0.7.2","maintainers":[{"name":"souloss","email":"826245622@qq.com"}],"homepage":"https://github.com/souloss/astro-minimax#readme","bugs":{"url":"https://github.com/souloss/astro-minimax/issues"},"bin":{"astro-ai-dev":"dist/server/dev-server.js"},"dist":{"shasum":"e34a088dd7743119002cf853b77528c8b04d023f","tarball":"https://registry.npmjs.org/@astro-minimax/ai/-/ai-0.7.2.tgz","fileCount":190,"integrity":"sha512-vUcSbAZfRs5SGDbgrgoyEUJVMDzgqn2yLro661pxadASZ+VdCAANov1LPd8vlGCWAi0le9FiApRIU318Kq0a+Q==","signatures":[{"sig":"MEUCIFeN3VSAI2rofPh1mfqYjhOa2pHj5aUAi4uz0uo5aVehAiEA60FifmbQi6P25SlaPM/9X5jtD9hbFQeNcNj/7BSq5NY=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":349060},"type":"module","_from":"file:astro-minimax-ai-0.7.2.tgz","engines":{"node":">=22.12.0","pnpm":">=9.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./data":{"types":"./dist/data/index.d.ts","import":"./dist/data/index.js"},"./prompt":{"types":"./dist/prompt/index.d.ts","import":"./dist/prompt/index.js"},"./search":{"types":"./dist/search/index.d.ts","import":"./dist/search/index.js"},"./server":{"types":"./dist/server/index.d.ts","import":"./dist/server/index.js"},"./stream":{"types":"./dist/stream/index.d.ts","import":"./dist/stream/index.js"},"./providers":{"types":"./dist/providers/index.d.ts","import":"./dist/providers/index.js"},"./middleware":{"types":"./dist/middleware/index.d.ts","import":"./dist/middleware/index.js"},"./components/*":"./src/components/*","./intelligence":{"types":"./dist/intelligence/index.d.ts","import":"./dist/intelligence/index.js"},"./package.json":"./package.json","./fact-registry":{"types":"./dist/fact-registry/index.d.ts","import":"./dist/fact-registry/index.js"},"./styles/source.css":"./src/styles/source.css"},"scripts":{"build":"tsc -p tsconfig.build.json","clean":"rm -rf dist","typecheck":"tsc --noEmit","build:watch":"tsc -p tsconfig.build.json --watch"},"_npmUser":{"name":"souloss","email":"826245622@qq.com"},"_resolved":"/tmp/ab6441945dada1390cd756d7b77f04b6/astro-minimax-ai-0.7.2.tgz","_integrity":"sha512-vUcSbAZfRs5SGDbgrgoyEUJVMDzgqn2yLro661pxadASZ+VdCAANov1LPd8vlGCWAi0le9FiApRIU318Kq0a+Q==","repository":{"url":"git+https://github.com/souloss/astro-minimax.git","type":"git","directory":"packages/ai"},"_npmVersion":"10.9.0","description":"Vendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs — supports OpenAI, Cloudflare AI, and custom providers.","directories":{},"sideEffects":false,"_nodeVersion":"23.2.0","dependencies":{"ai":"^6.0.116","workers-ai-provider":"^3.1.2","@astro-minimax/notify":"0.7.2","@ai-sdk/openai-compatible":"^2.0.35"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.9.3","@types/node":"^22.0.0","@cloudflare/workers-types":"^4.0.0"},"peerDependencies":{"preact":"^10.0.0","@ai-sdk/react":"^3.0.0","@cloudflare/workers-types":"^4.0.0"},"optionalDependencies":{"undici":"^6.0.0"},"peerDependenciesMeta":{"preact":{"optional":true},"@ai-sdk/react":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/ai_0.7.2_1773845808598_0.3590371359756084","host":"s3://npm-registry-packages-npm-production"}},"0.7.3":{"name":"@astro-minimax/ai","version":"0.7.3","keywords":["astro","ai","llm","rag","openai","cloudflare-ai","vector-search","streaming","chatbot"],"author":{"name":"Souloss"},"license":"MIT","_id":"@astro-minimax/ai@0.7.3","maintainers":[{"name":"souloss","email":"826245622@qq.com"}],"homepage":"https://github.com/souloss/astro-minimax#readme","bugs":{"url":"https://github.com/souloss/astro-minimax/issues"},"bin":{"astro-ai-dev":"dist/server/dev-server.js"},"dist":{"shasum":"9e5ba0b774ec8874c6f6828327f16c5edc9bf704","tarball":"https://registry.npmjs.org/@astro-minimax/ai/-/ai-0.7.3.tgz","fileCount":193,"integrity":"sha512-309VjJ12pf1E5JYmFWvzPy3JsNIB9XZDZMXzAgzXlb19FXIqC48w8UIiY6pVCFdhVliGNVzzu0Tt8CFfnE8Z9w==","signatures":[{"sig":"MEQCIB+2GA7RRORfyDRrsk5It9UA/+UlROmvDBuIxshJ4t9YAiBsmUw7EElnfh5nYsfJpG75JdVsvynz53ax/GheqTzU2w==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":373677},"type":"module","_from":"file:astro-minimax-ai-0.7.3.tgz","engines":{"node":">=22.12.0","pnpm":">=9.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./data":{"types":"./dist/data/index.d.ts","import":"./dist/data/index.js"},"./prompt":{"types":"./dist/prompt/index.d.ts","import":"./dist/prompt/index.js"},"./search":{"types":"./dist/search/index.d.ts","import":"./dist/search/index.js"},"./server":{"types":"./dist/server/index.d.ts","import":"./dist/server/index.js"},"./stream":{"types":"./dist/stream/index.d.ts","import":"./dist/stream/index.js"},"./providers":{"types":"./dist/providers/index.d.ts","import":"./dist/providers/index.js"},"./middleware":{"types":"./dist/middleware/index.d.ts","import":"./dist/middleware/index.js"},"./components/*":"./src/components/*","./intelligence":{"types":"./dist/intelligence/index.d.ts","import":"./dist/intelligence/index.js"},"./package.json":"./package.json","./fact-registry":{"types":"./dist/fact-registry/index.d.ts","import":"./dist/fact-registry/index.js"},"./styles/source.css":"./src/styles/source.css"},"scripts":{"build":"tsc -p tsconfig.build.json && chmod +x dist/server/dev-server.js","clean":"rm -rf dist","typecheck":"tsc --noEmit","build:watch":"tsc -p tsconfig.build.json --watch"},"_npmUser":{"name":"souloss","email":"826245622@qq.com"},"_resolved":"/tmp/13c990d554f99c4ae1ca218f243429a6/astro-minimax-ai-0.7.3.tgz","_integrity":"sha512-309VjJ12pf1E5JYmFWvzPy3JsNIB9XZDZMXzAgzXlb19FXIqC48w8UIiY6pVCFdhVliGNVzzu0Tt8CFfnE8Z9w==","repository":{"url":"git+https://github.com/souloss/astro-minimax.git","type":"git","directory":"packages/ai"},"_npmVersion":"10.9.0","description":"Vendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs — supports OpenAI, Cloudflare AI, and custom providers.","directories":{},"sideEffects":false,"_nodeVersion":"23.2.0","dependencies":{"ai":"^6.0.116","workers-ai-provider":"^3.1.2","@astro-minimax/notify":"0.7.3","@ai-sdk/openai-compatible":"^2.0.35"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.9.3","@types/node":"^22.0.0","@cloudflare/workers-types":"^4.0.0"},"peerDependencies":{"preact":"^10.0.0","@ai-sdk/react":"^3.0.0","@cloudflare/workers-types":"^4.0.0"},"optionalDependencies":{"undici":"^6.0.0"},"peerDependenciesMeta":{"preact":{"optional":true},"@ai-sdk/react":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/ai_0.7.3_1773854268059_0.6167777843451978","host":"s3://npm-registry-packages-npm-production"}},"0.7.4":{"name":"@astro-minimax/ai","version":"0.7.4","keywords":["astro","ai","llm","rag","openai","cloudflare-ai","vector-search","streaming","chatbot"],"author":{"name":"Souloss"},"license":"MIT","_id":"@astro-minimax/ai@0.7.4","maintainers":[{"name":"souloss","email":"826245622@qq.com"}],"homepage":"https://github.com/souloss/astro-minimax#readme","bugs":{"url":"https://github.com/souloss/astro-minimax/issues"},"bin":{"astro-ai-dev":"dist/server/dev-server.js"},"dist":{"shasum":"4b21796ae69da627b166785aa1729b7c27c3ed8b","tarball":"https://registry.npmjs.org/@astro-minimax/ai/-/ai-0.7.4.tgz","fileCount":193,"integrity":"sha512-txuMWgXi7BKi8LmuxRphG9UFTEB69bDSANyvWajfFy8dZzokzu6pMBLVzZysejNIK2j50U6UgVBCtlBPXvBkzA==","signatures":[{"sig":"MEQCIGjOsNZAkkjdOvKx5vm7PVR9f1+mEia7CPazF0Zaapj2AiANeuYSal7oErXOfWX9hdCHpmosdceNOudQekZnn1SEQQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":373715},"type":"module","_from":"file:astro-minimax-ai-0.7.4.tgz","engines":{"node":">=22.12.0","pnpm":">=9.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./data":{"types":"./dist/data/index.d.ts","import":"./dist/data/index.js"},"./prompt":{"types":"./dist/prompt/index.d.ts","import":"./dist/prompt/index.js"},"./search":{"types":"./dist/search/index.d.ts","import":"./dist/search/index.js"},"./server":{"types":"./dist/server/index.d.ts","import":"./dist/server/index.js"},"./stream":{"types":"./dist/stream/index.d.ts","import":"./dist/stream/index.js"},"./providers":{"types":"./dist/providers/index.d.ts","import":"./dist/providers/index.js"},"./middleware":{"types":"./dist/middleware/index.d.ts","import":"./dist/middleware/index.js"},"./components/*":"./src/components/*","./intelligence":{"types":"./dist/intelligence/index.d.ts","import":"./dist/intelligence/index.js"},"./package.json":"./package.json","./fact-registry":{"types":"./dist/fact-registry/index.d.ts","import":"./dist/fact-registry/index.js"},"./styles/source.css":"./src/styles/source.css"},"scripts":{"build":"tsc -p tsconfig.build.json && chmod +x dist/server/dev-server.js","clean":"rm -rf dist","typecheck":"tsc --noEmit","build:watch":"tsc -p tsconfig.build.json --watch"},"_npmUser":{"name":"souloss","email":"826245622@qq.com"},"_resolved":"/tmp/46ccd10a60a686b3e69e2b9e84b0fdd4/astro-minimax-ai-0.7.4.tgz","_integrity":"sha512-txuMWgXi7BKi8LmuxRphG9UFTEB69bDSANyvWajfFy8dZzokzu6pMBLVzZysejNIK2j50U6UgVBCtlBPXvBkzA==","repository":{"url":"git+https://github.com/souloss/astro-minimax.git","type":"git","directory":"packages/ai"},"_npmVersion":"10.9.0","description":"Vendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs — supports OpenAI, Cloudflare AI, and custom providers.","directories":{},"sideEffects":false,"_nodeVersion":"23.2.0","dependencies":{"ai":"^6.0.116","workers-ai-provider":"^3.1.2","@astro-minimax/notify":"0.7.4","@ai-sdk/openai-compatible":"^2.0.35"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.9.3","@types/node":"^22.0.0","@cloudflare/workers-types":"^4.0.0"},"peerDependencies":{"preact":"^10.0.0","@ai-sdk/react":"^3.0.0","@cloudflare/workers-types":"^4.0.0"},"optionalDependencies":{"undici":"^6.0.0"},"peerDependenciesMeta":{"preact":{"optional":true},"@ai-sdk/react":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/ai_0.7.4_1773858685651_0.434416695887053","host":"s3://npm-registry-packages-npm-production"}},"0.7.5":{"name":"@astro-minimax/ai","version":"0.7.5","keywords":["astro","ai","llm","rag","openai","cloudflare-ai","vector-search","streaming","chatbot"],"author":{"name":"Souloss"},"license":"MIT","_id":"@astro-minimax/ai@0.7.5","maintainers":[{"name":"souloss","email":"826245622@qq.com"}],"homepage":"https://github.com/souloss/astro-minimax#readme","bugs":{"url":"https://github.com/souloss/astro-minimax/issues"},"bin":{"astro-ai-dev":"dist/server/dev-server.js"},"dist":{"shasum":"26d4cf82e84a26a205fc728c68e696d14b04a12e","tarball":"https://registry.npmjs.org/@astro-minimax/ai/-/ai-0.7.5.tgz","fileCount":193,"integrity":"sha512-48Wo0ME5wPsTC+y8VCnmXaSZLxqlbmbdOc7lNO/AVbu/RqGc3QGUhc2Jb7NlLIZhkUewsJ1CiOEzqhAwkCfMEQ==","signatures":[{"sig":"MEYCIQDtPsZoHzDTP17KEw1KH9T2pjwnkYywwyDrbmxMG+01CQIhAJcyuXvikZhpk+SiGDvptCnpmRqBIINdAaDxGfv0QYam","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":373715},"type":"module","_from":"file:astro-minimax-ai-0.7.5.tgz","engines":{"node":">=22.12.0","pnpm":">=9.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./data":{"types":"./dist/data/index.d.ts","import":"./dist/data/index.js"},"./prompt":{"types":"./dist/prompt/index.d.ts","import":"./dist/prompt/index.js"},"./search":{"types":"./dist/search/index.d.ts","import":"./dist/search/index.js"},"./server":{"types":"./dist/server/index.d.ts","import":"./dist/server/index.js"},"./stream":{"types":"./dist/stream/index.d.ts","import":"./dist/stream/index.js"},"./providers":{"types":"./dist/providers/index.d.ts","import":"./dist/providers/index.js"},"./middleware":{"types":"./dist/middleware/index.d.ts","import":"./dist/middleware/index.js"},"./components/*":"./src/components/*","./intelligence":{"types":"./dist/intelligence/index.d.ts","import":"./dist/intelligence/index.js"},"./package.json":"./package.json","./fact-registry":{"types":"./dist/fact-registry/index.d.ts","import":"./dist/fact-registry/index.js"},"./styles/source.css":"./src/styles/source.css"},"scripts":{"build":"tsc -p tsconfig.build.json && chmod +x dist/server/dev-server.js","clean":"rm -rf dist","typecheck":"tsc --noEmit","build:watch":"tsc -p tsconfig.build.json --watch"},"_npmUser":{"name":"souloss","email":"826245622@qq.com"},"_resolved":"/tmp/7c9aa2b0189d3f4ab8cf6b274453c960/astro-minimax-ai-0.7.5.tgz","_integrity":"sha512-48Wo0ME5wPsTC+y8VCnmXaSZLxqlbmbdOc7lNO/AVbu/RqGc3QGUhc2Jb7NlLIZhkUewsJ1CiOEzqhAwkCfMEQ==","repository":{"url":"git+https://github.com/souloss/astro-minimax.git","type":"git","directory":"packages/ai"},"_npmVersion":"10.9.0","description":"Vendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs — supports OpenAI, Cloudflare AI, and custom providers.","directories":{},"sideEffects":false,"_nodeVersion":"23.2.0","dependencies":{"ai":"^6.0.116","workers-ai-provider":"^3.1.2","@astro-minimax/notify":"0.7.5","@ai-sdk/openai-compatible":"^2.0.35"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.9.3","@types/node":"^22.0.0","@cloudflare/workers-types":"^4.0.0"},"peerDependencies":{"preact":"^10.0.0","@ai-sdk/react":"^3.0.0","@cloudflare/workers-types":"^4.0.0"},"optionalDependencies":{"undici":"^6.0.0"},"peerDependenciesMeta":{"preact":{"optional":true},"@ai-sdk/react":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/ai_0.7.5_1773859194318_0.299636643687605","host":"s3://npm-registry-packages-npm-production"}},"0.8.0":{"name":"@astro-minimax/ai","version":"0.8.0","keywords":["astro","ai","llm","rag","openai","cloudflare-ai","vector-search","streaming","chatbot"],"author":{"name":"Souloss"},"license":"MIT","_id":"@astro-minimax/ai@0.8.0","maintainers":[{"name":"souloss","email":"826245622@qq.com"}],"homepage":"https://github.com/souloss/astro-minimax#readme","bugs":{"url":"https://github.com/souloss/astro-minimax/issues"},"bin":{"astro-ai-dev":"dist/server/dev-server.js"},"dist":{"shasum":"391e6a0b85915e5ada83e007f595b82fb12a91e5","tarball":"https://registry.npmjs.org/@astro-minimax/ai/-/ai-0.8.0.tgz","fileCount":144,"integrity":"sha512-LKO/60PyCTmKjHxkMh1Kno9GU+EMX+qm7F0hDaBXSoo3EzgOBoRcPUW18HtNMsWVBkw362NbQpAzaOefkzjDJQ==","signatures":[{"sig":"MEUCIQDKbzZV2YSHMCtyOfNPHCeQheNDL+O7nqcpoxo+Pg1gkQIgUEH5+Vkjdn8uSnAZDNUQNYgVvRya8OSg7bp2Oku+FjA=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":249413},"type":"module","_from":"file:astro-minimax-ai-0.8.0.tgz","engines":{"node":">=22.12.0","pnpm":">=9.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./data":{"types":"./dist/data/index.d.ts","import":"./dist/data/index.js"},"./prompt":{"types":"./dist/prompt/index.d.ts","import":"./dist/prompt/index.js"},"./search":{"types":"./dist/search/index.d.ts","import":"./dist/search/index.js"},"./server":{"types":"./dist/server/index.d.ts","import":"./dist/server/index.js"},"./stream":{"types":"./dist/stream/index.d.ts","import":"./dist/stream/index.js"},"./providers":{"types":"./dist/providers/index.d.ts","import":"./dist/providers/index.js"},"./middleware":{"types":"./dist/middleware/index.d.ts","import":"./dist/middleware/index.js"},"./intelligence":{"types":"./dist/intelligence/index.d.ts","import":"./dist/intelligence/index.js"},"./package.json":"./package.json","./fact-registry":{"types":"./dist/fact-registry/index.d.ts","import":"./dist/fact-registry/index.js"},"./styles/source.css":"./src/styles/source.css","./components/ChatPanel":{"types":"./dist/components/ChatPanel.d.ts","import":"./dist/components/ChatPanel.js"},"./components/AIChatContainer":{"types":"./dist/components/AIChatContainer.d.ts","import":"./dist/components/AIChatContainer.js"},"./components/AIChatWidget.astro":"./dist/components/AIChatWidget.astro"},"scripts":{"build":"node scripts/build.mjs","clean":"rm -rf dist","typecheck":"tsc --noEmit","build:watch":"node scripts/build.mjs --watch","build:components":"node scripts/build-components.mjs"},"_npmUser":{"name":"souloss","email":"826245622@qq.com"},"_resolved":"/tmp/f8e4594525894908e2ed3bd85eda9d4d/astro-minimax-ai-0.8.0.tgz","_integrity":"sha512-LKO/60PyCTmKjHxkMh1Kno9GU+EMX+qm7F0hDaBXSoo3EzgOBoRcPUW18HtNMsWVBkw362NbQpAzaOefkzjDJQ==","repository":{"url":"git+https://github.com/souloss/astro-minimax.git","type":"git","directory":"packages/ai"},"_npmVersion":"10.9.0","description":"Vendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs — supports OpenAI, Cloudflare AI, and custom providers.","directories":{},"sideEffects":false,"_nodeVersion":"23.2.0","dependencies":{"ai":"^6.0.116","workers-ai-provider":"^3.1.2","@astro-minimax/notify":"^0.7.5","@ai-sdk/openai-compatible":"^2.0.35"},"_hasShrinkwrap":false,"devDependencies":{"esbuild":"^0.25.0","typescript":"^5.9.3","@types/node":"^22.0.0","@cloudflare/workers-types":"^4.0.0"},"peerDependencies":{"preact":"^10.0.0","@ai-sdk/react":"^3.0.0","@cloudflare/workers-types":"^4.0.0"},"optionalDependencies":{"undici":"^6.0.0"},"peerDependenciesMeta":{"preact":{"optional":true},"@ai-sdk/react":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/ai_0.8.0_1773956506680_0.16120044272017586","host":"s3://npm-registry-packages-npm-production"}},"0.8.1":{"name":"@astro-minimax/ai","version":"0.8.1","keywords":["astro","ai","llm","rag","openai","cloudflare-ai","vector-search","streaming","chatbot"],"author":{"name":"Souloss"},"license":"MIT","_id":"@astro-minimax/ai@0.8.1","maintainers":[{"name":"souloss","email":"826245622@qq.com"}],"homepage":"https://github.com/souloss/astro-minimax#readme","bugs":{"url":"https://github.com/souloss/astro-minimax/issues"},"bin":{"astro-ai-dev":"dist/server/dev-server.js"},"dist":{"shasum":"9f51a8cf0959a7fd8096bc9774e24b79c669adb4","tarball":"https://registry.npmjs.org/@astro-minimax/ai/-/ai-0.8.1.tgz","fileCount":144,"integrity":"sha512-xfHHvFBmEwZyTgyHLEETOJGPWn5I52MXd3+cMQ0H235bd101Iap0DPWhVj05rtQfydcuw5WfDh7frtCP6/1pWw==","signatures":[{"sig":"MEYCIQD6F00i72u+eyuvd3hNDvbE/X9zxje9bVrITYUing15egIhAOZs3OoGqxMRiruZN8lTEbMsd81hZiJ0+vtIKj1OJHcw","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":249389},"type":"module","_from":"file:astro-minimax-ai-0.8.1.tgz","engines":{"node":">=22.12.0","pnpm":">=9.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./data":{"types":"./dist/data/index.d.ts","import":"./dist/data/index.js"},"./prompt":{"types":"./dist/prompt/index.d.ts","import":"./dist/prompt/index.js"},"./search":{"types":"./dist/search/index.d.ts","import":"./dist/search/index.js"},"./server":{"types":"./dist/server/index.d.ts","import":"./dist/server/index.js"},"./stream":{"types":"./dist/stream/index.d.ts","import":"./dist/stream/index.js"},"./providers":{"types":"./dist/providers/index.d.ts","import":"./dist/providers/index.js"},"./middleware":{"types":"./dist/middleware/index.d.ts","import":"./dist/middleware/index.js"},"./intelligence":{"types":"./dist/intelligence/index.d.ts","import":"./dist/intelligence/index.js"},"./package.json":"./package.json","./fact-registry":{"types":"./dist/fact-registry/index.d.ts","import":"./dist/fact-registry/index.js"},"./styles/source.css":"./src/styles/source.css","./components/ChatPanel":{"types":"./dist/components/ChatPanel.d.ts","import":"./dist/components/ChatPanel.js"},"./components/AIChatContainer":{"types":"./dist/components/AIChatContainer.d.ts","import":"./dist/components/AIChatContainer.js"},"./components/AIChatWidget.astro":"./dist/components/AIChatWidget.astro"},"scripts":{"build":"node scripts/build.mjs","clean":"rm -rf dist","typecheck":"tsc --noEmit","build:watch":"node scripts/build.mjs --watch","build:components":"node scripts/build-components.mjs"},"_npmUser":{"name":"souloss","email":"826245622@qq.com"},"_resolved":"/tmp/6863c35f07f69f1e7c14679995d3a98d/astro-minimax-ai-0.8.1.tgz","_integrity":"sha512-xfHHvFBmEwZyTgyHLEETOJGPWn5I52MXd3+cMQ0H235bd101Iap0DPWhVj05rtQfydcuw5WfDh7frtCP6/1pWw==","repository":{"url":"git+https://github.com/souloss/astro-minimax.git","type":"git","directory":"packages/ai"},"_npmVersion":"10.9.0","description":"Vendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs — supports OpenAI, Cloudflare AI, and custom providers.","directories":{},"sideEffects":false,"_nodeVersion":"23.2.0","dependencies":{"ai":"^6.0.116","workers-ai-provider":"^3.1.2","@astro-minimax/notify":"^0.7.5","@ai-sdk/openai-compatible":"^2.0.35"},"_hasShrinkwrap":false,"devDependencies":{"esbuild":"^0.25.0","typescript":"^5.9.3","@types/node":"^22.0.0","@cloudflare/workers-types":"^4.0.0"},"peerDependencies":{"preact":"^10.0.0","@ai-sdk/react":"^3.0.0","@cloudflare/workers-types":"^4.0.0"},"optionalDependencies":{"undici":"^6.0.0"},"peerDependenciesMeta":{"preact":{"optional":true},"@ai-sdk/react":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/ai_0.8.1_1773971226787_0.2893317883191273","host":"s3://npm-registry-packages-npm-production"}},"0.8.2":{"name":"@astro-minimax/ai","version":"0.8.2","keywords":["astro","ai","llm","rag","openai","cloudflare-ai","vector-search","streaming","chatbot"],"author":{"name":"Souloss"},"license":"MIT","_id":"@astro-minimax/ai@0.8.2","maintainers":[{"name":"souloss","email":"826245622@qq.com"}],"homepage":"https://github.com/souloss/astro-minimax#readme","bugs":{"url":"https://github.com/souloss/astro-minimax/issues"},"bin":{"astro-ai-dev":"dist/server/dev-server.js"},"dist":{"shasum":"2ea93fb536c2c93b8ab652e82cbfa0ec79e5e56c","tarball":"https://registry.npmjs.org/@astro-minimax/ai/-/ai-0.8.2.tgz","fileCount":144,"integrity":"sha512-bwLzRZ6kkOFRcRgkUrwZLm9D2GVf0V+gBurZhadPTpuBBpDlD2jESav4SZ4B0ET3UvePKdYE036f0vpLb/5kmQ==","signatures":[{"sig":"MEUCIQCn/QBvq3RZozz1BFEwKSQv7kRK9hOEQ1iT3gPmrpjQ0AIgeITu6FC8QmhKgMzqR5q8FgZ/bBNiKoJMaVpwS6mVKW0=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":249389},"type":"module","_from":"file:astro-minimax-ai-0.8.2.tgz","engines":{"node":">=22.12.0","pnpm":">=9.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./data":{"types":"./dist/data/index.d.ts","import":"./dist/data/index.js"},"./prompt":{"types":"./dist/prompt/index.d.ts","import":"./dist/prompt/index.js"},"./search":{"types":"./dist/search/index.d.ts","import":"./dist/search/index.js"},"./server":{"types":"./dist/server/index.d.ts","import":"./dist/server/index.js"},"./stream":{"types":"./dist/stream/index.d.ts","import":"./dist/stream/index.js"},"./providers":{"types":"./dist/providers/index.d.ts","import":"./dist/providers/index.js"},"./middleware":{"types":"./dist/middleware/index.d.ts","import":"./dist/middleware/index.js"},"./intelligence":{"types":"./dist/intelligence/index.d.ts","import":"./dist/intelligence/index.js"},"./package.json":"./package.json","./fact-registry":{"types":"./dist/fact-registry/index.d.ts","import":"./dist/fact-registry/index.js"},"./styles/source.css":"./src/styles/source.css","./components/ChatPanel":{"types":"./dist/components/ChatPanel.d.ts","import":"./dist/components/ChatPanel.js"},"./components/AIChatContainer":{"types":"./dist/components/AIChatContainer.d.ts","import":"./dist/components/AIChatContainer.js"},"./components/AIChatWidget.astro":"./dist/components/AIChatWidget.astro"},"scripts":{"build":"node scripts/build.mjs","clean":"rm -rf dist","typecheck":"tsc --noEmit","build:watch":"node scripts/build.mjs --watch","build:components":"node scripts/build-components.mjs"},"_npmUser":{"name":"souloss","email":"826245622@qq.com"},"_resolved":"/tmp/3daf18d726494142b575aab73d9cd228/astro-minimax-ai-0.8.2.tgz","_integrity":"sha512-bwLzRZ6kkOFRcRgkUrwZLm9D2GVf0V+gBurZhadPTpuBBpDlD2jESav4SZ4B0ET3UvePKdYE036f0vpLb/5kmQ==","repository":{"url":"git+https://github.com/souloss/astro-minimax.git","type":"git","directory":"packages/ai"},"_npmVersion":"10.9.0","description":"Vendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs — supports OpenAI, Cloudflare AI, and custom providers.","directories":{},"sideEffects":false,"_nodeVersion":"23.2.0","dependencies":{"ai":"^6.0.116","workers-ai-provider":"^3.1.2","@astro-minimax/notify":"^0.7.5","@ai-sdk/openai-compatible":"^2.0.35"},"_hasShrinkwrap":false,"devDependencies":{"esbuild":"^0.25.0","typescript":"^5.9.3","@types/node":"^22.0.0","@cloudflare/workers-types":"^4.0.0"},"peerDependencies":{"preact":"^10.0.0","@ai-sdk/react":"^3.0.0","@cloudflare/workers-types":"^4.0.0"},"optionalDependencies":{"undici":"^6.0.0"},"peerDependenciesMeta":{"preact":{"optional":true},"@ai-sdk/react":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/ai_0.8.2_1774072157656_0.3550330191372437","host":"s3://npm-registry-packages-npm-production"}},"0.8.3":{"name":"@astro-minimax/ai","version":"0.8.3","keywords":["astro","ai","llm","rag","openai","cloudflare-ai","vector-search","streaming","chatbot"],"author":{"name":"Souloss"},"license":"MIT","_id":"@astro-minimax/ai@0.8.3","maintainers":[{"name":"souloss","email":"826245622@qq.com"}],"homepage":"https://github.com/souloss/astro-minimax#readme","bugs":{"url":"https://github.com/souloss/astro-minimax/issues"},"bin":{"astro-ai-dev":"dist/server/dev-server.js"},"dist":{"shasum":"5e6ee2f1ad8d8de3fbece193f3eb13f0ead4aa04","tarball":"https://registry.npmjs.org/@astro-minimax/ai/-/ai-0.8.3.tgz","fileCount":144,"integrity":"sha512-0IAgrgpQGCyx1UgVCZqqdBZRceDjlYNiCRbKuv8bfKeNgxld4s8ITHnmm5NwVuSGXwa59RLEe/lcN8oz5OF7/g==","signatures":[{"sig":"MEUCIB0HX9jToYhr05w4LRW2h4npshAmABEFXl772efmnZCKAiEA2GRoIn7GLg3EuXGJ9db9KYw8VP2nLwIDlRn3iNE+6Lc=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":249389},"type":"module","_from":"file:astro-minimax-ai-0.8.3.tgz","engines":{"node":">=22.12.0","pnpm":">=9.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./data":{"types":"./dist/data/index.d.ts","import":"./dist/data/index.js"},"./prompt":{"types":"./dist/prompt/index.d.ts","import":"./dist/prompt/index.js"},"./search":{"types":"./dist/search/index.d.ts","import":"./dist/search/index.js"},"./server":{"types":"./dist/server/index.d.ts","import":"./dist/server/index.js"},"./stream":{"types":"./dist/stream/index.d.ts","import":"./dist/stream/index.js"},"./providers":{"types":"./dist/providers/index.d.ts","import":"./dist/providers/index.js"},"./middleware":{"types":"./dist/middleware/index.d.ts","import":"./dist/middleware/index.js"},"./intelligence":{"types":"./dist/intelligence/index.d.ts","import":"./dist/intelligence/index.js"},"./package.json":"./package.json","./fact-registry":{"types":"./dist/fact-registry/index.d.ts","import":"./dist/fact-registry/index.js"},"./styles/source.css":"./src/styles/source.css","./components/ChatPanel":{"types":"./dist/components/ChatPanel.d.ts","import":"./dist/components/ChatPanel.js"},"./components/AIChatContainer":{"types":"./dist/components/AIChatContainer.d.ts","import":"./dist/components/AIChatContainer.js"},"./components/AIChatWidget.astro":"./dist/components/AIChatWidget.astro"},"scripts":{"build":"node scripts/build.mjs","clean":"rm -rf dist","typecheck":"tsc --noEmit","build:watch":"node scripts/build.mjs --watch","build:components":"node scripts/build-components.mjs"},"_npmUser":{"name":"souloss","email":"826245622@qq.com"},"_resolved":"/tmp/d1986077830269d4dd12460b2444c625/astro-minimax-ai-0.8.3.tgz","_integrity":"sha512-0IAgrgpQGCyx1UgVCZqqdBZRceDjlYNiCRbKuv8bfKeNgxld4s8ITHnmm5NwVuSGXwa59RLEe/lcN8oz5OF7/g==","repository":{"url":"git+https://github.com/souloss/astro-minimax.git","type":"git","directory":"packages/ai"},"_npmVersion":"10.9.0","description":"Vendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs — supports OpenAI, Cloudflare AI, and custom providers.","directories":{},"sideEffects":false,"_nodeVersion":"23.2.0","dependencies":{"ai":"^6.0.116","workers-ai-provider":"^3.1.2","@astro-minimax/notify":"^0.7.5","@ai-sdk/openai-compatible":"^2.0.35"},"_hasShrinkwrap":false,"devDependencies":{"esbuild":"^0.25.0","typescript":"^5.9.3","@types/node":"^22.0.0","@cloudflare/workers-types":"^4.0.0"},"peerDependencies":{"preact":"^10.0.0","@ai-sdk/react":"^3.0.0","@cloudflare/workers-types":"^4.0.0"},"optionalDependencies":{"undici":"^6.0.0"},"peerDependenciesMeta":{"preact":{"optional":true},"@ai-sdk/react":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/ai_0.8.3_1774072438268_0.47770441452760104","host":"s3://npm-registry-packages-npm-production"}},"0.9.0":{"name":"@astro-minimax/ai","version":"0.9.0","keywords":["astro","ai","llm","rag","openai","cloudflare-ai","vector-search","streaming","chatbot"],"author":{"name":"Souloss"},"license":"MIT","_id":"@astro-minimax/ai@0.9.0","maintainers":[{"name":"souloss","email":"826245622@qq.com"}],"homepage":"https://github.com/souloss/astro-minimax#readme","bugs":{"url":"https://github.com/souloss/astro-minimax/issues"},"bin":{"astro-ai-dev":"dist/server/dev-server.js"},"dist":{"shasum":"1c5b437fad6aa6737017d9ff96527f050a8ef616","tarball":"https://registry.npmjs.org/@astro-minimax/ai/-/ai-0.9.0.tgz","fileCount":194,"integrity":"sha512-NxBlY8KhwaWHYk0XuMN5RHldBU5bprfru+dkO7TxN4K89XqIGZ7oIfNPsbEFdAuDyRLtMtXm2bLLRahA4GMWzw==","signatures":[{"sig":"MEYCIQD+r/w5nodTDD5p3CHb5g1ZJig1y5IjV3R458teQ+EhDAIhAIsqzRak4GAGvlJIUfsMNi9Es0U7kcn/QrAn+P+nEtWh","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":406163},"type":"module","_from":"file:astro-minimax-ai-0.9.0.tgz","engines":{"node":">=22.12.0","pnpm":">=9.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./data":{"types":"./dist/data/index.d.ts","import":"./dist/data/index.js"},"./prompt":{"types":"./dist/prompt/index.d.ts","import":"./dist/prompt/index.js"},"./search":{"types":"./dist/search/index.d.ts","import":"./dist/search/index.js"},"./server":{"types":"./dist/server/index.d.ts","import":"./dist/server/index.js"},"./stream":{"types":"./dist/stream/index.d.ts","import":"./dist/stream/index.js"},"./providers":{"types":"./dist/providers/index.d.ts","import":"./dist/providers/index.js"},"./middleware":{"types":"./dist/middleware/index.d.ts","import":"./dist/middleware/index.js"},"./intelligence":{"types":"./dist/intelligence/index.d.ts","import":"./dist/intelligence/index.js"},"./package.json":"./package.json","./fact-registry":{"types":"./dist/fact-registry/index.d.ts","import":"./dist/fact-registry/index.js"},"./styles/source.css":"./src/styles/source.css","./components/ChatPanel":{"types":"./dist/components/ChatPanel.d.ts","import":"./dist/components/ChatPanel.js"},"./components/AIChatContainer":{"types":"./dist/components/AIChatContainer.d.ts","import":"./dist/components/AIChatContainer.js"},"./components/AIChatWidget.astro":"./dist/components/AIChatWidget.astro"},"scripts":{"build":"node scripts/build.mjs","clean":"rm -rf dist","typecheck":"tsc --noEmit","build:watch":"node scripts/build.mjs --watch","build:components":"node scripts/build-components.mjs"},"_npmUser":{"name":"souloss","email":"826245622@qq.com"},"_resolved":"/tmp/f47ad05042613d377319da5c4780a9d8/astro-minimax-ai-0.9.0.tgz","_integrity":"sha512-NxBlY8KhwaWHYk0XuMN5RHldBU5bprfru+dkO7TxN4K89XqIGZ7oIfNPsbEFdAuDyRLtMtXm2bLLRahA4GMWzw==","repository":{"url":"git+https://github.com/souloss/astro-minimax.git","type":"git","directory":"packages/ai"},"_npmVersion":"10.9.0","description":"Vendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs — supports OpenAI, Cloudflare AI, and custom providers.","directories":{},"sideEffects":false,"_nodeVersion":"23.2.0","dependencies":{"ai":"^6.0.116","workers-ai-provider":"^3.1.2","@astro-minimax/notify":"0.7.5","@ai-sdk/openai-compatible":"^2.0.35"},"_hasShrinkwrap":false,"devDependencies":{"esbuild":"^0.25.0","typescript":"^5.9.3","@types/node":"^22.0.0","@cloudflare/workers-types":"^4.0.0"},"peerDependencies":{"preact":"^10.0.0","@ai-sdk/react":"^3.0.0","@cloudflare/workers-types":"^4.0.0"},"optionalDependencies":{"undici":"^6.0.0"},"peerDependenciesMeta":{"preact":{"optional":true},"@ai-sdk/react":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/ai_0.9.0_1774193062917_0.3925766750426116","host":"s3://npm-registry-packages-npm-production"}},"0.9.2":{"name":"@astro-minimax/ai","version":"0.9.2","keywords":["astro","ai","llm","rag","openai","cloudflare-ai","vector-search","streaming","chatbot"],"author":{"name":"Souloss"},"license":"MIT","_id":"@astro-minimax/ai@0.9.2","maintainers":[{"name":"souloss","email":"826245622@qq.com"}],"homepage":"https://github.com/souloss/astro-minimax#readme","bugs":{"url":"https://github.com/souloss/astro-minimax/issues"},"bin":{"astro-ai-dev":"dist/server/dev-server.js"},"dist":{"shasum":"20dc6ea64cbadb88117f3de439b99b10159eed52","tarball":"https://registry.npmjs.org/@astro-minimax/ai/-/ai-0.9.2.tgz","fileCount":317,"integrity":"sha512-w5l9fUS6j0xbMsb/wMaVpefvsc5sTByTD+uIlNqzJDRuY+j+zIzPM6vv7NqT9P6Ur7fayXpp9Wy5LLogXGbR5A==","signatures":[{"sig":"MEUCIDatwbiCzRAUUXXembFDSOwamEla6m/J81Sjpql6wb9uAiEA55ynalKZRyR6a9Rryb/SENRACKC9FY/JIeAzQnnnfRU=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":96840579},"type":"module","_from":"file:astro-minimax-ai-0.9.2.tgz","engines":{"node":">=22.12.0","pnpm":">=9.0.0"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./data":{"types":"./dist/data/index.d.ts","import":"./dist/data/index.js"},"./prompt":{"types":"./dist/prompt/index.d.ts","import":"./dist/prompt/index.js"},"./search":{"types":"./dist/search/index.d.ts","import":"./dist/search/index.js"},"./server":{"types":"./dist/server/index.d.ts","import":"./dist/server/index.js"},"./stream":{"types":"./dist/stream/index.d.ts","import":"./dist/stream/index.js"},"./providers":{"types":"./dist/providers/index.d.ts","import":"./dist/providers/index.js"},"./extensions":{"types":"./dist/extensions/index.d.ts","import":"./dist/extensions/index.js"},"./middleware":{"types":"./dist/middleware/index.d.ts","import":"./dist/middleware/index.js"},"./intelligence":{"types":"./dist/intelligence/index.d.ts","import":"./dist/intelligence/index.js"},"./package.json":"./package.json","./fact-registry":{"types":"./dist/fact-registry/index.d.ts","import":"./dist/fact-registry/index.js"},"./structured-output":{"types":"./dist/structured-output/index.d.ts","import":"./dist/structured-output/index.js"},"./styles/source.css":"./src/styles/source.css","./components/ChatPanel":{"types":"./dist/components/ChatPanel.d.ts","import":"./dist/components/ChatPanel.js"},"./components/AIChatContainer":{"types":"./dist/components/AIChatContainer.d.ts","import":"./dist/components/AIChatContainer.js"},"./components/AIChatWidget.astro":"./dist/components/AIChatWidget.astro"},"scripts":{"test":"vitest run","build":"node scripts/build.mjs","clean":"rm -rf dist","typecheck":"tsc --noEmit","test:watch":"vitest","build:watch":"node scripts/build.mjs --watch","test:coverage":"vitest run --coverage","build:components":"node scripts/build-components.mjs"},"_npmUser":{"name":"souloss","email":"826245622@qq.com"},"_resolved":"/tmp/af206f7e33b265e55d5103c98d375efc/astro-minimax-ai-0.9.2.tgz","_integrity":"sha512-w5l9fUS6j0xbMsb/wMaVpefvsc5sTByTD+uIlNqzJDRuY+j+zIzPM6vv7NqT9P6Ur7fayXpp9Wy5LLogXGbR5A==","repository":{"url":"git+https://github.com/souloss/astro-minimax.git","type":"git","directory":"packages/ai"},"_npmVersion":"10.9.0","description":"Vendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs — supports OpenAI, Cloudflare AI, and custom providers.","directories":{},"sideEffects":false,"_nodeVersion":"23.2.0","dependencies":{"ai":"^6.0.116","zod":"^4.3.6","workers-ai-provider":"^3.1.2","@astro-minimax/notify":"0.9.2","@ai-sdk/openai-compatible":"^2.0.35"},"_hasShrinkwrap":false,"devDependencies":{"vitest":"^3.0.0","esbuild":"^0.25.0","typescript":"^5.9.3","@types/node":"^22.0.0","@vitest/coverage-v8":"^3.0.0","@cloudflare/workers-types":"^4.0.0"},"peerDependencies":{"shiki":"^1.0.0 || ^2.0.0","preact":"^10.0.0","mermaid":"^11.0.0","markmap-lib":"^0.18.0","markmap-view":"^0.18.0","@ai-sdk/react":"^3.0.0","@cloudflare/workers-types":"^4.0.0"},"optionalDependencies":{"undici":"^6.0.0"},"peerDependenciesMeta":{"shiki":{"optional":true},"preact":{"optional":true},"mermaid":{"optional":true},"markmap-lib":{"optional":true},"markmap-view":{"optional":true},"@ai-sdk/react":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/ai_0.9.2_1774345760698_0.5008157668664439","host":"s3://npm-registry-packages-npm-production"}},"0.9.3":{"name":"@astro-minimax/ai","version":"0.9.3","type":"module","description":"Vendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs — supports OpenAI, Cloudflare AI, and custom providers.","author":{"name":"Souloss"},"license":"MIT","keywords":["astro","ai","llm","rag","openai","cloudflare-ai","vector-search","streaming","chatbot"],"homepage":"https://github.com/souloss/astro-minimax#readme","bugs":{"url":"https://github.com/souloss/astro-minimax/issues"},"repository":{"type":"git","url":"git+https://github.com/souloss/astro-minimax.git","directory":"packages/ai"},"bin":{"astro-ai-dev":"dist/server/dev-server.js"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"},"./middleware":{"types":"./dist/middleware/index.d.ts","import":"./dist/middleware/index.js"},"./cache":{"types":"./dist/cache/index.d.ts","import":"./dist/cache/index.js"},"./search":{"types":"./dist/search/index.d.ts","import":"./dist/search/index.js"},"./intelligence":{"types":"./dist/intelligence/index.d.ts","import":"./dist/intelligence/index.js"},"./prompt":{"types":"./dist/prompt/index.d.ts","import":"./dist/prompt/index.js"},"./data":{"types":"./dist/data/index.d.ts","import":"./dist/data/index.js"},"./fact-registry":{"types":"./dist/fact-registry/index.d.ts","import":"./dist/fact-registry/index.js"},"./server":{"types":"./dist/server/index.d.ts","import":"./dist/server/index.js"},"./extensions":{"types":"./dist/extensions/index.d.ts","import":"./dist/extensions/index.js"},"./structured-output":{"types":"./dist/structured-output/index.d.ts","import":"./dist/structured-output/index.js"},"./tools":{"types":"./dist/tools/index.d.ts","import":"./dist/tools/index.js"},"./components/ChatPanel":{"types":"./dist/components/ChatPanel.d.ts","import":"./dist/components/ChatPanel.js"},"./components/AIChatContainer":{"types":"./dist/components/AIChatContainer.d.ts","import":"./dist/components/AIChatContainer.js"},"./components/AIChatWidget.astro":"./dist/components/AIChatWidget.astro","./styles/source.css":"./src/styles/source.css","./package.json":"./package.json"},"sideEffects":false,"dependencies":{"@ai-sdk/openai-compatible":"^2.0.35","ai":"^6.0.116","workers-ai-provider":"^3.1.2","zod":"^4.3.6","@astro-minimax/knowledge-model":"0.9.3"},"optionalDependencies":{"undici":"^6.0.0"},"peerDependencies":{"@ai-sdk/react":"^3.0.0","@cloudflare/workers-types":"^4.0.0","preact":"^10.0.0","shiki":"^1.0.0 || ^2.0.0","mermaid":"^11.0.0","markmap-lib":"^0.18.0","markmap-view":"^0.18.0","@astro-minimax/notify":"0.9.3"},"peerDependenciesMeta":{"@ai-sdk/react":{"optional":true},"preact":{"optional":true},"shiki":{"optional":true},"mermaid":{"optional":true},"markmap-lib":{"optional":true},"markmap-view":{"optional":true},"@astro-minimax/notify":{"optional":true}},"devDependencies":{"@cloudflare/workers-types":"^4.0.0","@types/node":"^22.0.0","@vitest/coverage-v8":"^3.0.0","esbuild":"^0.25.0","typescript":"^5.9.3","vitest":"^3.0.0"},"engines":{"node":">=22.12.0","pnpm":">=9.0.0"},"scripts":{"build":"node scripts/build.mjs","build:watch":"node scripts/build.mjs --watch","build:components":"node scripts/build-components.mjs","typecheck":"tsc --noEmit","test":"vitest run","test:watch":"vitest","test:coverage":"vitest run --coverage","clean":"rm -rf dist"},"_id":"@astro-minimax/ai@0.9.3","_integrity":"sha512-a5QYffdZWer29gbYnShUFaMhXeS4MW6nik8g7X1NhvrBTN+4QkssYsBmItpETK7q/SsnigsHrj2MmnsvitC4yw==","_resolved":"/tmp/62f09e8cc9f1c6985c7116b145f1d166/astro-minimax-ai-0.9.3.tgz","_from":"file:astro-minimax-ai-0.9.3.tgz","_nodeVersion":"23.2.0","_npmVersion":"10.9.0","dist":{"integrity":"sha512-a5QYffdZWer29gbYnShUFaMhXeS4MW6nik8g7X1NhvrBTN+4QkssYsBmItpETK7q/SsnigsHrj2MmnsvitC4yw==","shasum":"913cc4965a564ff915b2ce73a1b694da6c0f6ec4","tarball":"https://registry.npmjs.org/@astro-minimax/ai/-/ai-0.9.3.tgz","fileCount":287,"unpackedSize":566014,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIEk9nV0GJ6+NcSc8nSHSW3qIy/mLpDpyrOebAmq/tGPLAiEAmcmfLOe4gOHQHZThSLggY8e5gMMSWCpR3b+wPhE8970="}]},"_npmUser":{"name":"souloss","email":"826245622@qq.com"},"directories":{},"maintainers":[{"name":"souloss","email":"826245622@qq.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/ai_0.9.3_1774722806713_0.3728259837318122"},"_hasShrinkwrap":false}},"time":{"created":"2026-03-17T06:34:28.159Z","modified":"2026-03-28T18:33:27.061Z","0.2.0":"2026-03-17T06:34:28.425Z","0.5.0":"2026-03-17T10:41:04.539Z","0.7.0":"2026-03-17T21:17:43.968Z","0.7.1":"2026-03-18T10:12:10.011Z","0.7.2":"2026-03-18T14:56:48.757Z","0.7.3":"2026-03-18T17:17:48.223Z","0.7.4":"2026-03-18T18:31:25.809Z","0.7.5":"2026-03-18T18:39:54.511Z","0.8.0":"2026-03-19T21:41:46.833Z","0.8.1":"2026-03-20T01:47:06.946Z","0.8.2":"2026-03-21T05:49:17.807Z","0.8.3":"2026-03-21T05:53:58.450Z","0.9.0":"2026-03-22T15:24:23.086Z","0.9.2":"2026-03-24T09:49:21.276Z","0.9.3":"2026-03-28T18:33:26.927Z"},"bugs":{"url":"https://github.com/souloss/astro-minimax/issues"},"author":{"name":"Souloss"},"license":"MIT","homepage":"https://github.com/souloss/astro-minimax#readme","keywords":["astro","ai","llm","rag","openai","cloudflare-ai","vector-search","streaming","chatbot"],"repository":{"type":"git","url":"git+https://github.com/souloss/astro-minimax.git","directory":"packages/ai"},"description":"Vendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs — supports OpenAI, Cloudflare AI, and custom providers.","maintainers":[{"name":"souloss","email":"826245622@qq.com"}],"readme":"# @astro-minimax/ai\n\nVendor-agnostic AI integration package with full RAG pipeline for astro-minimax blogs. Supports OpenAI-compatible APIs, Cloudflare Workers AI, and mock fallback.\n\n## Architecture\n\n```\n┌─────────────────────────────────────────────────────────┐\n│  Components (ChatPanel / AIChatWidget / AIChatContainer) │\n│  → useChat + DefaultChatTransport                        │\n└──────────────────────────┬──────────────────────────────┘\n                           │ POST /api/chat\n┌──────────────────────────▼──────────────────────────────┐\n│  Server (chat-handler.ts)                                │\n│  Rate Limit → Validate → Search → Evidence → Prompt →   │\n│  Provider Manager → streamText → SSE Response            │\n└──────────────────────────┬──────────────────────────────┘\n                           │\n     ┌─────────────────────┼──────────────────────┐\n     │                     │                      │\n ┌───▼───┐          ┌─────▼─────┐          ┌─────▼────┐\n │OpenAI │          │Workers AI │          │   Mock   │\n │Compat │          │ Binding   │          │ Fallback │\n └───────┘          └───────────┘          └──────────┘\n```\n\n### Modules\n\n| Module              | Purpose                                                                |\n| ------------------- | ---------------------------------------------------------------------- |\n| `server/`           | Reusable API handlers (`handleChatRequest`, `initializeMetadata`)      |\n| `provider-manager/` | Multi-provider management with priority, failover, health tracking     |\n| `search/`           | In-memory article/project search with session caching                  |\n| `intelligence/`     | Keyword extraction, evidence analysis, citation guard, answer mode, dynamic evidence budget |\n| `prompt/`           | Three-layer system prompt builder (static → semi-static → dynamic)     |\n| `data/`             | Bundle-backed runtime metadata loading and shared data types            |\n| `components/`       | Preact UI components (ChatPanel, AIChatWidget, AIChatContainer)        |\n| `extensions/`       | Search/prompt extensions and semantic fallback rules                   |\n| `structured-output/`| Schema-validated structured generation helpers                         |\n| `cache/`            | Response/session/injection cache utilities                             |\n| `fact-registry/`    | Verified facts used for grounded prompt assembly                       |\n| `tools/`            | Runtime tool registry and built-in action/search tools                 |\n\n## Features\n\n### Dynamic Evidence Budget\n\nThe system dynamically adjusts retrieval and analysis resources based on query complexity:\n\n| Complexity | Max Articles | Summary Length | Key Points | Deep Content |\n|------------|--------------|----------------|------------|--------------|\n| `simple`   | 4            | 48 chars       | 2          | No           |\n| `moderate` | 6            | 56 chars       | 3          | Yes          |\n| `complex`  | 8            | 64 chars       | 4          | Yes          |\n\nBudget is further adjusted by **answer mode** (count, list, opinion, recommendation):\n\n```typescript\nimport { getEvidenceBudget, applyBudgetToArticles } from '@astro-minimax/ai/intelligence';\n\nconst budget = getEvidenceBudget('moderate', 'list');\n// → { maxArticles: 8, summaryMaxLength: 80, ... }\n\nconst trimmedArticles = applyBudgetToArticles(articles, budget);\n```\n\n### Answer Mode Detection\n\nAutomatically detects the expected response format from user queries:\n\n| Mode            | Trigger Patterns              | Response Style                    |\n|-----------------|-------------------------------|-----------------------------------|\n| `fact`          | \"是什么\", \"what is\"           | Conclusion first, then evidence   |\n| `count`         | \"多少\", \"how many\"            | Number in first sentence          |\n| `list`          | \"哪些\", \"what are\"            | 2-6 items directly                |\n| `opinion`       | \"怎么看\", \"what do you think\" | \"I think...\" + 2-3 points         |\n| `recommendation`| \"推荐\", \"suggest\"             | 2-4 recommendations + reasons     |\n\nAnswer mode hints are injected into the dynamic prompt layer, guiding the LLM toward the appropriate format.\n\n### Reading Time Display\n\nArticle reading time is now displayed in the dynamic prompt layer:\n\n```\n**[Article Title](/posts/article)**\n阅读时间：约 5 分钟\n摘要：Article summary...\n```\n\n### Enhanced Citation Guard\n\nImproved URL validation prevents hallucinated links:\n\n- **Scheme whitelist**: Only `http://` and `https://` allowed\n- **Domain validation**: Blocks localhost, private IPs, internal networks\n- **XSS prevention**: Sanitizes dangerous URL patterns\n\n```typescript\nimport { createCitationGuardTransform } from '@astro-minimax/ai/intelligence';\n\nconst guard = createCitationGuardTransform({\n  articles,\n  projects,\n  siteUrl: 'https://example.com',\n  onApplied: ({ actions }) => console.log('Rewrote:', actions),\n});\n```\n\n## Installation\n\n```bash\npnpm add @astro-minimax/ai\n```\n\nThe `@astro-minimax/core` integration auto-detects this package and renders the AI chat widget.\n\n## Configuration\n\nIn `src/config.ts`:\n\n```typescript\nexport const SITE = {\n  ai: {\n    enabled: true,\n    mockMode: false,\n    apiEndpoint: \"/api/chat\",\n    welcomeMessage: undefined, // auto-generated\n    placeholder: undefined,\n  },\n};\n```\n\n### Environment Variables\n\n| Variable            | Required    | Description                                                 |\n| ------------------- | ----------- | ----------------------------------------------------------- |\n| `AI_BASE_URL`       | For OpenAI  | Base URL of OpenAI-compatible API                           |\n| `AI_API_KEY`        | For OpenAI  | API key                                                     |\n| `AI_MODEL`          | Recommended | Model name for OpenAI provider (default: `gpt-4o-mini`)     |\n| `AI_KEYWORD_MODEL`  | Optional    | Model for keyword extraction (defaults to `AI_MODEL`)       |\n| `AI_EVIDENCE_MODEL` | Optional    | Model for evidence analysis (defaults to keyword model)     |\n| `AI_BINDING_NAME`   | For Workers | Cloudflare AI binding name (default: `minimaxAI`)           |\n| `AI_WORKERS_MODEL`  | For Workers | Model for Workers AI (default: `@cf/zai-org/glm-4.7-flash`) |\n| `SITE_AUTHOR`       | Recommended | Author name for prompts                                     |\n| `SITE_URL`          | Recommended | Site URL for article links                                  |\n\n### Response Cache Configuration\n\n| Variable                    | Default | Description                               |\n| --------------------------- | ------- | ----------------------------------------- |\n| `AI_CACHE_ENABLED`          | `false` | Enable AI response caching                |\n| `AI_CACHE_TTL`              | `3600`  | Cache TTL in seconds (1 hour)             |\n| `AI_CACHE_PLAYBACK_DELAY`   | `20`    | Delay between chunks during playback (ms) |\n| `AI_CACHE_CHUNK_SIZE`       | `15`    | Characters per chunk during playback      |\n| `AI_CACHE_THINKING_DELAY`   | `5`     | Delay for thinking content playback (ms)  |\n\nWhen enabled, the system caches complete AI responses (including thinking/reasoning content) for public questions like \"What tech stack does this blog use?\". Subsequent identical queries are served from cache with simulated streaming playback, reducing API costs and response time.\n\n## Server Module\n\nThe server module provides reusable request handlers, decoupled from any specific runtime (Cloudflare, Node.js, etc.).\n\n### Usage in Cloudflare Pages Functions\n\n```typescript\n// functions/api/chat.ts\nimport { handleChatRequest, initializeMetadata } from '@astro-minimax/ai/server';\nimport knowledgeBundle from '../../datas/knowledge/runtime/knowledge-bundle.json';\n\nexport const onRequest: PagesFunction = async (context) => {\n  initializeMetadata({ knowledgeBundle }, context.env);\n\n  return handleChatRequest({ env: context.env, request: context.request });\n};\n```\n\n### Chat API Contract\n\n**Request:** `POST /api/chat`\n\n```json\n{\n  \"context\": {\n    \"scope\": \"article\",\n    \"article\": {\n      \"slug\": \"my-post\",\n      \"title\": \"My Post Title\",\n      \"summary\": \"Brief summary...\",\n      \"keyPoints\": [\"Point 1\", \"Point 2\"],\n      \"categories\": [\"tech\"]\n    }\n  },\n  \"id\": \"article:my-post\",\n  \"messages\": [...]\n}\n```\n\n`context.scope` values:\n\n- `\"global\"` — General blog chat (default)\n- `\"article\"` — Reading companion mode, focused on a specific article\n\n**Response:** UI Message Stream Protocol (SSE)\n\n- `text-start` / `text-delta` / `text-end` — Streaming text content\n- `source` — RAG article references\n- `message-metadata` — Processing status updates\n- `finish` — Stream completion\n\n**Error Response:**\n\n```json\n{\n  \"error\": \"请求太频繁，请稍后再试\",\n  \"code\": \"RATE_LIMITED\",\n  \"retryable\": true,\n  \"retryAfter\": 10\n}\n```\n\n| Code                   | Status | Retryable | Description           |\n| ---------------------- | ------ | --------- | --------------------- |\n| `RATE_LIMITED`         | 429    | Yes       | Too many requests     |\n| `PROVIDER_UNAVAILABLE` | 503    | Yes       | All providers failed  |\n| `TIMEOUT`              | 504    | Yes       | Request timeout       |\n| `INPUT_TOO_LONG`       | 400    | No        | Message exceeds limit |\n| `INVALID_REQUEST`      | 400    | No        | Malformed request     |\n| `INTERNAL_ERROR`       | 500    | Yes       | Server error          |\n\n## Provider System\n\n### Priority & Failover\n\n```\nWorkers AI (weight: 100) → OpenAI Compatible (weight: 90) → Mock (weight: 0)\n```\n\nWhen a provider fails, the next one is tried automatically. Mock fallback ensures users always get a response.\n\n### Timeout Budget (per request: 45s total)\n\n| Stage              | Timeout | Behavior on timeout              |\n| ------------------ | ------- | -------------------------------- |\n| Keyword extraction | 5s      | Falls back to local search query |\n| Evidence analysis  | 8s      | Skipped                          |\n| LLM streaming      | 30s     | Tries next provider, then mock   |\n\n## \"Read & Chat\" (边读边聊)\n\nWhen a user opens the AI chat on an article page, the system enters **reading companion mode**:\n\n1. **Article context** flows from `PostDetails.astro` → `Layout.astro` → `AIChatWidget` → `ChatPanel`\n2. **Welcome message** references the current article title\n3. **Quick prompts** are article-specific (summarize, explain, related topics)\n4. **API request** includes `context: { scope: \"article\", article: {...} }`\n5. **Server** enhances the prompt with article summary, key points, and reading companion instructions\n\n## Components\n\n### AIChatWidget.astro\n\nAstro entry point. Accepts `lang` and optional `articleContext` props. Renders `AIChatContainer` with `client:idle`.\n\n### AIChatContainer.tsx\n\nManages open/close state. Exposes `window.__aiChatToggle` for the floating action button.\n\n### ChatPanel.tsx\n\nCore chat UI built on `useChat` from `@ai-sdk/react`:\n\n- `DefaultChatTransport` with `prepareSendMessagesRequest` for context injection\n- Parts-based message rendering (`text`, `source`, custom data parts)\n- Error display with retry button (`regenerate()`)\n- Status indicators from message metadata\n- Mock mode with character-by-character streaming simulation\n\n## Exports\n\n| Path             | Contents                                                        |\n| ---------------- | --------------------------------------------------------------- |\n| `.`              | All modules                                                     |\n| `./server`       | `handleChatRequest`, `initializeMetadata`, error helpers, types |\n| `./middleware`   | Rate limiting                                                   |\n| `./search`       | Article/project search, session cache                           |\n| `./intelligence` | Keyword extraction, evidence analysis, citation guard, answer mode, evidence budget |\n| `./prompt`       | System prompt builder                                           |\n| `./cache`        | Cache adapters and response/session cache utilities             |\n| `./data`         | Metadata loading                                                |\n| `./fact-registry`| Verified facts registry                                         |\n| `./extensions`   | Extension registry, loader, and injector                        |\n| `./structured-output` | Structured output helpers                                   |\n| `./tools`        | Tool registry and built-in AI tools                             |\n| `./components/ChatPanel` | Preact chat panel component                             |\n| `./components/AIChatContainer` | Preact chat container component                   |\n| `./components/AIChatWidget.astro` | Astro chat widget entry point                  |\n\n## Testing\n\nThe package includes comprehensive unit tests with Vitest:\n\n```bash\ncd packages/ai\npnpm test\n```\n\nTest coverage includes:\n- Citation guard (10 tests)\n- Intent detection (7 tests)\n- Keyword extraction (7 tests)\n- Evidence analysis (7 tests)\n- Evidence budget (5 tests)\n","readmeFilename":"README.md"}