agentdb 1.1.0 → 1.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -710,9 +710,15 @@ ${colors.bright}EXAMPLES:${colors.reset}
710
710
  agentdb db stats
711
711
  `);
712
712
  }
713
- // ESM entry point check
714
- if (import.meta.url === `file://${process.argv[1]}`) {
715
- main().catch(console.error);
713
+ // ESM entry point - run when executed directly
714
+ if (import.meta.url.startsWith('file:')) {
715
+ const modulePath = import.meta.url.slice(7); // Remove 'file://'
716
+ const scriptPath = process.argv[1];
717
+
718
+ // Run if this file is being executed (handles both direct execution and npx/global bin)
719
+ if (modulePath.includes('agentdb-cli.js') || scriptPath?.includes('agentdb')) {
720
+ main().catch(console.error);
721
+ }
716
722
  }
717
723
  export { AgentDBCLI };
718
724
  //# sourceMappingURL=agentdb-cli.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agentdb",
3
- "version": "1.1.0",
3
+ "version": "1.1.1",
4
4
  "description": "AgentDB - Frontier Memory Features: Causal reasoning, reflexion memory, skill library, explainable recall, and automated learning for AI agents. 150x faster vector search with HNSW indexing.",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",