947 Commits

Author SHA1 Message Date
Alex Newman f7f11b2a4b chore(release): v8.5.0 - Cursor Support Now Available
🎉 Major release introducing full Cursor IDE support

New Features:
- Cursor IDE integration with native hook system
- Interactive setup wizard (bun run cursor:setup)
- Works without Claude Code using Gemini (free) or OpenRouter
- Cross-platform: macOS, Linux, Windows (PowerShell)
- Context injection via .cursor/rules directory
- Project registry for multi-workspace support
- MCP search tools for Cursor

Documentation:
- Full docs at docs.claude-mem.ai/cursor
- Gemini and OpenRouter setup guides

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v8.5.0
2025-12-29 23:12:15 -05:00
Alex Newman 69b2355b22 Merge pull request #493 from thedotmack/cursor-hooks-integration
feat(cursor): Complete Cursor IDE integration with cross-platform hooks
2025-12-29 23:07:07 -05:00
Alex Newman 9f1498ed24 refactor(docs): Update links in setup guides for consistency and clarity 2025-12-29 23:06:50 -05:00
Alex Newman e012c3e885 build worker service 2025-12-29 22:59:08 -05:00
Alex Newman 129c22c48d Add comprehensive tests for Cursor functionality
- Implement tests for cursor context updates in `cursor-context-update.test.ts`, validating context file creation, content structure, and edge cases.
- Create tests for cursor hook outputs in `cursor-hook-outputs.test.ts`, ensuring correct JSON output from hook scripts and handling of various input scenarios.
- Add tests for JSON utility functions in `cursor-hooks-json-utils.test.ts`, covering parsing, project name extraction, and URL encoding.
- Introduce tests for MCP configuration in `cursor-mcp-config.test.ts`, verifying configuration creation, updates, and format validation.
- Develop tests for the cursor project registry in `cursor-registry.test.ts`, ensuring correct registration, unregistration, and JSON format compliance.
2025-12-29 22:58:42 -05:00
Alex Newman 110d055b8b refactor(cursor): Update installation instructions for clarity and consistency 2025-12-29 22:40:03 -05:00
Alex Newman 101d2dd514 Implement feature X to enhance user experience and optimize performance 2025-12-29 22:32:28 -05:00
Alex Newman 646db6c490 refactor(cursor): Improve portability of sed commands in install script and update error handling in common.ps1 2025-12-29 22:32:07 -05:00
Alex Newman d160df4b86 refactor(cursor): Migrate setup commands from npm to Bun for improved performance
- Updated installation and setup commands in documentation to use Bun instead of npm.
- Adjusted commands across various setup guides including QUICKSTART.md, STANDALONE-SETUP.md, and others.
- Ensured consistency in command usage for all platforms (macOS, Linux, Windows).

This change enhances the installation process and aligns with the recent performance improvements associated with Bun.
2025-12-29 22:15:47 -05:00
Alex Newman b5e45377b0 feat: Enhance interactive setup for Claude memory integration
- Updated environment check to verify Claude Code presence.
- Improved provider selection process with clearer options and descriptions.
- Added functionality to keep current settings during provider configuration.
- Introduced installation scope selection for cursor hooks (project/user/skip).
- Implemented MCP server configuration in Cursor's mcp.json with error handling.
- Added utility functions to find MCP server script path and manage configurations.
2025-12-29 22:02:52 -05:00
Alex Newman 89a0a1baa3 feat(cursor): Update cursor commands to use Bun for improved performance 2025-12-29 21:33:48 -05:00
Alex Newman a82d1a24b9 feat(cursor): Add Windows PowerShell support for Cursor hooks
Complete Windows parity with bash scripts:
- Create 7 PowerShell scripts mirroring bash functionality
- Update installer to detect platform and install appropriate scripts
- Generate platform-specific hooks.json with PowerShell invocation
- Add enterprise support for Windows (ProgramData/Cursor)
- Update findCursorHooksDir to check for both .sh and .ps1
- Add comprehensive Windows documentation to STANDALONE-SETUP.md

