2026-08-22 02:18:27 +03:00
|
|
|
import type { NextConfig } from "next";
|
|
|
|
|
|
|
|
|
|
const nextConfig: NextConfig = {
|
|
|
|
|
// Framework-free core lives in src/ (plain TS, imported by routes and CLI alike).
|
2026-09-12 02:34:18 +03:00
|
|
|
// The pi engine must stay external: its providers are runtime-loaded Node
|
|
|
|
|
// code (undici streams, catalog data) that breaks when bundled into routes.
|
2026-09-13 14:29:16 +03:00
|
|
|
// transformers.js (embeddings) is runtime-loaded ONNX — same reason as
|
|
|
|
|
// the pi engine: bundling onnxruntime-node breaks route builds.
|
|
|
|
|
serverExternalPackages: [
|
|
|
|
|
"@earendil-works/pi-ai",
|
|
|
|
|
"@earendil-works/pi-agent-core",
|
|
|
|
|
"@huggingface/transformers",
|
|
|
|
|
],
|
2026-08-22 02:18:27 +03:00
|
|
|
};
|
|
|
|
|
|
2026-09-12 02:34:18 +03:00
|
|
|
export default nextConfig;
|