Skip to content

Soul-driven AI agent with permission-hardened tools, token budgets, and multi-channel access. Runs 24/7 from CLI, Telegram or More.

refactor: remove unused Ink dependencies and configure bundle settings for build optimization

Salman Qureshif2d1767155bd
diff --git a/package-lock.json b/package-lock.json
index bd989e02..0d3c1581 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -17,12 +17,8 @@
"chalk": "^5.4.0",
"commander": "^12.1.0",
"dotenv": "^16.4.7",
- "figures": "^6.1.0",
"grammy": "^1.42.0",
"ink": "^5.2.1",
- "ink-select-input": "^6.2.0",
- "ink-spinner": "^5.0.0",
- "ink-text-input": "^6.0.0",
"js-tiktoken": "^1.0.19",
"marked": "^14.1.4",
"node-cron": "^3.0.3",
@@ -1592,17 +1588,6 @@
"url": "https://github.com/sponsors/sindresorhus"
}
},
- "node_modules/cli-spinners": {
- "version": "2.9.2",
- "resolved": "https://registry.npmjs.org/cli-spinners/-/cli-spinners-2.9.2.tgz",
- "integrity": "sha512-ywqV+5MmyL4E7ybXgKys4DugZbX0FC6LnwrhjuykIjnK9k8OQacQ7axGKnjDXWNhns0xot3bZI5h55H8yo9cJg==",
- "engines": {
- "node": ">=6"
- },
- "funding": {
- "url": "https://github.com/sponsors/sindresorhus"
- }
- },
"node_modules/cli-truncate": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/cli-truncate/-/cli-truncate-4.0.0.tgz",
@@ -1901,20 +1886,6 @@
}
}
},
- "node_modules/figures": {
- "version": "6.1.0",
- "resolved": "https://registry.npmjs.org/figures/-/figures-6.1.0.tgz",
- "integrity": "sha512-d+l3qxjSesT4V7v2fh+QnmFnUWv9lSpjarhShNTgBOfA0ttejbQUAlHLitbjkoRiDulW0OPoQPYIGhIC8ohejg==",
- "dependencies": {
- "is-unicode-supported": "^2.0.0"
- },
- "engines": {
- "node": ">=18"
- },
- "funding": {
- "url": "https://github.com/sponsors/sindresorhus"
- }
- },
"node_modules/file-uri-to-path": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz",
@@ -2079,53 +2050,6 @@
}
}
},
- "node_modules/ink-select-input": {
- "version": "6.2.0",
- "resolved": "https://registry.npmjs.org/ink-select-input/-/ink-select-input-6.2.0.tgz",
- "integrity": "sha512-304fZXxkpYxJ9si5lxRCaX01GNlmPBgOZumXXRnPYbHW/iI31cgQynqk2tRypGLOF1cMIwPUzL2LSm6q4I5rQQ==",
- "dependencies": {
- "figures": "^6.1.0",
- "to-rotated": "^1.0.0"
- },
- "engines": {
- "node": ">=18"
- },
- "peerDependencies": {
- "ink": ">=5.0.0",
- "react": ">=18.0.0"
- }
- },
- "node_modules/ink-spinner": {
- "version": "5.0.0",
- "resolved": "https://registry.npmjs.org/ink-spinner/-/ink-spinner-5.0.0.tgz",
- "integrity": "sha512-EYEasbEjkqLGyPOUc8hBJZNuC5GvXGMLu0w5gdTNskPc7Izc5vO3tdQEYnzvshucyGCBXc86ig0ujXPMWaQCdA==",
- "dependencies": {
- "cli-spinners": "^2.7.0"
- },
- "engines": {
- "node": ">=14.16"
- },
- "peerDependencies": {
- "ink": ">=4.0.0",
- "react": ">=18.0.0"
- }
- },
- "node_modules/ink-text-input": {
- "version": "6.0.0",
- "resolved": "https://registry.npmjs.org/ink-text-input/-/ink-text-input-6.0.0.tgz",
- "integrity": "sha512-Fw64n7Yha5deb1rHY137zHTAbSTNelUKuB5Kkk2HACXEtwIHBCf9OH2tP/LQ9fRYTl1F0dZgbW0zPnZk6FA9Lw==",
- "dependencies": {
- "chalk": "^5.3.0",
- "type-fest": "^4.18.2"
- },
- "engines": {
- "node": ">=18"
- },
- "peerDependencies": {
- "ink": ">=5",
- "react": ">=18"
- }
- },
"node_modules/is-fullwidth-code-point": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-4.0.0.tgz",
@@ -2151,17 +2075,6 @@
"url": "https://github.com/sponsors/sindresorhus"
}
},
- "node_modules/is-unicode-supported": {
- "version": "2.1.0",
- "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-2.1.0.tgz",
- "integrity": "sha512-mE00Gnza5EEB3Ds0HfMyllZzbBrmLOX3vfWoj9A9PEnTfratQ/BcaJOuMhnkhjXvb2+FkY3VuHqtAGpTPmglFQ==",
- "engines": {
- "node": ">=18"
- },
- "funding": {
- "url": "https://github.com/sponsors/sindresorhus"
- }
- },
"node_modules/joycon": {
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/joycon/-/joycon-3.1.1.tgz",
@@ -3249,17 +3162,6 @@
"node": ">=14.0.0"
}
},
- "node_modules/to-rotated": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/to-rotated/-/to-rotated-1.0.0.tgz",
- "integrity": "sha512-KsEID8AfgUy+pxVRLsWp0VzCa69wxzUDZnzGbyIST/bcgcrMvTYoFBX/QORH4YApoD89EDuUovx4BTdpOn319Q==",
- "engines": {
- "node": ">=18"
- },
- "funding": {
- "url": "https://github.com/sponsors/sindresorhus"
- }
- },
"node_modules/tr46": {
"version": "0.0.3",
"resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz",
@@ -5037,11 +4939,6 @@
"restore-cursor": "^4.0.0"
}
},
- "cli-spinners": {
- "version": "2.9.2",
- "resolved": "https://registry.npmjs.org/cli-spinners/-/cli-spinners-2.9.2.tgz",
- "integrity": "sha512-ywqV+5MmyL4E7ybXgKys4DugZbX0FC6LnwrhjuykIjnK9k8OQacQ7axGKnjDXWNhns0xot3bZI5h55H8yo9cJg=="
- },
"cli-truncate": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/cli-truncate/-/cli-truncate-4.0.0.tgz",
@@ -5245,14 +5142,6 @@
"dev": true,
"requires": {}
},
- "figures": {
- "version": "6.1.0",
- "resolved": "https://registry.npmjs.org/figures/-/figures-6.1.0.tgz",
- "integrity": "sha512-d+l3qxjSesT4V7v2fh+QnmFnUWv9lSpjarhShNTgBOfA0ttejbQUAlHLitbjkoRiDulW0OPoQPYIGhIC8ohejg==",
- "requires": {
- "is-unicode-supported": "^2.0.0"
- }
- },
"file-uri-to-path": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz",
@@ -5359,32 +5248,6 @@
"yoga-layout": "~3.2.1"
}
},
- "ink-select-input": {
- "version": "6.2.0",
- "resolved": "https://registry.npmjs.org/ink-select-input/-/ink-select-input-6.2.0.tgz",
- "integrity": "sha512-304fZXxkpYxJ9si5lxRCaX01GNlmPBgOZumXXRnPYbHW/iI31cgQynqk2tRypGLOF1cMIwPUzL2LSm6q4I5rQQ==",
- "requires": {
- "figures": "^6.1.0",
- "to-rotated": "^1.0.0"
- }
- },
- "ink-spinner": {
- "version": "5.0.0",
- "resolved": "https://registry.npmjs.org/ink-spinner/-/ink-spinner-5.0.0.tgz",
- "integrity": "sha512-EYEasbEjkqLGyPOUc8hBJZNuC5GvXGMLu0w5gdTNskPc7Izc5vO3tdQEYnzvshucyGCBXc86ig0ujXPMWaQCdA==",
- "requires": {
- "cli-spinners": "^2.7.0"
- }
- },
- "ink-text-input": {
- "version": "6.0.0",
- "resolved": "https://registry.npmjs.org/ink-text-input/-/ink-text-input-6.0.0.tgz",
- "integrity": "sha512-Fw64n7Yha5deb1rHY137zHTAbSTNelUKuB5Kkk2HACXEtwIHBCf9OH2tP/LQ9fRYTl1F0dZgbW0zPnZk6FA9Lw==",
- "requires": {
- "chalk": "^5.3.0",
- "type-fest": "^4.18.2"
- }
- },
"is-fullwidth-code-point": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-4.0.0.tgz",
@@ -5395,11 +5258,6 @@
"resolved": "https://registry.npmjs.org/is-in-ci/-/is-in-ci-1.0.0.tgz",
"integrity": "sha512-eUuAjybVTHMYWm/U+vBO1sY/JOCgoPCXRxzdju0K+K0BiGW0SChEL1MLC0PoCIR1OlPo5YAp8HuQoUlsWEICwg=="
},
- "is-unicode-supported": {
- "version": "2.1.0",
- "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-2.1.0.tgz",
- "integrity": "sha512-mE00Gnza5EEB3Ds0HfMyllZzbBrmLOX3vfWoj9A9PEnTfratQ/BcaJOuMhnkhjXvb2+FkY3VuHqtAGpTPmglFQ=="
- },
"joycon": {
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/joycon/-/joycon-3.1.1.tgz",
@@ -6133,11 +5991,6 @@
"integrity": "sha512-azl+t0z7pw/z958Gy9svOTuzqIk6xq+NSheJzn5MMWtWTFywIacg2wUlzKFGtt3cthx0r2SxMK0yzJOR0IES7Q==",
"dev": true
},
- "to-rotated": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/to-rotated/-/to-rotated-1.0.0.tgz",
- "integrity": "sha512-KsEID8AfgUy+pxVRLsWp0VzCa69wxzUDZnzGbyIST/bcgcrMvTYoFBX/QORH4YApoD89EDuUovx4BTdpOn319Q=="
- },
"tr46": {
"version": "0.0.3",
"resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz",
diff --git a/package.json b/package.json
index e7846c60..e735a389 100644
--- a/package.json
+++ b/package.json
@@ -62,12 +62,8 @@
"chalk": "^5.4.0",
"commander": "^12.1.0",
"dotenv": "^16.4.7",
- "figures": "^6.1.0",
"grammy": "^1.42.0",
"ink": "^5.2.1",
- "ink-select-input": "^6.2.0",
- "ink-spinner": "^5.0.0",
- "ink-text-input": "^6.0.0",
"js-tiktoken": "^1.0.19",
"marked": "^14.1.4",
"node-cron": "^3.0.3",
diff --git a/tsup.config.ts b/tsup.config.ts
index d9b65be7..39ef43dc 100644
--- a/tsup.config.ts
+++ b/tsup.config.ts
@@ -6,12 +6,31 @@ export default defineConfig({
target: "node20",
outDir: "dist",
clean: true,
+ bundle: true,
splitting: false,
sourcemap: true,
minify: false,
banner: { js: "#!/usr/bin/env node" },
external: [
+ "ai",
+ "@ai-sdk/anthropic",
+ "@ai-sdk/deepseek",
+ "@ai-sdk/openai",
+ "@grammyjs/auto-retry",
+ "chalk",
+ "commander",
+ "dotenv",
"grammy",
+ "ink",
+ "js-tiktoken",
+ "marked",
+ "node-cron",
+ "ollama-ai-provider",
+ "pino",
+ "react",
+ "react-dom",
+ "yaml",
+ "zod",
"better-sqlite3",
],
-});
\ No newline at end of file
+});