Scripts added: common.ps1, session-init.ps1, context-inject.ps1,
save-observation.ps1, save-file-edit.ps1, session-summary.ps1, user-message.ps1

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-29 21:16:41 -05:00
Alex Newman ed8269250d docs(cursor): Add marketing copy and value proposition messaging
Add compelling marketing copy to Cursor documentation with consistent
messaging across all files:

- README.md: Added headline, "Why Claude-Mem?" section, quick install
- STANDALONE-SETUP.md: Added tagline and enhanced value props
- QUICKSTART.md: Added tagline and benefit statement
- docs/public/cursor/index.mdx: Added card grid highlighting benefits

Key messaging themes:
- "Persistent AI Memory for Cursor"
- "Your AI stops forgetting"
- "Free tier options available"
- "Works with or without Claude Code"

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-29 21:09:00 -05:00
Alex Newman 5325db1978 docs(cursor): Add Mintlify public documentation for Cursor integration
Create searchable public documentation for Cursor users:
- cursor/index.mdx: Landing page with installation paths and quick reference
- cursor/gemini-setup.mdx: Step-by-step Gemini free tier setup guide
- cursor/openrouter-setup.mdx: OpenRouter setup with model recommendations

Add Cursor Integration navigation group to docs.json.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-29 21:06:12 -05:00
Alex Newman 01ac957a23 feat(cursor): Add interactive setup wizard for standalone Cursor users
Phase 2 implementation: Enhanced CLI UX with guided first-run experience.

- Add `npm run cursor:setup` command for interactive wizard
- Auto-detect Claude Code installation
- Guide provider selection (Gemini recommended for free tier)
- Configure API keys interactively with settings persistence
- Auto-start worker and install hooks
- Clear instructions for next steps

This enables Cursor users without Claude Code to easily configure
claude-mem with free-tier providers like Gemini.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-29 21:02:15 -05:00
Alex Newman 8397f63af1 docs(cursor): Add standalone setup guide for Cursor users without Claude Code
- Create STANDALONE-SETUP.md with complete setup instructions for Gemini/OpenRouter
- Add "Quick Start for Cursor Users" section to README.md with standalone link
- Add provider configuration section to QUICKSTART.md with API key setup
- Fix worker restart command in README.md troubleshooting section

This enables Cursor users without Claude Code subscription to use claude-mem
with free-tier AI providers (Gemini 1500 req/day, OpenRouter free models).

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-29 20:47:22 -05:00
Alex Newman bca6b06919 feat(cursor): Enhance context injection and project registry management
- Updated `context-inject.sh` to refresh context before prompt submission and ensure worker is running.
- Added functionality to register and unregister projects for automatic context updates in `worker-service.ts`.
- Implemented methods to read and write the cursor project registry, allowing for better management of installed hooks.
- Integrated context updates into the `GeminiAgent`, `OpenRouterAgent`, and `SDKAgent` to ensure the latest context is available during sessions.

This update improves the integration of Claude-Mem with Cursor, ensuring that context is consistently updated and accessible across sessions.
2025-12-29 20:25:16 -05:00
Alex Newman 8d485890b9 feat(cursor): Add Claude-Mem Cursor hooks installation and management
- Introduced functionality for installing, uninstalling, and checking the status of Cursor hooks.
- Added a new command structure for managing hooks with detailed usage instructions.
- Implemented a method to locate the cursor-hooks directory across different environments.
- Updated build-hooks script to inform users about the location of Cursor hooks.

This enhancement streamlines the integration of Claude-Mem with Cursor, improving user experience and accessibility of hooks.
2025-12-29 20:14:23 -05:00
Alex Newman 6c25bbcbf4 docs: update CHANGELOG.md for v8.2.10 release 2025-12-29 19:11:41 -05:00
Alex Newman 22760f0b7a chore(release): v8.2.10
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v8.2.10
2025-12-29 19:10:32 -05:00
Alex Newman b30c3d193f fix(worker): Auto-restart worker on version mismatch (#484)
When the plugin updates but the worker was already running on the old version,
hooks would fail with 400 errors because the new hook scripts tried to call
APIs that don't exist in the old worker.

Changes:
- /api/version now returns BUILT_IN_VERSION (compiled at build time) instead
  of reading from disk at runtime
- worker-service start command now checks for version mismatch and
  auto-restarts if the running worker version differs from plugin version
- Downgraded hook version mismatch warning to debug logging (now handled
  by auto-restart)

Fixes #484

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-29 19:08:24 -05:00
Alex Newman 78f6008d63 docs: update CHANGELOG.md for v8.2.9 release
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-29 18:45:13 -05:00
Alex Newman 89919db7ce chore(release): v8.2.9
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v8.2.9
2025-12-29 18:42:46 -05:00
Alex Newman 794a93489f Merge pull request #492 from thedotmack/windows-fix
refactor(worker): Remove file-based locking and improve Windows stability
2025-12-29 18:41:00 -05:00
Alex Newman fdb3eb11c3 fix(hooks): reduce timeout values for worker service commands to improve responsiveness 2025-12-29 18:22:33 -05:00
Alex Newman a85d523371 remove bun lock 2025-12-29 18:05:34 -05:00
Alex Newman 3b28b779c8 Increase polling duration for worker readiness check from 5 seconds to 15 seconds, updating related comments for clarity. 2025-12-29 17:55:11 -05:00
Erik M Jacobs 3ea180c1ef refactor(worker): Remove file-based locking and improve Windows stability
This commit simplifies worker startup coordination and addresses Windows-specific issues:

**Lock Removal**:
- Removed entire file-based locking system (~100 lines)
- Replaced with health-check-first approach
- Port binding provides natural mutual exclusion - multiple spawns fail cleanly

**Windows Stability**:
- Removed all AbortSignal.timeout() calls to reduce Bun libuv assertion errors
- Added 500ms shutdown delays on Windows to prevent zombie ports
- Worker service has its own timeouts, so client-side timeouts are redundant

**Package.json Updates**:
- Updated worker scripts to use worker-service.cjs directly
- Removed references to deleted worker-cli.js and worker-wrapper.cjs

**Key Changes**:
- src/services/worker-service.ts: Lock removal, shutdown delays, simplified start logic
- src/hooks/*.ts: Removed AbortSignal.timeout from all HTTP requests
- src/shared/worker-utils.ts: Removed AbortSignal.timeout from health checks
- package.json: Updated worker:* scripts

Resolves startup hangs, reduces assertion errors, and prevents zombie port issues.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-29 16:44:40 -05:00
Alex Newman 0330b4d37e docs: update CHANGELOG.md for v8.2.8
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-29 16:25:28 -05:00
Alex Newman 6b1e91188b chore: bump version to 8.2.8
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
v8.2.8
2025-12-29 16:24:06 -05:00
Alex Newman 87169a78a4 Merge pull request #489 from thedotmack/bugfix/chroma-mcp-orphan-cleanup
fix: prevent orphaned chroma-mcp processes via signal handlers
2025-12-29 16:21:45 -05:00
Alex Newman 2bb07dd41a feat: register signal handlers in constructor for earlier cleanup protection
Addresses review feedback to register signal handlers earlier in the
lifecycle. Previously handlers were registered in start() after HTTP
server initialization, leaving a vulnerability window.

Benefits:
- Signal handlers now active immediately after WorkerService construction
- Protects against signals received during initialization (DB setup,
  HTTP server binding, background initialization)
- Prevents orphaned chroma-mcp processes even if killed during startup
- shutdown() method is defensive and safe to call at any stage

This closes the gap where a SIGTERM/SIGINT during initializeBackground()
could leave chroma-mcp subprocess running without cleanup.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-29 16:17:58 -05:00
Alex Newman 9eedbd4fbd fix: address PR review feedback - remove duplicate signal handlers and ensure PID cleanup
Addresses code review feedback from PR #489:

1. Moved PID file cleanup into shutdown() method to ensure it's always
   cleaned up regardless of how shutdown is triggered
2. Removed duplicate signal handlers in main() function that were
   redundant with the handlers in start() method

This eliminates the race condition where both sets of handlers could
trigger, and ensures consistent PID file cleanup behavior.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-29 16:10:19 -05:00
Alex Newman 5bd8181db9 build: rebuild worker service with signal handler fix
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-29 15:55:35 -05:00
Alex Newman 571926ecfa feat: add graceful shutdown handling to WorkerService 2025-12-29 15:54:22 -05:00
Alex Newman f7561bd4f8 update worker service 2025-12-29 00:37:08 -05:00
Alex Newman 7194443e42 Merge branch 'updates/docs' 2025-12-29 00:35:21 -05:00
Alex Newman d874ce6eb3 fix: escape less-than character in search-architecture.mdx to resolve MDX parsing error
Changed '<10ms' to 'Sub-10ms' to avoid MDX interpreting the < character as an HTML tag opening, which was causing deployment failure.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-29 00:34:14 -05:00
Alex Newman dce4d7a3f9 Merge pull request #480 from thedotmack/updates/docs
Documentation: Update to MCP Architecture and 3-Layer Workflow
2025-12-29 00:31:01 -05:00
Alex Newman d28e71298b docs: update CHANGELOG.md from releases
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-29 00:26:54 -05:00
Alex Newman 00d0bc51e0 Refactor search documentation to implement a 3-layer workflow for memory retrieval; update tool names and usage examples for clarity and efficiency. Enhance troubleshooting section with new error handling and token management strategies. 2025-12-29 00:26:06 -05:00
Alex Newman 75c5b750d8 chore: bump version to 8.2.7
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
v8.2.7
2025-12-29 00:25:12 -05:00
Alex Newman 809489bc8e Merge pull request #477 from thedotmack/bugfix/mcp-clarity
Token Optimizations
2025-12-29 00:17:03 -05:00
Alex Newman f1aa4c3943 fix: wrap migration 17 in transaction and update docs
- Add BEGIN/COMMIT/ROLLBACK to session ID column rename migration
- Update claude-desktop.mdx to reflect streamlined MCP tools
- Remove obsolete skill zip download instructions

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 23:43:34 -05:00
Alex Newman 678cfacca9 Remove outdated troubleshooting documentation for database, diagnostics, reference, and worker operations in claude-mem plugin. 2025-12-28 23:34:24 -05:00
Alex Newman 0e913a25ff Refactor mem-search operations: remove outdated documentation files, enhance search parameters, and improve token efficiency guidelines. Update MCP server descriptions for clarity on search and timeline functionalities. Remove unnecessary zip build process for mem-search skill. 2025-12-28 23:32:52 -05:00
Alex Newman 979918d202 Refactor MCP server tool definitions and workflows
- Removed unused tool endpoints and schemas to streamline the codebase.
- Consolidated tool descriptions to emphasize a 3-layer workflow for memory search.
- Updated input schemas and handler functions for clarity and efficiency.
- Enhanced documentation within tool descriptions for better user guidance.
2025-12-28 23:25:26 -05:00
Alex Newman 656a7f7c0f Refactor session ID references from sdk_session_id to memory_session_id across multiple services and database queries
- Updated SQL queries in cleanup-duplicates.ts and context-generator.ts to use memory_session_id.
- Modified interfaces in context-generator.ts to reflect the new session ID naming.
- Implemented a repair migration in SessionStore.ts to rename columns in existing tables.
- Adjusted FormattingService.ts and SDKAgent.ts to utilize memory_session_id for session handling.
- Ensured SearchManager.ts retrieves summaries and observations using the updated memory_session_id.
2025-12-28 23:13:47 -05:00
Alex Newman d7c183b3e1 fix: rename 'mem-search' to 'mcp-search' for consistency across documentation and configuration 2025-12-28 22:55:05 -05:00
Alex Newman b92eb3dbb5 docs: update CHANGELOG.md from releases
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 22:35:25 -05:00