This is page 47 of 47. Use http://codebase.md/doobidoo/mcp-memory-service?lines=true&page={x} to view the full context.
# Directory Structure
```
├── .claude
│ ├── agents
│ │ ├── amp-bridge.md
│ │ ├── amp-pr-automator.md
│ │ ├── code-quality-guard.md
│ │ ├── gemini-pr-automator.md
│ │ └── github-release-manager.md
│ ├── settings.local.json.backup
│ └── settings.local.json.local
├── .commit-message
├── .dockerignore
├── .env.example
├── .env.sqlite.backup
├── .envnn#
├── .gitattributes
├── .github
│ ├── FUNDING.yml
│ ├── ISSUE_TEMPLATE
│ │ ├── bug_report.yml
│ │ ├── config.yml
│ │ ├── feature_request.yml
│ │ └── performance_issue.yml
│ ├── pull_request_template.md
│ └── workflows
│ ├── bridge-tests.yml
│ ├── CACHE_FIX.md
│ ├── claude-code-review.yml
│ ├── claude.yml
│ ├── cleanup-images.yml.disabled
│ ├── dev-setup-validation.yml
│ ├── docker-publish.yml
│ ├── LATEST_FIXES.md
│ ├── main-optimized.yml.disabled
│ ├── main.yml
│ ├── publish-and-test.yml
│ ├── README_OPTIMIZATION.md
│ ├── release-tag.yml.disabled
│ ├── release.yml
│ ├── roadmap-review-reminder.yml
│ ├── SECRET_CONDITIONAL_FIX.md
│ └── WORKFLOW_FIXES.md
├── .gitignore
├── .mcp.json.backup
├── .mcp.json.template
├── .pyscn
│ ├── .gitignore
│ └── reports
│ └── analyze_20251123_214224.html
├── AGENTS.md
├── archive
│ ├── deployment
│ │ ├── deploy_fastmcp_fixed.sh
│ │ ├── deploy_http_with_mcp.sh
│ │ └── deploy_mcp_v4.sh
│ ├── deployment-configs
│ │ ├── empty_config.yml
│ │ └── smithery.yaml
│ ├── development
│ │ └── test_fastmcp.py
│ ├── docs-removed-2025-08-23
│ │ ├── authentication.md
│ │ ├── claude_integration.md
│ │ ├── claude-code-compatibility.md
│ │ ├── claude-code-integration.md
│ │ ├── claude-code-quickstart.md
│ │ ├── claude-desktop-setup.md
│ │ ├── complete-setup-guide.md
│ │ ├── database-synchronization.md
│ │ ├── development
│ │ │ ├── autonomous-memory-consolidation.md
│ │ │ ├── CLEANUP_PLAN.md
│ │ │ ├── CLEANUP_README.md
│ │ │ ├── CLEANUP_SUMMARY.md
│ │ │ ├── dream-inspired-memory-consolidation.md
│ │ │ ├── hybrid-slm-memory-consolidation.md
│ │ │ ├── mcp-milestone.md
│ │ │ ├── multi-client-architecture.md
│ │ │ ├── test-results.md
│ │ │ └── TIMESTAMP_FIX_SUMMARY.md
│ │ ├── distributed-sync.md
│ │ ├── invocation_guide.md
│ │ ├── macos-intel.md
│ │ ├── master-guide.md
│ │ ├── mcp-client-configuration.md
│ │ ├── multi-client-server.md
│ │ ├── service-installation.md
│ │ ├── sessions
│ │ │ └── MCP_ENHANCEMENT_SESSION_MEMORY_v4.1.0.md
│ │ ├── UBUNTU_SETUP.md
│ │ ├── ubuntu.md
│ │ ├── windows-setup.md
│ │ └── windows.md
│ ├── docs-root-cleanup-2025-08-23
│ │ ├── AWESOME_LIST_SUBMISSION.md
│ │ ├── CLOUDFLARE_IMPLEMENTATION.md
│ │ ├── DOCUMENTATION_ANALYSIS.md
│ │ ├── DOCUMENTATION_CLEANUP_PLAN.md
│ │ ├── DOCUMENTATION_CONSOLIDATION_COMPLETE.md
│ │ ├── LITESTREAM_SETUP_GUIDE.md
│ │ ├── lm_studio_system_prompt.md
│ │ ├── PYTORCH_DOWNLOAD_FIX.md
│ │ └── README-ORIGINAL-BACKUP.md
│ ├── investigations
│ │ └── MACOS_HOOKS_INVESTIGATION.md
│ ├── litestream-configs-v6.3.0
│ │ ├── install_service.sh
│ │ ├── litestream_master_config_fixed.yml
│ │ ├── litestream_master_config.yml
│ │ ├── litestream_replica_config_fixed.yml
│ │ ├── litestream_replica_config.yml
│ │ ├── litestream_replica_simple.yml
│ │ ├── litestream-http.service
│ │ ├── litestream.service
│ │ └── requirements-cloudflare.txt
│ ├── release-notes
│ │ └── release-notes-v7.1.4.md
│ └── setup-development
│ ├── README.md
│ ├── setup_consolidation_mdns.sh
│ ├── STARTUP_SETUP_GUIDE.md
│ └── test_service.sh
├── CHANGELOG-HISTORIC.md
├── CHANGELOG.md
├── claude_commands
│ ├── memory-context.md
│ ├── memory-health.md
│ ├── memory-ingest-dir.md
│ ├── memory-ingest.md
│ ├── memory-recall.md
│ ├── memory-search.md
│ ├── memory-store.md
│ ├── README.md
│ └── session-start.md
├── claude-hooks
│ ├── config.json
│ ├── config.template.json
│ ├── CONFIGURATION.md
│ ├── core
│ │ ├── memory-retrieval.js
│ │ ├── mid-conversation.js
│ │ ├── session-end.js
│ │ ├── session-start.js
│ │ └── topic-change.js
│ ├── debug-pattern-test.js
│ ├── install_claude_hooks_windows.ps1
│ ├── install_hooks.py
│ ├── memory-mode-controller.js
│ ├── MIGRATION.md
│ ├── README-NATURAL-TRIGGERS.md
│ ├── README-phase2.md
│ ├── README.md
│ ├── simple-test.js
│ ├── statusline.sh
│ ├── test-adaptive-weights.js
│ ├── test-dual-protocol-hook.js
│ ├── test-mcp-hook.js
│ ├── test-natural-triggers.js
│ ├── test-recency-scoring.js
│ ├── tests
│ │ ├── integration-test.js
│ │ ├── phase2-integration-test.js
│ │ ├── test-code-execution.js
│ │ ├── test-cross-session.json
│ │ ├── test-session-tracking.json
│ │ └── test-threading.json
│ ├── utilities
│ │ ├── adaptive-pattern-detector.js
│ │ ├── context-formatter.js
│ │ ├── context-shift-detector.js
│ │ ├── conversation-analyzer.js
│ │ ├── dynamic-context-updater.js
│ │ ├── git-analyzer.js
│ │ ├── mcp-client.js
│ │ ├── memory-client.js
│ │ ├── memory-scorer.js
│ │ ├── performance-manager.js
│ │ ├── project-detector.js
│ │ ├── session-tracker.js
│ │ ├── tiered-conversation-monitor.js
│ │ └── version-checker.js
│ └── WINDOWS-SESSIONSTART-BUG.md
├── CLAUDE.md
├── CODE_OF_CONDUCT.md
├── CONTRIBUTING.md
├── Development-Sprint-November-2025.md
├── docs
│ ├── amp-cli-bridge.md
│ ├── api
│ │ ├── code-execution-interface.md
│ │ ├── memory-metadata-api.md
│ │ ├── PHASE1_IMPLEMENTATION_SUMMARY.md
│ │ ├── PHASE2_IMPLEMENTATION_SUMMARY.md
│ │ ├── PHASE2_REPORT.md
│ │ └── tag-standardization.md
│ ├── architecture
│ │ ├── search-enhancement-spec.md
│ │ └── search-examples.md
│ ├── architecture.md
│ ├── archive
│ │ └── obsolete-workflows
│ │ ├── load_memory_context.md
│ │ └── README.md
│ ├── assets
│ │ └── images
│ │ ├── dashboard-v3.3.0-preview.png
│ │ ├── memory-awareness-hooks-example.png
│ │ ├── project-infographic.svg
│ │ └── README.md
│ ├── CLAUDE_CODE_QUICK_REFERENCE.md
│ ├── cloudflare-setup.md
│ ├── deployment
│ │ ├── docker.md
│ │ ├── dual-service.md
│ │ ├── production-guide.md
│ │ └── systemd-service.md
│ ├── development
│ │ ├── ai-agent-instructions.md
│ │ ├── code-quality
│ │ │ ├── phase-2a-completion.md
│ │ │ ├── phase-2a-handle-get-prompt.md
│ │ │ ├── phase-2a-index.md
│ │ │ ├── phase-2a-install-package.md
│ │ │ └── phase-2b-session-summary.md
│ │ ├── code-quality-workflow.md
│ │ ├── dashboard-workflow.md
│ │ ├── issue-management.md
│ │ ├── pr-review-guide.md
│ │ ├── refactoring-notes.md
│ │ ├── release-checklist.md
│ │ └── todo-tracker.md
│ ├── docker-optimized-build.md
│ ├── document-ingestion.md
│ ├── DOCUMENTATION_AUDIT.md
│ ├── enhancement-roadmap-issue-14.md
│ ├── examples
│ │ ├── analysis-scripts.js
│ │ ├── maintenance-session-example.md
│ │ ├── memory-distribution-chart.jsx
│ │ └── tag-schema.json
│ ├── first-time-setup.md
│ ├── glama-deployment.md
│ ├── guides
│ │ ├── advanced-command-examples.md
│ │ ├── chromadb-migration.md
│ │ ├── commands-vs-mcp-server.md
│ │ ├── mcp-enhancements.md
│ │ ├── mdns-service-discovery.md
│ │ ├── memory-consolidation-guide.md
│ │ ├── migration.md
│ │ ├── scripts.md
│ │ └── STORAGE_BACKENDS.md
│ ├── HOOK_IMPROVEMENTS.md
│ ├── hooks
│ │ └── phase2-code-execution-migration.md
│ ├── http-server-management.md
│ ├── ide-compatability.md
│ ├── IMAGE_RETENTION_POLICY.md
│ ├── images
│ │ └── dashboard-placeholder.md
│ ├── implementation
│ │ ├── health_checks.md
│ │ └── performance.md
│ ├── IMPLEMENTATION_PLAN_HTTP_SSE.md
│ ├── integration
│ │ ├── homebrew.md
│ │ └── multi-client.md
│ ├── integrations
│ │ ├── gemini.md
│ │ ├── groq-bridge.md
│ │ ├── groq-integration-summary.md
│ │ └── groq-model-comparison.md
│ ├── integrations.md
│ ├── legacy
│ │ └── dual-protocol-hooks.md
│ ├── LM_STUDIO_COMPATIBILITY.md
│ ├── maintenance
│ │ └── memory-maintenance.md
│ ├── mastery
│ │ ├── api-reference.md
│ │ ├── architecture-overview.md
│ │ ├── configuration-guide.md
│ │ ├── local-setup-and-run.md
│ │ ├── testing-guide.md
│ │ └── troubleshooting.md
│ ├── migration
│ │ └── code-execution-api-quick-start.md
│ ├── natural-memory-triggers
│ │ ├── cli-reference.md
│ │ ├── installation-guide.md
│ │ └── performance-optimization.md
│ ├── oauth-setup.md
│ ├── pr-graphql-integration.md
│ ├── quick-setup-cloudflare-dual-environment.md
│ ├── README.md
│ ├── remote-configuration-wiki-section.md
│ ├── research
│ │ ├── code-execution-interface-implementation.md
│ │ └── code-execution-interface-summary.md
│ ├── ROADMAP.md
│ ├── sqlite-vec-backend.md
│ ├── statistics
│ │ ├── charts
│ │ │ ├── activity_patterns.png
│ │ │ ├── contributors.png
│ │ │ ├── growth_trajectory.png
│ │ │ ├── monthly_activity.png
│ │ │ └── october_sprint.png
│ │ ├── data
│ │ │ ├── activity_by_day.csv
│ │ │ ├── activity_by_hour.csv
│ │ │ ├── contributors.csv
│ │ │ └── monthly_activity.csv
│ │ ├── generate_charts.py
│ │ └── REPOSITORY_STATISTICS.md
│ ├── technical
│ │ ├── development.md
│ │ ├── memory-migration.md
│ │ ├── migration-log.md
│ │ ├── sqlite-vec-embedding-fixes.md
│ │ └── tag-storage.md
│ ├── testing
│ │ └── regression-tests.md
│ ├── testing-cloudflare-backend.md
│ ├── troubleshooting
│ │ ├── cloudflare-api-token-setup.md
│ │ ├── cloudflare-authentication.md
│ │ ├── general.md
│ │ ├── hooks-quick-reference.md
│ │ ├── pr162-schema-caching-issue.md
│ │ ├── session-end-hooks.md
│ │ └── sync-issues.md
│ └── tutorials
│ ├── advanced-techniques.md
│ ├── data-analysis.md
│ └── demo-session-walkthrough.md
├── examples
│ ├── claude_desktop_config_template.json
│ ├── claude_desktop_config_windows.json
│ ├── claude-desktop-http-config.json
│ ├── config
│ │ └── claude_desktop_config.json
│ ├── http-mcp-bridge.js
│ ├── memory_export_template.json
│ ├── README.md
│ ├── setup
│ │ └── setup_multi_client_complete.py
│ └── start_https_example.sh
├── install_service.py
├── install.py
├── LICENSE
├── NOTICE
├── pyproject.toml
├── pytest.ini
├── README.md
├── run_server.py
├── scripts
│ ├── .claude
│ │ └── settings.local.json
│ ├── archive
│ │ └── check_missing_timestamps.py
│ ├── backup
│ │ ├── backup_memories.py
│ │ ├── backup_sqlite_vec.sh
│ │ ├── export_distributable_memories.sh
│ │ └── restore_memories.py
│ ├── benchmarks
│ │ ├── benchmark_code_execution_api.py
│ │ ├── benchmark_hybrid_sync.py
│ │ └── benchmark_server_caching.py
│ ├── database
│ │ ├── analyze_sqlite_vec_db.py
│ │ ├── check_sqlite_vec_status.py
│ │ ├── db_health_check.py
│ │ └── simple_timestamp_check.py
│ ├── development
│ │ ├── debug_server_initialization.py
│ │ ├── find_orphaned_files.py
│ │ ├── fix_mdns.sh
│ │ ├── fix_sitecustomize.py
│ │ ├── remote_ingest.sh
│ │ ├── setup-git-merge-drivers.sh
│ │ ├── uv-lock-merge.sh
│ │ └── verify_hybrid_sync.py
│ ├── hooks
│ │ └── pre-commit
│ ├── installation
│ │ ├── install_linux_service.py
│ │ ├── install_macos_service.py
│ │ ├── install_uv.py
│ │ ├── install_windows_service.py
│ │ ├── install.py
│ │ ├── setup_backup_cron.sh
│ │ ├── setup_claude_mcp.sh
│ │ └── setup_cloudflare_resources.py
│ ├── linux
│ │ ├── service_status.sh
│ │ ├── start_service.sh
│ │ ├── stop_service.sh
│ │ ├── uninstall_service.sh
│ │ └── view_logs.sh
│ ├── maintenance
│ │ ├── assign_memory_types.py
│ │ ├── check_memory_types.py
│ │ ├── cleanup_corrupted_encoding.py
│ │ ├── cleanup_memories.py
│ │ ├── cleanup_organize.py
│ │ ├── consolidate_memory_types.py
│ │ ├── consolidation_mappings.json
│ │ ├── delete_orphaned_vectors_fixed.py
│ │ ├── fast_cleanup_duplicates_with_tracking.sh
│ │ ├── find_all_duplicates.py
│ │ ├── find_cloudflare_duplicates.py
│ │ ├── find_duplicates.py
│ │ ├── memory-types.md
│ │ ├── README.md
│ │ ├── recover_timestamps_from_cloudflare.py
│ │ ├── regenerate_embeddings.py
│ │ ├── repair_malformed_tags.py
│ │ ├── repair_memories.py
│ │ ├── repair_sqlite_vec_embeddings.py
│ │ ├── repair_zero_embeddings.py
│ │ ├── restore_from_json_export.py
│ │ └── scan_todos.sh
│ ├── migration
│ │ ├── cleanup_mcp_timestamps.py
│ │ ├── legacy
│ │ │ └── migrate_chroma_to_sqlite.py
│ │ ├── mcp-migration.py
│ │ ├── migrate_sqlite_vec_embeddings.py
│ │ ├── migrate_storage.py
│ │ ├── migrate_tags.py
│ │ ├── migrate_timestamps.py
│ │ ├── migrate_to_cloudflare.py
│ │ ├── migrate_to_sqlite_vec.py
│ │ ├── migrate_v5_enhanced.py
│ │ ├── TIMESTAMP_CLEANUP_README.md
│ │ └── verify_mcp_timestamps.py
│ ├── pr
│ │ ├── amp_collect_results.sh
│ │ ├── amp_detect_breaking_changes.sh
│ │ ├── amp_generate_tests.sh
│ │ ├── amp_pr_review.sh
│ │ ├── amp_quality_gate.sh
│ │ ├── amp_suggest_fixes.sh
│ │ ├── auto_review.sh
│ │ ├── detect_breaking_changes.sh
│ │ ├── generate_tests.sh
│ │ ├── lib
│ │ │ └── graphql_helpers.sh
│ │ ├── quality_gate.sh
│ │ ├── resolve_threads.sh
│ │ ├── run_pyscn_analysis.sh
│ │ ├── run_quality_checks.sh
│ │ ├── thread_status.sh
│ │ └── watch_reviews.sh
│ ├── quality
│ │ ├── fix_dead_code_install.sh
│ │ ├── phase1_dead_code_analysis.md
│ │ ├── phase2_complexity_analysis.md
│ │ ├── README_PHASE1.md
│ │ ├── README_PHASE2.md
│ │ ├── track_pyscn_metrics.sh
│ │ └── weekly_quality_review.sh
│ ├── README.md
│ ├── run
│ │ ├── run_mcp_memory.sh
│ │ ├── run-with-uv.sh
│ │ └── start_sqlite_vec.sh
│ ├── run_memory_server.py
│ ├── server
│ │ ├── check_http_server.py
│ │ ├── check_server_health.py
│ │ ├── memory_offline.py
│ │ ├── preload_models.py
│ │ ├── run_http_server.py
│ │ ├── run_memory_server.py
│ │ ├── start_http_server.bat
│ │ └── start_http_server.sh
│ ├── service
│ │ ├── deploy_dual_services.sh
│ │ ├── install_http_service.sh
│ │ ├── mcp-memory-http.service
│ │ ├── mcp-memory.service
│ │ ├── memory_service_manager.sh
│ │ ├── service_control.sh
│ │ ├── service_utils.py
│ │ └── update_service.sh
│ ├── sync
│ │ ├── check_drift.py
│ │ ├── claude_sync_commands.py
│ │ ├── export_memories.py
│ │ ├── import_memories.py
│ │ ├── litestream
│ │ │ ├── apply_local_changes.sh
│ │ │ ├── enhanced_memory_store.sh
│ │ │ ├── init_staging_db.sh
│ │ │ ├── io.litestream.replication.plist
│ │ │ ├── manual_sync.sh
│ │ │ ├── memory_sync.sh
│ │ │ ├── pull_remote_changes.sh
│ │ │ ├── push_to_remote.sh
│ │ │ ├── README.md
│ │ │ ├── resolve_conflicts.sh
│ │ │ ├── setup_local_litestream.sh
│ │ │ ├── setup_remote_litestream.sh
│ │ │ ├── staging_db_init.sql
│ │ │ ├── stash_local_changes.sh
│ │ │ ├── sync_from_remote_noconfig.sh
│ │ │ └── sync_from_remote.sh
│ │ ├── README.md
│ │ ├── safe_cloudflare_update.sh
│ │ ├── sync_memory_backends.py
│ │ └── sync_now.py
│ ├── testing
│ │ ├── run_complete_test.py
│ │ ├── run_memory_test.sh
│ │ ├── simple_test.py
│ │ ├── test_cleanup_logic.py
│ │ ├── test_cloudflare_backend.py
│ │ ├── test_docker_functionality.py
│ │ ├── test_installation.py
│ │ ├── test_mdns.py
│ │ ├── test_memory_api.py
│ │ ├── test_memory_simple.py
│ │ ├── test_migration.py
│ │ ├── test_search_api.py
│ │ ├── test_sqlite_vec_embeddings.py
│ │ ├── test_sse_events.py
│ │ ├── test-connection.py
│ │ └── test-hook.js
│ ├── utils
│ │ ├── claude_commands_utils.py
│ │ ├── generate_personalized_claude_md.sh
│ │ ├── groq
│ │ ├── groq_agent_bridge.py
│ │ ├── list-collections.py
│ │ ├── memory_wrapper_uv.py
│ │ ├── query_memories.py
│ │ ├── smithery_wrapper.py
│ │ ├── test_groq_bridge.sh
│ │ └── uv_wrapper.py
│ └── validation
│ ├── check_dev_setup.py
│ ├── check_documentation_links.py
│ ├── diagnose_backend_config.py
│ ├── validate_configuration_complete.py
│ ├── validate_memories.py
│ ├── validate_migration.py
│ ├── validate_timestamp_integrity.py
│ ├── verify_environment.py
│ ├── verify_pytorch_windows.py
│ └── verify_torch.py
├── SECURITY.md
├── selective_timestamp_recovery.py
├── SPONSORS.md
├── src
│ └── mcp_memory_service
│ ├── __init__.py
│ ├── api
│ │ ├── __init__.py
│ │ ├── client.py
│ │ ├── operations.py
│ │ ├── sync_wrapper.py
│ │ └── types.py
│ ├── backup
│ │ ├── __init__.py
│ │ └── scheduler.py
│ ├── cli
│ │ ├── __init__.py
│ │ ├── ingestion.py
│ │ ├── main.py
│ │ └── utils.py
│ ├── config.py
│ ├── consolidation
│ │ ├── __init__.py
│ │ ├── associations.py
│ │ ├── base.py
│ │ ├── clustering.py
│ │ ├── compression.py
│ │ ├── consolidator.py
│ │ ├── decay.py
│ │ ├── forgetting.py
│ │ ├── health.py
│ │ └── scheduler.py
│ ├── dependency_check.py
│ ├── discovery
│ │ ├── __init__.py
│ │ ├── client.py
│ │ └── mdns_service.py
│ ├── embeddings
│ │ ├── __init__.py
│ │ └── onnx_embeddings.py
│ ├── ingestion
│ │ ├── __init__.py
│ │ ├── base.py
│ │ ├── chunker.py
│ │ ├── csv_loader.py
│ │ ├── json_loader.py
│ │ ├── pdf_loader.py
│ │ ├── registry.py
│ │ ├── semtools_loader.py
│ │ └── text_loader.py
│ ├── lm_studio_compat.py
│ ├── mcp_server.py
│ ├── models
│ │ ├── __init__.py
│ │ └── memory.py
│ ├── server.py
│ ├── services
│ │ ├── __init__.py
│ │ └── memory_service.py
│ ├── storage
│ │ ├── __init__.py
│ │ ├── base.py
│ │ ├── cloudflare.py
│ │ ├── factory.py
│ │ ├── http_client.py
│ │ ├── hybrid.py
│ │ └── sqlite_vec.py
│ ├── sync
│ │ ├── __init__.py
│ │ ├── exporter.py
│ │ ├── importer.py
│ │ └── litestream_config.py
│ ├── utils
│ │ ├── __init__.py
│ │ ├── cache_manager.py
│ │ ├── content_splitter.py
│ │ ├── db_utils.py
│ │ ├── debug.py
│ │ ├── document_processing.py
│ │ ├── gpu_detection.py
│ │ ├── hashing.py
│ │ ├── http_server_manager.py
│ │ ├── port_detection.py
│ │ ├── system_detection.py
│ │ └── time_parser.py
│ └── web
│ ├── __init__.py
│ ├── api
│ │ ├── __init__.py
│ │ ├── analytics.py
│ │ ├── backup.py
│ │ ├── consolidation.py
│ │ ├── documents.py
│ │ ├── events.py
│ │ ├── health.py
│ │ ├── manage.py
│ │ ├── mcp.py
│ │ ├── memories.py
│ │ ├── search.py
│ │ └── sync.py
│ ├── app.py
│ ├── dependencies.py
│ ├── oauth
│ │ ├── __init__.py
│ │ ├── authorization.py
│ │ ├── discovery.py
│ │ ├── middleware.py
│ │ ├── models.py
│ │ ├── registration.py
│ │ └── storage.py
│ ├── sse.py
│ └── static
│ ├── app.js
│ ├── index.html
│ ├── README.md
│ ├── sse_test.html
│ └── style.css
├── start_http_debug.bat
├── start_http_server.sh
├── test_document.txt
├── test_version_checker.js
├── tests
│ ├── __init__.py
│ ├── api
│ │ ├── __init__.py
│ │ ├── test_compact_types.py
│ │ └── test_operations.py
│ ├── bridge
│ │ ├── mock_responses.js
│ │ ├── package-lock.json
│ │ ├── package.json
│ │ └── test_http_mcp_bridge.js
│ ├── conftest.py
│ ├── consolidation
│ │ ├── __init__.py
│ │ ├── conftest.py
│ │ ├── test_associations.py
│ │ ├── test_clustering.py
│ │ ├── test_compression.py
│ │ ├── test_consolidator.py
│ │ ├── test_decay.py
│ │ └── test_forgetting.py
│ ├── contracts
│ │ └── api-specification.yml
│ ├── integration
│ │ ├── package-lock.json
│ │ ├── package.json
│ │ ├── test_api_key_fallback.py
│ │ ├── test_api_memories_chronological.py
│ │ ├── test_api_tag_time_search.py
│ │ ├── test_api_with_memory_service.py
│ │ ├── test_bridge_integration.js
│ │ ├── test_cli_interfaces.py
│ │ ├── test_cloudflare_connection.py
│ │ ├── test_concurrent_clients.py
│ │ ├── test_data_serialization_consistency.py
│ │ ├── test_http_server_startup.py
│ │ ├── test_mcp_memory.py
│ │ ├── test_mdns_integration.py
│ │ ├── test_oauth_basic_auth.py
│ │ ├── test_oauth_flow.py
│ │ ├── test_server_handlers.py
│ │ └── test_store_memory.py
│ ├── performance
│ │ ├── test_background_sync.py
│ │ └── test_hybrid_live.py
│ ├── README.md
│ ├── smithery
│ │ └── test_smithery.py
│ ├── sqlite
│ │ └── simple_sqlite_vec_test.py
│ ├── test_client.py
│ ├── test_content_splitting.py
│ ├── test_database.py
│ ├── test_hybrid_cloudflare_limits.py
│ ├── test_hybrid_storage.py
│ ├── test_memory_ops.py
│ ├── test_semantic_search.py
│ ├── test_sqlite_vec_storage.py
│ ├── test_time_parser.py
│ ├── test_timestamp_preservation.py
│ ├── timestamp
│ │ ├── test_hook_vs_manual_storage.py
│ │ ├── test_issue99_final_validation.py
│ │ ├── test_search_retrieval_inconsistency.py
│ │ ├── test_timestamp_issue.py
│ │ └── test_timestamp_simple.py
│ └── unit
│ ├── conftest.py
│ ├── test_cloudflare_storage.py
│ ├── test_csv_loader.py
│ ├── test_fastapi_dependencies.py
│ ├── test_import.py
│ ├── test_json_loader.py
│ ├── test_mdns_simple.py
│ ├── test_mdns.py
│ ├── test_memory_service.py
│ ├── test_memory.py
│ ├── test_semtools_loader.py
│ ├── test_storage_interface_compatibility.py
│ └── test_tag_time_filtering.py
├── tools
│ ├── docker
│ │ ├── DEPRECATED.md
│ │ ├── docker-compose.http.yml
│ │ ├── docker-compose.pythonpath.yml
│ │ ├── docker-compose.standalone.yml
│ │ ├── docker-compose.uv.yml
│ │ ├── docker-compose.yml
│ │ ├── docker-entrypoint-persistent.sh
│ │ ├── docker-entrypoint-unified.sh
│ │ ├── docker-entrypoint.sh
│ │ ├── Dockerfile
│ │ ├── Dockerfile.glama
│ │ ├── Dockerfile.slim
│ │ ├── README.md
│ │ └── test-docker-modes.sh
│ └── README.md
└── uv.lock
```
# Files
--------------------------------------------------------------------------------
/CHANGELOG-HISTORIC.md:
--------------------------------------------------------------------------------
```markdown
1 | # Historic Changelog
2 |
3 | **Historic releases for MCP Memory Service (v8.0.0 - v8.23.0 and v7.x)**
4 |
5 | For recent releases (v8.24.0+), see [CHANGELOG.md](./CHANGELOG.md).
6 |
7 | The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
8 |
9 | ---
10 | ## [8.23.0] - 2025-11-10
11 |
12 | ### Added
13 | - **Consolidation Scheduler via Code Execution API** - Dream-based memory consolidation now operates independently of MCP server
14 | - **Architecture Shift**: Migrated ConsolidationScheduler from MCP server to HTTP server using Code Execution API (v8.19.0+)
15 | - **Token Efficiency**: Achieves **88% token reduction** (803K tokens/year saved) by eliminating redundant memory retrieval
16 | - **24/7 Operation**: Consolidation now runs continuously via HTTP server, independent of Claude Desktop sessions
17 | - **Code Execution Extensions**:
18 | - Added `CompactConsolidationResult` and `CompactSchedulerStatus` types for efficient data transfer
19 | - Implemented `consolidate()` and `scheduler_status()` functions in API operations
20 | - Enhanced API client with consolidator/scheduler management capabilities
21 | - **HTTP API Endpoints** (new):
22 | - `POST /api/consolidation/trigger` - Manual consolidation trigger for specific time horizons
23 | - `GET /api/consolidation/status` - Scheduler health and job status monitoring
24 | - `GET /api/consolidation/recommendations` - Analysis-based consolidation suggestions
25 | - **Graceful Lifecycle**: HTTP server lifespan events handle scheduler startup/shutdown
26 | - **Dependencies**: Made `apscheduler>=3.11.0` a required dependency (previously optional)
27 | - **Files Modified**:
28 | - `src/mcp_memory_service/api/types.py` - New compact result types
29 | - `src/mcp_memory_service/api/operations.py` - Consolidation functions
30 | - `src/mcp_memory_service/api/client.py` - Client methods
31 | - `src/mcp_memory_service/api/__init__.py` - Export updates
32 | - `src/mcp_memory_service/web/app.py` - Scheduler integration
33 | - `src/mcp_memory_service/web/api/consolidation.py` - NEW endpoint router
34 | - `pyproject.toml` - Dependency update
35 |
36 | ### Changed
37 | - **Consolidation Workflow**: Users can now trigger and monitor consolidation via HTTP API or web dashboard
38 | - **Performance**: Background consolidation no longer impacts MCP server response times
39 | - **Reliability**: Scheduler continues running even when Claude Desktop is closed
40 |
41 | ### Migration Notes
42 | - **Backward Compatible**: Existing MCP consolidation tools continue to work via Code Execution API
43 | - **HTTP Server Required**: For scheduled consolidation, HTTP server must be running (`export MCP_HTTP_ENABLED=true`)
44 | - **No Action Needed**: Consolidation automatically migrates to HTTP server when enabled
45 |
46 | ### Technical Details
47 | - **Token Savings Breakdown**:
48 | - Before: ~900K tokens/year (MCP server retrieval overhead)
49 | - After: ~97K tokens/year (compact API responses)
50 | - Reduction: 803K tokens (88% efficiency gain)
51 | - **Execution Model**: Code Execution API handles consolidation in isolated Python environment
52 | - **Scheduler Configuration**: Same settings as before (`.env` or environment variables)
53 |
54 | ## [8.22.3] - 2025-11-10
55 |
56 | ### Fixed
57 | - **Complete Tag Schema Validation Fix**: Extended oneOf schema pattern to ALL MCP tools with tags parameter
58 | - Previous fixes (v8.22.1-v8.22.2) only addressed character-split bugs in handler code
59 | - Root cause: 7 tools had schemas accepting ONLY arrays, rejecting comma-separated strings at MCP client validation
60 | - Updated tool schemas to accept both array and string formats using `oneOf` pattern:
61 | - `update_memory_metadata` (line 1733)
62 | - `search_by_tag` (line 1428)
63 | - `delete_by_tag` (line 1475)
64 | - `delete_by_tags` (line 1506)
65 | - `delete_by_all_tags` (line 1536)
66 | - `ingest_document` (line 1958)
67 | - `ingest_directory` (line 2015)
68 | - Added `normalize_tags()` calls in all affected handlers to properly parse comma-separated strings
69 | - Validation now happens gracefully: client accepts both formats, server normalizes to array
70 | - **Breaking**: Users must reconnect MCP client (`/mcp` in Claude Code) to fetch updated schemas
71 | - Resolves recurring "Input validation error: 'X' is not of type 'array'" errors
72 |
73 | ### Technical Details
74 | - **Validation Flow**: MCP client validates against tool schema → Server normalizes tags → Storage processes
75 | - **Schema Pattern**: Each tags parameter now uses `{"oneOf": [{"type": "array"}, {"type": "string"}]}`
76 | - **Handler Updates**: 7 handlers updated to import and call `normalize_tags()` from `services/memory_service.py`
77 | - **File Modified**: `src/mcp_memory_service/server.py` (schemas + handlers)
78 |
79 | ### Notes
80 | - This completes the tag parsing fix saga (v8.22.1 → v8.22.2 → v8.22.3)
81 | - v8.22.1: Fixed character-split bug in documents.py
82 | - v8.22.2: Extended fix to server.py and cli/ingestion.py handlers
83 | - v8.22.3: Fixed JSON schemas to accept comma-separated strings at validation layer
84 |
85 | ## [8.22.2] - 2025-11-09
86 |
87 | ### Fixed
88 | - **Complete Tag Parsing Fix** - Extended v8.22.1 fix to all remaining locations where tag parsing bug existed
89 | - **Additional Files Fixed**:
90 | - `src/mcp_memory_service/server.py` - MCP ingest_document and ingest_directory tool handlers (2 locations)
91 | - `src/mcp_memory_service/cli/ingestion.py` - CLI ingest_file and ingest_directory commands (2 locations)
92 | - **Root Cause**: Same as v8.22.1 - `.extend()` on comma-separated string treated as character iterable
93 | - **Impact**: MCP tools and CLI commands now correctly parse comma-separated tags
94 | - **Database Repair**: 6 additional memories repaired from metadata backup (total 19 across both releases)
95 | - **Verification**: All tag parsing code paths now include `isinstance()` type checking
96 |
97 | ## [8.22.1] - 2025-11-09
98 |
99 | ### Fixed
100 | - **Document Ingestion Tag Parsing** - Fixed critical data corruption bug where tags were stored character-by-character instead of as complete strings
101 | - **Root Cause**: When `chunk.metadata['tags']` contained a comma-separated string (e.g., `"claude-code-hooks,update-investigation"`), the `extend()` method treated it as an iterable and added each character individually
102 | - **Symptom**: Tags like `"claude-code-hooks,update-investigation,configuration,breaking-changes"` became `['c','l','a','u','d','e','-','c','o','d','e','-','h','o','o','k','s',',','u','p','d','a','t','e',...]` (80+ character tags per memory)
103 | - **Impact**: Memories were unsearchable by tags, tag filtering broken, tag display cluttered with single characters
104 | - **Fix**: Added `isinstance()` type check to detect string vs list, properly split comma-separated strings before extending tag list
105 | - **Database Repair**: 13 affected memories automatically repaired using metadata field (which stored correct tags)
106 | - **Files Modified**: `src/mcp_memory_service/web/api/documents.py` (lines 424-430 for single uploads, 536-542 for batch uploads)
107 |
108 | ## [8.22.0] - 2025-11-09
109 |
110 | ### Fixed
111 | - **Session-Start Hook Stability & UX** - Comprehensive reliability and output quality improvements
112 | - **Memory Age Calculation**: Fixed memory age analyzer defaulting to 365 days for all memories
113 | - Added `created_at_iso` field to Code Execution API response mapping
114 | - Now correctly shows recent work (e.g., "🕒 today", "📅 2d ago")
115 | - Resolves memory age display bug (Related: Issue #214)
116 | - **Timeout Improvements**: Prevents timeouts during DNS retries and slow network operations
117 | - Increased code execution timeout: 8000ms → 15000ms
118 | - Increased sessionStart hook timeout: 10000ms → 20000ms
119 | - **Tree Formatting Enhancements**: Complete rewrite for proper ANSI-aware rendering
120 | - ANSI-aware width calculation in wrapText() function
121 | - Tree prefix parameter for proper continuation line formatting
122 | - Normalized embedded newlines to prevent structure breaks
123 | - Fixed line breaks cutting through tree characters (│, ├─, └─)
124 | - **Date Sanitization**: Enhanced patterns for multi-line date formats
125 | - Removes clutter from old session summaries (e.g., "Date:\n 9.11.")
126 | - Added re-sanitization after section extraction
127 | - **Output Visibility**: Restored console.log output for user-visible tree display
128 | - Critical fix for output regression where tree was invisible to users
129 | - **Status Bar Improvements**: Added "memories" label for clarity
130 | - Format: "💭 6 (4 recent) memories" instead of just "💭 6 (4 recent)"
131 | - Corrected documentation: "static" instead of "300ms updates"
132 | - **Configuration**: Removed duplicate codeExecution block from config.json
133 | - Files modified: `core/session-start.js`, `utilities/context-formatter.js`, `statusline.sh`, `README.md`, `config.json`
134 |
135 | ## [8.21.0] - 2025-11-08
136 |
137 | ### Added
138 | - **Amp PR Automator Agent** - Lightweight PR automation using Amp CLI (1,240+ lines)
139 | - OAuth-free alternative to Gemini PR Automator with file-based workflow
140 | - `.claude/agents/amp-pr-automator.md` - Complete agent definition
141 | - `scripts/pr/amp_quality_gate.sh` - Parallel complexity, security, type hint checks
142 | - `scripts/pr/amp_collect_results.sh` - Aggregate Amp analysis results
143 | - `scripts/pr/amp_suggest_fixes.sh` - Generate fix suggestions from review feedback
144 | - `scripts/pr/amp_generate_tests.sh` - Create pytest tests for new code
145 | - `scripts/pr/amp_detect_breaking_changes.sh` - Identify API breaking changes
146 | - `scripts/pr/amp_pr_review.sh` - Complete review workflow orchestration
147 | - Fast parallel processing with UUID-based prompt/response tracking
148 | - Credit conservation through focused, non-interactive tasks
149 |
150 | ### Fixed
151 | - **Memory Hook Tag+Time Filtering** (Issue #214, PR #215) - Fixed semantic over-filtering bug
152 | - Enhanced `search_by_tag()` with optional `time_start` parameter across all backends
153 | - Replaced limited `parse_time_query` with robust `parse_time_expression` from `utils.time_parser`
154 | - Fixed HTTP client time filter format (ISO date instead of custom string)
155 | - Improved SQL construction clarity in Cloudflare backend
156 | - Removed unused `match_all` parameter from hybrid backend (regression fix)
157 | - Quality gate: 9.2/10 (Gemini Code Assist review - 4 critical issues fixed)
158 | - Time parser tests: 14/14 PASS (100%)
159 |
160 | ## [8.20.1] - 2025-11-08
161 |
162 | ### Fixed
163 | - **retrieve_memory MCP tool**: Fixed MemoryQueryResult serialization error introduced in v8.19.1
164 | - Extract Memory object from MemoryQueryResult before formatting response
165 | - Add similarity_score to response for consistency with recall_memory
166 | - Affects all backends (sqlite-vec, cloudflare, hybrid)
167 | - Issue #211 follow-up fix - thanks @VibeCodeChef for detailed testing!
168 |
169 | ## [8.20.0] - 2025-11-08
170 |
171 | ### Added
172 | - **GraphQL PR Review Integration** - GitHub GraphQL API for advanced PR operations
173 | - `resolve_threads.sh` - Auto-resolve review threads when commits address feedback (saves 2+ min/PR)
174 | - `thread_status.sh` - Display all review threads with resolution status
175 | - Reusable GraphQL helper library in `scripts/pr/lib/graphql_helpers.sh`
176 | - Smart commit tracking for resolved vs outdated threads
177 | - **PR Automation Workflow** - Comprehensive Gemini Code Assist integration
178 | - `auto_review.sh` - Automated iterative PR review cycles (saves 10-30 min/PR)
179 | - `quality_gate.sh` - Pre-PR quality checks (complexity, security, tests, breaking changes)
180 | - `generate_tests.sh` - Auto-generate pytest tests for new code
181 | - `detect_breaking_changes.sh` - API diff analysis with severity classification
182 | - **Amp Bridge Redesign** - Direct code execution mode for batch operations
183 | - Execute prompts directly without prompt file management
184 | - Batch processing support for multiple operations
185 | - Improved error handling and output formatting
186 | - **Code Quality Guard Agent** - Fast automated code quality analysis
187 | - Pre-commit hook for complexity scoring (blocks >8, warns >7)
188 | - Security pattern detection (SQL injection, XSS, command injection)
189 | - TODO prioritization with impact analysis (Critical/High/Medium/Low)
190 | - Integrated with Gemini CLI for fast analysis
191 | - **Gemini PR Automator Agent** - Eliminates manual review wait times
192 | - Automated "Fix → Comment → /gemini review → Wait → Repeat" workflow
193 | - Intelligent fix classification (safe vs unsafe)
194 | - Comprehensive test generation for all new code
195 | - Breaking change detection with severity levels
196 | - **Groq Bridge Integration** - 10x faster alternative to Gemini CLI
197 | - Python CLI (`groq_agent_bridge.py`) for non-interactive LLM calls
198 | - Support for llama-3.3-70b-versatile, Kimi K2 (256K context), and other Groq models
199 | - Drop-in replacement for Gemini CLI with same interface
200 | - Model comparison documentation with performance benchmarks
201 | - **Pre-commit Hook Infrastructure** - Quality gates before commit
202 | - Symlinked hook: `.git/hooks/pre-commit` → `scripts/hooks/pre-commit`
203 | - Automated complexity checks on staged Python files
204 | - Security vulnerability scanning (blocks commit if found)
205 | - Graceful degradation if Gemini CLI not installed
206 |
207 | ### Documentation
208 | - Added `docs/pr-graphql-integration.md` - GraphQL PR review integration guide
209 | - Added `docs/integrations/groq-bridge.md` - Setup and usage guide for Groq integration
210 | - Added `docs/integrations/groq-integration-summary.md` - Integration overview
211 | - Added `docs/integrations/groq-model-comparison.md` - Performance benchmarks and model selection
212 | - Added `docs/amp-cli-bridge.md` - Amp CLI integration guide
213 | - Added `docs/development/todo-tracker.md` - Automated TODO tracking output
214 | - Added `docs/troubleshooting/hooks-quick-reference.md` - Hook debugging and troubleshooting
215 | - Added `docs/document-ingestion.md` - Document parsing guide
216 | - Added `docs/legacy/dual-protocol-hooks.md` - Historical hook configuration
217 | - Added `scripts/maintenance/memory-types.md` - Memory type taxonomy documentation
218 |
219 | ### Changed
220 | - Updated `.claude/agents/github-release-manager.md` - Enhanced with latest release workflow
221 | - Updated `.env.example` - Removed deprecated ChromaDB backend references
222 | - Updated API specification - Removed `chroma` from backend enum
223 | - Updated example configs - Modernized to use Python module approach
224 |
225 | ### Fixed
226 | - **PR Automation Scripts** - Addressed all Gemini Code Assist review feedback
227 | - Removed hardcoded repository name from all PR scripts (now dynamic with `gh repo view`)
228 | - Fixed script path handling in documentation examples
229 | - Improved error messages and validation in GraphQL helpers
230 | - Enhanced documentation with correct usage examples
231 | - Removed all ChromaDB artifacts from active code (deprecated in v8.0.0)
232 | - Fixed broken test imports (`CHROMADB_MAX_CONTENT_LENGTH` removed)
233 | - Updated integration tests to remove `--chroma-path` CLI assertions
234 | - Cleaned up example configurations
235 | - Added clear deprecation warnings in `install.py`
236 |
237 | ### Performance
238 | - Groq bridge provides 10x faster inference vs Gemini CLI
239 | - llama-3.3-70b: ~300ms response time
240 | - Kimi K2: ~200ms response time (fastest)
241 | - llama-3.1-8b-instant: ~300ms response time
242 | - Pre-commit hooks minimize developer wait time with complexity checks
243 |
244 | ## [8.19.1] - 2025-11-07
245 |
246 | ### Fixed
247 | - **Critical MCP Tool Regressions** (Issue #211) - Two core MCP tools broken in v8.19.0
248 | - **retrieve_memory**: Fixed parameter error where unsupported 'tags' parameter was passed to storage.retrieve()
249 | - Removed unsupported parameters from storage call
250 | - Implemented post-retrieval filtering in MemoryService
251 | - File: `src/mcp_memory_service/services/memory_service.py`
252 | - **search_by_tag**: Fixed type error where code assumed created_at was always string
253 | - Added type checking for both float (timestamp) and string (ISO format)
254 | - Uses `datetime.fromtimestamp()` for floats, `datetime.fromisoformat()` for strings
255 | - Files: `src/mcp_memory_service/server.py` (handle_search_by_tag, handle_retrieve_memory)
256 | - **Impact**: Both tools now work correctly with hybrid storage backend
257 | - **Root Cause**: v8.19.0 refactoring introduced incompatibilities with hybrid storage
258 |
259 | ## [8.19.0] - 2025-11-07
260 |
261 | ### Added
262 | - **Code Execution Interface API** 🚀 - Revolutionary token efficiency for MCP Memory Service (Issue #206)
263 | - **Core API Module** (`src/mcp_memory_service/api/`):
264 | - Compact NamedTuple types (91% size reduction vs MCP tool responses)
265 | - Core operations: `search()`, `store()`, `health()`
266 | - Sync wrapper utilities (hide asyncio complexity)
267 | - Storage client with connection reuse
268 | - **Session Hook Migration** (`claude-hooks/core/session-start.js`):
269 | - Code execution wrapper for token-efficient memory retrieval
270 | - Automatic MCP fallback (100% reliability)
271 | - Performance metrics tracking
272 | - Zero breaking changes
273 | - **Migration Guide** (`docs/migration/code-execution-api-quick-start.md`):
274 | - 5-minute migration workflow
275 | - Cost savings calculator
276 | - Comprehensive troubleshooting
277 | - Platform-specific instructions
278 | - **Comprehensive Documentation**:
279 | - API reference guide
280 | - Phase 1 and Phase 2 implementation summaries
281 | - Research documents (10,000+ words)
282 | - Performance benchmarks
283 |
284 | ### Changed
285 | - **Installer Default** - Code execution now enabled by default for new installations
286 | - Auto-detects Python path (Windows: `python`, Unix: `python3`)
287 | - Validates Python version (warns if < 3.10)
288 | - Shows token reduction benefits during installation
289 | - Graceful upgrade path for existing users
290 |
291 | ### Performance
292 | - **Token Reduction (Validated)**:
293 | - Session hooks: **75% reduction** (3,600 → 900 tokens)
294 | - Search operations: **85% reduction** (2,625 → 385 tokens)
295 | - Store operations: **90% reduction** (150 → 15 tokens)
296 | - Health checks: **84% reduction** (125 → 20 tokens)
297 | - **Execution Performance**:
298 | - Cold start: 61.1ms (target: <100ms)
299 | - Warm calls: 1.3ms avg (target: <10ms)
300 | - Memory overhead: <10MB
301 | - **Annual Savings Potential**:
302 | - 10 users: **$23.82/year** (158.8M tokens saved)
303 | - 100 users: **$238.20/year** (1.59B tokens saved)
304 | - 1000 users: **$2,382/year** (15.9B tokens saved)
305 |
306 | ### Fixed
307 | - **Cross-Platform Compatibility** - Replaced hardcoded macOS paths with `get_base_directory()`
308 | - **Async/Await Pattern** - Fixed async `health()` to properly await storage operations
309 | - **Resource Management** - Added explicit `close()` and `close_async()` methods
310 | - **Documentation** - Fixed Unicode symbols and absolute local paths for better compatibility
311 |
312 | ### Technical Details
313 | - **Files Added**: 23 files, 6,517 lines (production + tests + docs)
314 | - **Test Coverage**: 52 tests (88% passing)
315 | - **Backward Compatibility**: 100% (zero breaking changes)
316 | - **Platform Support**: macOS, Linux, Windows
317 | - **API Exports**: `search`, `store`, `health`, `close`, `close_async`
318 |
319 | ### Removed
320 | - **Obsolete ChromaDB Test Infrastructure** - Removed all test files referencing deprecated ChromaDB storage backend
321 | - **Deleted Files**:
322 | - `tests/performance/test_caching.py` - ChromaDB-specific performance tests
323 | - `tests/test_timestamp_recall.py` - Timestamp tests using ChromaDB APIs
324 | - `tests/test_tag_storage.py` - Tag storage tests for ChromaDB
325 | - `tests/integration/test_storage.py` - ChromaDB storage diagnostic script
326 | - `tests/unit/test_tags.py` - Tag deletion tests using deprecated CHROMA_PATH
327 | - `tests/test_content_splitting.py::test_chromadb_limit()` - ChromaDB content limit test
328 | - **Updated**: `tests/conftest.py` - Generic database testing fixture (removed ChromaDB reference)
329 | - **Context**: ChromaDB backend was fully replaced by SQLite-vec, Cloudflare, and Hybrid backends
330 | - **Impact**: Test suite no longer has broken imports or references to removed storage layer
331 |
332 | ## [8.18.2] - 2025-11-06
333 |
334 | ### Fixed
335 | - **MCP Tool Handler Method Name** - Fixed critical bug where MCP tool handlers called non-existent `retrieve_memory()` method
336 | - **Root Cause**: Method name mismatch introduced in commit 36e9845 during MemoryService refactoring (Oct 28, 2025)
337 | - **Symptom**: `'MemoryService' object has no attribute 'retrieve_memory'` error when using MCP retrieve_memory tool
338 | - **Fix**: Updated handlers to call correct `retrieve_memories()` method (plural)
339 | - **Files Modified**: `src/mcp_memory_service/server.py` (line 2153), `src/mcp_memory_service/mcp_server.py` (line 227)
340 | - **Additional**: Removed unsupported `min_similarity` parameter from MCP tool definition
341 | - **Impact**: MCP retrieve_memory tool now functions correctly
342 | - **Issue**: [#207](https://github.com/doobidoo/mcp-memory-service/issues/207)
343 |
344 | ## [8.18.1] - 2025-11-05
345 |
346 | ### Fixed
347 | - **Test Suite Import Errors** - Resolved critical import failures blocking all test collection
348 | - **MCP Client Import**: Updated from deprecated `mcp` module to `mcp.client.session` (v1.1.2 API)
349 | - **Storage Path Import**: Removed obsolete `CHROMA_PATH` constant that no longer exists in current architecture
350 | - **Impact**: Restored ability to collect and run 190 test cases across unit, integration, and E2E test suites
351 | - **PR**: [#205](https://github.com/doobidoo/mcp-memory-service/pull/205)
352 | - **Issue**: [#204](https://github.com/doobidoo/mcp-memory-service/issues/204)
353 |
354 | ### Technical Details
355 | - **Test Files Updated**: `tests/unit/test_import.py`, `tests/integration/test_store_memory.py`
356 | - **Import Fix**: `from mcp import ClientSession, StdioServerParameters` → `from mcp.client.session import ClientSession`
357 | - **Cleanup**: Removed dependency on deprecated storage constants
358 |
359 | ## [8.18.0] - 2025-11-05
360 |
361 | ### Performance
362 | - **Analytics Dashboard Optimization** - 90% performance improvement for dashboard analytics
363 | - **New Method**: `get_memory_timestamps()` added to all storage backends (SQLite-Vec, Cloudflare, Hybrid)
364 | - **Optimization**: Single optimized SQL query instead of N individual queries for timestamp retrieval
365 | - **Impact**: Dashboard analytics load significantly faster, especially with large memory datasets
366 | - **PR**: [#203](https://github.com/doobidoo/mcp-memory-service/pull/203)
367 | - **Issue**: [#186](https://github.com/doobidoo/mcp-memory-service/issues/186)
368 |
369 | ### Added
370 | - **Type Safety Enhancements** - Pydantic models for analytics data structures
371 | - **Models**: `LargestMemory` (content hash, size, created timestamp) and `GrowthTrendPoint` (date, cumulative count)
372 | - **Benefit**: Enhanced type checking and validation for analytics endpoints
373 | - **File**: `src/mcp_memory_service/web/api/analytics.py`
374 |
375 | ### Fixed
376 | - **Weekly Activity Year Handling** - Fixed incorrect aggregation of same week numbers across different years
377 | - **Issue**: Week 1 of 2024 and Week 1 of 2025 were being combined in weekly activity charts
378 | - **Solution**: Year included in grouping logic for proper temporal separation
379 | - **Impact**: Weekly activity charts now accurately reflect year boundaries
380 |
381 | ### Technical Details
382 | - **Storage Interface**: `get_memory_timestamps()` method added to base `MemoryStorage` class
383 | - **Backend Implementation**: Optimized SQL queries for SQLite-Vec, Cloudflare D1, and Hybrid storage
384 | - **Code Quality**: Import organization and naming consistency improvements per Gemini Code Assist review
385 |
386 | ## [8.17.1] - 2025-11-05
387 |
388 | ### Documentation
389 | - **Workflow Documentation Harvest** - Comprehensive project management templates adapted from PR #199
390 | - **GitHub Issue Templates**: Structured bug/feature/performance reports with environment validation
391 | - `bug_report.yml`: OS, Python version, storage backend, reproduction steps
392 | - `feature_request.yml`: Use case, alternatives, impact assessment
393 | - `performance_issue.yml`: Metrics, database size, profiling data
394 | - `config.yml`: Template selector with Wiki/Discussions links
395 | - **Regression Test Scenarios**: 10 structured test procedures (Setup → Execute → Evidence → Pass/Fail)
396 | - Database locking tests (concurrent MCP servers, concurrent operations)
397 | - Storage backend integrity (hybrid sync, backend switching)
398 | - Dashboard performance (page load <2s, operations <1s)
399 | - Tag filtering correctness (exact matching, index usage)
400 | - MCP protocol compliance (schema validation, tool execution)
401 | - **PR Review Guide**: Standardized code review with Gemini integration
402 | - Template compliance checklist, code quality standards (type hints, async patterns, security)
403 | - Testing verification (>80% coverage), merge criteria, effective feedback templates
404 | - **Issue Management Guide**: Triage, closure, and post-release workflows
405 | - 48h triage response, professional closure templates, GitHub CLI automation
406 | - Issue→PR→Release tracking, post-release systematic review
407 | - **Release Checklist Enhancements**: Version management and emergency procedures
408 | - 3-file version bump procedure (`__init__.py` → `pyproject.toml` → `uv lock`)
409 | - CHANGELOG quality gates, GitHub workflow verification
410 | - Emergency rollback procedure (Docker/PyPI/Git steps, recovery timeline)
411 | - **Impact**: 2,400+ lines of actionable documentation (7 new files, 1 enhanced)
412 | - **Files**: `.github/ISSUE_TEMPLATE/`, `docs/testing/regression-tests.md`, `docs/development/pr-review-guide.md`, `docs/development/issue-management.md`, `docs/development/release-checklist.md`
413 | - **Source**: Adapted from [PR #199](https://github.com/doobidoo/mcp-memory-service/pull/199) by Ray Walker (27Bslash6)
414 | - **Commit**: [ca5ccf3](https://github.com/doobidoo/mcp-memory-service/commit/ca5ccf3f460feca06d3c9232303a6e528ca2c76f)
415 |
416 | ### Fixed
417 | - **CRITICAL: Dashboard Analytics Accuracy** - Fixed analytics endpoint showing incorrect memory count
418 | - **Issue**: Dashboard displayed 1,000 memories (sampling) instead of actual 2,222 total
419 | - **Root Cause**: Analytics endpoint used `get_recent_memories(n=1000)` sampling approach instead of direct SQL query
420 | - **Solution**: Direct SQL query via `storage.primary.conn` for `HybridMemoryStorage` backend
421 | - **File**: `src/mcp_memory_service/web/api/analytics.py` (line 386)
422 | - **Impact**: Dashboard now shows accurate memory totals for all storage backends
423 | - **Additional Fix**: Corrected attribute check from `storage.sqlite` to `storage.primary` for hybrid backend detection
424 |
425 | ### Added
426 | - **Malformed Tags Repair Utility** - Intelligent repair tool for JSON serialization artifacts in tags
427 | - **Script**: `scripts/maintenance/repair_malformed_tags.py`
428 | - **Repaired**: 1,870 malformed tags across 369 memories
429 | - **Patterns Detected**: JSON quotes (`\"tag\"`), brackets (`[tag]`), mixed artifacts
430 | - **Features**: Multi-tier parser, dry-run mode, automatic backups, progress tracking
431 | - **Safety**: Creates backup before modifications, validates repairs
432 |
433 | - **Intelligent Memory Type Assignment** - Automated type inference for untyped memories
434 | - **Script**: `scripts/maintenance/assign_memory_types.py`
435 | - **Processed**: 119 untyped memories with multi-tier inference algorithm
436 | - **Inference Methods**:
437 | - Tag-based mapping (80+ tag-to-type associations)
438 | - Pattern-based detection (40+ content patterns)
439 | - Metadata analysis (activity indicators)
440 | - Fallback heuristics (default to "note")
441 | - **Confidence Scoring**: High/medium/low confidence levels for inference quality
442 | - **Features**: Dry-run mode, automatic backups, detailed statistics
443 |
444 | ### Technical Details
445 | - **Analytics Fix**: Removed "Using sampling approach" warning from logs
446 | - **Database Backups**: Both maintenance scripts create timestamped backups before modifications
447 | - **Type Taxonomy**: Follows 24 core types from consolidated memory type system
448 | - **Hybrid Backend**: Scripts properly detect and handle `HybridMemoryStorage` architecture
449 |
450 | ## [8.17.0] - 2025-11-04
451 |
452 | ### Added
453 | - **Platform-Aware Consolidation Tool** - Cross-platform database path detection for memory type consolidation
454 | - **Auto-detection**: macOS (`~/Library/Application Support`), Windows (`%LOCALAPPDATA%`), Linux (`~/.local/share`)
455 | - **Script**: `scripts/maintenance/consolidate_memory_types.py` enhanced with `platform.system()` detection
456 | - **Benefit**: Works seamlessly across all platforms without manual path configuration
457 | - **PR**: [#201](https://github.com/doobidoo/mcp-memory-service/pull/201)
458 |
459 | - **External JSON Configuration** - Editable consolidation mappings for flexible type management
460 | - **File**: `scripts/maintenance/consolidation_mappings.json` (294 mappings, v1.1.0)
461 | - **Schema**: JSON Schema validation with taxonomy documentation
462 | - **Extensibility**: Add custom type mappings without code changes
463 | - **Taxonomy**: 24 core types organized into 5 categories
464 | - **PR**: [#201](https://github.com/doobidoo/mcp-memory-service/pull/201)
465 |
466 | - **Agent System Documentation** - Comprehensive agent guidelines for development workflows
467 | - **File**: `AGENTS.md` - Central documentation for available agents
468 | - **Agent**: `amp-bridge` - Amp CLI integration for research without credit consumption
469 | - **Integration**: Semi-automated file-based workflow with Amp's `@file` reference syntax
470 | - **CLAUDE.md**: Updated with Amp CLI Bridge architecture and quick start guide
471 | - **PR**: [#201](https://github.com/doobidoo/mcp-memory-service/pull/201)
472 |
473 | ### Fixed
474 | - **Dashboard Analytics Chart Layout** - Resolved rendering and proportionality issues
475 | - **Fixed**: Chart bars rendering outside containers
476 | - **Fixed**: Uniform bar sizes despite different values
477 | - **Fixed**: Memory type distribution showing incorrect proportions
478 | - **Enhancement**: Switched to 200px pixel scale for proper visualization
479 | - **Enhancement**: CSS container constraints with `overflow-x: auto` and flexbox improvements
480 | - **Files**: `web/static/app.js`, `web/static/index.html`, `web/static/style.css`
481 | - **PR**: [#200](https://github.com/doobidoo/mcp-memory-service/pull/200)
482 |
483 | ### Technical Details
484 | - **Platform Detection**: Uses `platform.system()` for "Darwin" (macOS), "Windows", and Linux
485 | - **Backward Compatibility**: Existing scripts continue to work with new platform-aware paths
486 | - **Agent Workflow**: Claude Code creates prompts → User runs `amp @prompt-file` → Amp writes response → Agent presents results
487 | - **Chart Rendering**: Dashboard now properly visualizes memory distribution with accurate proportions
488 |
489 | ## [8.16.2] - 2025-11-03
490 |
491 | ### Fixed
492 | - **Critical Bug**: Fixed bidirectional sync script crash due to incorrect Memory attribute access
493 | - **File**: `scripts/sync/sync_memory_backends.py`
494 | - **Root Cause**: Script accessed non-existent `memory.id` and `memory.hash` attributes instead of correct `memory.content_hash`
495 | - **Impact**: Bidirectional sync between SQLite-vec and Cloudflare backends completely broken
496 | - **Lines Fixed**: 81, 121, 137, 146, 149, 151, 153, 155, 158
497 | - **Testing**: Dry-run validated with 1,978 SQLite memories and 1,958 Cloudflare memories
498 | - **Result**: Successfully identified 338 memories to sync, 1,640 duplicates correctly skipped
499 |
500 | ### Technical Details
501 | - **Error Type**: `AttributeError: 'Memory' object has no attribute 'id'/'hash'`
502 | - **Correct Attribute**: `content_hash` - SHA-256 based unique identifier for memory content
503 | - **Affected Methods**: `get_all_memories_from_backend()`, `_sync_between_backends()`
504 | - **Backward Compatibility**: No breaking changes, only fixes broken functionality
505 |
506 | ## [8.16.1] - 2025-11-02
507 |
508 | ### Fixed
509 | - **Critical Bug**: Fixed `KeyError: 'message'` in MCP server handler (`server.py:2118`)
510 | - **Issue**: [#198](https://github.com/doobidoo/mcp-memory-service/issues/198)
511 | - **Root Cause**: `handle_store_memory()` attempted to access non-existent `result["message"]` key
512 | - **Impact**: All memory store operations via MCP `server.py` handler failed completely
513 | - **Fix**: Properly handle `MemoryService.store_memory()` response format:
514 | - Success (single): `{"success": True, "memory": {...}}`
515 | - Success (chunked): `{"success": True, "memories": [...], "total_chunks": N}`
516 | - Failure: `{"success": False, "error": "..."}`
517 | - **Response Messages**: Now include truncated content hash for verification
518 | - **Related**: This was part of issue #197 where async/await bug was fixed in v8.16.0, but this response format bug was missed
519 |
520 | ### Added
521 | - **Integration Tests**: New test suite for MCP handler methods (`tests/integration/test_mcp_handlers.py`)
522 | - **Coverage**: 11 test cases for `handle_store_memory()`, `handle_retrieve_memory()`, `handle_search_by_tag()`
523 | - **Regression Tests**: Specific tests for issue #198 to prevent future KeyError bugs
524 | - **Test Scenarios**: Success, chunked response, error handling, edge cases
525 | - **Purpose**: Prevent similar bugs in future releases
526 |
527 | ### Technical Details
528 | - **Affected Handler**: Only `handle_store_memory()` was affected by this bug
529 | - **Fixed Code Pattern**: Matches the correct pattern used in `mcp_server.py:182-205`
530 | - **Backward Compatibility**: No breaking changes, only fixes broken functionality
531 |
532 | ## [8.16.0] - 2025-11-01
533 |
534 | ### Added
535 | - **Memory Type Consolidation Tool** 🆕 - Professional-grade database maintenance for type taxonomy cleanup
536 | - **Script**: `scripts/maintenance/consolidate_memory_types.py` (v1.0.0)
537 | - **Configuration**: `scripts/maintenance/consolidation_mappings.json` (168 predefined mappings)
538 | - **Performance**: ~5 seconds for 1,000 memory updates
539 | - **Safety Features**:
540 | - ✅ Automatic timestamped backups before execution
541 | - ✅ Dry-run mode for safe preview
542 | - ✅ Transaction safety (atomic with rollback)
543 | - ✅ Database lock detection
544 | - ✅ HTTP server status warnings
545 | - ✅ Disk space verification
546 | - ✅ Backup integrity validation
547 | - **Consolidates**: 341 fragmented types → 24 core taxonomy types
548 | - **Real-world test**: 1,049 memories updated in 5s (59% of database)
549 | - **Type reduction**: 342 → 128 unique types (63% reduction)
550 | - **Zero data loss**: Only type reassignments, preserves all content
551 |
552 | - **Standardized Memory Type Taxonomy** - 24 core types organized into 5 categories
553 | - **Content Types** (4): note, reference, document, guide
554 | - **Activity Types** (5): session, implementation, analysis, troubleshooting, test
555 | - **Artifact Types** (4): fix, feature, release, deployment
556 | - **Progress Types** (2): milestone, status
557 | - **Infrastructure Types** (5): configuration, infrastructure, process, security, architecture
558 | - **Other Types** (4): documentation, solution, achievement, technical
559 | - **Purpose**: Prevents future type fragmentation
560 | - **Benefits**: Improved query efficiency, consistent naming, better semantic grouping
561 |
562 | ### Changed
563 | - **CLAUDE.md** - Added Memory Type Taxonomy section to Development Guidelines
564 | - Documents 24 core types with clear usage guidelines
565 | - Provides examples of what to avoid (bug-fix vs fix, technical-* prefixes)
566 | - Added consolidation commands to Essential Commands section
567 | - Includes best practices for maintaining type consistency
568 |
569 | ### Documentation
570 | - **Comprehensive Maintenance Documentation**
571 | - Updated `scripts/maintenance/README.md` with consolidation tool guide
572 | - Added to Quick Reference table with performance metrics
573 | - Detailed usage instructions with safety prerequisites
574 | - Recovery procedures for backup restoration
575 | - Maintenance schedule recommendations (monthly dry-run checks)
576 | - **Real-world example**: Production consolidation results from Nov 2025
577 |
578 | ### Technical Details
579 | - **Consolidation Mappings**:
580 | - NULL/empty → `note` (609 memories in real test)
581 | - Milestone/completion variants → `milestone` (21 source types → 60 memories)
582 | - Session variants → `session` (8 source types → 37 memories)
583 | - Technical-* prefix removal → base types (62 memories)
584 | - Project-* prefix removal → base types (67 memories)
585 | - Fix/bug variants → `fix` (8 source types → 28 memories)
586 | - See `consolidation_mappings.json` for complete mapping list (168 rules)
587 |
588 | ### Notes
589 | - **Customizable**: Edit `consolidation_mappings.json` to customize behavior
590 | - **Idempotent**: Safe to run multiple times with same mappings
591 | - **Platform support**: Linux, macOS, Windows (disk space check requires statvfs)
592 | - **Recommended schedule**: Run --dry-run monthly, execute when types exceed 150
593 |
594 | ## [8.15.1] - 2025-10-31
595 |
596 | ### Fixed
597 | - **Critical Python Syntax Error in Hook Installer** - Fixed IndentationError in `claude-hooks/install_hooks.py` (line 790)
598 | - **Issue**: Extra closing braces in SessionEnd hook configuration caused installation to fail
599 | - **Symptom**: `IndentationError: unexpected indent` when running `python install_hooks.py`
600 | - **Root Cause**: Git merge conflict resolution left two extra `}` characters (lines 790-791)
601 | - **Impact**: Users could not install or update hooks after pulling v8.15.0
602 | - **Fix**: Removed extra closing braces, corrected indentation
603 | - **Files Modified**: `claude-hooks/install_hooks.py`
604 | - **Testing**: Verified successful installation on macOS after fix
605 |
606 | ### Technical Details
607 | - **Line Numbers**: 788-791 in install_hooks.py
608 | - **Error Type**: IndentationError (Python syntax)
609 | - **Detection Method**: Manual testing during hook reinstallation
610 | - **Resolution Time**: Immediate (same-day patch)
611 |
612 | ## [8.15.0] - 2025-10-31
613 |
614 | ### Added
615 | - **`/session-start` Slash Command** - Manual session initialization for all platforms
616 | - Provides same functionality as automatic SessionStart hook
617 | - Displays project context, git history, relevant memories
618 | - **Platform**: Works on Windows, macOS, Linux
619 | - **Use Case**: Primary workaround for Windows SessionStart hook bug (#160)
620 | - **Location**: `claude_commands/session-start.md`
621 | - **Benefits**:
622 | - ✅ Safe manual alternative to automatic hooks
623 | - ✅ No configuration changes needed
624 | - ✅ Full memory awareness functionality
625 | - ✅ Prevents Claude Code hangs on Windows
626 |
627 | ### Changed
628 | - **Windows-Aware Installer** - Platform detection and automatic configuration
629 | - Detects Windows platform during hook installation
630 | - Automatically skips SessionStart hook configuration on Windows
631 | - Shows clear warning about SessionStart limitation
632 | - Suggests `/session-start` slash command as alternative
633 | - Also skips statusLine configuration on Windows (requires bash)
634 | - **Files Modified**: `claude-hooks/install_hooks.py` (lines 749-817)
635 | - **User Impact**: Prevents Windows users from accidentally breaking Claude Code
636 |
637 | ### Documentation
638 | - **Enhanced Windows Support Documentation**
639 | - Updated `claude_commands/README.md` with `/session-start` command details
640 | - Added Windows workaround section to `claude-hooks/README.md`
641 | - Updated `CLAUDE.md` with `/session-start` as #1 recommended workaround
642 | - Added comprehensive troubleshooting guidance
643 | - Updated GitHub issue #160 with new workaround instructions
644 |
645 | ### Fixed
646 | - **Windows Installation Experience** - Prevents SessionStart hook deadlock (Issue #160)
647 | - **Previous Behavior**: Windows users install hooks → Claude Code hangs → frustration
648 | - **New Behavior**: Windows users see warning → skip SessionStart → use `/session-start` → works
649 | - **Breaking Change**: None - fully backward compatible
650 | - **Upstream Issue**: Awaiting fix from Anthropic Claude Code team (claude-code#9542)
651 |
652 | ### Technical Details
653 | - **Files Created**: 1 new slash command
654 | - `claude_commands/session-start.md` - Full command documentation
655 | - **Files Modified**: 4 files
656 | - `claude-hooks/install_hooks.py` - Windows platform detection and warnings
657 | - `claude_commands/README.md` - Added `/session-start` to available commands
658 | - `claude-hooks/README.md` - Added slash command workaround reference
659 | - `CLAUDE.md` - Updated workaround prioritization
660 |
661 | - **Platform Compatibility**:
662 | - ✅ Windows: `/session-start` command works, automatic hooks skipped
663 | - ✅ macOS: All features work (automatic hooks + slash command)
664 | - ✅ Linux: All features work (automatic hooks + slash command)
665 |
666 | ## [8.14.2] - 2025-10-31
667 |
668 | ### Performance
669 | - **Optimized MemoryService.get_memory_by_hash()** - O(1) direct lookup replaces O(n) scan (Issue #196)
670 | - **Previous Implementation**: Loaded ALL memories via `storage.get_all_memories()`, then filtered by hash
671 | - **New Implementation**: Direct O(1) database lookup via `storage.get_by_hash()`
672 | - **Performance Impact**:
673 | - Small datasets (10-100 memories): ~2x faster
674 | - Medium datasets (100-1000 memories): ~10-50x faster
675 | - Large datasets (1000+ memories): ~100x+ faster
676 | - **Memory Usage**: Single memory object vs loading entire dataset into memory
677 |
678 | ### Added
679 | - **Abstract method `get_by_hash()` in MemoryStorage base class** (storage/base.py)
680 | - Enforces O(1) direct hash lookup across all storage backends
681 | - Required implementation for all storage backends
682 | - Returns `Optional[Memory]` (None if not found)
683 |
684 | - **Implemented `get_by_hash()` in CloudflareStorage** (storage/cloudflare.py)
685 | - Direct D1 SQL query: `SELECT * FROM memories WHERE content_hash = ?`
686 | - Handles R2 content loading if needed
687 | - Loads tags separately
688 | - Follows same pattern as SqliteVecMemoryStorage implementation
689 |
690 | ### Changed
691 | - **MemoryService.get_memory_by_hash()** now uses direct storage lookup
692 | - Removed inefficient `get_all_memories()` + filter approach
693 | - Simplified implementation (5 lines vs 10 lines)
694 | - Updated docstring to reflect O(1) lookup
695 |
696 | ### Testing
697 | - **Updated unit tests** (tests/unit/test_memory_service.py)
698 | - Mocks now use `storage.get_by_hash()` instead of `storage.get_all_memories()`
699 | - Added assertions to verify method calls
700 | - All 3 test cases pass (found, not found, error handling)
701 |
702 | - **Updated integration tests** (tests/integration/test_api_with_memory_service.py)
703 | - Mock updated for proper method delegation
704 | - Real storage backends (SqliteVecMemoryStorage, HybridMemoryStorage) work correctly
705 |
706 | ### Technical Details
707 | - **Files Modified**: 5 files
708 | - `src/mcp_memory_service/storage/base.py`: Added abstract `get_by_hash()` method
709 | - `src/mcp_memory_service/storage/cloudflare.py`: Implemented `get_by_hash()` (40 lines)
710 | - `src/mcp_memory_service/services/memory_service.py`: Optimized `get_memory_by_hash()`
711 | - `tests/unit/test_memory_service.py`: Updated mocks
712 | - `tests/integration/test_api_with_memory_service.py`: Updated mocks
713 |
714 | - **Breaking Changes**: None - fully backward compatible
715 | - **All Storage Backends Now Support get_by_hash()**:
716 | - ✅ SqliteVecMemoryStorage (line 1153)
717 | - ✅ CloudflareStorage (line 666)
718 | - ✅ HybridMemoryStorage (line 974, delegates to primary)
719 |
720 | ## [8.14.1] - 2025-10-31
721 |
722 | ### Added
723 | - **Type Safety Improvements** - Comprehensive TypedDict definitions for all MemoryService return types
724 | - **Problem**: All MemoryService methods returned loose `Dict[str, Any]` types, providing no IDE support or compile-time validation
725 | - **Solution**: Created 14 specific TypedDict classes for structured return types
726 | - Store operations: `StoreMemorySingleSuccess`, `StoreMemoryChunkedSuccess`, `StoreMemoryFailure`
727 | - List operations: `ListMemoriesSuccess`, `ListMemoriesError`
728 | - Retrieve operations: `RetrieveMemoriesSuccess`, `RetrieveMemoriesError`
729 | - Search operations: `SearchByTagSuccess`, `SearchByTagError`
730 | - Delete operations: `DeleteMemorySuccess`, `DeleteMemoryFailure`
731 | - Health operations: `HealthCheckSuccess`, `HealthCheckFailure`
732 | - **Benefits**:
733 | - ✅ IDE autocomplete for all return values (type `result["` to see available keys)
734 | - ✅ Compile-time type checking catches typos (e.g., `result["succes"]` → type error)
735 | - ✅ Self-documenting API - clear contracts for all methods
736 | - ✅ Refactoring safety - renaming keys shows all affected code
737 | - ✅ 100% backward compatible - no runtime changes
738 | - ✅ Zero performance impact - pure static typing
739 |
740 | ### Fixed
741 | - **Missing HybridMemoryStorage.get_by_hash()** - Added delegation method to HybridMemoryStorage
742 | - Fixed `AttributeError: 'HybridMemoryStorage' object has no attribute 'get_by_hash'`
743 | - All storage backends now implement `get_by_hash()`: SqliteVecMemoryStorage, CloudflareMemoryStorage, HybridMemoryStorage
744 | - Enables direct memory retrieval by content hash without loading all memories
745 | - See issue #196 for planned optimization to use this method in MemoryService
746 |
747 | ### Technical Details
748 | - **Files Modified**:
749 | - `src/mcp_memory_service/services/memory_service.py`: Added 14 TypedDict classes, updated 6 method signatures
750 | - `src/mcp_memory_service/storage/hybrid.py`: Added `get_by_hash()` delegation method
751 | - **Breaking Changes**: None - fully backward compatible (TypedDict is structural typing)
752 | - **Testing**: All tests pass (15/15), comprehensive structure validation, HTTP API integration verified
753 |
754 | ## [8.14.0] - 2025-10-31
755 |
756 | ### Fixed
757 | - **Comprehensive Tag Normalization** - DRY solution for all tag format handling
758 | - **Problem**: Inconsistent tag handling across different APIs caused validation errors
759 | - Top-level `tags` parameter accepted strings, but MemoryService expected arrays
760 | - `metadata.tags` field had no normalization, causing "is not of type 'array'" errors
761 | - Comma-separated strings like `"tag1,tag2,tag3"` were not split into arrays
762 | - Normalization logic was duplicated in some methods but missing in others
763 | - **Root Cause**:
764 | - MCP/HTTP adapters accepted `Union[str, List[str], None]` in signatures
765 | - But passed values to MemoryService without normalization
766 | - MemoryService expected `Optional[List[str]]`, causing type mismatch
767 | - `search_by_tag()` had normalization, but `store_memory()` did not (DRY violation)
768 | - **Solution** (DRY Principle Applied):
769 | - Created centralized `normalize_tags()` utility function (services/memory_service.py:27-56)
770 | - Handles ALL input formats:
771 | - `None` → `[]`
772 | - `"tag1,tag2,tag3"` → `["tag1", "tag2", "tag3"]`
773 | - `"single-tag"` → `["single-tag"]`
774 | - `["tag1", "tag2"]` → `["tag1", "tag2"]` (passthrough)
775 | - Updated `MemoryService.store_memory()` to:
776 | - Accept `Union[str, List[str], None]` type hint
777 | - Normalize both `tags` parameter and `metadata.tags` field
778 | - Merge tags from both sources with deduplication
779 | - Updated `MemoryService.search_by_tag()` to use utility (removed duplicate code)
780 | - **Files Modified**:
781 | - `src/mcp_memory_service/services/memory_service.py`: Added normalize_tags(), updated store_memory() and search_by_tag()
782 | - `src/mcp_memory_service/mcp_server.py`: Updated docstring to reflect all formats supported
783 | - **Benefits**:
784 | - ✅ Single source of truth for tag normalization (DRY)
785 | - ✅ All tag formats work everywhere (top-level, metadata, any protocol)
786 | - ✅ No more validation errors for comma-separated strings
787 | - ✅ Fully backward compatible
788 | - ✅ Consistent behavior across all endpoints
789 | - **User Impact**:
790 | - Can use any tag format anywhere without errors
791 | - No need to remember which parameter accepts which format
792 | - Improved developer experience and reduced friction
793 |
794 | ### Technical Details
795 | - **Affected Components**: MemoryService (business logic layer), MCP server documentation
796 | - **Breaking Changes**: None - fully backward compatible
797 | - **Tag Merge Behavior**: When tags provided in both parameter and metadata, they are merged and deduplicated
798 | - **Testing**: Verified with all format combinations (None, string, comma-separated, array, metadata.tags)
799 |
800 | ## [8.13.5] - 2025-10-31
801 |
802 | ### Fixed
803 | - **Memory Hooks Display Polish** - Visual improvements for cleaner, more professional CLI output
804 | - **Issue**: Multiple visual inconsistencies in memory hooks tree structure display
805 | - **Problems Identified**:
806 | 1. Redundant bottom frame (`╰────╯`) after tree naturally ended with `└─`
807 | 2. Wrapped text continuation showing vertical lines (`│`) after last items
808 | 3. Duplicate final summary message ("Context injected") when header already shows count
809 | 4. Embedded formatting (✅, •, markdown) conflicting with tree structure
810 | 5. Excessive content length despite adaptive truncation
811 | - **Fixes** (commits ed46d24, 998a39c):
812 | - **Content Sanitization**: Remove checkmarks, bullets, markdown formatting that conflicts with tree characters
813 | - **Smart Truncation**: Extract first 1-2 sentences for <400 char limits using sentence boundary detection
814 | - **Tree Continuation Logic**: Last items show clean indentation without vertical lines on wrapped text
815 | - **Remove Redundant Frame**: Tree ends naturally with `└─`, no separate closing box
816 | - **Remove Duplicate Message**: Header shows "X memories loaded", no redundant final summary
817 | - **Files Modified**:
818 | - `claude-hooks/utilities/context-formatter.js`: Content sanitization, smart truncation, tree continuation fixes
819 | - `claude-hooks/core/session-start.js`: Removed redundant success message
820 | - **Result**: Clean, consistent tree structure with proper visual hierarchy and no redundancy
821 | - **User Impact**: Professional CLI output, easier to scan, maintains continuous blue tree lines properly
822 |
823 | ### Technical Details
824 | - **Affected Component**: Claude Code memory awareness hooks (SessionStart display)
825 | - **Deployment**: Hooks loaded from repository automatically, no server restart needed
826 | - **Testing**: Verified with mock execution and real Claude Code session
827 |
828 | ## [8.13.4] - 2025-10-30
829 |
830 | ### Fixed
831 | - **Critical: Memory Hooks Showing Incorrect Ages** (#195) - Timestamp unit mismatch causing 20,371-day ages
832 | - **Error**: Memory hooks reporting `avgAge: 20371 days, medianAge: 20371 days` when actual age was 6 days
833 | - **User Impact**: Recent memories didn't surface, auto-calibration incorrectly triggered "stale memory" warnings
834 | - **Root Cause** (claude-hooks/utilities/memory-client.js:273): Timestamp unit mismatch
835 | - HTTP API returns Unix timestamps in **SECONDS**: `1758344479.729`
836 | - JavaScript `Date()` expects **MILLISECONDS**: Interpreted as `Jan 21, 1970` (55 years ago)
837 | - Age calculation: `(now - 1758344479ms) / 86400000 = 20371 days`
838 | - **Symptoms**:
839 | - `[Memory Age Analyzer] { avgAge: 20371, recentPercent: 0, isStale: true }`
840 | - Hooks showed "Stale memory set detected (median: 20371d old)"
841 | - Recent development work (< 7 days) never surfaced in context
842 | - **Fix** (claude-hooks/utilities/memory-client.js:273-294, commit 5c54894):
843 | - Convert API timestamps from seconds to milliseconds (`× 1000`)
844 | - Added year 2100 check (`< 4102444800`) to prevent double-conversion
845 | - Applied in `_performApiPost()` response handler for both `created_at` and `updated_at`
846 | - **Result**:
847 | - `avgAge: 6 days, medianAge: 5 days, recentPercent: 100%, isStale: false`
848 | - Recent memories surface correctly
849 | - Auto-calibration works properly
850 | - Git context weight adjusts based on actual ages
851 | - **Note**: Affects all users using HTTP protocol for memory hooks
852 |
853 | ### Technical Details
854 | - **Affected Component**: Claude Code memory awareness hooks (HTTP protocol path)
855 | - **File Changed**: `claude-hooks/utilities/memory-client.js` (lines 273-294)
856 | - **Deployment**: Hooks loaded from repository automatically, no server restart needed
857 | - **Issue**: https://github.com/doobidoo/mcp-memory-service/issues/195
858 |
859 | ## [8.13.3] - 2025-10-30
860 |
861 | ### Fixed
862 | - **Critical: MCP Memory Tools Broken** - v8.12.0 regression preventing all MCP memory operations
863 | - **Error**: `KeyError: 'message'` when calling any MCP memory tool (store, retrieve, search, etc.)
864 | - **User Impact**: MCP tools completely non-functional - "Error storing memory: 'message'"
865 | - **Root Cause** (mcp_server.py:175): Return format mismatch between MemoryService and MCP tool expectations
866 | - MCP tool expects: `{success: bool, message: str, content_hash: str}`
867 | - MemoryService returns: `{success: bool, memory: {...}}`
868 | - MCP protocol tries to access missing 'message' field → KeyError
869 | - **Why It Persisted**: HTTP API doesn't require these specific fields, so integration tests passed
870 | - **Fix** (mcp_server.py:173-206): Transform MemoryService response to MCP TypedDict format
871 | - Capture result from MemoryService.store_memory()
872 | - Extract content_hash from nested memory object
873 | - Add descriptive "message" field
874 | - Handle 3 cases: failure (error message), chunked (multiple memories), single memory
875 | - **Result**: MCP tools now work correctly with proper error messages
876 | - **Note**: Requires MCP server restart (`/mcp` command in Claude Code) to load fix
877 |
878 | ### Technical Details
879 | - **Introduced**: v8.12.0 MemoryService architecture refactoring (#176)
880 | - **Affected Tools**: store_memory, all MCP protocol operations
881 | - **HTTP API**: Unaffected (different response format requirements)
882 | - **Test Gap**: No integration tests validating MCP tool response formats
883 |
884 | ## [8.13.2] - 2025-10-30
885 |
886 | ### Fixed
887 | - **Memory Sync Script Broken** (#193): Fixed sync_memory_backends.py calling non-existent `store_memory()` method
888 | - **Error**: `AttributeError: 'CloudflareStorage' object has no attribute 'store_memory'`
889 | - **User Impact**: Sync script completely non-functional - couldn't sync memories between Cloudflare and SQLite backends
890 | - **Root Cause** (scripts/sync/sync_memory_backends.py:144-147): Script used old `store_memory()` API that no longer exists
891 | - **Fix** (#194, b69de83): Updated to use proper `Memory` object creation and `storage.store()` method
892 | - Create `Memory` object with `content`, `content_hash`, `tags`, `metadata`, `created_at`
893 | - Call `await target_storage.store(memory_obj)` instead of non-existent `store_memory()`
894 | - Added safe `.get('metadata', {})` to prevent KeyError on missing metadata
895 | - Fixed import order to comply with PEP 8 (config → models → storage)
896 | - **Result**: Sync script now successfully syncs memories between backends
897 | - **Credit**: Fix by AMP via PR #194, reviewed by Gemini
898 |
899 | ## [8.13.1] - 2025-10-30
900 |
901 | ### Fixed
902 | - **Critical Concurrent Access Bug**: MCP server initialization failed with "database is locked" when HTTP server running
903 | - **Error**: `sqlite3.OperationalError: database is locked` during MCP tool initialization
904 | - **User Impact**: MCP memory tools completely non-functional while HTTP server running - "this worked before without any flaws"
905 | - **Root Cause #1** (sqlite_vec.py:329): Connection timeout set AFTER opening database instead of during connection
906 | - Original: `sqlite3.connect(path)` used default 5-second timeout, then applied `PRAGMA busy_timeout=15000`
907 | - SQLite only respects timeout parameter passed to `connect()`, not pragma applied afterward
908 | - MCP server timed out before it could set the higher timeout value
909 | - **Root Cause #2** (sqlite_vec.py:467-476): Both servers attempting DDL operations (CREATE TABLE, CREATE INDEX) simultaneously
910 | - Even with WAL mode, DDL operations require brief exclusive locks
911 | - No detection of already-initialized database before running DDL
912 | - **Fix #1** (sqlite_vec.py:291-326): Parse `busy_timeout` from `MCP_MEMORY_SQLITE_PRAGMAS` environment variable BEFORE opening connection
913 | - Convert from milliseconds to seconds (15000ms → 15.0s)
914 | - Pass timeout to `sqlite3.connect(path, timeout=15.0)` for immediate effect
915 | - Allows MCP server to wait up to 15 seconds for HTTP server's DDL operations
916 | - **Fix #2** (sqlite_vec.py:355-373): Detect already-initialized database and skip DDL operations
917 | - Check if `memories` and `memory_embeddings` tables exist after loading sqlite-vec extension
918 | - If tables exist, just load embedding model and mark as initialized
919 | - Prevents "database is locked" errors from concurrent CREATE TABLE/INDEX attempts
920 | - **Result**: MCP and HTTP servers now coexist without conflicts, maintaining pre-v8.9.0 concurrent access behavior
921 |
922 | ### Technical Details
923 | - **Timeline**: Bug discovered during memory consolidation testing, fixed same day
924 | - **Affected Versions**: v8.9.0 introduced database lock prevention pragmas but didn't fix concurrent initialization
925 | - **Test Validation**: MCP health check returns healthy with 1857 memories while HTTP server running
926 | - **Log Evidence**: "Database already initialized by another process, skipping DDL operations" confirms fix working
927 |
928 | ## [8.13.0] - 2025-10-29
929 |
930 | ### Added
931 | - **HTTP Server Integration Tests** (#190): Comprehensive test suite with 32 tests prevents production bugs like v8.12.0
932 | - `tests/integration/test_http_server_startup.py`: 8 tests for server startup validation
933 | - `tests/unit/test_fastapi_dependencies.py`: 11 tests for dependency injection
934 | - `tests/unit/test_storage_interface_compatibility.py`: 13 tests for backend interface consistency
935 | - Extended `tests/integration/test_api_with_memory_service.py`: +11 HTTP API tests with TestClient
936 | - Tests would have caught all 3 v8.12.0 production bugs (import-time evaluation, syntax errors, interface mismatches)
937 |
938 | - **Storage Method: get_largest_memories()** (#186): Efficient database queries for largest memories by content length
939 | - Added to all storage backends (SQLite, Cloudflare, Hybrid)
940 | - Uses `ORDER BY LENGTH(content) DESC LIMIT n` instead of loading 1000 memories and sorting in Python
941 | - Analytics dashboard now queries entire dataset for truly largest memories
942 |
943 | ### Fixed
944 | - **Analytics Dashboard Timezone Bug** (#186): Fixed heatmap calendar showing wrong day-of-week near timezone boundaries
945 | - JavaScript `new Date('YYYY-MM-DD')` parsed as UTC midnight, but `getDay()` used local timezone
946 | - Changed to parse date components in local timezone: `new Date(year, month-1, day)`
947 | - Prevents calendar cells from shifting to previous/next day for users in UTC-12 to UTC+12 timezones
948 |
949 | ### Improved
950 | - **Analytics Performance**: Reduced memory sample for average size calculation from 1000→100 memories
951 | - **Test Coverage**: Zero HTTP integration tests → 32 comprehensive tests covering server startup, dependencies, and API endpoints
952 |
953 | ### Documentation
954 | - **MCP Schema Caching** (#173): Closed with comprehensive documentation in CLAUDE.md and troubleshooting guides
955 | - Root cause: MCP protocol caches tool schemas client-side
956 | - Workaround: `/mcp` command reconnects server with fresh schema
957 | - Documented symptoms, diagnosis, and resolution steps
958 |
959 | ## [8.12.1] - 2025-10-28
960 |
961 | ### Fixed
962 | - **Critical Production Bug #1** (ef2c64d): Import-time default parameter evaluation in `get_memory_service()`
963 | - **Error**: `HTTPException: 503: Storage not initialized` during module import
964 | - **Root Cause**: Python evaluates default parameters at function definition time, not call time
965 | - **Impact**: HTTP server couldn't start - module import failed immediately
966 | - **Fix**: Changed from `storage: MemoryStorage = get_storage()` to `storage: MemoryStorage = Depends(get_storage)`
967 | - **Technical**: FastAPI's `Depends()` defers evaluation until request time and integrates with dependency injection
968 |
969 | - **Critical Production Bug #2** (77de4d2): Syntax error + missing FastAPI Depends import in `memories.py`
970 | - **Error**: `SyntaxError: expected an indented block after 'if' statement on line 152`
971 | - **Root Cause**: `if INCLUDE_HOSTNAME:` had no indented body, nested if-elif-else block not indented
972 | - **Impact**: SyntaxError prevented module import + FastAPI validation failure
973 | - **Fix**: Properly indented hostname resolution logic, added missing `Depends` import to dependencies.py
974 |
975 | - **Critical Production Bug #3** (f935c56): Missing `tags` parameter in `count_all_memories()` across all storage backends
976 | - **Error**: `TypeError: count_all_memories() got an unexpected keyword argument 'tags'`
977 | - **User Report**: "failed to load dashboard data"
978 | - **Root Cause**: MemoryService called `count_all_memories(memory_type=type, tags=tags)` but base class and implementations didn't accept tags parameter
979 | - **Impact**: Dashboard completely broken - GET /api/memories returned 500 errors
980 | - **Fix**: Updated 4 files (base.py, hybrid.py, sqlite_vec.py, cloudflare.py) to add tags parameter with SQL LIKE filtering
981 | - **Why Tests Missed It**: AsyncMock accepts ANY parameters, never tested real storage backend implementations
982 |
983 | - **Analytics Metrics Bug** (8beeb07): Analytics tab showed different metrics than Dashboard tab
984 | - **Problem**: Dashboard queried ALL memories, Analytics sampled only 1000 recent memories
985 | - **Impact**: "This Week" count was inaccurate when total memories > 1000
986 | - **Fix**: Changed Analytics endpoint to use `storage.get_stats()` instead of sampling
987 | - **Performance**: Eliminated O(n) memory loading for simple count operation, now uses efficient SQL COUNT
988 |
989 | ### Changed
990 | - **Analytics Endpoint Performance** - Increased monthly sample from 2,000 to 5,000 memories
991 | - **Code Quality** - Added TODO comments for moving monthly calculations to storage layer
992 |
993 | ### Technical Details
994 | - **Timeline**: All 4 bugs discovered and fixed within 4 hours of v8.12.0 release (15:03 UTC → 22:03 UTC)
995 | - **Post-Mortem**: Created Issue #190 for HTTP server integration tests to prevent future production bugs
996 | - **Test Coverage Gap**: v8.12.0 had 55 tests but zero HTTP server integration tests
997 | - **Lesson Learned**: Tests used mocked storage that never actually started the server or tested real FastAPI dependency injection
998 |
999 | **Note**: This patch release resolves all production issues from v8.12.0 architectural changes. Comprehensive analysis stored in memory with tag `v8.12.0,post-release-bugs`.
1000 |
1001 | ## [8.12.0] - 2025-10-28
1002 |
1003 | ### Added
1004 | - **MemoryService Architecture** - Centralized business logic layer (Issue #188, PR #189)
1005 | - Single source of truth for all memory operations
1006 | - Consistent behavior across API endpoints and MCP tools
1007 | - 80% code duplication reduction between API and MCP servers
1008 | - Dependency injection pattern for clean architecture
1009 | - **Comprehensive Test Coverage**:
1010 | - 34 unit tests (100% pass rate)
1011 | - 21 integration tests for API layer
1012 | - End-to-end workflow tests with real storage
1013 | - Performance validation for database-level filtering
1014 |
1015 | ### Fixed
1016 | - **Critical Bug #1**: `split_content()` missing required `max_length` parameter
1017 | - Impact: Would crash immediately on any content chunking operation
1018 | - Fix: Added proper parameter passing with storage backend max_length
1019 | - **Critical Bug #2**: `storage.delete_memory()` method does not exist in base class
1020 | - Impact: Delete functionality completely broken
1021 | - Fix: Changed to use `storage.delete(content_hash)` from base class
1022 | - **Critical Bug #3**: `storage.get_memory()` method does not exist in base class
1023 | - Impact: Get by hash functionality completely broken
1024 | - Fix: Implemented using `get_all_memories()` with client-side filtering
1025 | - **Critical Bug #4**: `storage.health_check()` method does not exist in base class
1026 | - Impact: Health check functionality completely broken
1027 | - Fix: Changed to use `storage.get_stats()` from base class
1028 | - **Critical Bug #5**: `storage.search_by_tags()` method mismatch (plural vs singular)
1029 | - Impact: Tag search functionality completely broken
1030 | - Fix: Changed to use `storage.search_by_tag()` (singular) from base class
1031 | - **Critical Bug #6**: Incorrect chunking logic comparing `len(content) > CONTENT_PRESERVE_BOUNDARIES`
1032 | - Impact: ALL content >1 character would trigger chunking (CONTENT_PRESERVE_BOUNDARIES is boolean `True`)
1033 | - Fix: Proper comparison using `storage.max_content_length` numeric value
1034 | - **Critical Bug #7**: Missing `store()` return value handling
1035 | - Impact: Success/failure not properly tracked
1036 | - Fix: Proper unpacking of `(success, message)` tuple from storage operations
1037 |
1038 | ### Changed
1039 | - **API Endpoints** - Refactored to use MemoryService dependency injection
1040 | - `/api/memories` (list, create) uses MemoryService
1041 | - `/api/search` endpoints use MemoryService
1042 | - Consistent response formatting via service layer
1043 | - **Code Maintainability** - Removed 356 lines of duplicated code
1044 | - Single place to modify business logic
1045 | - Unified error handling
1046 | - Consistent hostname tagging logic
1047 | - **Performance** - Database-level filtering prevents O(n) memory loading
1048 | - Scalable pagination with offset/limit at storage layer
1049 | - Efficient tag and type filtering
1050 |
1051 | ### Technical Details
1052 | - **Files Modified**: 6 files, 1469 additions, 356 deletions
1053 | - **Test Coverage**: 55 new tests (34 unit + 21 integration)
1054 | - **Bug Discovery**: Comprehensive testing revealed 7 critical bugs that would have made the release non-functional
1055 | - **Quality Process**: Test-driven debugging approach prevented broken release
1056 |
1057 | **Note**: This release demonstrates the critical importance of comprehensive testing before merging architectural changes. All 7 bugs were caught through systematic unit and integration testing.
1058 |
1059 | ## [8.11.0] - 2025-10-28
1060 |
1061 | ### Added
1062 | - **JSON Document Loader** - Complete implementation of JSON file ingestion (Issue #181, PR #187)
1063 | - **Nested Structure Flattening**: Converts nested JSON to searchable text with dot notation or bracket notation
1064 | - **Configurable Strategies**: Choose flattening style, max depth, type inclusion
1065 | - **Array Handling**: Multiple modes (expand, summarize, flatten) for different use cases
1066 | - **Comprehensive Tests**: 15 unit tests covering all functionality
1067 | - **Use Cases**: Knowledge base exports, API documentation, config files, structured metadata
1068 |
1069 | - **CSV Document Loader** - Complete implementation of CSV file ingestion (Issue #181, PR #187)
1070 | - **Auto-Detection**: Automatically detects delimiters (comma, semicolon, tab, pipe) and headers
1071 | - **Row-Based Formatting**: Converts tabular data to searchable text with column context
1072 | - **Encoding Support**: Auto-detects UTF-8, UTF-16, UTF-32, Latin-1, CP1252
1073 | - **Large File Handling**: Efficient row-based chunking for scalability
1074 | - **Comprehensive Tests**: 14 unit tests covering all functionality
1075 | - **Use Cases**: Data dictionaries, reference tables, tabular documentation, log analysis
1076 |
1077 | ### Fixed
1078 | - **False Advertising** - Resolved issue where JSON and CSV were listed in `SUPPORTED_FORMATS` but had no loader implementations
1079 | - Previous behavior: Upload would fail with "No loader available" error
1080 | - New behavior: Full functional support with proper chunking and metadata
1081 |
1082 | ### Changed
1083 | - **Ingestion Module** - Updated to register new JSON and CSV loaders
1084 | - **Test Coverage** - Added 29 new unit tests (15 JSON + 14 CSV)
1085 |
1086 | ## [8.10.0] - 2025-10-28
1087 |
1088 | ### Added
1089 | - **Complete Analytics Dashboard Implementation** (Issue #182, PR #183)
1090 | - Memory Types Breakdown (pie chart)
1091 | - Activity Heatmap (GitHub-style calendar with 90d/6mo/1yr periods)
1092 | - Top Tags Report (usage trends, co-occurrence patterns)
1093 | - Recent Activity Report (hourly/daily/weekly breakdowns)
1094 | - Storage Report (largest memories, efficiency metrics)
1095 | - Streak Tracking (current and longest consecutive days)
1096 |
1097 | ### Fixed
1098 | - **Activity Streak Calculation** - Fixed current streak to include today check
1099 | - **Total Days Calculation** - Corrected date span vs active days count
1100 | - **Longest Streak Initialization** - Fixed from 0 to 1
1101 |
1102 | ### Changed
1103 | - **Analytics API** - Added 5 new endpoints with Pydantic models
1104 | - **Dashboard Documentation** - Updated wiki with complete analytics features
1105 |
1106 | ## [8.9.0] - 2025-10-27
1107 |
1108 | ### Fixed
1109 | - **Database Lock Prevention** - Resolved "database is locked" errors during concurrent HTTP + MCP server access (Issue discovered during performance troubleshooting)
1110 | - **Root Cause**: Default `busy_timeout=5000ms` too short for concurrent writes from multiple MCP clients
1111 | - **Solution**: Applied recommended SQLite pragmas (`busy_timeout=15000,cache_size=20000`)
1112 | - **WAL Mode**: Already enabled by default, now properly configured for multi-client access
1113 | - **Impact**: Zero database locks during testing with 5 concurrent write operations
1114 | - **Documentation**: Updated multi-client architecture docs with pragma recommendations
1115 |
1116 | ### Added
1117 | - **Hybrid Backend Installer Support** - Full hybrid backend support in simplified installer (`scripts/installation/install.py`)
1118 | - **Interactive Selection**: Hybrid now option 4 (recommended default) in installer menu
1119 | - **Automatic Configuration**: SQLite pragmas set automatically for sqlite_vec and hybrid backends
1120 | - **Cloudflare Setup**: Interactive credential configuration with connection testing
1121 | - **Graceful Fallback**: Falls back to sqlite_vec if Cloudflare setup cancelled or fails
1122 | - **Claude Desktop Integration**: Hybrid backend configuration includes:
1123 | - SQLite pragmas for concurrent access (`MCP_MEMORY_SQLITE_PRAGMAS`)
1124 | - Cloudflare credentials for background sync
1125 | - Proper environment variable propagation
1126 | - **Benefits**:
1127 | - 5ms local reads (SQLite-vec)
1128 | - Zero user-facing latency (background Cloudflare sync)
1129 | - Multi-device synchronization
1130 | - Concurrent access support
1131 |
1132 | ### Changed
1133 | - **Installer Defaults** - Hybrid backend now recommended for production use
1134 | - Updated argparse choices to include `hybrid` option
1135 | - Changed default selection from sqlite_vec to hybrid (option 4)
1136 | - Enhanced compatibility detection with "recommended" status for hybrid
1137 | - Improved final installation messages with backend-specific guidance
1138 | - **Environment Management** - Cloudflare credentials now set in current environment immediately
1139 | - `save_credentials_to_env()` sets both .env file AND os.environ
1140 | - Ensures credentials available for Claude Desktop config generation
1141 | - Proper variable propagation for hybrid and cloudflare backends
1142 | - **Path Configuration** - Updated `configure_paths()` to handle all backends
1143 | - SQLite database paths for: `sqlite_vec`, `hybrid`, `cloudflare`
1144 | - Cloudflare credentials included when backend requires them
1145 | - Backward compatible with existing installations
1146 |
1147 | ### Technical Details
1148 | - **Files Modified**:
1149 | - `scripts/installation/install.py`: Lines 655-659 (compatibility), 758 (menu), 784-802 (selection), 970-1017 (hybrid install), 1123-1133 (env config), 1304 (path config), 1381-1401 (Claude Desktop config), 1808-1821 (final messages)
1150 | - `src/mcp_memory_service/__init__.py`: Line 50 (version bump)
1151 | - `pyproject.toml`: Line 7 (version bump)
1152 | - **Concurrent Access Testing**: 5/5 simultaneous writes succeeded without locks
1153 | - **HTTP Server Logs**: Confirmed background Cloudflare sync working (line 369: "Successfully stored memory")
1154 |
1155 | ## [8.8.2] - 2025-10-26
1156 |
1157 | ### Fixed
1158 | - **Document Upload Tag Validation** - Prevents bloated tags from space-separated file paths (Issue #174, PR #179)
1159 | - **Enhanced Tag Parsing**: Split tags by comma OR space instead of comma only
1160 | - **Robust file:// URI Handling**: Uses `urllib.parse` for proper URL decoding and path handling
1161 | - Handles URL-encoded characters (e.g., `%20` for spaces)
1162 | - Handles different path formats (e.g., `file:///C:/...`)
1163 | - Properly handles Windows paths with leading slash from urlparse
1164 | - **File Path Sanitization**: Remove `file://` prefixes, extract filenames only, clean path separators
1165 | - **Explicit Tag Length Validation**: Tags exceeding 100 chars now raise explicit HTTPException instead of being silently dropped
1166 |
1167 | ### Added
1168 | - **Processing Mode Toggle** - UI enhancement for multiple file uploads (PR #179)
1169 | - **Batch Processing**: All files processed together (faster, default)
1170 | - **Individual Processing**: Each file processed separately with better error isolation
1171 | - Toggle only appears when multiple files are selected
1172 | - Comprehensive help section explaining both modes with pros/cons
1173 |
1174 | ### Changed
1175 | - **Code Quality Improvements** - Eliminated code duplication in document upload endpoints (PR #179)
1176 | - Extracted `parse_and_validate_tags()` helper function to eliminate duplicate tag parsing logic
1177 | - Removed 44 lines of duplicate code from `upload_document` and `batch_upload_documents`
1178 | - Extracted magic number (500ms upload delay) to static constant `INDIVIDUAL_UPLOAD_DELAY`
1179 | - Simplified toggle display logic with ternary operator
1180 | - Created Issue #180 for remaining medium-priority code quality suggestions
1181 |
1182 | ## [8.8.1] - 2025-10-26
1183 |
1184 | ### Fixed
1185 | - **Error Handling Improvements** - Enhanced robustness in MemoryService and maintenance scripts (Issue #177)
1186 | - **MemoryService.store_memory()**: Added specific exception handling for better error classification
1187 | - `ValueError` → validation errors with "Validation error" messages
1188 | - `httpx.NetworkError/TimeoutException/HTTPStatusError` → storage errors with "Storage error" messages
1189 | - Generic `Exception` → unexpected errors with full logging and "unexpected error" messages
1190 | - **Maintenance Scripts**: Added proper error handling to prevent crashes
1191 | - `find_cloudflare_duplicates.py`: Wrapped `get_all_memories_bulk()` in try/except, graceful handling of empty results
1192 | - `delete_orphaned_vectors_fixed.py`: Already used public API (no changes needed)
1193 |
1194 | ### Added
1195 | - **Encapsulation Methods** - New public APIs for Cloudflare storage operations (Issue #177)
1196 | - `CloudflareStorage.delete_vectors_by_ids()` - Batch vector deletion with proper error handling
1197 | - `CloudflareStorage.get_all_memories_bulk()` - Efficient bulk loading without N+1 tag queries
1198 | - `CloudflareStorage._row_to_memory()` - Helper for converting D1 rows to Memory objects
1199 | - **Performance**: Bulk operations avoid expensive individual tag lookups
1200 | - **Maintainability**: Public APIs instead of direct access to private `_retry_request` method
1201 |
1202 | ### Changed
1203 | - **Dependency Management** - Added conditional typing-extensions for Python 3.10 (Issue #177)
1204 | - Added `"typing-extensions>=4.0.0; python_version < '3.11'"` to pyproject.toml
1205 | - Ensures `NotRequired` import works correctly on Python 3.10
1206 | - No impact on Python 3.11+ installations
1207 |
1208 | ### Review
1209 | - **Gemini Code Assist**: "This pull request significantly improves the codebase by enhancing error handling and improving encapsulation... well-executed and contribute to better maintainability"
1210 | - **Feedback Addressed**: All review suggestions implemented, including enhanced exception handling
1211 |
1212 | ## [8.8.0] - 2025-10-26
1213 |
1214 | ### Changed
1215 | - **DRY Refactoring** - Eliminated code duplication between MCP and HTTP servers (PR #176, Issue #172)
1216 | - **Problem**: MCP (`mcp_server.py`) and HTTP (`server.py`) servers had 364 lines of duplicated business logic
1217 | - Bug fixes applied to one server were missed in the other (e.g., PR #162 tags validation)
1218 | - Maintenance burden of keeping two implementations synchronized
1219 | - Risk of behavioral inconsistencies between protocols
1220 | - **Solution**:
1221 | - Created `MemoryService` class (442 lines) as single source of truth for business logic
1222 | - Refactored `mcp_server.py` to thin adapter (-338 lines, now ~50 lines per method)
1223 | - Refactored `server.py` to use MemoryService (169 lines modified)
1224 | - Both servers now delegate to shared business logic
1225 | - **Benefits**:
1226 | - **Single source of truth**: All memory operations (store, retrieve, search, delete) in one place
1227 | - **Consistent behavior**: Both protocols guaranteed identical business logic
1228 | - **Easier maintenance**: Bug fixes automatically apply to both servers
1229 | - **Better testability**: Business logic isolated and independently testable
1230 | - **Prevents future bugs**: Impossible to fix one server and forget the other
1231 | - **Type Safety**: Added TypedDict classes (`MemoryResult`, `OperationResult`, `HealthStats`) for better type annotations
1232 | - **Backward Compatibility**: No API changes, both servers remain fully compatible
1233 | - **Testing**: All tests passing (15/15 Cloudflare storage tests)
1234 | - **Review**: Gemini Code Assist: "significant and valuable refactoring... greatly improves maintainability and consistency"
1235 | - **Follow-up**: Minor improvements tracked in Issue #177 (error handling, encapsulation)
1236 |
1237 | ### Fixed
1238 | - **Python 3.10 Compatibility** - Added `NotRequired` import fallback (src/mcp_memory_service/mcp_server.py:23-26)
1239 | - Uses `typing.NotRequired` on Python 3.11+
1240 | - Falls back to `typing_extensions.NotRequired` on Python 3.10
1241 | - Ensures compatibility across Python versions
1242 |
1243 | ### Added
1244 | - **Maintenance Scripts** - Cloudflare cleanup utilities (from v8.7.1 work)
1245 | - `scripts/maintenance/find_cloudflare_duplicates.py` - Detect duplicates in Cloudflare D1
1246 | - `scripts/maintenance/delete_orphaned_vectors_fixed.py` - Clean orphaned Vectorize vectors
1247 | - `scripts/maintenance/fast_cleanup_duplicates_with_tracking.sh` - Platform-aware SQLite cleanup
1248 | - `scripts/maintenance/find_all_duplicates.py` - Platform detection (macOS/Linux paths)
1249 |
1250 | ## [8.7.1] - 2025-10-26
1251 |
1252 | ### Fixed
1253 | - **Cloudflare Vectorize Deletion** - Fixed vector deletion endpoint bug (src/mcp_memory_service/storage/cloudflare.py:671)
1254 | - **Problem**: Used incorrect endpoint `/delete-by-ids` (hyphens) causing 404 Not Found errors, preventing vector deletion
1255 | - **Solution**:
1256 | - Changed to correct Cloudflare API endpoint `/delete_by_ids` (underscores)
1257 | - Fixed payload format from `[vector_id]` to `{"ids": [vector_id]}`
1258 | - Created working cleanup script: `scripts/maintenance/delete_orphaned_vectors_fixed.py`
1259 | - Removed obsolete broken script: `scripts/maintenance/delete_orphaned_vectors.py`
1260 | - **Impact**: Successfully deleted 646 orphaned vectors from Vectorize in 7 batches
1261 | - **Testing**: Verified with production data (646 vectors, 100/batch, all mutations successful)
1262 | - **Discovery**: Found via web research of official Cloudflare Vectorize API documentation
1263 |
1264 | ## [8.7.0] - 2025-10-26
1265 |
1266 | ### Fixed
1267 | - **Cosine Similarity Migration** - Fixed 0% similarity scores in search results (src/mcp_memory_service/storage/sqlite_vec.py:187)
1268 | - **Problem**: L2 distance metric gave 0% similarity for all searches due to score calculation `max(0, 1-distance)` returning 0 for distances >1.0
1269 | - **Solution**:
1270 | - Migrated embeddings table from L2 to cosine distance metric
1271 | - Updated score calculation to `1.0 - (distance/2.0)` for cosine range [0,2]
1272 | - Added automatic migration logic with database locking retry (exponential backoff)
1273 | - Implemented `_initialized` flag to prevent multiple initialization
1274 | - Created metadata table for storage configuration persistence
1275 | - **Performance**: Search scores improved from 0% to 70-79%, exact match accuracy 79.2% (was 61%)
1276 | - **Impact**: 2605 embeddings regenerated successfully
1277 |
1278 | - **Dashboard Search Improvements** - Enhanced search threshold handling (src/mcp_memory_service/web/static/app.js:283)
1279 | - Fixed search threshold always being sent even when not explicitly set
1280 | - Improved document filtering to properly handle memory object structure
1281 | - Only send `similarity_threshold` parameter when user explicitly sets it
1282 | - Better handling of `memory.memory_type` and `memory.tags` for document results
1283 |
1284 | ### Added
1285 | - **Maintenance Scripts** - Comprehensive database maintenance tooling (scripts/maintenance/)
1286 | - **regenerate_embeddings.py** - Regenerate all embeddings after migrations (~5min for 2600 memories)
1287 | - **fast_cleanup_duplicates.sh** - 1800x faster duplicate removal using direct SQL (<5s for 100+ duplicates vs 2.5 hours via API)
1288 | - **find_all_duplicates.py** - Fast duplicate detection with timestamp normalization (<2s for 2000 memories)
1289 | - **README.md** - Complete documentation with performance benchmarks, best practices, and troubleshooting
1290 |
1291 | ### Technical Details
1292 | - **Migration Approach**: Drop-and-recreate embeddings table to change distance metric (vec0 limitation)
1293 | - **Retry Logic**: Exponential backoff for database locking (1s → 2s → 4s delays)
1294 | - **Performance Benchmark**: Direct SQL vs API operations show 1800x speedup for bulk deletions
1295 | - **Duplicate Detection**: Content normalization removes timestamps for semantic comparison using MD5 hashing
1296 |
1297 | ## [8.6.0] - 2025-10-25
1298 |
1299 | ### Added
1300 | - **Document Ingestion System** - Complete document upload and management through web UI (#147, #164)
1301 | - **Single and Batch Upload**: Drag-and-drop or file browser support for PDF, TXT, MD, JSON documents
1302 | - **Background Processing**: Async document processing with progress tracking and status updates
1303 | - **Document Management UI**: New Documents tab in web dashboard with full CRUD operations
1304 | - **Upload History**: Track all document ingestion with status, chunk counts, and file sizes
1305 | - **Document Viewer**: Modal displaying all memory chunks from uploaded documents (up to 1000 chunks)
1306 | - **Document Removal**: Delete documents and their associated memory chunks with confirmation
1307 | - **Search Ingested Content**: Semantic search within uploaded documents to verify indexing
1308 | - **Claude Commands**: `/memory-ingest` and `/memory-ingest-dir` for CLI document upload
1309 | - **API Endpoints**:
1310 | - `POST /api/documents/upload` - Single document upload
1311 | - `POST /api/documents/batch-upload` - Multiple document upload
1312 | - `GET /api/documents/history` - Upload history
1313 | - `GET /api/documents/status/{upload_id}` - Upload status
1314 | - `GET /api/documents/search-content/{upload_id}` - View document chunks
1315 | - `DELETE /api/documents/remove/{upload_id}` - Remove document
1316 | - `DELETE /api/documents/remove-by-tags` - Bulk remove by tags
1317 | - **Files Created**:
1318 | - `src/mcp_memory_service/web/api/documents.py` (779 lines) - Document API
1319 | - `claude_commands/memory-ingest.md` - Single document ingestion command
1320 | - `claude_commands/memory-ingest-dir.md` - Directory ingestion command
1321 | - `docs/development/dashboard-workflow.md` - Development workflow documentation
1322 |
1323 | - **Chunking Configuration Help** - Interactive UI guidance for document chunking parameters
1324 | - Inline help panels with collapsible sections for chunk size and overlap settings
1325 | - Visual diagram showing how overlap works between consecutive chunks
1326 | - Pre-configured recommendations (Default: 1000/200, Smaller: 500/100, Larger: 2000/400)
1327 | - Rule-of-thumb guidelines (15-25% overlap of chunk size)
1328 | - Full dark mode support for all help elements
1329 |
1330 | - **Tag Length Validation** - Server-side validation to prevent data corruption (#174)
1331 | - Maximum tag length enforced at 100 characters
1332 | - Validation on both single and batch upload endpoints
1333 | - Clear error messages showing first invalid tag
1334 | - Frontend filtering to hide malformed tags in display
1335 | - Prevents bloated tags from accidental file path pasting
1336 |
1337 | ### Fixed
1338 | - **Security Vulnerabilities** - Multiple critical security fixes addressed
1339 | - Path traversal vulnerability in file uploads (use `tempfile.NamedTemporaryFile()`)
1340 | - XSS prevention in tag display and event handlers (escape all user-provided filenames)
1341 | - CSP compliance by removing inline `onclick` handlers, using `addEventListener` instead
1342 | - Proper input validation and sanitization throughout upload flow
1343 |
1344 | - **Document Viewer Critical Bugs** - Comprehensive fixes for document management
1345 | - **Chunk Limit**: Increased from 10 to 1000 chunks (was only showing first 10 of 430 chunks)
1346 | - **Upload Session Persistence**: Documents now viewable after server restart (session optional, uses `upload_id` tag search)
1347 | - **Filename Retrieval**: Get filename from memory metadata when session unavailable
1348 | - **Batch File Size**: Calculate and display total file size for batch uploads (was showing 0.0 KB)
1349 | - **Multiple Confirmation Dialogs**: Fixed duplicate event listeners causing N dialogs for N uploads
1350 | - **Event Listener Deduplication**: Added `documentsListenersSetup` flag to prevent duplicate setup
1351 |
1352 | - **Storage Backend Enhancements** - `delete_by_tags` implementation for document deletion
1353 | - Added `delete_by_tags()` method to `MemoryStorage` base class with error aggregation
1354 | - Optimized `SqliteVecMemoryStorage.delete_by_tags()` with single SQL query using OR conditions
1355 | - Added `HybridMemoryStorage.delete_by_tags()` with sync queue support for cloud backends
1356 | - Fixed return value handling (tuple unpacking instead of dict access)
1357 |
1358 | - **UI/UX Improvements** - Enhanced user experience across document management
1359 | - Added scrolling to Recent Memories section (max-height: 600px) to prevent infinite expansion
1360 | - Document chunk modal now scrollable (max-height: 400px) for long content
1361 | - Modal visibility fixed with proper `active` class pattern and CSS transitions
1362 | - Dark mode support for all document UI components (chunk items, modals, previews)
1363 | - Event handlers for View/Remove buttons in document preview cards
1364 | - Responsive design with mobile breakpoints (768px, 1024px)
1365 |
1366 | - **Resource Management** - Proper cleanup and error handling
1367 | - Temp file cleanup moved to `finally` blocks to prevent orphaned files
1368 | - File extension validation fixed (strip leading dot for consistent checking)
1369 | - Session cleanup timing bug fixed (use `total_seconds()` instead of `.seconds`)
1370 | - Loader registration order corrected (PDFLoader takes precedence as fallback)
1371 |
1372 | - **MCP Server Tag Format Support** - Accept both string and array formats
1373 | - MCP tools now accept `"tag1,tag2"` (string) and `["tag1", "tag2"]` (array)
1374 | - Consistent tag handling between API and MCP endpoints
1375 | - Fixes validation errors from schema mismatches
1376 |
1377 | ### Changed
1378 | - **API Response Improvements** - Better error messages and status handling
1379 | - Float timestamp handling in document search (convert via `datetime.fromtimestamp()`)
1380 | - Partial success handling for bulk operations with clear error reporting
1381 | - Progress tracking for background tasks with status updates
1382 |
1383 | ### Technical Details
1384 | - **Testing**: 19 Gemini Code Assist reviews addressed with comprehensive fixes
1385 | - **Performance**: Document viewer handles 430+ chunks efficiently
1386 | - **Compatibility**: Cross-platform temp file handling (Windows, macOS, Linux)
1387 | - **Code Quality**: Removed dead code, duplicate docstrings, and unused Pydantic models
1388 |
1389 | ### Migration Notes
1390 | - No breaking changes - fully backward compatible
1391 | - Existing installations will automatically gain document ingestion capabilities
1392 | - Tag validation only affects new uploads (existing tags unchanged)
1393 |
1394 | ## [8.5.14] - 2025-10-23
1395 |
1396 | ### Added
1397 | - **Memory Hooks: Expanded Git Keyword Extraction** - Dramatically improved memory retrieval by capturing more relevant technical terms from git commits
1398 | - **Problem**: Limited keyword extraction (only 12 terms) missed important development context
1399 | - Git analyzer captured only generic terms: `fix, memory, chore, feat, refactor`
1400 | - Recent work on timestamp parsing, dashboard, analytics not reflected in queries
1401 | - Version numbers (v8.5.12, v8.5.13) not extracted
1402 | - Memory hooks couldn't match against specific technical work
1403 | - **Solution**: Expanded keyword extraction in `git-analyzer.js`
1404 | - **Technical Terms**: Increased from 12 to 38 terms including:
1405 | - Time/Date: `timestamp, parsing, sort, sorting, date, age`
1406 | - Dashboard: `dashboard, analytics, footer, layout, grid, css, stats, display`
1407 | - Development: `async, sync, bugfix, release, version`
1408 | - Features: `embedding, consolidation, memory, retrieval, scoring`
1409 | - Infrastructure: `api, endpoint, server, http, mcp, client, protocol`
1410 | - **Version Extraction**: Added regex to capture version numbers (v8.5.12, v8.5.13, etc.)
1411 | - **Changelog Terms**: Expanded from 12 to 23 terms with same additions
1412 | - **Keyword Limits**: Increased capacity
1413 | - keywords: 15 → 20 terms
1414 | - themes: 10 → 12 entries
1415 | - filePatterns: 10 → 12 entries
1416 | - **Impact**:
1417 | - **Before**: 5 generic terms → limited semantic matching
1418 | - **After**: 20 specific development terms → precise context retrieval
1419 | - Example: `feat, git, memory, retrieval, fix, timestamp, age, v8.5.8, chore, version, v8.5.13, sort, date, dashboard, analytics, stats, display, footer, layout, v8.5.12`
1420 | - **Result**: Memory hooks now capture and retrieve memories about specific technical work (releases, features, bugfixes)
1421 | - **Files Modified**:
1422 | - `claude-hooks/utilities/git-analyzer.js` - Expanded `extractDevelopmentKeywords()` function (commit 4a02c1a)
1423 | - **Testing**: Verified improved extraction with test run showing 20 relevant keywords vs previous 5 generic terms
1424 |
1425 | ## [8.5.13] - 2025-10-23
1426 |
1427 | ### Fixed
1428 | - **Memory Hooks: Unix Timestamp Parsing in Date Sorting** - Fixed critical bug where memories were not sorting chronologically in Claude Code session start
1429 | - **Root Cause**: JavaScript `Date()` constructor expects milliseconds but API returns Unix timestamps in seconds
1430 | - **Impact**: Memory hooks showed old memories (Oct 11-21) before recent ones (Oct 23) despite `sortByCreationDate: true` configuration
1431 | - **Technical Details**:
1432 | - API returns `created_at` as Unix timestamp in seconds (e.g., 1729700000)
1433 | - JavaScript `new Date(1729700000)` interprets this as milliseconds → January 21, 1970
1434 | - All dates appeared as 1970-01-01, breaking chronological sort
1435 | - Relevance scores then determined order, causing old high-scoring memories to rank first
1436 | - **Fix**:
1437 | - Created `getTimestamp()` helper function in `session-start.js` (lines 907-928)
1438 | - Converts `created_at` (seconds) to milliseconds by multiplying by 1000
1439 | - Falls back to `created_at_iso` string parsing if available
1440 | - Proper date comparison ensures newest memories sort first
1441 | - **Result**: Memory hooks now correctly show most recent project memories at session start
1442 | - **Files Modified**:
1443 | - `claude-hooks/core/session-start.js` - Added Unix timestamp conversion helper (commit 71606e5)
1444 |
1445 | ## [8.5.12] - 2025-10-23
1446 |
1447 | ### Fixed
1448 | - **Dashboard: Analytics Stats Display** - Fixed analytics tab showing 0/N/A for key metrics
1449 | - **Root Cause**: Async/sync mismatch in `get_stats()` method implementations
1450 | - **Impact**: Analytics dashboard displayed only "this week" count; total memories, unique tags, and database size showed 0 or N/A
1451 | - **Fix**:
1452 | - Made `SqliteVecMemoryStorage.get_stats()` async (line 1242)
1453 | - Updated `HybridMemoryStorage.get_stats()` to properly await primary storage call (line 878)
1454 | - Added `database_size_bytes` and `database_size_mb` to hybrid stats response
1455 | - Fixed all callers in `health.py` and `mcp.py` to await `get_stats()`
1456 | - **Result**: All metrics now display correctly (1778 memories, 2549 tags, 7.74MB)
1457 | - **Files Modified**:
1458 | - `src/mcp_memory_service/storage/sqlite_vec.py` - Made get_stats() async
1459 | - `src/mcp_memory_service/storage/hybrid.py` - Added await and database size fields
1460 | - `src/mcp_memory_service/web/api/health.py` - Simplified async handling
1461 | - `src/mcp_memory_service/web/api/mcp.py` - Added await calls
1462 |
1463 | - **Dashboard: Footer Layout** - Fixed footer appearing between header and content instead of at bottom
1464 | - **Root Cause**: Footer not included in CSS grid layout template
1465 | - **Impact**: Broken visual layout with footer misplaced in page flow
1466 | - **Fix**:
1467 | - Updated `.app-container` grid to include 5th row with "footer" area
1468 | - Assigned `grid-area: footer` to `.app-footer` class
1469 | - **Result**: Footer now correctly positioned at bottom of page
1470 | - **Files Modified**:
1471 | - `src/mcp_memory_service/web/static/style.css` - Updated grid layout (lines 101-110, 1899)
1472 |
1473 | - **HTTP Server: Runtime Warnings** - Eliminated "coroutine was never awaited" warnings in logs
1474 | - **Root Cause**: Legacy sync/async detection code after all backends became async
1475 | - **Impact**: Runtime warnings cluttering server logs
1476 | - **Fix**: Removed hybrid backend detection logic, all `get_stats()` calls now consistently await
1477 | - **Result**: Clean server logs with no warnings
1478 |
1479 | ## [8.5.11] - 2025-10-23
1480 |
1481 | ### Fixed
1482 | - **Consolidation System: Embedding Retrieval in get_all_memories()** - Fixed SQLite-vec backend to actually retrieve embeddings (PR #171, fixes #169)
1483 | - **Root Cause**: `get_all_memories()` methods only queried `memories` table without joining `memory_embeddings` virtual table
1484 | - **Impact**: Consolidation system received 0 embeddings despite 1773 memories in database, preventing association discovery and semantic clustering
1485 | - **Discovery**: PR #170 claimed to fix this but only modified debug tools; actual fix required changes to `sqlite_vec.py`
1486 | - **Fix**:
1487 | - Added `deserialize_embedding()` helper function using numpy.frombuffer() (sqlite-vec only provides serialize, not deserialize)
1488 | - Updated both `get_all_memories()` methods (lines 1468 and 1681) with LEFT JOIN to `memory_embeddings` table
1489 | - Modified `_row_to_memory()` helper to handle 10-column rows with embeddings
1490 | - Applied Gemini Code Assist improvement to simplify row unpacking logic
1491 | - **Test Results** (1773 memories):
1492 | - Embeddings retrieved: 1773/1773 (100%)
1493 | - Associations discovered: 90-91 (0.3-0.7 similarity range)
1494 | - Semantic clusters created: 3 (DBSCAN grouping)
1495 | - Performance: 1249-1414 memories/second
1496 | - Duration: 1.25-1.42 seconds
1497 | - **Consolidation Status**: ✅ **FULLY FUNCTIONAL** (all three blockers fixed: PR #166, #168, #171)
1498 | - **Files Modified**:
1499 | - `src/mcp_memory_service/storage/sqlite_vec.py` - Added embedding retrieval to all memory fetch operations
1500 |
1501 | ## [8.5.10] - 2025-10-23
1502 |
1503 | ### Fixed
1504 | - **Debug Tools: Embedding Retrieval Functionality** - Fixed debug MCP tools for SQLite-vec backend (PR #170, addresses #169)
1505 | - **Root Cause**: `debug_retrieve_memory` function was written for ChromaDB but codebase now uses SQLite-vec storage
1506 | - **Impact**: Debug tools (`debug_retrieve`) were broken, preventing debugging of embedding retrieval operations
1507 | - **Fix**: Updated debug utilities to work with current SQLite-vec storage backend
1508 | - **Changes**:
1509 | - Fixed `debug_retrieve_memory` in `src/mcp_memory_service/utils/debug.py` to use storage's `retrieve()` method
1510 | - Enhanced debug output with similarity scores, backend information, query details, and raw distance values
1511 | - Added proper filtering by similarity threshold
1512 | - **Files Modified**:
1513 | - `src/mcp_memory_service/utils/debug.py` - Updated for SQLite-vec compatibility
1514 | - `src/mcp_memory_service/server.py` - Enhanced debug output formatting
1515 |
1516 | ### Added
1517 | - **Debug Tool: get_raw_embedding MCP Tool** - New debugging capability for embedding inspection (PR #170)
1518 | - **Purpose**: Direct debugging of embedding generation process
1519 | - **Features**:
1520 | - Shows raw embedding vectors with configurable display (first 10 and last 10 values for readability)
1521 | - Displays embedding dimensions
1522 | - Shows generation status and error messages
1523 | - **Use Case**: Troubleshooting embedding-related issues in consolidation and semantic search
1524 | - **Files Modified**:
1525 | - `src/mcp_memory_service/server.py` - Added `get_raw_embedding` tool and handler
1526 |
1527 | ## [8.5.9] - 2025-10-22
1528 |
1529 | ### Fixed
1530 | - **Consolidation System: Missing update_memory() Method** - Added `update_memory()` method to all storage backends (PR #166, fixes #165)
1531 | - **Root Cause**: Storage backends only implemented `update_memory_metadata()`, but consolidation system's `StorageProtocol` required `update_memory()` for saving consolidated results
1532 | - **Impact**: Prevented consolidation system from saving associations, clusters, compressions, and archived memories
1533 | - **Fix**: Added `update_memory()` method to base `MemoryStorage` class, delegating to `update_memory_metadata()` for proper implementation
1534 | - **Affected Backends**: CloudflareStorage, SqliteVecMemoryStorage, HybridMemoryStorage
1535 | - **Test Results**:
1536 | - Verified on SQLite-vec backend with 1773 memories
1537 | - Performance: 5011 memories/second (local SQLite-vec) vs 2.5 mem/s (Cloudflare)
1538 | - Method successfully executes without AttributeError
1539 | - **Files Modified**:
1540 | - `src/mcp_memory_service/storage/base.py` - Added `update_memory()` to base class
1541 | - `src/mcp_memory_service/storage/http_client.py` - Updated HTTP client call
1542 | - `src/mcp_memory_service/storage/hybrid.py` - Fixed method reference
1543 |
1544 | - **Consolidation System: Datetime Timezone Mismatch** - Fixed timezone handling in decay calculator (PR #168, fixes #167)
1545 | - **Root Cause**: Mixed offset-naive and offset-aware datetime objects causing `TypeError` when calculating time differences
1546 | - **Location**: `src/mcp_memory_service/consolidation/decay.py:191` in `_calculate_access_boost()`
1547 | - **Impact**: Blocked decay calculator from completing, preventing associations, clustering, compression, and archival
1548 | - **Fix**: Added timezone normalization to ensure both `current_time` and `last_accessed` are timezone-aware (UTC) before subtraction
1549 | - **Implementation**:
1550 | - Check if datetime is timezone-naive and convert to UTC if needed
1551 | - Ensures consistent timezone handling across all datetime operations
1552 | - **Files Modified**:
1553 | - `src/mcp_memory_service/consolidation/decay.py` - Added timezone normalization logic
1554 |
1555 | ### Added
1556 | - **Consolidation Documentation** - Comprehensive setup and testing guides
1557 | - `CONSOLIDATION_SETUP.md` - Complete configuration guide for dream-inspired memory consolidation
1558 | - `CONSOLIDATION_TEST_RESULTS.md` - Expected results and troubleshooting guide
1559 | - Documentation covers all 7 consolidation engines and 7 MCP tools
1560 |
1561 | ## [8.5.8] - 2025-10-22
1562 |
1563 | ### Fixed
1564 | - **Critical: Memory Age Calculation in Hooks** - Fixed Unix timestamp handling that caused memories to appear 20,363 days old (55 years) when they were actually recent
1565 | - **Root Cause**: JavaScript's `Date()` constructor expects milliseconds, but SQLite database stores Unix timestamps in seconds. Three functions incorrectly treated seconds as milliseconds: `calculateTimeDecay()`, `calculateRecencyBonus()`, and `analyzeMemoryAgeDistribution()`
1566 | - **Symptoms**:
1567 | - Memory Age Analyzer showed `avgAge: 20363` days instead of actual age
1568 | - Stale memory detection incorrectly triggered (`isStale: true`)
1569 | - Recent memory percentage showed 0% when should be 100%
1570 | - Time decay scores incorrect (1% instead of 100% for today's memories)
1571 | - Recency bonus not applied (0% instead of +15%)
1572 | - **Fix**: Added type checking to convert Unix timestamps properly - multiply by 1000 when timestamp is a number (seconds), pass through when it's an ISO string
1573 | - **Impact**: Memory age calculations now accurate, stale detection works correctly, recency bonuses applied properly
1574 | - **Files Modified**:
1575 | - `claude-hooks/utilities/memory-scorer.js` (lines 11-17, 237-243, 524-534)
1576 | - **Test Results**: Memories now show correct ages (0.4 days vs 20,363 days before fix)
1577 | - **Platform**: All platforms (macOS, Linux, Windows)
1578 |
1579 | ### Changed
1580 | - **Installer Enhancement**: Added automatic statusLine configuration for v8.5.7 features
1581 | - Installer now copies `statusline.sh` to `~/.claude/hooks/`
1582 | - Checks for `jq` dependency (required for statusLine parsing)
1583 | - Automatically adds `statusLine` configuration to `settings.json`
1584 | - Enhanced documentation for statusLine setup and requirements
1585 |
1586 | ### Documentation
1587 | - Added `jq` as required dependency for statusLine feature
1588 | - Documented statusLine configuration in README.md installation section
1589 | - Clarified Unix timestamp handling in memory-scorer.js code comments
1590 |
1591 | ## [8.5.7] - 2025-10-21
1592 |
1593 | ### Added
1594 | - **SessionStart Hook Visibility Features** - Three complementary methods to view session memory context
1595 | - **Visible Summary Output**: Clean bordered console display showing project, storage, memory count with recent indicator, and git context
1596 | - **Detailed Log File**: Complete session context written to `~/.claude/last-session-context.txt` including project details, storage backend, memory statistics, git analysis, and top loaded memories
1597 | - **Status Line Display**: Always-visible status bar at bottom of Claude Code terminal showing `🧠 8 (5 recent) | 📊 10 commits`
1598 | - **Files Modified**:
1599 | - `~/.claude/hooks/core/session-start.js` - Added summary output, log file generation, and cache file write logic
1600 | - `~/.claude/settings.json` - Added statusLine configuration
1601 | - **Files Created**:
1602 | - `~/.claude/statusline.sh` - Bash script for status line display (requires `jq`)
1603 | - `~/.claude/last-session-context.txt` - Auto-generated detailed log file
1604 | - `~/.claude/hooks/utilities/session-cache.json` - Status line data cache
1605 | - **Platform**: Linux/macOS (Windows SessionStart hook still broken - issue #160)
1606 |
1607 | ### Changed
1608 | - SessionStart hook output now provides visible feedback instead of being hidden in system-reminder tags
1609 | - Status line updates every 300ms with latest session memory context
1610 | - Log file automatically updates on each SessionStart hook execution
1611 |
1612 | ### Documentation
1613 | - Clarified difference between macOS and Linux hook output behavior (both use system-reminder tags since v2.2.0)
1614 | - Documented that `<session-start-hook>` wrapper tags were intentionally removed in v2.2.0 for cleaner output
1615 | - Added troubleshooting guide for status line visibility features
1616 |
1617 | ## [8.5.6] - 2025-10-16
1618 |
1619 | ### Fixed
1620 | - **Critical: Memory Hooks HTTPS SSL Certificate Validation** - Fixed hooks failing to connect to HTTPS server with self-signed certificates
1621 | - **Root Cause**: Node.js HTTPS requests were rejecting self-signed SSL certificates silently, causing "No active connection available" errors
1622 | - **Symptoms**:
1623 | - Hooks showed "Failed to connect using any available protocol"
1624 | - No memories retrieved despite server being healthy
1625 | - HTTP server running but hooks couldn't establish connection
1626 | - **Fix**: Added `rejectUnauthorized: false` to both health check and API POST request options in memory-client.js
1627 | - **Impact**: Hooks now successfully connect via HTTPS to servers with self-signed certificates
1628 | - **Files Modified**:
1629 | - `claude-hooks/utilities/memory-client.js` (lines 174, 257)
1630 | - `~/.claude/hooks/utilities/memory-client.js` (deployed)
1631 | - **Test Results**: ✅ 7 memories retrieved from 1558 total, all phases working correctly
1632 | - **Platform**: All platforms (macOS, Linux, Windows)
1633 |
1634 | ### Changed
1635 | - Memory hooks now support HTTPS endpoints with self-signed certificates without manual certificate trust configuration
1636 |
1637 | ## [8.5.5] - 2025-10-14
1638 |
1639 | ### Fixed
1640 | - **Critical: Claude Code Hooks Configuration** - Fixed session-start hook hanging/unresponsiveness on Windows
1641 | - **Root Cause**: Missing forced process exit in session-start.js caused Node.js event loop to remain active with unclosed connections
1642 | - **Fix 1**: Added `.finally()` block with 100ms delayed `process.exit(0)` to ensure clean termination
1643 | - **Fix 2**: Corrected port mismatch in `~/.claude/hooks/config.json` (8889 → 8000) to match HTTP server
1644 | - **Impact**: Hooks now complete in <15 seconds without hanging, Claude Code remains responsive
1645 | - **Files Modified**:
1646 | - `~/.claude/hooks/core/session-start.js` (lines 1010-1013)
1647 | - `~/.claude/hooks/config.json` (line 7)
1648 | - **Platform**: Windows (also applies to macOS/Linux)
1649 |
1650 | ### Changed
1651 | - **Documentation**: Added critical warning section to CLAUDE.md about hook configuration synchronization
1652 | - Documents port mismatch symptoms (hanging hooks, unresponsive Claude Code, connection timeouts)
1653 | - Lists all configuration files to check (`config.json`, HTTP server port, dashboard port)
1654 | - Provides verification commands for Windows/Linux/macOS
1655 | - Explains common mistakes (using dashboard port 8888/8443 instead of API port 8000)
1656 |
1657 | ## [8.5.4] - 2025-10-13
1658 |
1659 | ### Fixed
1660 | - **MCP Server**: Added explicit documentation to `store_memory` tool clarifying that `metadata.tags` must be an array, not a comma-separated string
1661 | - Prevents validation error: `Input validation error: '...' is not of type 'array'`
1662 | - Includes clear examples showing correct (array) vs incorrect (string) format
1663 | - Documentation-only change - no code logic modified
1664 |
1665 | ### Changed
1666 | - Improved `store_memory` tool docstring with metadata format validation examples in `src/mcp_memory_service/mcp_server.py`
1667 |
1668 | ## [Unreleased]
1669 |
1670 | ### ✨ **Added**
1671 |
1672 | #### **Linux systemd Service Support**
1673 | Added comprehensive systemd user service support for automatic HTTP server management on Linux systems.
1674 |
1675 | **New Files:**
1676 | - `scripts/service/mcp-memory-http.service` - systemd user service definition
1677 | - `scripts/service/install_http_service.sh` - Interactive installation script
1678 | - `docs/deployment/systemd-service.md` - Detailed systemd setup guide
1679 |
1680 | **Features:**
1681 | - ✅ **Automatic startup** on user login
1682 | - ✅ **Persistent operation** with loginctl linger support
1683 | - ✅ **Automatic restarts** on failure (RestartSec=10)
1684 | - ✅ **Centralized logging** via journald
1685 | - ✅ **Easy management** via systemctl commands
1686 | - ✅ **Environment loading** from .env file
1687 | - ✅ **Security hardening** (NoNewPrivileges, PrivateTmp)
1688 |
1689 | **Usage:**
1690 | ```bash
1691 | bash scripts/service/install_http_service.sh # Install
1692 | systemctl --user start mcp-memory-http.service
1693 | systemctl --user enable mcp-memory-http.service
1694 | loginctl enable-linger $USER
1695 | ```
1696 |
1697 | ### 📚 **Documentation**
1698 |
1699 | #### **Enhanced HTTP Server Management**
1700 | - Updated `docs/http-server-management.md` with systemd section
1701 | - Added troubleshooting for port mismatch issues (8000 vs 8889)
1702 | - Documented hooks endpoint configuration requirements
1703 |
1704 | #### **CLAUDE.md Updates**
1705 | - Added systemd commands to Essential Commands section
1706 | - Added "Troubleshooting Hooks Not Retrieving Memories" section
1707 | - Cross-referenced detailed documentation guides
1708 |
1709 | ### 🐛 **Fixed**
1710 |
1711 | #### **Hooks Configuration Troubleshooting**
1712 | - Documented common port mismatch issue between hooks config and HTTP server
1713 | - Added diagnostic commands for verifying HTTP server status
1714 | - Clarified that HTTP server is **required** for hooks (stdio MCP cannot be used)
1715 |
1716 | **Root Cause:** Many installations had hooks configured for port 8889 while HTTP server runs on port 8000 (default in .env). This caused silent failures where hooks couldn't connect.
1717 |
1718 | **Solution:**
1719 | 1. Update hooks config endpoint to `http://127.0.0.1:8000`
1720 | 2. Verify with: `systemctl --user status mcp-memory-http.service`
1721 | 3. Test with: `curl http://127.0.0.1:8000/api/health`
1722 |
1723 | ### 🔧 **Changed**
1724 |
1725 | - Service files now use `WantedBy=default.target` for user services (not multi-user.target)
1726 | - Removed `User=` and `Group=` directives from user service (causes GROUP error)
1727 | - Enhanced error messages and troubleshooting documentation
1728 |
1729 | ### 🎨 **Improved**
1730 |
1731 | #### **Claude Code Hooks UI Enhancements**
1732 | Significantly improved visual formatting and readability of memory context injection in Claude Code hooks.
1733 |
1734 | **Enhanced Features:**
1735 | - ✅ **Intelligent Text Wrapping** - New `wrapText()` function preserves word boundaries and indentation
1736 | - ✅ **Unicode Box Drawing** - Professional visual formatting with ╭╮╯╰ characters for better structure
1737 | - ✅ **Recency-Based Display** - Recent memories (< 7 days) stay prominent, older ones are dimmed
1738 | - ✅ **Simplified Date Formatting** - Cleaner date display with recency indicators (today, yesterday, day name, date)
1739 | - ✅ **Enhanced Memory Categorization** - Better visual hierarchy for different memory types
1740 |
1741 | **Files Modified:**
1742 | - `claude-hooks/utilities/context-formatter.js` - Major refactoring with wrapText function and enhanced formatMemoryForCLI
1743 | - `claude-hooks/core/session-start.js` - Minor display improvements for project detection
1744 | - `.claude/settings.local.json` - Platform-specific configuration updates (Windows→Linux path migration)
1745 |
1746 | **Performance:**
1747 | - No performance impact - Lightweight formatting enhancements
1748 | - Better readability improves development efficiency
1749 | - Maintains all existing functionality while improving presentation
1750 |
1751 | ---
1752 |
1753 | ## [8.5.3] - 2025-10-12
1754 |
1755 | ### 🐛 **Fixed**
1756 |
1757 | #### **Critical Memory Hooks Bug Fixes (Claude Code Integration)**
1758 | Fixed critical bugs preventing memory retrieval in Claude Code session-start hooks. Memory awareness now works correctly with both semantic and time-based searches.
1759 |
1760 | **Problem**: Memory hooks showed "No relevant memories found" despite 1,419 memories in database. Retrieved memories were unrelated (from wrong projects) and sorted incorrectly (oldest first).
1761 |
1762 | **Root Causes Fixed:**
1763 |
1764 | 1. **Empty Semantic Query Bug** (search.py:264-272)
1765 | - **Issue**: `storage.retrieve("")` with empty string returned no results
1766 | - **Fix**: Now uses `get_recent_memories()` when `semantic_query` is empty
1767 | - **Impact**: Time-based searches without semantic filtering now work correctly
1768 |
1769 | 2. **Missing Time Expression** (search.py:401-403)
1770 | - **Issue**: Hook sends `'last-2-weeks'` but parser didn't recognize it
1771 | - **Fix**: Added support for 'last 2 weeks', 'past 2 weeks', 'last-2-weeks'
1772 | - **Impact**: Phase 2 fallback queries now work properly
1773 |
1774 | 3. **Performance Optimization** (search.py:36)
1775 | - **Change**: Reduced candidate pool from 1000 to 100 for time filtering
1776 | - **Rationale**: Prevents timeout on large databases, improves response time
1777 | - **Impact**: Search completes in <100ms vs timing out
1778 |
1779 | 4. **CRITICAL: Missing `await` Keywords** (hybrid.py:912, 916, 935, 947)
1780 | - **Issue**: 4 async methods returned unawaited coroutines, causing server hangs
1781 | - **Methods Fixed**:
1782 | - Line 912: `get_all_tags()`
1783 | - Line 916: `get_recent_memories(n)` ⭐ **THE CRITICAL ONE**
1784 | - Line 935: `recall_memory(query, n_results)`
1785 | - Line 947: `get_memories_by_time_range(start_time, end_time)`
1786 | - **Impact**: Hybrid backend now works perfectly (11ms response time!)
1787 |
1788 | 5. **JavaScript Refactoring** (memory-client.js:213-293)
1789 | - **Issue**: ~100 lines of duplicated HTTP request code
1790 | - **Fix**: Created `_performApiPost()` helper to eliminate duplication
1791 | - **Impact**: Improved maintainability, DRY compliance
1792 |
1793 | 6. **Port Consistency** (memory-client.js:166)
1794 | - **Issue**: Health checks used standard web ports (443/80) while API calls used dev ports (8443/8889)
1795 | - **Fix**: Made both use development ports consistently
1796 | - **Impact**: Prevents connection failures with development endpoints
1797 |
1798 | **Testing & Verification:**
1799 | ```bash
1800 | # Before fix: Timeout
1801 | curl -s -m 5 "http://127.0.0.1:8889/api/search/by-time" -H "Content-Type: application/json" -d '{"query":"last-2-weeks","n_results":10}'
1802 | # (hangs indefinitely)
1803 |
1804 | # After fix: Success
1805 | curl -s -m 5 "http://127.0.0.1:8889/api/search/by-time" -H "Content-Type: application/json" -d '{"query":"last-2-weeks","n_results":10}'
1806 | # Status: 200 (11ms)
1807 | # Results: 5 memories retrieved
1808 | ```
1809 |
1810 | **Files Modified:**
1811 | - `src/mcp_memory_service/web/api/search.py` - Empty query fix, time expression, pool size, UTC timezone
1812 | - `src/mcp_memory_service/storage/hybrid.py` - Fixed 4 missing await keywords
1813 | - `claude-hooks/utilities/memory-client.js` - Refactored HTTP helpers, port consistency, API contract
1814 | - `claude-hooks/core/session-start.js` - Updated hardcoded endpoint fallbacks
1815 | - `claude-hooks/config.json` - HTTP endpoint configuration
1816 |
1817 | **Code Review**: All fixes reviewed and approved by Gemini Code Assist with PEP 8 compliance, timezone-aware datetimes, list comprehensions, and proper error handling.
1818 |
1819 | **PR Reference**: [#156](https://github.com/doobidoo/mcp-memory-service/pull/156)
1820 |
1821 | ## [8.5.2] - 2025-10-11
1822 |
1823 | ### 🐛 **Fixed**
1824 |
1825 | #### **v8.5.0 Implementation Missing (Code Completion)**
1826 | Complete implementation of Hybrid Backend Sync Dashboard feature that was documented in v8.5.0 CHANGELOG but code was never committed.
1827 |
1828 | **Context**: v8.5.0 release (c241292) included CHANGELOG documentation and version bump but the actual implementation files were accidentally not staged/committed. This release completes the v8.5.0 feature by committing the missing implementation code.
1829 |
1830 | **Files Added:**
1831 | - `src/mcp_memory_service/web/api/sync.py` - Sync API endpoints (GET /api/sync/status, POST /api/sync/force)
1832 | - `start_http_server.sh` - Cross-platform HTTP server management script
1833 |
1834 | **Files Modified:**
1835 | - `src/mcp_memory_service/web/app.py` - Integrated sync router
1836 | - `src/mcp_memory_service/web/static/app.js` - Sync status UI with polling
1837 | - `src/mcp_memory_service/web/static/index.html` - Sync status bar markup
1838 | - `src/mcp_memory_service/web/static/style.css` - Sync bar styling + grid layout
1839 | - `src/mcp_memory_service/storage/hybrid.py` - Added `get_sync_status()` method
1840 | - `src/mcp_memory_service/web/api/health.py` - Health check enhancements
1841 | - `src/mcp_memory_service/storage/sqlite_vec.py` - Database path fixes
1842 |
1843 | **Additional Improvements:**
1844 | - `claude-hooks/utilities/context-formatter.js` - Tree text wrapping improvements for better CLI output
1845 |
1846 | **Impact**: Users can now access the complete Hybrid Backend Sync Dashboard feature including manual sync triggers and real-time status monitoring as originally intended in v8.5.0.
1847 |
1848 | ## [8.5.1] - 2025-10-11
1849 |
1850 | ### 🎯 **New Features**
1851 |
1852 | #### **Dynamic Memory Weight Adjustment (Claude Code Hooks)**
1853 | Intelligent auto-calibration prevents stale memories from dominating session context when recent development exists.
1854 |
1855 | **Problem Solved:**
1856 | Users reported "Current Development" section showing outdated memories (24-57 days old) instead of recent work from the last 7 days. Root cause: static configuration couldn't adapt to mismatches between git activity and memory age.
1857 |
1858 | **Solution - Memory Age Distribution Analyzer:**
1859 | - **Auto-Detection**: Analyzes memory age percentiles (median, p75, p90, avg)
1860 | - **Staleness Detection**: Triggers when median > 30 days or < 20% recent memories
1861 | - **Smart Calibration**: Automatically adjusts weights:
1862 | - `timeDecay`: 0.25 → 0.50 (+100% boost for recent memories)
1863 | - `tagRelevance`: 0.35 → 0.20 (-43% reduce old tag matches)
1864 | - **Impact**: Stale memory sets automatically prioritize any recent memories
1865 |
1866 | **Solution - Adaptive Git Context Weight:**
1867 | - **Scenario 1**: Recent commits (< 7d) + Stale memories (median > 30d)
1868 | - Reduces git weight by 30%: `1.8x → 1.3x`
1869 | - Prevents old git-related memories from dominating
1870 | - **Scenario 2**: Recent commits + Recent memories (both < 14d)
1871 | - Keeps configured weight: `1.8x → 1.8x`
1872 | - Git context is relevant and aligned
1873 | - **Scenario 3**: Old commits (> 14d) + Some recent memories
1874 | - Reduces git weight by 15%: `1.8x → 1.5x`
1875 | - Lets recent non-git memories surface
1876 |
1877 | **Configuration Options:**
1878 | ```json
1879 | {
1880 | "memoryScoring": {
1881 | "autoCalibrate": true // Enable/disable auto-calibration
1882 | },
1883 | "gitAnalysis": {
1884 | "adaptiveGitWeight": true // Enable/disable adaptive git weight
1885 | }
1886 | }
1887 | ```
1888 |
1889 | **Transparency Output:**
1890 | ```
1891 | 🎯 Auto-Calibration → Stale memory set detected (median: 54d old, 0% recent)
1892 | Adjusted Weights → timeDecay: 0.50, tagRelevance: 0.20
1893 | ⚙️ Adaptive Git Weight → Recent commits (1d ago) but stale memories - reducing git boost: 1.8 → 1.3
1894 | ```
1895 |
1896 | **Files Added:**
1897 | - `claude-hooks/test-adaptive-weights.js` - Comprehensive test scenarios
1898 |
1899 | **Files Modified:**
1900 | - `claude-hooks/utilities/memory-scorer.js` (+162 lines):
1901 | - `analyzeMemoryAgeDistribution()` - Detects staleness and recommends adjustments
1902 | - `calculateAdaptiveGitWeight()` - Dynamically adjusts git boost based on context alignment
1903 | - `claude-hooks/core/session-start.js` (+60 lines):
1904 | - Integrated age analysis before scoring
1905 | - Auto-calibration logic with config check
1906 | - Adaptive git weight calculation with transparency output
1907 | - `claude-hooks/config.json` (+2 options):
1908 | - Added `memoryScoring.autoCalibrate: true` (default enabled)
1909 | - Added `gitAnalysis.adaptiveGitWeight: true` (default enabled)
1910 |
1911 | **Benefits:**
1912 | - ✅ **Automatic Detection**: No manual config changes when memories become stale
1913 | - ✅ **Context-Aware**: Git boost only applies when it enhances (not harms) relevance
1914 | - ✅ **Transparent**: Shows reasoning for adjustments in session output
1915 | - ✅ **Opt-Out Available**: Users can disable via config if desired
1916 | - ✅ **Backward Compatible**: Defaults preserve existing behavior when memories are recent
1917 |
1918 | **Test Results:**
1919 | - Scenario 1 (Stale): Automatically calibrated weights and reduced git boost 1.8x → 1.3x
1920 | - Scenario 2 (Recent): No calibration needed, preserved git weight at 1.8x
1921 | - Both scenarios working as expected, preventing outdated context issues
1922 |
1923 | ## [8.5.0] - 2025-10-11
1924 |
1925 | ### 🎉 **New Features**
1926 |
1927 | #### **Hybrid Backend Sync Dashboard**
1928 | Manual sync management UI with real-time status monitoring for hybrid storage backend.
1929 |
1930 | **Features:**
1931 | - **Sync Status Bar** - Color-coded visual indicator between navigation and main content
1932 | - 🔄 Syncing (blue gradient) - Active synchronization in progress
1933 | - ⏱️ Pending (yellow gradient) - Operations queued, shows ETA and count
1934 | - ✅ Synced (green gradient) - All operations synchronized, shows last sync time
1935 | - ⚠️ Error (red gradient) - Sync failures detected, shows failed operation count
1936 | - **"Sync Now" Button** - Manual trigger for immediate Cloudflare ↔ SQLite synchronization
1937 | - **Real-time Monitoring** - 10-second polling for live sync status updates
1938 | - **REST API Endpoints:**
1939 | - `GET /api/sync/status` - Current sync state, pending operations, last sync time
1940 | - `POST /api/sync/force` - Manually trigger immediate sync
1941 |
1942 | **Technical Implementation:**
1943 | - New sync API router: `src/mcp_memory_service/web/api/sync.py` (complete CRUD endpoints)
1944 | - Frontend integration: `src/mcp_memory_service/web/static/app.js:379-485` (status monitoring + manual sync)
1945 | - CSS styling: `src/mcp_memory_service/web/static/style.css:292-403` (grid layout + animations)
1946 | - HTML structure: `src/mcp_memory_service/web/static/index.html:125-138` (sync bar markup)
1947 | - Backend method: `src/mcp_memory_service/storage/hybrid.py:982-994` (added `get_sync_status()`)
1948 |
1949 | ### 🐛 **Fixed**
1950 |
1951 | - **CSS Grid Layout Bug** - Sync status bar invisible despite JavaScript detecting hybrid mode
1952 | - **Root Cause**: `.app-container` grid layout defined `"header" "nav" "main"` but sync bar wasn't assigned a grid area
1953 | - **Fix**: Added `grid-area: sync` to `.sync-status-bar` and expanded grid to include sync row
1954 | - **Files**: `style.css:101-109` (grid layout), `style.css:293` (sync bar grid area)
1955 |
1956 | - **Sync Status Logic Error** - "Sync Now" button incorrectly disabled when background service running
1957 | - **Root Cause**: Confused `is_running` (service alive) with `actively_syncing` (active sync operation)
1958 | - **Fix**: Changed status determination to check `actively_syncing` field instead of `is_running`
1959 | - **Impact**: Button now correctly enabled when 0 pending operations
1960 | - **File**: `src/mcp_memory_service/web/api/sync.py:106-118`
1961 |
1962 | - **Database Path Mismatch** - HTTP server using different SQLite database than Claude Code MCP
1963 | - **Root Cause**: Missing `MCP_MEMORY_SQLITE_PATH` environment variable in HTTP server startup
1964 | - **Fix**: Added explicit database path to match Claude Desktop config
1965 | - **File**: `start_http_server.sh:4` (added `MCP_MEMORY_SQLITE_PATH` export)
1966 |
1967 | - **Backend Configuration Inconsistency** - Claude Desktop using `cloudflare` backend while HTTP server using `hybrid`
1968 | - **Root Cause**: Mismatched storage backend configurations preventing data synchronization
1969 | - **Fix**: Unified both to use `hybrid` backend with same SQLite database
1970 | - **File**: `claude_desktop_config.json:70` (changed `"cloudflare"` → `"hybrid"`)
1971 | - **Impact**: Dashboard now shows same 1413 memories as Claude Code
1972 |
1973 | ### 🔧 **Improvements**
1974 |
1975 | - **Enhanced Health Check** - `/api/health/detailed` now includes sync status for hybrid backend
1976 | - Shows sync service state, pending operations, last sync time, failed operations
1977 | - File: `src/mcp_memory_service/web/api/health.py:141-154`
1978 |
1979 | - **Cleaned Database Files** - Removed obsolete SQLite databases to prevent confusion
1980 | - Deleted: `memory_http.db` (701 memories), `backup_sqlite_vec.db`, `sqlite_vec_backup_20250822_230643.db`
1981 |
1982 | - **Updated Startup Script** - `start_http_server.sh` now includes all required environment variables
1983 | - Added: `MCP_MEMORY_SQLITE_PATH`, `MCP_HTTP_ENABLED`
1984 | - Ensures HTTP server uses same database as Claude Code
1985 |
1986 | ### 📊 **Impact**
1987 |
1988 | - **User Experience**: Dashboard now provides complete visibility and control over hybrid backend synchronization
1989 | - **Data Consistency**: Unified backend configuration ensures Claude Code and HTTP dashboard always show same data
1990 | - **Performance**: Manual sync trigger allows immediate synchronization instead of waiting 5 minutes
1991 | - **Reliability**: Fixed grid layout bug ensures sync status bar always visible when in hybrid mode
1992 |
1993 | ## [8.4.3] - 2025-10-11
1994 |
1995 | ### 🐛 Fixed
1996 | - **Sync Script Import Path:** Fixed `scripts/sync/sync_memory_backends.py` module import path to work correctly from scripts directory
1997 | - Changed `sys.path.insert(0, str(Path(__file__).parent.parent))` → `sys.path.insert(0, str(Path(__file__).parent.parent.parent))`
1998 | - Resolves `ModuleNotFoundError: No module named 'src'` when using manual sync commands
1999 | - Fixes: `python scripts/sync/claude_sync_commands.py backup/restore/sync` commands
2000 |
2001 | ### 📊 Impact
2002 | - Users can now successfully run manual sync utilities for hybrid backend
2003 | - Manual Cloudflare ↔ SQLite synchronization commands now functional
2004 |
2005 | ## [8.4.2] - 2025-10-11
2006 |
2007 | ### 🎯 **Performance & Optimization**
2008 |
2009 | #### **Additional MCP Context Optimization: Debug Tools Removal**
2010 | - **Problem**: Continuing context optimization efforts from v8.4.1, identified 2 additional low-value debug tools
2011 | - **Solution**: Removed debug/maintenance MCP tools with zero test dependencies
2012 |
2013 | **Tools Removed:**
2014 | - `get_embedding` (606 tokens) - Returns raw embedding vectors; low-level debugging only
2015 | - `check_embedding_model` (553 tokens) - Checks if embedding model loaded; errors surface naturally
2016 |
2017 | **Rationale:** These were specialized debugging tools rarely needed in practice. Embedding errors are caught during normal retrieval operations, and raw embedding inspection is a niche development task not required for AI assistant integration.
2018 |
2019 | **Impact:**
2020 | - ✅ **MCP tools**: 26.8k → 25.6k tokens (4.5% additional reduction, -1.2k tokens)
2021 | - ✅ **Total optimization since v8.4.0**: 31.4k → 25.6k tokens (18.5% reduction, -5.8k tokens saved)
2022 | - ✅ **Zero breaking changes**: No test coverage for these tools
2023 | - ✅ **Conservative approach**: Removed only tools with no dependencies
2024 |
2025 | **Files Modified:**
2026 | - `src/mcp_memory_service/server.py`: Removed 2 tool definitions, handlers, and implementations (~61 lines)
2027 |
2028 | **Note:** Further optimization possible with MODERATE approach (debug_retrieve, exact_match_retrieve, cleanup_duplicates) if additional context savings needed.
2029 |
2030 | ## [8.4.1] - 2025-10-11
2031 |
2032 | ### 🎯 **Performance & Optimization**
2033 |
2034 | #### **MCP Context Optimization: Dashboard Tools Removal**
2035 | - **Problem**: MCP tools consuming 31.4k tokens (15.7% of context budget) with redundant dashboard variants that duplicated web UI functionality
2036 | - **Solution**: Removed 8 dashboard-specific MCP tools that were unnecessary for Claude Code integration
2037 |
2038 | **Tools Removed:**
2039 | - `dashboard_check_health`, `dashboard_recall_memory`, `dashboard_retrieve_memory`
2040 | - `dashboard_search_by_tag`, `dashboard_get_stats`, `dashboard_optimize_db`
2041 | - `dashboard_create_backup`, `dashboard_delete_memory`
2042 |
2043 | **Rationale:** Web dashboard uses REST API endpoints (`/api/*`), not MCP tools. These were legacy wrappers created during early dashboard development that bloated context without providing value for AI assistant integration.
2044 |
2045 | **Impact:**
2046 | - ✅ **MCP tools**: 31.4k → 26.8k tokens (15% reduction, -4.6k tokens saved)
2047 | - ✅ **Zero functional impact**: Core memory tools preserved (`check_database_health`, `recall_memory`, etc.)
2048 | - ✅ **Cleaner separation**: MCP protocol for Claude Code integration, HTTP REST API for web dashboard
2049 |
2050 | **Files Modified:**
2051 | - `src/mcp_memory_service/server.py`: Removed 8 tool definitions, call_tool handlers, and method implementations (~506 lines)
2052 | - `docs/api/tag-standardization.md`: Updated to use `check_database_health()` instead of `dashboard_get_stats()`
2053 | - `docs/maintenance/memory-maintenance.md`: Removed redundant dashboard tool reference
2054 | - `docs/guides/mcp-enhancements.md`: Removed `dashboard_optimize_db` progress tracking example
2055 | - `docs/assets/images/project-infographic.svg`: Removed `dashboard_*_ops` visual reference
2056 |
2057 | **Note:** Web dashboard at `https://localhost:8443` continues working normally via REST API. No user-facing changes.
2058 |
2059 | ## [8.4.0] - 2025-10-08
2060 |
2061 | ### ✨ **Features & Improvements**
2062 |
2063 | #### **Claude Code Memory Hooks Recency Optimization**
2064 | - **Problem Solved**: Memory hooks were surfacing 60+ day old memories instead of recent development work (Oct v8.0-v8.3), causing critical development context to be missing despite being stored in the database
2065 | - **Core Enhancement**: Comprehensive recency optimization with rebalanced scoring algorithm to prioritize recent memories over well-tagged old content
2066 |
2067 | ##### **Scoring Algorithm Improvements**
2068 | - **Weight Rebalancing** (`config.json`):
2069 | - `timeDecay`: 0.25 → 0.40 (+60% influence on recency)
2070 | - `tagRelevance`: 0.35 → 0.25 (-29% to reduce tag dominance)
2071 | - `contentQuality`: 0.25 → 0.20 (-20% to balance with time)
2072 | - **Gentler Time Decay**:
2073 | - `timeDecayRate`: 0.1 → 0.05 (30-day memories: 0.22 vs 0.05 score - preserves older memories)
2074 | - **Stronger Git Context**:
2075 | - `gitContextWeight`: 1.2 → 1.8 (80% boost vs 20% for git-derived memories)
2076 | - Implemented multiplication in `session-start.js` after scoring
2077 | - **Expanded Time Windows**:
2078 | - `recentTimeWindow`: "last-week" → "last-month" (broader recent search)
2079 | - `fallbackTimeWindow`: "last-month" → "last-3-months" (wider fallback range)
2080 | - **Higher Quality Bar**: `minRelevanceScore`: 0.3 → 0.4 (filters generic old content)
2081 |
2082 | ##### **New Recency Bonus System** (`memory-scorer.js`)
2083 | - **Tiered Additive Bonuses**:
2084 | - < 7 days: +0.15 bonus (strong boost for last week)
2085 | - < 14 days: +0.10 bonus (moderate boost for last 2 weeks)
2086 | - < 30 days: +0.05 bonus (small boost for last month)
2087 | - **Implementation**: Configurable tier-based system using `RECENCY_TIERS` array
2088 | - **Impact**: Ensures recent memories always get advantage regardless of tag relevance
2089 |
2090 | ##### **Documentation & Testing**
2091 | - **Added**: Comprehensive `CONFIGURATION.md` (450+ lines)
2092 | - All scoring weights with impact analysis
2093 | - Time decay behavior and examples
2094 | - Git context weight strategy
2095 | - Recency bonus system documentation
2096 | - Tuning guide for different workflows
2097 | - Migration notes from v1.0
2098 | - **Added**: Validation test suite (`test-recency-scoring.js`)
2099 | - Tests scoring algorithm with memories of different ages
2100 | - Validates time decay and recency bonus calculations
2101 | - Confirms recent memories rank higher (success criteria: 2 of top 3 < 7 days old)
2102 |
2103 | ##### **Results**
2104 | - **Before**: Top 3 memories averaged 45+ days old (July-Sept content)
2105 | - **After**: All top 3 memories < 7 days old ✅
2106 | - **Validation**: 80% higher likelihood of surfacing recent work
2107 |
2108 | **Impact**: ✅ Memory hooks now reliably surface recent development context, significantly improving Claude Code session awareness for active projects
2109 |
2110 | ##### **Technical Details**
2111 | - **PR**: [#155](https://github.com/doobidoo/mcp-memory-service/pull/155) - Memory hooks recency optimization
2112 | - **Files Modified**:
2113 | - Configuration: `claude-hooks/config.json` (scoring weights, time windows, git context)
2114 | - Scoring: `claude-hooks/utilities/memory-scorer.js` (recency bonus, configurable decay)
2115 | - Session: `claude-hooks/core/session-start.js` (git context weight implementation)
2116 | - Tests: `claude-hooks/test-recency-scoring.js` (validation suite)
2117 | - Documentation: `claude-hooks/CONFIGURATION.md` (comprehensive guide)
2118 | - **Code Review**: 7 rounds of Gemini Code Assist review completed
2119 | - **CRITICAL bugs fixed**: Config values not being used (round 5), gitContextWeight not implemented (round 6)
2120 | - **Security fixes**: TLS certificate validation, future timestamp handling
2121 | - **Maintainability**: DRY refactoring, tier-based configuration, comprehensive docs
2122 | - **Test Results**: ✅ All validation checks passed - recent memories consistently prioritized
2123 |
2124 | ## [8.3.1] - 2025-10-07
2125 |
2126 | ### ✨ **Features & Improvements**
2127 |
2128 | #### **HTTP Server Management Tools**
2129 | - **Added**: Cross-platform HTTP server management utilities for Claude Code Natural Memory Triggers
2130 | - **New Scripts**:
2131 | - `scripts/server/check_http_server.py`: Health check utility for HTTP server status verification
2132 | - Supports both HTTP and HTTPS endpoints via environment variables
2133 | - Verbose output by default, `-q` flag for quiet mode (exit codes only)
2134 | - Detects MCP_HTTPS_ENABLED, MCP_HTTP_PORT, MCP_HTTPS_PORT configuration
2135 | - `scripts/server/start_http_server.sh`: Auto-start script for Unix/macOS
2136 | - Intelligent server detection with 5-second polling loop
2137 | - Background process management via nohup
2138 | - Logs to `/tmp/mcp-http-server.log`
2139 | - `scripts/server/start_http_server.bat`: Auto-start script for Windows
2140 | - 5-second polling loop for reliable startup detection
2141 | - Starts server in new window for easy monitoring
2142 | - Handles already-running servers gracefully
2143 | - **Documentation**: Comprehensive `docs/http-server-management.md` guide
2144 | - Why HTTP server is required for Natural Memory Triggers
2145 | - Quick health check commands
2146 | - Manual and auto-start procedures
2147 | - Troubleshooting guide with common issues
2148 | - Integration with Claude Code hooks
2149 | - Automation examples (launchd, Task Scheduler, shell aliases)
2150 | - **Use Case**: Essential for Claude Code hooks to inject relevant memories at session start without MCP conflicts
2151 | - **Wiki**: User-specific setup examples moved to wiki as reference guides
2152 | - Windows-Hybrid-Backend-Setup-Example.md
2153 | - Windows-Setup-Summary-Example.md
2154 |
2155 | **Impact**: ✅ Streamlined HTTP server management, improved Natural Memory Triggers reliability, better cross-platform support
2156 |
2157 | ##### **Technical Details**
2158 | - **PR**: [#154](https://github.com/doobidoo/mcp-memory-service/pull/154) - HTTP server management tools
2159 | - **Files Added**: 4 new files
2160 | - Scripts: `check_http_server.py`, `start_http_server.sh`, `start_http_server.bat`
2161 | - Documentation: `http-server-management.md`
2162 | - **Gemini Reviews**: 3 rounds of code review and refinement
2163 | - Security: Removed hardcoded credentials (replaced with placeholders)
2164 | - Robustness: Improved exception handling, added polling loops
2165 | - CLI Usability: Simplified argument parsing (removed redundant `-v` flag)
2166 | - **Cross-platform**: Fully tested on Unix/macOS and Windows environments
2167 | - **Integration**: Works seamlessly with existing `run_http_server.py` script
2168 |
2169 | ## [8.3.0] - 2025-10-07
2170 |
2171 | ### 🧹 **Refactoring & Code Cleanup**
2172 |
2173 | #### **Complete ChromaDB Backend Removal**
2174 | - **Removed**: ~300-500 lines of ChromaDB dead code following v8.0.0 deprecation
2175 | - **Scope**: Complete cleanup across 18 files including configuration, CLI, server, storage, utilities, and web interface
2176 | - **Changes**:
2177 | - **Configuration** (`config.py`): Removed CHROMA_PATH, CHROMA_SETTINGS, COLLECTION_METADATA, CHROMADB_MAX_CONTENT_LENGTH
2178 | - **CLI** (`cli/main.py`, `cli/ingestion.py`): Removed `--chroma-path` option, removed 'chromadb' from storage backend choices
2179 | - **Server** (`server.py`): Removed ChromaDB initialization (~60 lines), stats fallback (~40 lines), backup handler, validation logic
2180 | - **Utilities** (`utils/db_utils.py`): Removed ChromaDB validation, stats, and repair functions (~140 lines)
2181 | - **Storage** (`storage/cloudflare.py`, `storage/sqlite_vec.py`): Updated docstrings to be backend-agnostic
2182 | - **Web** (`web/app.py`): Removed 'chromadb' from backend display name mapping
2183 | - **Documentation**: Updated all error messages to suggest Cloudflare instead of ChromaDB
2184 | - **Impact**: ✅ Cleaner codebase, reduced technical debt, no misleading ChromaDB references
2185 | - **SUPPORTED_BACKENDS**: Now correctly shows `['sqlite_vec', 'sqlite-vec', 'cloudflare', 'hybrid']`
2186 |
2187 | #### **CLI Backend Consistency Enhancement**
2188 | - **Added**: 'sqlite-vec' hyphenated alias to all CLI storage backend choices
2189 | - **Affected commands**: `server`, `status`, `ingest_document`, `ingest_directory`
2190 | - **Rationale**: Ensures CLI behavior matches SUPPORTED_BACKENDS configuration
2191 | - **Impact**: ✅ Improved user experience with consistent backend naming across CLI and configuration
2192 |
2193 | ### 🐛 **Bug Fixes**
2194 |
2195 | #### **Dashboard System Information Display (Issue #151)**
2196 | - **Fixed**: Dashboard showing "N/A" for embedding model, embedding dimensions, and database size on non-hybrid backends
2197 | - **Root cause**: JavaScript expected hybrid-backend-specific nested paths (`storage.primary_stats.*`)
2198 | - **Solution**: Added fallback paths in `app.js` SYSTEM_INFO_CONFIG:
2199 | - `settingsEmbeddingModel`: Falls back to `storage.embedding_model`
2200 | - `settingsEmbeddingDim`: Falls back to `storage.embedding_dimension`
2201 | - `settingsDbSize`: Falls back to `storage.database_size_mb`
2202 | - **Impact**: ✅ Dashboard now correctly displays system information for sqlite-vec, cloudflare, and hybrid backends
2203 |
2204 | ##### **Technical Details**
2205 | - **PR**: [#153](https://github.com/doobidoo/mcp-memory-service/pull/153) - ChromaDB dead code removal + Issue #151 fix
2206 | - **Files Modified**: 18 files
2207 | - Core cleanup: `config.py`, `server.py`, `mcp_server.py`, `utils/db_utils.py`
2208 | - CLI: `cli/main.py`, `cli/ingestion.py`, `cli/utils.py`
2209 | - Storage: `storage/factory.py`, `storage/cloudflare.py`, `storage/sqlite_vec.py`
2210 | - Web: `web/app.py`, `web/api/health.py`, `web/static/app.js`
2211 | - Utilities: `utils/debug.py`, `embeddings/onnx_embeddings.py`
2212 | - Package: `__init__.py`, `dependency_check.py`
2213 | - **Code Review**: Approved by Gemini Code Assist with high-quality feedback
2214 | - **Testing**: ✅ SQLite-vec backend initialization, ✅ SUPPORTED_BACKENDS verification, ✅ Service startup
2215 |
2216 | ## [8.2.4] - 2025-10-06
2217 |
2218 | ### 🐛 **Bug Fixes**
2219 |
2220 | #### **Critical: Memory Hooks JSON Parsing Failure**
2221 | - **Fixed**: Memory awareness hooks completely broken - unable to retrieve memories due to JSON parsing errors
2222 | - **Root cause**: Naive string replacement in HTTP client destroyed valid JSON
2223 | - `replace(/'/g, '"')` broke apostrophes in content (e.g., "it's" → "it"s")
2224 | - Replaced Python-style values (True/False/None) in already-valid JSON
2225 | - Used `/mcp` MCP-over-HTTP bridge instead of direct REST API
2226 | - **Solution**:
2227 | - Removed destructive string replacements
2228 | - Updated to use direct REST API endpoints (`/api/search`, `/api/search/by-time`)
2229 | - Parse JSON responses directly without conversion
2230 | - **Impact**: ✅ Memory hooks now successfully retrieve context-relevant memories at session start
2231 |
2232 | #### **HTTP Server Backend Configuration Override**
2233 | - **Fixed**: HTTP server ignored `.env` configuration, forcing `sqlite_vec` instead of configured `hybrid` backend
2234 | - **Root cause**: `run_http_server.py` used `os.environ.setdefault()` after `.env` loading, overriding user config
2235 | - **Solution**: Commented out the backend override line to respect `.env` settings
2236 | - **Impact**: ✅ Hybrid backend now works correctly via HTTP server
2237 |
2238 | ##### **Technical Details**
2239 | - **Files**:
2240 | - `C:\Users\heinrich.krupp\.claude\hooks\utilities\memory-client.js` - Fixed `queryMemoriesHTTP()` method
2241 | - `scripts/server/run_http_server.py` - Removed backend configuration override (line 148)
2242 | - **Affected**: All users using memory hooks with HTTP protocol (automatic session awareness)
2243 |
2244 | ## [8.2.3] - 2025-10-05
2245 |
2246 | ### ✨ **Enhancements**
2247 |
2248 | #### **Dashboard Footer Navigation**
2249 | - **Added**: Comprehensive footer to dashboard with three sections
2250 | - **Documentation**: Links to Wiki Home, Troubleshooting Guide, Backend Configuration Issues
2251 | - **Resources**: GitHub Repository (with icon), Portfolio (doobidoo.github.io), API Documentation
2252 | - **About**: Project description, Apache 2.0 license link, copyright notice
2253 | - **Features**: Security attributes (target="_blank", rel="noopener"), responsive design (mobile breakpoint 768px)
2254 | - **Impact**: ✅ Improved discoverability of documentation and resources from dashboard
2255 |
2256 | ### 🐛 **Bug Fixes**
2257 |
2258 | #### **Dark Mode Footer Styling**
2259 | - **Critical fix**: Footer appearing bright/light in dark mode instead of dark
2260 | - **Root cause**: Incorrect CSS variable usage - using wrong end of inverted color scale
2261 | - Background used `var(--neutral-900)` (#f9fafb - light) instead of `var(--neutral-100)` (#1f2937 - dark)
2262 | - Headings used `var(--neutral-100)` (dark text) instead of `var(--neutral-900)` (light text)
2263 | - **Solution**: Corrected CSS variables to match dashboard card pattern with !important flags
2264 | - **Impact**: ✅ Footer now properly displays with dark background and light text in dark mode
2265 |
2266 | ##### **Technical Details**
2267 | - **Files**:
2268 | - `src/mcp_memory_service/web/static/index.html` - Footer HTML structure (lines 463-517)
2269 | - `src/mcp_memory_service/web/static/style.css` - Footer styling and dark mode overrides (lines 1757-1893)
2270 |
2271 | ## [8.2.2] - 2025-10-05
2272 |
2273 | ### ✨ **Enhancements**
2274 |
2275 | #### **HTTP-MCP Bridge: recall_memory Tool Support**
2276 | - **Added**: `recall_memory` tool to MCP HTTP bridge API
2277 | - **Functionality**: Natural language time-based memory retrieval (e.g., "last week", "yesterday")
2278 | - **Integration**: Seamlessly maps to storage backend's `recall_memory` method
2279 | - **API**: Accepts `query` (natural language) and optional `n_results` parameter
2280 | - **Use Case**: Enables time-aware memory recall through HTTP/MCP bridge interface
2281 |
2282 | ##### **Technical Details**
2283 | - **File**: `src/mcp_memory_service/web/api/mcp.py`
2284 | - Added `recall_memory` tool definition to `MCP_TOOLS` array
2285 | - Implemented handler in `handle_tool_call()` function
2286 | - Returns standardized format: content, content_hash, tags, created_at
2287 |
2288 | ## [8.2.1] - 2025-10-05
2289 |
2290 | ### 🐛 **Bug Fixes**
2291 |
2292 | #### **Critical: Missing Core Dependencies**
2293 | - **Fixed**: `sentence-transformers` and `torch` moved from optional `[ml]` extras to base dependencies
2294 | - **Root cause**: v8.2.0 removed ChromaDB but accidentally made semantic search dependencies optional
2295 | - **Impact**: Service failed to start with `ImportError: sentence-transformers is not available`
2296 | - **Resolution**: These are core dependencies required for semantic memory functionality
2297 | - **Breaking**: Users upgrading from v8.2.0 must run `uv sync` to install corrected dependencies
2298 |
2299 | ##### **Technical Details**
2300 | - **File**: `pyproject.toml`
2301 | - Moved `sentence-transformers>=2.2.2` from `[ml]` to `dependencies`
2302 | - Moved `torch>=2.0.0` from `[ml]` to `dependencies`
2303 | - Semantic search is core functionality, not optional
2304 |
2305 | ## [8.2.0] - 2025-10-05
2306 |
2307 | ### ✨ **Dashboard UX Improvements**
2308 |
2309 | #### **Dark Mode Polish**
2310 | - **Fixed**: Connection status indicator now properly displays in dark mode
2311 | - **Implementation**: Added dark mode CSS override for `.connection-status` component
2312 | - **Impact**: ✅ All dashboard elements now fully support dark mode without visual glitches
2313 |
2314 | #### **Browse Tab User Experience**
2315 | - **Enhancement**: Automatic smooth scroll to results when clicking a tag
2316 | - **Implementation**: Added `scrollIntoView()` with smooth behavior to `filterByTag()` method
2317 | - **User Benefit**: No more manual scrolling needed - tag selection immediately shows filtered memories
2318 | - **Impact**: ✅ Significantly improved discoverability and flow in Browse by Tags view
2319 |
2320 | ##### **Technical Details**
2321 | - **File**: `src/mcp_memory_service/web/static/style.css`
2322 | - Added dark mode override for connection status background, border, and text colors
2323 | - Uses CSS variables for consistency with theme system
2324 | - **File**: `src/mcp_memory_service/web/static/app.js`
2325 | - Added smooth scroll animation when displaying tag-filtered results
2326 | - Scrolls results section into view with `block: 'start'` positioning
2327 |
2328 | ## [8.1.2] - 2025-10-05
2329 |
2330 | ### 🐛 **Bug Fixes**
2331 |
2332 | #### **Dashboard Statistics Display**
2333 | - **Critical fix**: Dashboard showing 0 for "This Week" and "Tags" statistics on Hybrid and Cloudflare backends
2334 | - **Root cause**: Statistics fields not exposed at top level of storage health response
2335 |
2336 | ##### **Hybrid Backend Fix** (`src/mcp_memory_service/storage/hybrid.py`)
2337 | - Extract `unique_tags` from `primary_stats` to top-level stats dictionary
2338 | - Extract `memories_this_week` from `primary_stats` to top-level stats dictionary
2339 | - Maintains consistency with SQLite-vec standalone backend behavior
2340 |
2341 | ##### **Cloudflare Backend Fix** (`src/mcp_memory_service/storage/cloudflare.py`)
2342 | - Added SQL subquery to calculate `unique_tags` from tags table
2343 | - Added SQL subquery to calculate `memories_this_week` (last 7 days)
2344 | - Now returns both statistics in `get_stats()` response
2345 |
2346 | ##### **Impact**
2347 | - ✅ Dashboard now correctly displays weekly memory count for all backends
2348 | - ✅ Dashboard now correctly displays unique tags count for all backends
2349 | - ✅ SQLite-vec standalone backend already had these fields (no change needed)
2350 | - ✅ Fixes issue where hybrid/cloudflare users saw "0" despite having memories and tags
2351 |
2352 | ## [8.1.1] - 2025-10-05
2353 |
2354 | ### 🐛 **Bug Fixes**
2355 |
2356 | #### **Dark Mode Text Contrast Regression**
2357 | - **Critical fix**: Memory card text barely visible in dark mode due to hardcoded white backgrounds
2358 | - **Root cause**: CSS variable redefinition made text colors too faint when applied to white backgrounds
2359 | - **Solution**: Override all major containers with dark backgrounds (`#1f2937`) and force bright text colors
2360 |
2361 | ##### **Fixed Components**
2362 | - Memory cards: Now use dark card backgrounds with bright white text (`#f9fafb`)
2363 | - Memory metadata: Labels bright white (`#f9fafb`), values light gray (`#d1d5db`)
2364 | - Action cards: Dark backgrounds for proper contrast
2365 | - All containers: App header, welcome card, search filters, modals now properly dark
2366 |
2367 | ##### **Technical Details**
2368 | - Added `!important` overrides for 11 container backgrounds
2369 | - Memory content text: `var(--neutral-900) !important` → `#f9fafb`
2370 | - Memory meta labels: `var(--neutral-900) !important` → `#f9fafb`
2371 | - Memory meta values: `var(--neutral-600) !important` → `#d1d5db`
2372 | - Cache-busting comments to force browser reload
2373 |
2374 | ##### **Impact**
2375 | - ✅ Dark mode now fully readable across all dashboard views
2376 | - ✅ Proper contrast ratios for accessibility
2377 | - ✅ No visual regression from v8.1.0 light mode
2378 |
2379 | ## [8.1.0] - 2025-10-04
2380 |
2381 | ### ✨ **Dashboard Dark Mode & UX Enhancements**
2382 |
2383 | Production-ready dashboard improvements with comprehensive dark mode support, settings management, and optimized CSS architecture.
2384 |
2385 | #### 🎨 **New Features**
2386 |
2387 | ##### **Dark Mode Toggle**
2388 | - **Clean theme switching** with sun/moon icon toggle in header
2389 | - **Persistent preference** via localStorage - theme survives page reloads
2390 | - **Smooth transitions** between light and dark themes
2391 | - **Full coverage** across all dashboard views (Dashboard, Search, Browse)
2392 | - **Performance**: Instant theme switching with CSS class toggle
2393 |
2394 | ##### **Settings Modal**
2395 | - **Centralized preferences** accessible via cogwheel button
2396 | - **User preferences**:
2397 | - Theme selection (Light/Dark)
2398 | - View density (Comfortable/Compact)
2399 | - Memory preview lines (1-10)
2400 | - **System information display**:
2401 | - Application version
2402 | - Storage backend configuration (Hybrid/SQLite/Cloudflare)
2403 | - Primary/secondary backend details
2404 | - Embedding model and dimensions
2405 | - Database size
2406 | - Total memories count
2407 | - Server uptime (human-readable format)
2408 | - **Robust data loading**: Promise.allSettled() for graceful error handling
2409 | - **User feedback**: Toast notifications for save failures
2410 |
2411 | #### 🏗️ **Architecture & Performance**
2412 |
2413 | ##### **CSS Optimization - Variable Redefinition Approach**
2414 | - **Massive code reduction**: 2116 → 1708 lines (**-408 lines, -19% smaller**)
2415 | - **Clean implementation**: Redefine CSS variables in `body.dark-mode` instead of 200+ hardcoded overrides
2416 | - **Maintainability**: Single source of truth for dark mode colors
2417 | - **Automatic theming**: All components using CSS variables get dark mode support
2418 | - **No !important abuse**: Eliminated all !important tags except `.hidden` utility class
2419 |
2420 | ##### **JavaScript Improvements**
2421 | - **Data-driven configuration**: System info fields defined in static config object
2422 | - **Static class properties**: Constants defined once per class, not per instance
2423 | - **Robust error handling**: Promise.allSettled() prevents partial failures
2424 | - **Zero value handling**: Proper `!= null` checks (displays 0 MB, 0 memories correctly)
2425 | - **Smart field updates**: Targeted element updates using config keys
2426 |
2427 | ##### **HTML Optimization**
2428 | - **SVG icon deduplication**: Info icon defined once in `<defs>`, reused via `<use>`
2429 | - **File size reduction**: 4 inline SVG instances → 1 reusable symbol
2430 | - **Accessibility**: Proper `aria-hidden` and semantic structure
2431 | - **No inline styles**: All styling moved to CSS for better separation of concerns
2432 |
2433 | #### 📊 **Performance Metrics**
2434 |
2435 | | Component | Target | Actual | Status |
2436 | |-----------|--------|--------|--------|
2437 | | Page Load | <2s | 25ms | ✅ EXCELLENT |
2438 | | Memory Operations | <1s | 26ms | ✅ EXCELLENT |
2439 | | Tag Search | <500ms | <100ms | ✅ EXCELLENT |
2440 | | Theme Toggle | Instant | <1ms | ✅ EXCELLENT |
2441 | | CSS File Size | Smaller | -19% | ✅ EXCELLENT |
2442 |
2443 | #### 🔍 **Code Quality**
2444 |
2445 | ##### **Gemini Code Assist Review**
2446 | - **8 review iterations** - All feedback addressed
2447 | - **Final verdict**: "Solid enhancement to the dashboard's user experience"
2448 | - **Key improvements**:
2449 | - Variable redefinition pattern for dark mode
2450 | - Removed redundant arrays (derive from Object.keys)
2451 | - SVG icon deduplication
2452 | - Better error messages for users
2453 | - Static method optimization
2454 |
2455 | ##### **Files Changed**
2456 | - `src/mcp_memory_service/web/static/style.css`: -408 lines (major refactoring)
2457 | - `src/mcp_memory_service/web/static/app.js`: +255 lines (settings, theme management)
2458 | - `src/mcp_memory_service/web/static/index.html`: +134 lines (modal, icons, SVG defs)
2459 | - **Net change**: -19 lines (improved functionality with less code)
2460 |
2461 | #### 🎯 **User Experience**
2462 |
2463 | - **Visual comfort**: Dark mode reduces eye strain for long sessions
2464 | - **Personalization**: User-controlled theme and display preferences
2465 | - **Transparency**: System information visible in settings modal
2466 | - **Feedback**: Error notifications for localStorage failures
2467 | - **Consistency**: Dark mode styling matches across all views
2468 | - **Accessibility**: High contrast, semantic HTML, keyboard navigation
2469 |
2470 | #### 📝 **Technical Details**
2471 |
2472 | - **Conservative approach**: Original light mode design preserved pixel-perfect
2473 | - **Additive CSS**: Dark mode styles never modify existing rules
2474 | - **Browser compatibility**: CSS variables, localStorage, SSE all widely supported
2475 | - **Mobile responsive**: Works on all screen sizes (tested 768px, 1024px breakpoints)
2476 | - **XSS protection**: All user inputs properly escaped via `escapeHtml()`
2477 |
2478 | **PR**: #150 (16 commits, 543 additions, 23 deletions)
2479 |
2480 | ---
2481 |
2482 | ## [8.0.0] - 2025-10-04
2483 |
2484 | ### 💥 **BREAKING CHANGE: ChromaDB Backend Removed**
2485 |
2486 | **This is a major breaking change release**. The ChromaDB backend has been completely removed from the codebase after being deprecated since v5.x.
2487 |
2488 | #### ❌ **Removed**
2489 |
2490 | ##### **ChromaDB Backend Complete Removal**
2491 | - **Deleted 2,841 lines** of ChromaDB-related code from the codebase
2492 | - **Core files removed**:
2493 | - `src/mcp_memory_service/storage/chroma.py` (1,501 lines)
2494 | - `src/mcp_memory_service/storage/chroma_enhanced.py` (176 lines)
2495 | - `tests/unit/test_chroma.py`
2496 | - `tests/chromadb/test_chromadb_types.py`
2497 | - **Dependencies removed**:
2498 | - `chromadb` optional dependency group from `pyproject.toml`
2499 | - ~2GB PyTorch + sentence-transformers dependency burden eliminated
2500 | - **Factory updates**:
2501 | - Removed ChromaDB backend case from storage factory
2502 | - Removed ChromaStorage initialization logic
2503 | - Added clear error messages directing to migration guide
2504 |
2505 | #### 📦 **Migration & Legacy Support**
2506 |
2507 | ##### **ChromaDB Legacy Branch**
2508 | - **Branch**: [`chromadb-legacy`](https://github.com/doobidoo/mcp-memory-service/tree/chromadb-legacy)
2509 | - **Tag**: `chromadb-legacy-final` - Final ChromaDB code snapshot before removal
2510 | - **Status**: Frozen/Archived - No active maintenance
2511 | - **Purpose**: Historical reference and migration support
2512 |
2513 | ##### **Migration Script Preserved**
2514 | - **Location**: `scripts/migration/legacy/migrate_chroma_to_sqlite.py`
2515 | - **Status**: Moved to legacy folder, still functional for migrations
2516 | - **Alternative**: Check chromadb-legacy branch for additional migration tools
2517 |
2518 | ##### **Migration Guide**
2519 | See **Issue #148** for comprehensive ChromaDB to Hybrid/SQLite-vec/Cloudflare migration instructions:
2520 | - Step-by-step migration procedures
2521 | - Data backup and validation steps
2522 | - Recommended migration path: **ChromaDB → Hybrid Backend**
2523 |
2524 | #### ✅ **Supported Storage Backends (v8.0.0+)**
2525 |
2526 | | Backend | Status | Use Case | Performance |
2527 | |---------|--------|----------|-------------|
2528 | | **Hybrid** | ⭐ RECOMMENDED | Production, multi-device | 5ms (SQLite) + cloud sync |
2529 | | **SQLite-vec** | ✅ Supported | Development, single-device | 5ms read/write |
2530 | | **Cloudflare** | ✅ Supported | Cloud-native, serverless | Network dependent |
2531 | | **HTTP Client** | ✅ Supported | Distributed, multi-client | Network dependent |
2532 | | **ChromaDB** | ❌ REMOVED | N/A - See legacy branch | N/A |
2533 |
2534 | #### 📊 **Impact & Rationale**
2535 |
2536 | **Why Remove ChromaDB?**
2537 | - **Performance**: ChromaDB 15ms vs SQLite-vec 5ms (3x slower)
2538 | - **Dependencies**: ~2GB PyTorch download eliminated
2539 | - **Maintenance**: 2,841 lines of code removed reduces complexity
2540 | - **Better Alternatives**: Hybrid backend provides superior performance with cloud sync
2541 |
2542 | **For Existing ChromaDB Users:**
2543 | - **No immediate action required** - Can continue using v7.x releases
2544 | - **Upgrade path available** - Migration guide in Issue #148
2545 | - **Legacy branch available** - Full code preserved for reference
2546 | - **Support timeline**: v7.x will remain available, but no new features
2547 |
2548 | #### 🔧 **Technical Changes**
2549 |
2550 | **Code Removed:**
2551 | - ChromaDB storage backend implementations
2552 | - ChromaDB-specific tests and fixtures
2553 | - ChromaDB configuration handling in factory
2554 | - ChromaDB deprecation warnings in server.py
2555 |
2556 | **Error Handling:**
2557 | - Attempting to use `MCP_MEMORY_STORAGE_BACKEND=chroma` now raises clear `ValueError`
2558 | - Error message includes link to migration guide and legacy branch
2559 | - Fallback logic removed - only valid backends accepted
2560 |
2561 | **Dependencies:**
2562 | - Removed `chromadb>=0.5.0` from optional dependencies
2563 | - Updated `full` dependency group to exclude chromadb
2564 | - No impact on core dependencies - only optional dependency cleanup
2565 |
2566 | #### 🚀 **Upgrade Instructions**
2567 |
2568 | **For ChromaDB Users (REQUIRED MIGRATION):**
2569 | 1. **Backup your data**:
2570 | ```bash
2571 | # Use legacy migration script
2572 | git checkout chromadb-legacy
2573 | python scripts/migration/migrate_chroma_to_sqlite.py
2574 | ```
2575 |
2576 | 2. **Switch backend**:
2577 | ```bash
2578 | # Recommended: Hybrid backend (best of both worlds)
2579 | export MCP_MEMORY_STORAGE_BACKEND=hybrid
2580 |
2581 | # Or: SQLite-vec (local-only)
2582 | export MCP_MEMORY_STORAGE_BACKEND=sqlite_vec
2583 |
2584 | # Or: Cloudflare (cloud-only)
2585 | export MCP_MEMORY_STORAGE_BACKEND=cloudflare
2586 | ```
2587 |
2588 | 3. **Update to v8.0.0**:
2589 | ```bash
2590 | git checkout main
2591 | git pull origin main
2592 | python install.py --storage-backend hybrid
2593 | ```
2594 |
2595 | 4. **Validate migration**:
2596 | ```bash
2597 | python scripts/validation/validate_configuration_complete.py
2598 | ```
2599 |
2600 | **For Non-ChromaDB Users (No Action Required):**
2601 | - Upgrade seamlessly - no breaking changes for SQLite-vec, Cloudflare, or Hybrid users
2602 | - Enjoy reduced dependency footprint and simplified codebase
2603 |
2604 | #### 📚 **Documentation Updates**
2605 | - Updated architecture diagrams to show ChromaDB as deprecated/removed
2606 | - Updated storage backend comparison tables
2607 | - Added migration guide in Issue #148
2608 | - Legacy branch README updated with archive notice
2609 |
2610 | #### 🔗 **References**
2611 | - **Issue**: #148 - Plan ChromaDB Backend Deprecation and Removal (→ v8.0.0)
2612 | - **Legacy Branch**: https://github.com/doobidoo/mcp-memory-service/tree/chromadb-legacy
2613 | - **Migration Guide**: See Issue #148 for detailed migration instructions
2614 |
2615 | ---
2616 |
2617 | ## Historic Releases
2618 |
2619 | For older releases (v7.21.0 and earlier), see [CHANGELOG-HISTORIC.md](./CHANGELOG-HISTORIC.md).
2620 |
2621 | **Historic Version Range**: v0.1.0 through v7.21.0 (2025-07-XX through 2025-10-03)
2622 | ## [7.6.0] - 2025-10-04
2623 |
2624 | ### ✨ **Enhanced Document Ingestion with Semtools Support**
2625 |
2626 | #### 🆕 **Core Features**
2627 | - **Semtools loader integration** - Optional Rust-based document parser with LlamaParse API for superior extraction quality
2628 | - **New format support** - DOCX, DOC, PPTX, XLSX (requires semtools installation)
2629 | - **Intelligent chunking** - Respects paragraph and sentence boundaries for better semantic coherence
2630 | - **Graceful fallback** - Auto-detects semtools availability, uses native parsers (PyPDF2/pdfplumber) if unavailable
2631 | - **Configuration options** - Environment variables for LLAMAPARSE_API_KEY, MCP_DOCUMENT_CHUNK_SIZE, MCP_DOCUMENT_CHUNK_OVERLAP
2632 | - **Zero breaking changes** - Fully backward compatible, existing document ingestion unchanged
2633 |
2634 | #### 📄 **Supported Document Formats**
2635 | | Format | Native Parser | With Semtools | Quality |
2636 | |--------|--------------|---------------|---------|
2637 | | PDF | PyPDF2/pdfplumber | ✅ LlamaParse | Excellent (OCR, tables) |
2638 | | DOCX/DOC | ❌ Not supported | ✅ LlamaParse | Excellent |
2639 | | PPTX | ❌ Not supported | ✅ LlamaParse | Excellent |
2640 | | XLSX | ❌ Not supported | ✅ LlamaParse | Excellent |
2641 | | TXT/MD | ✅ Built-in | N/A | Perfect |
2642 |
2643 | #### 🔧 **Technical Implementation**
2644 | - **New file**: `src/mcp_memory_service/ingestion/semtools_loader.py` (220 lines)
2645 | - SemtoolsLoader class implementing DocumentLoader interface
2646 | - Async subprocess execution with 5-minute timeout for large documents
2647 | - Automatic semtools availability detection via `shutil.which()`
2648 | - LlamaParse API key support via LLAMAPARSE_API_KEY environment variable
2649 | - Comprehensive error handling with detailed logging
2650 | - **Modified**: `src/mcp_memory_service/config.py` - Added document processing configuration section (lines 564-586)
2651 | - **Modified**: `src/mcp_memory_service/ingestion/registry.py` - Registered new formats (DOCX, PPTX, XLSX)
2652 | - **Modified**: `src/mcp_memory_service/ingestion/__init__.py` - Auto-registration of semtools loader
2653 | - **Modified**: `CLAUDE.md` - Added comprehensive "Document Ingestion (v7.6.0+)" section with usage examples
2654 | - **Tests**: `tests/unit/test_semtools_loader.py` - 12 comprehensive unit tests, all passing ✅
2655 |
2656 | #### 📦 **Installation & Configuration**
2657 | ```bash
2658 | # Optional - install semtools for enhanced parsing
2659 | npm i -g @llamaindex/semtools
2660 | # or
2661 | cargo install semtools
2662 |
2663 | # Optional - configure LlamaParse API for best quality
2664 | export LLAMAPARSE_API_KEY="llx-..."
2665 |
2666 | # Document chunking configuration
2667 | export MCP_DOCUMENT_CHUNK_SIZE=1000 # Characters per chunk (default: 1000)
2668 | export MCP_DOCUMENT_CHUNK_OVERLAP=200 # Overlap between chunks (default: 200)
2669 | ```
2670 |
2671 | #### 🎯 **Usage Example**
2672 | ```python
2673 | from pathlib import Path
2674 | from mcp_memory_service.ingestion import get_loader_for_file
2675 |
2676 | # Automatic format detection and loader selection
2677 | loader = get_loader_for_file(Path("document.pdf"))
2678 | async for chunk in loader.extract_chunks(Path("document.pdf")):
2679 | await store_memory(chunk.content, tags=["documentation"])
2680 | ```
2681 |
2682 | #### ✅ **Benefits**
2683 | - **Superior PDF parsing** - OCR capabilities and table extraction via LlamaParse
2684 | - **Microsoft Office support** - DOCX, PPTX formats now supported (previously unavailable)
2685 | - **Production-ready** - Comprehensive error handling, timeout protection, detailed logging
2686 | - **Flexible deployment** - Optional enhancement, works perfectly without semtools
2687 | - **Automatic detection** - No configuration needed, auto-selects best available parser
2688 | - **Minimal overhead** - Only ~5ms initialization cost when semtools not installed
2689 |
2690 | #### 🔗 **Related Issues**
2691 | - Closes #94 - Integrate Semtools for Enhanced Document Processing
2692 | - Future work tracked in #147 - CLI commands, batch processing, progress reporting, benchmarks
2693 |
2694 | #### 📊 **Test Coverage**
2695 | - 12/12 unit tests passing
2696 | - Tests cover: initialization, availability checking, file handling, successful extraction, API key usage, error scenarios, timeout handling, empty content, registry integration
2697 | - Comprehensive mocking of subprocess execution for reliable CI/CD
2698 |
2699 | ## [7.5.5] - 2025-10-04
2700 |
2701 | ### 🐛 **Bug Fixes - HybridMemoryStorage Critical Issues**
2702 |
2703 | #### Fixed - Health Check Support (PR #145)
2704 | - **HybridMemoryStorage recognition in health checks** - Resolved "Unknown storage type: HybridMemoryStorage" error
2705 | - **Dashboard statistics for hybrid backend** - Added comprehensive stats collection from SQLite-vec primary storage
2706 | - **Health validation for hybrid storage** - Implemented proper validation logic for hybrid backend
2707 | - **Cloudflare sync status visibility** - Display sync service status (not_configured/configured/syncing)
2708 |
2709 | #### Fixed - Missing recall() Method (PR #146)
2710 | - **AttributeError on time-based queries** - Added missing `recall()` method to HybridMemoryStorage
2711 | - **Server.py compatibility** - Resolves errors when server calls `storage.recall()` with time filtering
2712 | - **Consistent API** - Matches method signature of SqliteVecMemoryStorage and CloudflareStorage
2713 | - **Delegation to primary** - Properly delegates to SQLite-vec primary storage for recall operations
2714 |
2715 | #### Technical Details
2716 | - Added `HybridMemoryStorage` case to `dashboard_get_stats()` endpoint (server.py:2503)
2717 | - Added `HybridMemoryStorage` case to `check_database_health()` endpoint (server.py:3705)
2718 | - Added `recall()` method to HybridMemoryStorage (hybrid.py:916)
2719 | - Method signature: `async def recall(query: Optional[str] = None, n_results: int = 5, start_timestamp: Optional[float] = None, end_timestamp: Optional[float] = None) -> List[MemoryQueryResult]`
2720 | - Query primary storage (SQLite-vec) for memory counts, tags, database info
2721 | - Fixed code quality issues from Gemini Code Assist review (removed duplicate imports, refactored getattr usage)
2722 |
2723 | #### Impact
2724 | - ✅ HTTP dashboard now properly displays hybrid backend statistics
2725 | - ✅ MCP health check tool correctly validates hybrid storage
2726 | - ✅ Time-based recall queries now work correctly with hybrid backend
2727 | - ✅ No more "Unknown storage type" or AttributeError exceptions
2728 | - ✅ HybridMemoryStorage fully compatible with all server.py operations
2729 |
2730 | ## [7.5.4] - 2025-10-04
2731 |
2732 | ### ✨ **Configurable Hybrid Sync Break Conditions**
2733 |
2734 | #### 🔄 **Enhanced Synchronization Control**
2735 | - **Configurable early break conditions** - Made hybrid sync termination thresholds configurable via environment variables
2736 | - `MCP_HYBRID_MAX_EMPTY_BATCHES` - Stop after N consecutive batches without new syncs (default: 20, was hardcoded 5)
2737 | - `MCP_HYBRID_MIN_CHECK_COUNT` - Minimum memories to check before early stop (default: 1000, was hardcoded 200)
2738 | - **Increased default thresholds** - Quadrupled default values (5→20 batches, 200→1000 memories) to ensure complete synchronization
2739 | - **Enhanced logging** - Added detailed sync progress logging every 100 memories with consecutive empty batch tracking
2740 | - **Threshold visibility** - Break condition log messages now display threshold values for better diagnostics
2741 |
2742 | #### 🐛 **Bug Fix - Incomplete Synchronization**
2743 | - **Resolved incomplete sync issue** - Dashboard was showing only 1040 memories instead of 1200+ from Cloudflare
2744 | - **Root cause** - Hardcoded early break conditions triggered prematurely causing missing memories
2745 | - **Impact** - Missing memories distributed throughout Cloudflare dataset were never synced to local SQLite
2746 |
2747 | #### ⚙️ **Configuration**
2748 | ```bash
2749 | # Environment variables for tuning sync behavior
2750 | export MCP_HYBRID_MAX_EMPTY_BATCHES=20 # Stop after N empty batches (min: 1)
2751 | export MCP_HYBRID_MIN_CHECK_COUNT=1000 # Min memories to check before early stop (min: 1)
2752 | ```
2753 |
2754 | #### 🔧 **Code Quality Improvements**
2755 | - **Added input validation** - `min_value=1` constraint prevents zero values that would break sync
2756 | - **Fixed progress logging** - Prevents misleading initial log message at `processed_count=0`
2757 | - **Eliminated duplicate defaults** - Refactored to use `getattr` pattern for config imports
2758 | - **Improved maintainability** - Centralized default values in config.py
2759 |
2760 | #### ✅ **Benefits**
2761 | - Complete synchronization of all Cloudflare memories to SQLite
2762 | - Configurable per deployment needs without code changes
2763 | - Better diagnostics for troubleshooting sync issues
2764 | - Maintains protection against infinite loops (early break still active)
2765 | - Preserves Cloudflare API protection through configurable limits
2766 | - No behavior change for deployments with small datasets
2767 |
2768 | #### 🔗 **References**
2769 | - Closes issue: Incomplete hybrid sync (1040/1200+ memories)
2770 | - PR #142: Configurable hybrid sync break conditions
2771 | - All Gemini Code Assist feedback addressed
2772 |
2773 | ## [7.5.3] - 2025-10-04
2774 |
2775 | ### 🏗️ **Repository Organization**
2776 |
2777 | #### 📁 **Litestream Sync System Reorganization**
2778 | - **Consolidated Litestream scripts** → `scripts/sync/litestream/`
2779 | - Moved 9 shell scripts from `/sync/` directory (git-like staging workflow)
2780 | - Relocated 4 root-level setup scripts (`enhanced_memory_store.sh`, `setup_local_litestream.sh`, etc.)
2781 | - Moved macOS launchd service (`io.litestream.replication.plist`)
2782 | - Moved staging database schema (`staging_db_init.sql`)
2783 | - **Created comprehensive documentation** - `scripts/sync/litestream/README.md`
2784 | - Local network HTTP API sync architecture
2785 | - Git-like staging workflow guide
2786 | - Setup and configuration instructions
2787 | - Comparison with Cloudflare hybrid sync
2788 |
2789 | #### 📂 **Deployment Files Consolidation**
2790 | - **Moved systemd service** → `scripts/service/mcp-memory.service`
2791 | - **Archived unused configs** → `archive/deployment-configs/`
2792 | - `smithery.yaml`
2793 | - `empty_config.yml`
2794 | - **Removed empty `/deployment/` directory**
2795 |
2796 | #### 🛠️ **Debug/Investigation Files Organization**
2797 | - **Moved to `scripts/development/`**:
2798 | - `debug_server_initialization.py` - Cloudflare backend debugger
2799 | - `verify_hybrid_sync.py` - Hybrid storage verification
2800 | - **Archived documentation** → `archive/`
2801 | - `MACOS_HOOKS_INVESTIGATION.md` → `archive/investigations/`
2802 | - `release-notes-v7.1.4.md` → `archive/release-notes/`
2803 |
2804 | #### 📚 **Documentation Updates**
2805 | - **Enhanced `scripts/README.md`** with dual sync system documentation
2806 | - Cloudflare Hybrid Sync (cloud backend) section
2807 | - Litestream Sync (local network HTTP API) section
2808 | - Clear distinction between the two systems
2809 |
2810 | ### 🎯 **Key Clarifications**
2811 | - **Litestream sync**: Multi-device synchronization via central SQLite-vec HTTP API (local network)
2812 | - Use case: Privacy-focused, data stays on local network
2813 | - Architecture: Git-like staging workflow with conflict detection
2814 | - **Cloudflare sync**: Cloud-based hybrid backend (internet)
2815 | - Use case: Global access, automatic cloud backup
2816 | - Architecture: Direct sync queue with background operations
2817 |
2818 | ### 📦 **Files Affected**
2819 | - 27 files changed, 594 insertions(+), 3 deletions(-)
2820 | - 13 files renamed/relocated
2821 | - 3 new documentation files
2822 | - 3 new archive directories
2823 |
2824 | ### ⚠️ **Breaking Changes**
2825 | None - Purely organizational changes with no functional impact
2826 |
2827 | ### 🔄 **Migration Notes**
2828 | If using Litestream sync scripts:
2829 | - Update script paths: `/sync/memory_sync.sh` → `scripts/sync/litestream/memory_sync.sh`
2830 | - Launchd plist location: `/deployment/io.litestream.replication.plist` → `scripts/sync/litestream/io.litestream.replication.plist`
2831 | - All scripts remain functionally identical
2832 |
2833 | ## [7.5.2] - 2025-10-03
2834 |
2835 | ### 🐛 **Bug Fixes**
2836 |
2837 | #### 🔧 **MCP HTTP Endpoint Fixes**
2838 | - **Fixed JSON serialization** - Changed `str(result)` to `json.dumps(result)` for proper client parsing
2839 | - MCP endpoint was returning Python dict string representation (`{'key': 'value'}`) instead of valid JSON (`{"key": "value"}`)
2840 | - Caused hook clients to fail parsing responses with "Expected ',' or '}'" errors
2841 | - **Fixed similarity threshold** - Changed default from `0.7` to `0.0` to return all relevant memories
2842 | - 70% similarity threshold was too restrictive, filtering out memories with scores 0.2-0.5
2843 | - Now returns all results, allowing client-side scoring to determine relevance
2844 |
2845 | #### 🔌 **Memory Hooks HTTP/HTTPS Protocol Detection**
2846 | - **Fixed protocol detection** in `claude-hooks/utilities/memory-client.js`
2847 | - Added `http` module import alongside existing `https` module
2848 | - Implemented dynamic protocol selection: `const protocol = url.protocol === 'https:' ? https : http`
2849 | - Previously hardcoded `https.request()` failed for `http://` endpoints
2850 |
2851 | ### 🎯 **Impact**
2852 | - ✅ Session-start hooks now properly inject memory context on Claude Code startup
2853 | - ✅ HTTP memory server (port 8888) connectivity fully restored
2854 | - ✅ Relevant memories (score 0.2-0.5) no longer filtered out by overly restrictive threshold
2855 | - ✅ JSON parsing errors resolved for all memory retrieval operations
2856 |
2857 | ## [7.5.1] - 2025-10-03
2858 |
2859 | ### 🛠️ **Linux Enhancements**
2860 |
2861 | #### 🔄 **Manual Sync Utilities for Hybrid Storage**
2862 | - **`sync_now.py` script** - Manual on-demand synchronization for hybrid storage on Linux
2863 | - Type-safe data structures with `TypedDict` (SyncResult, SyncStatus)
2864 | - Comprehensive logging with configurable levels
2865 | - Verbose mode (`--verbose`) for detailed error tracebacks
2866 | - Robust status validation prevents misleading success reports
2867 | - Proper error handling with specific exception types
2868 | - **Systemd integration** - Automated hourly background synchronization
2869 | - `mcp-memory-sync.service` - Systemd service for executing sync operations
2870 | - `mcp-memory-sync.timer` - Systemd timer triggering hourly syncs (5min after boot, persistent across reboots)
2871 | - **Security improvement** - API key moved to separate environment file in systemd service template
2872 |
2873 | ### 🔧 **Code Quality**
2874 | - Enhanced error handling throughout sync utilities
2875 | - Improved type safety with typed dictionaries for API results
2876 | - Better logging practices using `logger.exception()` for verbose errors
2877 | - Modular import structure following Python best practices
2878 |
2879 | ## [7.5.0] - 2025-10-03
2880 |
2881 | ### ✨ **New Features**
2882 |
2883 | #### 🎯 **Backend-Specific Content Length Limits with Auto-Splitting**
2884 | - **Intelligent content length management** - Prevents embedding failures by enforcing backend-specific limits
2885 | - **Automatic content splitting** - Long content automatically splits into linked chunks with preserved context
2886 | - **Backend-aware limits**:
2887 | - Cloudflare: 800 characters (BGE-base-en-v1.5 model 512 token limit)
2888 | - ChromaDB: 1500 characters (all-MiniLM-L6-v2 model 384 token limit)
2889 | - SQLite-vec: Unlimited (local storage)
2890 | - Hybrid: 800 characters (constrained by Cloudflare secondary storage)
2891 | - **Smart boundary preservation** - Splits respect natural boundaries (paragraphs → sentences → words)
2892 | - **Context preservation** - 50-character overlap between chunks maintains semantic continuity
2893 | - **LLM-friendly tool descriptions** - MCP tool docstrings inform LLMs about limits upfront
2894 |
2895 | ### 🔧 **Infrastructure Enhancements**
2896 |
2897 | #### 📦 **New Content Splitter Utility**
2898 | - **`content_splitter.py` module** - Comprehensive content chunking with boundary-aware splitting
2899 | - **Priority-based split points**:
2900 | 1. Double newlines (paragraph breaks)
2901 | 2. Single newlines
2902 | 3. Sentence endings (. ! ? followed by space)
2903 | 4. Spaces (word boundaries)
2904 | 5. Character position (last resort)
2905 | - **Configurable overlap** - Default 50 chars, customizable via `MCP_CONTENT_SPLIT_OVERLAP`
2906 | - **Validation helpers** - `estimate_chunks_needed()`, `validate_chunk_lengths()` utilities
2907 |
2908 | #### 🏗️ **Storage Backend Updates**
2909 | - **Abstract base class properties** - Added `max_content_length` and `supports_chunking` to `MemoryStorage`
2910 | - **Backend implementations**:
2911 | - `CloudflareStorage`: 800 char limit, chunking supported
2912 | - `ChromaMemoryStorage`: 1500 char limit, chunking supported
2913 | - `SqliteVecMemoryStorage`: No limit (None), chunking supported
2914 | - `HybridMemoryStorage`: 800 char limit (follows Cloudflare), chunking supported
2915 |
2916 | #### ⚙️ **Configuration System**
2917 | - **New config constants** in `config.py`:
2918 | - `CLOUDFLARE_MAX_CONTENT_LENGTH` (default: 800)
2919 | - `CHROMADB_MAX_CONTENT_LENGTH` (default: 1500)
2920 | - `SQLITEVEC_MAX_CONTENT_LENGTH` (default: None/unlimited)
2921 | - `HYBRID_MAX_CONTENT_LENGTH` (default: 800)
2922 | - `ENABLE_AUTO_SPLIT` (default: True)
2923 | - `CONTENT_SPLIT_OVERLAP` (default: 50)
2924 | - `CONTENT_PRESERVE_BOUNDARIES` (default: True)
2925 | - **Environment variable support** - All limits configurable via environment variables
2926 | - **Validation and logging** - Safe parsing with min/max bounds and startup logging
2927 |
2928 | ### 🛠️ **MCP Server Tool Enhancements**
2929 |
2930 | #### 💾 **Enhanced `store_memory` Tool**
2931 | - **Automatic content splitting** - Transparently handles content exceeding backend limits
2932 | - **Chunk metadata tracking**:
2933 | - `is_chunk`: Boolean flag identifying chunked memories
2934 | - `chunk_index`: Current chunk number (1-based)
2935 | - `total_chunks`: Total number of chunks
2936 | - `original_length`: Original content length before splitting
2937 | - **Chunk tags** - Automatic `chunk:N/M` tags for easy retrieval
2938 | - **Enhanced return values**:
2939 | - Single memory: `content_hash`
2940 | - Split content: `chunks_created`, `chunk_hashes` array
2941 | - **Updated docstring** - Clear backend limits documentation visible to LLMs
2942 |
2943 | ### 🧪 **Testing & Validation**
2944 |
2945 | #### ✅ **Comprehensive Test Suite**
2946 | - **`test_content_splitting.py`** - 20+ test cases covering:
2947 | - Basic splitting functionality (short/long content, empty strings)
2948 | - Boundary preservation (paragraphs, sentences, words, code blocks)
2949 | - Overlap validation and chunk estimation
2950 | - Backend limit verification (all 4 backends)
2951 | - Configuration constant validation
2952 | - **Edge case coverage** - Empty content, exact lengths, overlaps
2953 | - **Integration testing** - Ready for all storage backends
2954 |
2955 | ### 📝 **Technical Implementation Details**
2956 |
2957 | #### 🔍 **Design Decisions**
2958 | - **Conservative limits** - Buffer below actual token limits to account for tokenization variance
2959 | - **Cloudflare priority** - Hybrid backend follows Cloudflare's stricter limit for sync compatibility
2960 | - **Opt-out capable** - Set `MCP_ENABLE_AUTO_SPLIT=false` to disable auto-splitting
2961 | - **Backward compatible** - No breaking changes to existing functionality
2962 |
2963 | #### ⚡ **Performance Considerations**
2964 | - **Minimal overhead** - Content length checks are O(1) property access
2965 | - **Efficient chunking** - Single-pass splitting with smart boundary detection
2966 | - **No unnecessary splitting** - Content within limits passes through unchanged
2967 | - **Batch operations** - All chunks stored in single transaction when possible
2968 |
2969 | ### 🔗 **References**
2970 | - Addresses issue: First memory store attempt (1,570 chars) exceeded Cloudflare's BGE model limit
2971 | - Solution: Backend-specific limits with automatic intelligent content splitting
2972 | - Feature branch: `feat/content-length-limits-with-splitting`
2973 |
2974 | ## [7.4.1] - 2025-10-03
2975 |
2976 | ### 🐛 **Bug Fixes**
2977 |
2978 | #### 🧪 **Claude Hooks Integration Tests**
2979 | - **Fixed dual-protocol config compatibility** - Tests now support both legacy (direct endpoint) and new (dual-protocol) configuration structures
2980 | - **Improved CI/CD compatibility** - Tests gracefully handle scenarios when memory service is not running
2981 | - **Enhanced error handling** - Better detection and handling of connection failures and missing dependencies
2982 | - **Achieved 100% test pass rate** - Improved from 78.6% to 100% success rate across all 14 integration tests
2983 |
2984 | ### 🔧 **Technical Improvements**
2985 | - Updated configuration loading test to detect both `config.memoryService.endpoint` and `config.memoryService.http.endpoint`
2986 | - Enhanced connectivity test to treat service unavailability as expected behavior in test environments
2987 | - Improved mock session start hook to handle `memoryClient` reference errors gracefully
2988 |
2989 | ## [7.4.0] - 2025-10-03
2990 |
2991 | ### ✨ **Enhanced Search Tab UX**
2992 |
2993 | #### 🔍 **Advanced Search Functionality**
2994 | - **Enhanced date filter options** - Added "Yesterday" and "This quarter" options to improve time-based search granularity
2995 | - **Live search mode with toggle** - Implemented intelligent live/manual search modes with debounced input (300ms) to prevent API overload
2996 | - **Independent semantic search** - Semantic search now works independently from tag filtering for more flexible query combinations
2997 | - **Improved filter behavior** - Fixed confusing filter interactions and enhanced user experience with clear mode indicators
2998 |
2999 | #### 🎨 **UI/UX Improvements**
3000 | - **Resolved toggle visibility issues** - Fixed Live Search toggle contrast and visibility problems on white backgrounds
3001 | - **Eliminated layout shifts** - Moved toggle to header to prevent dynamic position changes due to text length variations
3002 | - **Enhanced tooltips** - Increased tooltip widths (desktop: 300px, mobile: 250px) for better readability
3003 | - **Accessible design patterns** - Implemented standard toggle design with proper contrast ratios and always-visible controls
3004 |
3005 | #### ⚡ **Performance Optimization**
3006 | - **Debounced search input** - 300ms delay prevents overwhelming API with rapid keystrokes during tag searches
3007 | - **Smart search triggering** - Live search mode provides immediate results while manual mode offers user control
3008 | - **Efficient event handling** - Optimized DOM manipulation and event listener management
3009 |
3010 | ### 🔧 **Code Quality Enhancement**
3011 |
3012 | #### 📚 **DRY Principles Implementation**
3013 | - **Eliminated code duplication** - Refactored diagnostic script `test_cloudflare_token()` function following Gemini Code Assist feedback
3014 | - **Extracted reusable helper** - Created `_verify_token_endpoint()` function reducing ~60 lines of duplicated token verification logic
3015 | - **Enhanced consistency** - Both account-scoped and user endpoint tests now display identical token information fields
3016 | - **Improved maintainability** - Centralized error handling and output formatting for easier future extensions
3017 |
3018 | ### 🔗 **References**
3019 | - Addresses user feedback on search tab UX requiring "further attention" with comprehensive improvements
3020 | - Implements Gemini Code Assist code review recommendations from PR #139
3021 | - Enhances overall dashboard usability with systematic testing of filter combinations
3022 |
3023 | ## [7.3.2] - 2025-10-03
3024 |
3025 | ### 🐛 **Critical Bug Fixes**
3026 |
3027 | #### 🔧 **HybridMemoryStorage Import Missing**
3028 | - **Fixed critical import error** - Added missing `HybridMemoryStorage` import in `storage/__init__.py` after v7.3.0 update
3029 | - **Symptom resolved** - "Unknown storage type: HybridMemoryStorage" error no longer occurs
3030 | - **Health check restored** - HTTP dashboard now properly displays hybrid backend status
3031 | - **Backwards compatibility** - Import follows same conditional pattern as other storage backends
3032 |
3033 | #### 🛡️ **Enhanced Cloudflare Token Authentication**
3034 | - **Resolved token endpoint confusion** - Clear guidance on using account-scoped vs generic verification endpoints
3035 | - **Documentation improvements** - Comprehensive `.env.example` with correct curl examples and warnings
3036 | - **Enhanced diagnostics** - `diagnose_backend_config.py` now tests both token verification endpoints
3037 | - **Developer experience** - New troubleshooting guide prevents common authentication mistakes
3038 |
3039 | ### 📚 **Documentation Enhancements**
3040 |
3041 | #### 🔍 **Comprehensive Troubleshooting Guide**
3042 | - **New guide:** `docs/troubleshooting/cloudflare-authentication.md` with complete Cloudflare setup guidance
3043 | - **Token verification clarity** - Explains difference between account-scoped and generic API endpoints
3044 | - **Common errors documented** - Solutions for "Invalid API Token" and related authentication failures
3045 | - **Step-by-step checklist** - Systematic approach to diagnosing token and authentication issues
3046 |
3047 | #### ⚙️ **Enhanced Configuration Examples**
3048 | - **Improved .env.example** - Combines comprehensive v7.3.1 configuration with token verification guidance
3049 | - **Clear warnings** - Explicit guidance on which endpoints to use and avoid
3050 | - **Security best practices** - Token handling and verification recommendations
3051 |
3052 | ### 🔗 **References**
3053 | - Closes critical post-v7.3.0 hybrid storage import issue
3054 | - Addresses developer confusion around Cloudflare token verification endpoints
3055 | - PR #139: Fix HybridMemoryStorage import + Add comprehensive Cloudflare token verification guide
3056 |
3057 | ## [7.3.1] - 2025-10-03
3058 |
3059 | ### 🐛 **Bug Fixes**
3060 |
3061 | #### 🔧 **HTTP Dashboard Backend Selection**
3062 | - **Fixed HTTP dashboard backend selection** - Dashboard now properly respects `MCP_MEMORY_STORAGE_BACKEND` configuration
3063 | - **Universal backend support** - Web interface works with all backends: SQLite-vec, Cloudflare, ChromaDB, and Hybrid
3064 | - **Tags functionality restored** - Fixed broken browse by tags feature for all storage backends
3065 | - **Shared factory pattern** - Eliminated code duplication between MCP server and web interface initialization
3066 |
3067 | #### 🛠️ **Code Quality Improvements**
3068 | - **Extracted fallback logic** - Centralized SQLite-vec fallback handling for better maintainability
3069 | - **Enhanced type safety** - Improved type hints throughout web interface components
3070 | - **Gemini Code Assistant feedback** - Addressed all code review suggestions for better robustness
3071 |
3072 | ### 🔗 **References**
3073 | - Closes #136: HTTP Dashboard doesn't use Cloudflare backend despite configuration
3074 | - PR #138: Complete universal storage backend support for HTTP dashboard
3075 |
3076 | ## [7.3.0] - 2025-10-02
3077 |
3078 | ### 🎉 **API Documentation Restoration**
3079 |
3080 | **Successfully restored comprehensive API documentation with interactive dashboard integration following PR #121.**
3081 |
3082 | ### ✅ **Key Features**
3083 |
3084 | #### 🔍 **Dual Interface Solution**
3085 | - **Dedicated `/api-overview` route** - Standalone comprehensive API documentation page
3086 | - **API Documentation tab** - Integrated dashboard tab for seamless user experience
3087 | - **Unified navigation** - Consistent access to API information across both interfaces
3088 |
3089 | #### ⚡ **Dynamic Content Loading**
3090 | - **Real-time version display** - Dynamic version loading via `/api/health/detailed` endpoint
3091 | - **Backend status integration** - Live backend information display
3092 | - **Enhanced user awareness** - Always shows current system state
3093 |
3094 | #### 📱 **Enhanced User Experience**
3095 | - **Responsive design** - Organized endpoint sections with mobile compatibility
3096 | - **Performance optimized** - CSS transitions optimized for better performance
3097 | - **Consistent navigation** - Fixed naming conflicts for seamless tab switching
3098 |
3099 | ### 🛠️ **Technical Improvements**
3100 |
3101 | #### 🔧 **API Consistency**
3102 | - **Fixed endpoint path documentation** - Updated from `{hash}` to `{content_hash}` for accuracy
3103 | - **Comprehensive endpoint coverage** - All API endpoints properly documented
3104 | - **Organized by functionality** - Logical grouping of endpoints for easy navigation
3105 |
3106 | #### 🎨 **Performance Optimization**
3107 | - **CSS performance** - Replaced `transition: all` with specific `border-color` and `box-shadow` transitions
3108 | - **Load time maintained** - 25ms page load performance preserved
3109 | - **Memory operation speed** - 26ms operation performance maintained
3110 |
3111 | ### 📊 **Restored Functionality**
3112 |
3113 | | Feature | Status | Notes |
3114 | |---------|--------|-------|
3115 | | API Overview Page | ✅ RESTORED | `/api-overview` route with full documentation |
3116 | | Dashboard Integration | ✅ NEW | API docs tab in interactive dashboard |
3117 | | Dynamic Content | ✅ ENHANCED | Real-time version and backend display |
3118 | | Mobile Responsive | ✅ MAINTAINED | CSS breakpoints preserved |
3119 | | Performance | ✅ OPTIMIZED | Enhanced CSS transitions |
3120 |
3121 | ### 🔄 **Architecture**
3122 |
3123 | #### **Dual Interface Implementation**
3124 | - **FastAPI Integration** - `get_api_overview_html()` function with embedded JavaScript
3125 | - **Dashboard Enhancement** - Additional navigation tab with organized content sections
3126 | - **Unified Styling** - Consistent CSS styling across both interfaces
3127 | - **Protocol Independence** - Works with both HTTP and MCP protocols
3128 |
3129 | ### 🎯 **User Impact**
3130 |
3131 | **Addresses critical missing functionality:**
3132 | - Restores API documentation that was missing after v7.2.2 interactive dashboard
3133 | - Provides both standalone and integrated access to API information
3134 | - Maintains excellent performance benchmarks while adding functionality
3135 | - Enhances developer experience with comprehensive endpoint documentation
3136 |
3137 | **This release ensures users have complete access to API documentation through multiple interfaces while preserving the performance excellence of the interactive dashboard.**
3138 |
3139 | ## [7.2.2] - 2025-09-30
3140 |
3141 | ### 🎉 **Interactive Dashboard Validation Complete**
3142 |
3143 | **Successfully completed comprehensive testing and validation of the Interactive Dashboard (PR #125).**
3144 |
3145 | ### ✅ **Validation Results**
3146 | - **Performance Excellence**: Page load 25ms (target: <2s), Memory operations 26ms (target: <1s)
3147 | - **Search Functionality**: Semantic search, tag-based search, and time-based search all working perfectly
3148 | - **Real-time Updates**: Server-Sent Events (SSE) with heartbeat and connection management validated
3149 | - **Security**: XSS protection via escapeHtml function properly implemented throughout frontend
3150 | - **OAuth Compatibility**: Both enabled and disabled OAuth modes tested and working
3151 | - **Mobile Responsive**: CSS breakpoints for mobile (768px) and tablet (1024px) verified
3152 | - **Large Dataset Performance**: Excellent performance tested with 994+ memories
3153 | - **Claude Desktop Integration**: MCP protocol compatibility confirmed
3154 |
3155 | ### 🚀 **Production Ready**
3156 | The Interactive Dashboard is now **fully validated and ready for production use**, providing:
3157 | - Complete memory CRUD operations
3158 | - Advanced search and filtering capabilities
3159 | - Real-time updates via Server-Sent Events
3160 | - Mobile-responsive design
3161 | - Security best practices
3162 | - Excellent performance with large datasets
3163 |
3164 | ### 📊 **Testing Metrics**
3165 | | Component | Target | Actual | Status |
3166 | |-----------|--------|--------|--------|
3167 | | Page Load | <2s | 25ms | ✅ EXCELLENT |
3168 | | Memory Ops | <1s | 26ms | ✅ EXCELLENT |
3169 | | Tag Search | <500ms | <100ms | ✅ EXCELLENT |
3170 | | Large Dataset | 1000+ | 994+ tested | ✅ EXCELLENT |
3171 |
3172 | **Issue #123 closed as completed. Dashboard provides immediate user value and solid foundation for future features.**
3173 |
3174 | ## [7.2.0] - 2025-09-30
3175 |
3176 | ### 🚀 **Major Performance: ChromaDB Optional Docker Optimization**
3177 |
3178 | **⚠️ BREAKING CHANGE**: ChromaDB is no longer installed by default to dramatically improve Docker build performance and reduce image sizes.
3179 |
3180 | ### 🎯 **Key Benefits**
3181 | - **70-80% faster Docker build times** (from ~10-15 min to ~2-3 min)
3182 | - **1-2GB smaller Docker images** (~2.5GB → ~800MB standard, ~400MB slim)
3183 | - **Lower memory footprint** in production deployments
3184 | - **Maintained backward compatibility** with clear opt-in mechanism
3185 |
3186 | ### 🔧 **Installation Changes**
3187 | ```bash
3188 | # Default installation (lightweight, sqlite_vec only)
3189 | python scripts/installation/install.py
3190 |
3191 | # With ChromaDB support (heavy dependencies)
3192 | python scripts/installation/install.py --with-chromadb
3193 |
3194 | # Docker builds automatically use optimized sqlite_vec backend
3195 | docker build -f tools/docker/Dockerfile -t mcp-memory-service:latest .
3196 | ```
3197 |
3198 | ### 📋 **What Changed**
3199 | - **pyproject.toml**: Added `full` optional dependency group, moved ChromaDB to optional
3200 | - **server.py**: Added conditional ChromaDB imports with graceful error handling
3201 | - **mcp_server.py**: Enhanced ChromaDB import error messages and fallback logic
3202 | - **install.py**: Added `--with-chromadb` flag for opt-in ChromaDB installation
3203 | - **README.md**: Updated storage backend documentation with ChromaDB optional notes
3204 | - **NEW**: `docs/docker-optimized-build.md` - Comprehensive Docker optimization guide
3205 |
3206 | ### 🛡️ **Migration Guide**
3207 | **For users who need ChromaDB:**
3208 | 1. Run: `python scripts/installation/install.py --with-chromadb`
3209 | 2. Or install manually: `pip install mcp-memory-service[chromadb]`
3210 |
3211 | **For Docker users:**
3212 | - No action needed - automatically get performance improvements
3213 | - Docker builds now default to optimized sqlite_vec backend
3214 |
3215 | ### 🧪 **Error Handling**
3216 | - Clear error messages when ChromaDB backend selected but not installed
3217 | - Graceful fallback to sqlite_vec when ChromaDB unavailable
3218 | - Helpful guidance on how to install ChromaDB if needed
3219 |
3220 | ### 📊 **Performance Comparison**
3221 | | Metric | Before | After | Improvement |
3222 | |--------|--------|-------|-------------|
3223 | | Docker build | ~10-15 min | ~2-3 min | **80% faster** |
3224 | | Image size | ~2.5GB | ~800MB | **68% smaller** |
3225 | | Memory usage | High | Low | **Significantly reduced** |
3226 |
3227 | ## [7.1.5] - 2025-09-29
3228 |
3229 | ### 🔧 **Improvements**
3230 |
3231 | - **Enhanced timestamp consistency across memory retrieval methods** - All memory retrieval endpoints now display consistent timestamp information:
3232 | - `retrieve_memory` now shows timestamps in "YYYY-MM-DD HH:MM:SS" format matching `recall_memory`
3233 | - `search_by_tag` now shows timestamps in same consistent format
3234 | - Improved code quality using `getattr` pattern instead of `hasattr` checks
3235 | - Resolves timestamp metadata inconsistency reported in issue #126
3236 |
3237 | - **Enhanced CLI hybrid backend support** - CLI commands now fully support hybrid storage backend:
3238 | - Added 'hybrid' option to `--storage-backend` choices for both `server` and `status` commands
3239 | - Completes hybrid backend integration across all system components
3240 | - Enables seamless CLI usage with hybrid SQLite-vec + Cloudflare architecture
3241 |
3242 | - **Hybrid storage backend server integration** - Server.py now fully supports hybrid backend operations:
3243 | - Added `sanitized` method to hybrid storage for tag handling compatibility
3244 | - Enhanced initialization and health check support for hybrid backend
3245 | - Maintains performance optimization with Cloudflare synchronization
3246 |
3247 | ### 🛡️ **Security Fixes**
3248 |
3249 | - **Credential exposure prevention** - Enhanced security measures to prevent accidental credential exposure:
3250 | - Improved handling of environment variables in logging and error messages
3251 | - Additional safeguards against sensitive configuration leakage
3252 | - Follows security best practices for credential management
3253 |
3254 | - **Resource leak fixes** - Memory and resource management improvements:
3255 | - Enhanced connection cleanup in storage backends
3256 | - Improved async resource handling to prevent leaks
3257 | - Better error recovery and cleanup procedures
3258 |
3259 | ### 🎯 **Code Quality**
3260 |
3261 | - **Implemented Gemini Code Assistant improvements** - Enhanced code maintainability and safety:
3262 | - Replaced `hasattr` + direct attribute access with safer `getattr(obj, "attr", None)` pattern
3263 | - Cleaner, more readable code with consistent error handling
3264 | - Improved null safety and defensive programming practices
3265 |
3266 | ## [7.1.4] - 2025-09-28
3267 |
3268 | ### 🚀 **Major Feature: Unified Cross-Platform Hook Installer**
3269 |
3270 | - **NEW: Single Python installer replaces 4+ platform-specific scripts**
3271 | - Consolidated `install.sh`, `install-natural-triggers.sh`, `install_claude_hooks_windows.bat` into unified `install_hooks.py`
3272 | - Full cross-platform compatibility (Windows, macOS, Linux)
3273 | - Intelligent JSON configuration merging preserves existing Claude Code hooks
3274 | - Dynamic path resolution eliminates hardcoded developer paths
3275 | - Atomic installations with automatic rollback on failure
3276 |
3277 | - **Enhanced Safety & User Experience**
3278 | - Smart settings.json merging prevents configuration loss
3279 | - Comprehensive backup system with timestamped restore points
3280 | - Empty directory cleanup for proper uninstall process
3281 | - Dry-run support for safe testing before installation
3282 | - Enhanced error handling with detailed user feedback
3283 |
3284 | - **Natural Memory Triggers v7.1.3 Integration**
3285 | - Advanced trigger detection with 85%+ accuracy
3286 | - Multi-tier performance optimization (50ms/150ms/500ms)
3287 | - Mid-conversation memory injection
3288 | - CLI management tools for real-time configuration
3289 | - Git-aware context and repository integration
3290 |
3291 | ### 🔧 **Installation Commands Updated**
3292 | ```bash
3293 | # New unified installation (replaces all previous methods)
3294 | cd claude-hooks
3295 | python install_hooks.py --natural-triggers # Recommended
3296 | python install_hooks.py --basic # Basic hooks only
3297 | python install_hooks.py --all # Everything
3298 |
3299 | # Integrated with main installer
3300 | python scripts/installation/install.py --install-natural-triggers
3301 | ```
3302 |
3303 | ### 📋 **Migration & Documentation**
3304 | - Added comprehensive `claude-hooks/MIGRATION.md` with transition guide
3305 | - Updated README.md installation instructions
3306 | - Legacy shell scripts removed (eliminates security and compatibility issues)
3307 | - Clear upgrade path for existing users
3308 |
3309 | ### 🛠 **Technical Improvements**
3310 | - Addressed all Gemini Code Assist review feedback
3311 | - Enhanced cross-platform path handling with proper quoting
3312 | - Improved integration between main installer and hook installer
3313 | - Professional CLI interface with consistent options across platforms
3314 |
3315 | ### ⚠️ **Breaking Changes**
3316 | - Legacy shell installers (`install.sh`, `install-natural-triggers.sh`) removed
3317 | - Installation commands updated - see `claude-hooks/MIGRATION.md` for details
3318 | - Users must switch to unified Python installer for future installations
3319 |
3320 | ## [7.1.3] - 2025-09-28
3321 |
3322 | ### 🚨 **SECURITY FIX**
3323 |
3324 | - **CRITICAL: Removed sensitive configuration files from repository** - Immediate security remediation:
3325 | - **Removed `.claude/settings.local.json*` files from git tracking and complete history**
3326 | - **Used `git filter-branch` to purge all sensitive data from repository history**
3327 | - **Force-pushed rewritten history to remove exposed API tokens and secrets**
3328 | - Added comprehensive `.gitignore` patterns for future protection
3329 | - **BREAKING: Repository history rewritten - force pull required for existing clones**
3330 | - **ACTION REQUIRED: Rotate any exposed Cloudflare API tokens immediately**
3331 | - Addresses critical security vulnerability from issues #118 and personal config exposure
3332 |
3333 | ### ⚠️ **Post-Security Actions Required**
3334 | 1. **Immediately rotate any Cloudflare API tokens** that were in the exposed files
3335 | 2. **Force pull** or re-clone repository: `git fetch origin && git reset --hard origin/develop`
3336 | 3. **Review local `.claude/settings.local.json`** files for any other sensitive data
3337 | 4. **Verify no sensitive data** remains in your local configurations
3338 |
3339 | ## [7.1.2] - 2025-09-28
3340 |
3341 | ### 🔧 **Improvements**
3342 |
3343 | - **Stop tracking personal Claude settings to prevent merge conflicts** - Added `.claude/settings.local.json*` patterns to `.gitignore`:
3344 | - Prevents future tracking of personal configuration files
3345 | - Uses `--skip-worktree` to ignore local changes to existing tracked files
3346 | - Protects user privacy and eliminates merge conflicts
3347 | - Preserves existing user configurations while fixing repository hygiene (Fixes #118)
3348 |
3349 | ## [7.1.1] - 2025-09-28
3350 |
3351 | ### 🐛 **Bug Fixes**
3352 |
3353 | - **Fixed misleading error message in document ingestion** - The `ingest_document` tool now provides accurate error messages:
3354 | - Shows "File not found" with full resolved path when files don't exist
3355 | - Only shows "Unsupported file format" for truly unsupported formats
3356 | - Includes list of supported formats (.md, .txt, .pdf, .json, .csv) in format errors
3357 | - Resolves issue where Markdown files were incorrectly reported as unsupported (Fixes #122)
3358 |
3359 | ## [7.1.0] - 2025-09-27
3360 |
3361 | ### 🧠 **Natural Memory Triggers for Claude Code**
3362 |
3363 | This release introduces **Natural Memory Triggers v7.1.0** - an intelligent memory awareness system that automatically detects when Claude should retrieve relevant memories from your development history.
3364 |
3365 | #### ✨ **New Features**
3366 |
3367 | ##### 🎯 **Intelligent Trigger Detection**
3368 | - **✅ Semantic Analysis** - Advanced natural language processing to understand memory-seeking patterns
3369 | - **Pattern Recognition**: Detects phrases like "What did we decide...", "How did we implement..."
3370 | - **Question Classification**: Identifies when user is seeking information from past work
3371 | - **Context Understanding**: Analyzes conversation flow and topic shifts
3372 | - **✅ Git-Aware Context** - Repository integration for enhanced relevance
3373 | - **Commit Analysis**: Extracts development themes from recent commit history
3374 | - **Changelog Integration**: Parses project changelogs for version-specific context
3375 | - **Development Keywords**: Builds search queries from git history and file patterns
3376 |
3377 | ##### ⚡ **Performance-Optimized Architecture**
3378 | - **✅ Multi-Tier Processing** - Three-tier performance system
3379 | - **Instant Tier** (< 50ms): Pattern matching and cache checks
3380 | - **Fast Tier** (< 150ms): Lightweight semantic analysis
3381 | - **Intensive Tier** (< 500ms): Deep semantic understanding
3382 | - **✅ Adaptive Performance Profiles**
3383 | - **Speed Focused**: Minimal latency, basic memory awareness
3384 | - **Balanced**: Optimal speed/context balance (recommended)
3385 | - **Memory Aware**: Maximum context awareness
3386 | - **Adaptive**: Machine learning-based optimization
3387 |
3388 | ##### 🎮 **CLI Management System**
3389 | - **✅ Memory Mode Controller** - Comprehensive command-line interface
3390 | - **Profile Switching**: `node memory-mode-controller.js profile balanced`
3391 | - **Sensitivity Control**: `node memory-mode-controller.js sensitivity 0.7`
3392 | - **Status Monitoring**: Real-time performance metrics and configuration display
3393 | - **System Management**: Enable/disable triggers, reset to defaults
3394 |
3395 | #### 🔧 **Technical Implementation**
3396 |
3397 | ##### **Core Components**
3398 | - **`claude-hooks/core/mid-conversation.js`** - Main hook implementation with stateful management
3399 | - **`claude-hooks/utilities/tiered-conversation-monitor.js`** - Multi-tier semantic analysis engine
3400 | - **`claude-hooks/utilities/performance-manager.js`** - Performance monitoring and adaptive optimization
3401 | - **`claude-hooks/utilities/git-analyzer.js`** - Git repository context analysis
3402 | - **`claude-hooks/memory-mode-controller.js`** - CLI controller for system management
3403 |
3404 | ##### **Smart Memory Scoring**
3405 | - **✅ Multi-Factor Relevance** - Sophisticated scoring algorithm
3406 | - **Content Relevance** (15%): Semantic similarity to current context
3407 | - **Tag Relevance** (35%): Project and topic-specific weighting
3408 | - **Time Decay** (25%): Recent memories weighted higher
3409 | - **Content Quality** (25%): Filters out low-value memories
3410 | - **✅ Conversation Context** - Session-aware analysis
3411 | - **Topic Tracking**: Maintains context window for semantic analysis
3412 | - **Pattern Detection**: Learns user preferences and conversation patterns
3413 | - **Confidence Thresholds**: Only triggers when confidence meets user-defined threshold
3414 |
3415 | #### 🧪 **Quality Assurance**
3416 |
3417 | ##### **Comprehensive Testing**
3418 | - **✅ Test Suite** - 18 automated tests covering all functionality
3419 | - **Configuration Management**: Nested JSON handling and validation
3420 | - **Performance Profiling**: Latency measurement and optimization
3421 | - **Semantic Analysis**: Pattern detection and confidence scoring
3422 | - **CLI Integration**: Command processing and state management
3423 | - **✅ Gemini Code Assist Integration** - AI-powered code review
3424 | - **Static Analysis**: Identified and fixed 21 code quality issues
3425 | - **Performance Optimization**: Division-by-zero prevention, cache management
3426 | - **Configuration Validation**: Duplicate key detection and consolidation
3427 |
3428 | #### 🔄 **Installation & Compatibility**
3429 |
3430 | ##### **Seamless Integration**
3431 | - **✅ Zero-Restart Installation** - Dynamic hook loading during Claude Code sessions
3432 | - **✅ Backward Compatibility** - Works alongside existing memory service functionality
3433 | - **✅ Configuration Preservation** - Maintains existing settings while adding new features
3434 | - **✅ Platform Support** - macOS, Windows, and Linux compatibility
3435 |
3436 | #### 📊 **Performance Metrics**
3437 |
3438 | ##### **Benchmarks**
3439 | - **Instant Analysis**: < 50ms response time for pattern matching
3440 | - **Fast Analysis**: < 150ms for lightweight semantic processing
3441 | - **Cache Performance**: < 5ms for cached results with LRU management
3442 | - **Memory Efficiency**: Automatic cleanup prevents memory bloat
3443 | - **Trigger Accuracy**: 85%+ confidence for memory-seeking pattern detection
3444 |
3445 | #### 🎯 **Usage Examples**
3446 |
3447 | Natural Memory Triggers automatically activate for phrases like:
3448 | - "What approach did we use for authentication?"
3449 | - "How did we handle error handling in this project?"
3450 | - "What were the main architectural decisions we made?"
3451 | - "Similar to what we implemented before..."
3452 | - "Remember when we discussed..."
3453 |
3454 | #### 📚 **Documentation**
3455 |
3456 | - **✅ Complete User Guide** - Comprehensive documentation at `claude-hooks/README-NATURAL-TRIGGERS.md`
3457 | - **✅ CLI Reference** - Detailed command documentation and usage examples
3458 | - **✅ Configuration Guide** - Performance profile explanations and optimization tips
3459 | - **✅ Troubleshooting** - Common issues and resolution steps
3460 |
3461 | ---
3462 |
3463 | ## [7.0.0] - 2025-09-27
3464 |
3465 | ### 🎉 **Major Release - OAuth 2.1 Dynamic Client Registration**
3466 |
3467 | This major release introduces comprehensive **OAuth 2.1 Dynamic Client Registration**, enabling **Claude Code HTTP transport** and **enterprise-grade authentication** while maintaining full backward compatibility with existing API key workflows.
3468 |
3469 | #### ✨ **New Features**
3470 |
3471 | ##### 🔐 **OAuth 2.1 Implementation**
3472 | - **✅ Dynamic Client Registration** - Complete RFC 7591 compliant implementation
3473 | - **Auto-Discovery**: `.well-known/oauth-authorization-server/mcp` endpoint for client auto-configuration
3474 | - **Runtime Registration**: Clients can register dynamically without manual setup
3475 | - **Standards Compliance**: Full OAuth 2.1 and RFC 8414 authorization server metadata
3476 | - **Security Best Practices**: HTTPS enforcement, secure redirect URI validation
3477 |
3478 | - **✅ JWT Authentication** - Modern token-based authentication
3479 | - **RS256 Signing**: RSA key pairs for enhanced security (with HS256 fallback)
3480 | - **Scope-Based Authorization**: Granular permissions (`read`, `write`, `admin`)
3481 | - **Token Validation**: Comprehensive JWT verification with proper error handling
3482 | - **Configurable Expiration**: Customizable token and authorization code lifetimes
3483 |
3484 | ##### 🚀 **Claude Code Integration**
3485 | - **✅ HTTP Transport Support** - Direct integration with Claude Code
3486 | - **Automatic Setup**: Claude Code discovers and registers OAuth client automatically
3487 | - **Team Collaboration**: Enables Claude Code team features via HTTP transport
3488 | - **Seamless Authentication**: JWT tokens handled transparently by client
3489 |
3490 | ##### 🛡️ **Enhanced Security Architecture**
3491 | - **✅ Multi-Method Authentication** - Flexible authentication options
3492 | - **OAuth Bearer Tokens**: Primary authentication method for modern clients
3493 | - **API Key Fallback**: Existing API key authentication preserved for backward compatibility
3494 | - **Anonymous Access**: Optional anonymous access with explicit opt-in (`MCP_ALLOW_ANONYMOUS_ACCESS`)
3495 |
3496 | - **✅ Production Security Features**
3497 | - **Thread-Safe Operations**: Async/await with proper locking mechanisms
3498 | - **Background Token Cleanup**: Automatic expiration and cleanup of tokens/codes
3499 | - **Security Validation**: Comprehensive startup validation with production warnings
3500 | - **Configuration Hardening**: HTTP transport warnings, key strength validation
3501 |
3502 | #### 🔧 **Technical Implementation**
3503 |
3504 | ##### **New OAuth Endpoints**
3505 | - **`/.well-known/oauth-authorization-server/mcp`** - OAuth server metadata discovery
3506 | - **`/.well-known/openid-configuration/mcp`** - OpenID Connect compatibility endpoint
3507 | - **`/oauth/register`** - Dynamic client registration endpoint
3508 | - **`/oauth/authorize`** - Authorization code flow endpoint
3509 | - **`/oauth/token`** - Token exchange endpoint (supports both `authorization_code` and `client_credentials` flows)
3510 |
3511 | ##### **Authentication Middleware**
3512 | - **✅ Unified Auth Handling**: Single middleware protecting all API endpoints
3513 | - **✅ Scope Validation**: Automatic scope checking for protected resources
3514 | - **✅ Graceful Fallback**: OAuth → API key → Anonymous (if enabled)
3515 | - **✅ Enhanced Error Messages**: Context-aware authentication error responses
3516 |
3517 | ##### **Configuration System**
3518 | - **✅ Environment Variables**: Comprehensive OAuth configuration options
3519 | ```bash
3520 | MCP_OAUTH_ENABLED=true # Enable/disable OAuth (default: true)
3521 | MCP_OAUTH_SECRET_KEY=<secure-key> # JWT signing key (auto-generated if not set)
3522 | MCP_OAUTH_ISSUER=<issuer-url> # OAuth issuer URL (auto-detected)
3523 | MCP_OAUTH_ACCESS_TOKEN_EXPIRE_MINUTES=60 # Token expiration (default: 60 minutes)
3524 | MCP_ALLOW_ANONYMOUS_ACCESS=false # Anonymous access (default: false)
3525 | ```
3526 |
3527 | #### 🔄 **Backward Compatibility**
3528 | - **✅ Zero Breaking Changes**: All existing API key workflows continue to work unchanged
3529 | - **✅ Optional OAuth**: OAuth can be completely disabled with `MCP_OAUTH_ENABLED=false`
3530 | - **✅ Graceful Coexistence**: API key and OAuth authentication work side-by-side
3531 | - **✅ Migration Path**: Existing users can adopt OAuth gradually or continue with API keys
3532 |
3533 | #### 📊 **Development & Quality Metrics**
3534 | - **✅ 17 Comprehensive Review Cycles** with Gemini Code Assist feedback integration
3535 | - **✅ All Security Issues Resolved** (critical, high, medium severity vulnerabilities addressed)
3536 | - **✅ Extensive Testing Suite**: New integration tests for OAuth flows and security scenarios
3537 | - **✅ Production Readiness**: Comprehensive validation, monitoring, and health checks
3538 |
3539 | #### 🚀 **Impact & Benefits**
3540 |
3541 | ##### **For Existing Users**
3542 | - **No Changes Required**: Continue using API key authentication without modification
3543 | - **Enhanced Security**: Option to upgrade to industry-standard OAuth when ready
3544 | - **Future-Proof**: Foundation for additional enterprise features
3545 |
3546 | ##### **For Claude Code Users**
3547 | - **Team Collaboration**: HTTP transport enables Claude Code team features
3548 | - **Automatic Setup**: Zero-configuration OAuth setup and token management
3549 | - **Enterprise Ready**: Standards-compliant authentication for organizational use
3550 |
3551 | ##### **For Enterprise Environments**
3552 | - **Standards Compliance**: Full OAuth 2.1 and RFC compliance for security audits
3553 | - **Centralized Auth**: Foundation for integration with existing identity providers
3554 | - **Audit Trail**: Comprehensive logging and token lifecycle management
3555 |
3556 | #### 🔜 **Future Enhancements**
3557 | This release provides the foundation for additional OAuth features:
3558 | - **Persistent Storage**: Production-ready client and token storage backends
3559 | - **PKCE Support**: Enhanced security for public clients
3560 | - **Refresh Tokens**: Long-lived authentication sessions
3561 | - **User Consent UI**: Interactive authorization flows
3562 | - **Identity Provider Integration**: SAML, OIDC, and enterprise SSO support
3563 |
3564 | #### 📚 **Documentation**
3565 | - **✅ Complete Setup Guide**: Step-by-step OAuth configuration documentation (`docs/oauth-setup.md`)
3566 | - **✅ API Reference**: Comprehensive endpoint documentation with examples
3567 | - **✅ Security Guide**: Production deployment best practices and security considerations
3568 | - **✅ Migration Guide**: Smooth transition path for existing users
3569 |
3570 | ---
3571 |
3572 | **This major release transforms the MCP Memory Service from a simple memory tool into an enterprise-ready service with standards-compliant authentication, enabling new use cases while preserving the simplicity that makes it valuable.**
3573 |
3574 | ## [6.23.0] - 2025-09-27
3575 |
3576 | ### 🎉 **Major Feature Release - Memory Management Enhancement**
3577 |
3578 | This release combines three major improvements: comprehensive memory management tools, enhanced documentation, and dependency standardization. All changes have been reviewed and approved by Gemini Code Assist with very positive feedback.
3579 |
3580 | #### ✨ **New Features**
3581 | - **🛠️ New `list_memories` MCP Tool** - Added paginated memory browsing with filtering capabilities
3582 | - ✅ **Pagination Support**: Page-based navigation (1-based indexing) with configurable page sizes (1-100)
3583 | - ✅ **Database-Level Filtering**: Filter by memory type and tags using efficient SQL queries
3584 | - ✅ **Performance Optimized**: Direct database filtering instead of Python-level post-processing
3585 | - ✅ **Consistent API**: Available in both MCP server and HTTP/REST endpoints
3586 |
3587 | #### 🚀 **Performance Improvements**
3588 | - **⚡ Database-Level Filtering** - Replaced inefficient Python-level filtering with SQL WHERE clauses
3589 | - ❌ **Previous**: Fetch all records → filter in Python → paginate (slow, memory-intensive)
3590 | - ✅ **Now**: Filter + paginate in database → return results (5ms response time)
3591 | - ✅ **Benefits**: Dramatically reduced memory usage and improved response times for large datasets
3592 | - ✅ **Backends**: Implemented across SQLite-vec, ChromaDB, Cloudflare, and Hybrid storage
3593 |
3594 | - **🔧 Enhanced Storage Interface** - Extended `get_all_memories()` with tags parameter
3595 | - ✅ **Tag Filtering**: Support for OR-based tag matching at database level
3596 | - ✅ **Backward Compatible**: All existing code continues to work unchanged
3597 | - ✅ **Consistent**: Same interface across all storage backends
3598 |
3599 | #### 🛡️ **Security Enhancements**
3600 | - **🔒 Eliminated Security Vulnerabilities** - Removed dangerous runtime dependency installation
3601 | - ❌ **Removed**: Automatic `pip install` execution in Docker containers
3602 | - ✅ **Security**: Prevents potential code injection and supply chain attacks
3603 | - ✅ **Reliability**: Dependencies now properly managed through container build process
3604 |
3605 | - **🔑 Fixed Hardcoded Credentials** - Replaced hardcoded API keys with environment variables
3606 | - ❌ **Previous**: API keys stored in plain text in debug scripts
3607 | - ✅ **Fixed**: All credentials now sourced from secure environment variables
3608 | - ✅ **Security**: Follows security best practices for credential management
3609 |
3610 | #### 📚 **Documentation Improvements**
3611 | - **📖 Comprehensive Documentation Suite** - Added professional documentation in `docs/mastery/`
3612 | - ✅ **API Reference**: Complete API documentation with examples
3613 | - ✅ **Architecture Overview**: Detailed system architecture documentation
3614 | - ✅ **Configuration Guide**: Comprehensive configuration management guide
3615 | - ✅ **Setup Instructions**: Step-by-step local setup and run guide
3616 | - ✅ **Testing Guide**: Testing strategies and debugging instructions
3617 | - ✅ **Troubleshooting**: Common issues and solutions
3618 |
3619 | - **🔧 Enhanced Development Resources** - Added advanced search and refactoring documentation
3620 | - ✅ **Search Enhancement Guide**: Advanced search capabilities and examples
3621 | - ✅ **Refactoring Summary**: Complete analysis of architectural changes
3622 | - ✅ **Integration Examples**: Multi-client setup for various AI platforms
3623 |
3624 | #### 🔧 **Infrastructure Improvements**
3625 | - **🐳 Docker Optimization** - Enhanced Docker configuration for production deployments
3626 | - ✅ **Security Updates**: Updated base images and security patches
3627 | - ✅ **Performance**: Optimized container size and startup time
3628 | - ✅ **Flexibility**: Better support for different deployment scenarios
3629 |
3630 | - **📦 Dependency Management** - Standardized and improved dependency handling
3631 | - ✅ **ChromaDB Compatibility**: Restored ChromaDB as optional dependency for backward compatibility
3632 | - ✅ **Updated Dependencies**: Updated PyPDF2 → pypdf2 for better maintenance
3633 | - ✅ **Optional Dependencies**: Clean separation of core vs optional features
3634 |
3635 | #### 🪟 **Platform Support**
3636 | - **💻 Enhanced Windows Support** - Added comprehensive Windows debugging capabilities
3637 | - ✅ **Debug Script**: New `start_http_debug.bat` for Windows HTTP mode testing
3638 | - ✅ **103 Lines Added**: Comprehensive Windows debugging and troubleshooting support
3639 | - ✅ **Environment Variables**: Proper Windows environment variable handling
3640 |
3641 | #### 🧹 **Code Quality**
3642 | - **♻️ Major Refactoring** - Removed redundant functionality while maintaining compatibility
3643 | - ✅ **317 Lines Removed**: Eliminated duplicate `search_by_time` and `search_similar` tools
3644 | - ✅ **Functional Redundancy**: Removed tools that exactly duplicated existing functionality
3645 | - ✅ **API Consolidation**: Streamlined API surface while preserving all capabilities
3646 | - ✅ **Performance**: Reduced codebase complexity without losing features
3647 |
3648 | #### 🤖 **AI Code Review Integration**
3649 | - **✅ Gemini Code Assist Approved** - All changes reviewed and approved with very positive feedback
3650 | - ✅ **Architecture Review**: Praised database-level filtering implementation
3651 | - ✅ **Security Review**: Confirmed elimination of security vulnerabilities
3652 | - ✅ **Performance Review**: Validated performance optimization approach
3653 | - ✅ **Code Quality**: Approved refactoring and redundancy removal
3654 |
3655 | #### 📋 **Migration Notes**
3656 | - **🔄 Backward Compatibility**: All existing integrations continue to work unchanged
3657 | - **📦 Optional Dependencies**: ChromaDB users should install with `pip install mcp-memory-service[chromadb]`
3658 | - **🛠️ New Tools**: The `list_memories` tool is automatically available to all MCP clients
3659 | - **⚠️ Removed Tools**: `search_by_time` and `search_similar` tools have been removed (functionality available through existing tools)
3660 |
3661 | #### 💡 **Usage Examples**
3662 | ```python
3663 | # New list_memories tool with filtering
3664 | await list_memories(page=1, page_size=20, tag="important", memory_type="note")
3665 |
3666 | # Database-level tag filtering (improved performance)
3667 | memories = await storage.get_all_memories(limit=50, tags=["work", "project"])
3668 |
3669 | # Enhanced pagination with type filtering
3670 | memories = await storage.get_all_memories(
3671 | limit=10, offset=20, memory_type="decision", tags=["urgent"]
3672 | )
3673 | ```
3674 |
3675 | ---
3676 |
3677 | ## [6.22.1] - 2025-09-26
3678 |
3679 | ### 🔧 **Dashboard Statistics Fix**
3680 |
3681 | #### Bug Fixes
3682 | - **🎯 Backend-Agnostic Dashboard Stats** - Fixed `dashboard_get_stats` to use configured storage backend instead of hardcoded ChromaDB
3683 | - ❌ **Previous Issue**: Dashboard always showed ChromaDB stats (often 0 memories) regardless of actual backend
3684 | - ✅ **Fixed**: Now properly detects and uses SQLite-vec, Cloudflare, or ChromaDB based on configuration
3685 | - ✅ **Consistency**: Uses same pattern as `handle_check_database_health` for reliable backend detection
3686 | - ✅ **Accuracy**: Dashboard now shows correct memory counts and backend information
3687 |
3688 | #### Technical Improvements
3689 | - **Backend Detection**: Dynamic storage type detection via `storage.__class__.__name__`
3690 | - **Error Handling**: Proper async/await handling and graceful error reporting
3691 | - **Code Consistency**: Unified approach with existing health check functionality
3692 |
3693 | ---
3694 |
3695 | **Resolves**: GitHub Issue where dashboard stats were incorrectly hardcoded to ChromaDB
3696 | **Credit**: Thanks to @MichaelPaulukonis for identifying and fixing this backend detection issue
3697 |
3698 | ---
3699 |
3700 | ## [6.22.0] - 2024-09-25
3701 |
3702 | ### 🎯 **Chronological Ordering & Performance Improvements**
3703 |
3704 | #### Major API Enhancements
3705 | - **🌟 Chronological Memory Ordering** - `/api/memories` endpoint now returns memories in chronological order (newest first)
3706 | - ✅ **Improved User Experience**: More intuitive memory browsing with recent memories prioritized
3707 | - ✅ **Consistent Across All Backends**: SQLite-vec, ChromaDB, Cloudflare D1, and Hybrid
3708 | - ✅ **Proper Pagination Support**: Server-side sorting with efficient limit/offset handling
3709 | - ✅ **Backward Compatible**: Same API interface with enhanced ordering
3710 |
3711 | #### Critical Performance Fixes 🚀
3712 | - **⚡ Storage-Layer Memory Type Filtering** - Addressed critical performance bottleneck
3713 | - ❌ **Previous Issue**: API loaded ALL memories into application memory when filtering by `memory_type`
3714 | - ✅ **Fixed**: Efficient storage-layer filtering with SQL WHERE clauses
3715 | - ✅ **Performance Impact**: 16.5% improvement in filtering operations
3716 | - ✅ **Scalability**: Prevents service instability with large datasets (1000+ memories)
3717 | - **Enhanced Storage Interface**
3718 | - Added `memory_type` parameter to `get_all_memories()` and `count_all_memories()` methods
3719 | - Implemented across all backends: SQLite-vec, ChromaDB, Cloudflare D1, Hybrid
3720 | - Maintains chronological ordering while applying efficient filters
3721 |
3722 | #### Code Quality Improvements
3723 | - **🔧 ChromaDB Code Refactoring** - Eliminated code duplication
3724 | - Created `_create_memory_from_results()` helper method
3725 | - Consolidated 5 duplicate Memory object creation patterns
3726 | - Enhanced maintainability and consistency across ChromaDB operations
3727 | - **Comprehensive Test Suite**
3728 | - Added 10 new test cases specifically for chronological ordering
3729 | - Covers edge cases: empty storage, large offsets, mixed timestamps
3730 | - Validates API endpoint behavior and storage backend compatibility
3731 |
3732 | #### Backend-Specific Optimizations
3733 | - **SQLite-vec**: Efficient `ORDER BY created_at DESC` with parameterized WHERE clauses
3734 | - **ChromaDB**: Client-side sorting with performance warnings for large datasets (>1000 memories)
3735 | - **Cloudflare D1**: Server-side SQL sorting and filtering for optimal performance
3736 | - **Hybrid**: Delegates to primary storage (SQLite-vec) for consistent performance
3737 |
3738 | #### Developer Experience
3739 | - Enhanced error handling and logging for filtering operations
3740 | - Improved API response consistency across all storage backends
3741 | - Better performance monitoring and debugging capabilities
3742 |
3743 | ---
3744 |
3745 | **Resolves**: GitHub Issue #79 - Implement chronological ordering for /api/memories endpoint
3746 | **Addresses**: Gemini Code Assist performance and maintainability feedback
3747 |
3748 | ---
3749 |
3750 | ## [6.21.0] - 2024-09-25
3751 |
3752 | ### 🚀 **Hybrid Storage Backend - Performance Revolution**
3753 |
3754 | #### Major New Features
3755 | - **🌟 Revolutionary Hybrid Storage Backend** - Combines the best of both worlds:
3756 | - ✅ **SQLite-vec Performance**: ~5ms reads/writes (10-100x faster than Cloudflare-only)
3757 | - ✅ **Cloudflare Persistence**: Multi-device synchronization and cloud backup
3758 | - ✅ **Zero User-Facing Latency**: All operations hit SQLite-vec first, background sync to cloud
3759 | - ✅ **Intelligent Write-Through Cache**: Instant response with async cloud synchronization
3760 |
3761 | #### Enhanced Architecture & Performance
3762 | - **Background Synchronization Service**
3763 | - Async queue with intelligent retry logic and exponential backoff
3764 | - Concurrent sync operations with configurable batch processing
3765 | - Real-time health monitoring and capacity tracking
3766 | - Graceful degradation when cloud services are unavailable
3767 | - **Advanced Error Handling**
3768 | - Intelligent error categorization (temporary vs permanent vs limit errors)
3769 | - Automatic retry for network/temporary issues
3770 | - No-retry policy for hard limits (prevents infinite loops)
3771 | - Comprehensive logging with error classification
3772 |
3773 | #### Cloudflare Limit Protection & Monitoring 🛡️
3774 | - **Pre-Sync Validation**
3775 | - Metadata size validation (10KB limit per vector)
3776 | - Vector count monitoring (5M vector limit)
3777 | - Automatic capacity checks before sync operations
3778 | - **Real-Time Capacity Monitoring**
3779 | - Usage percentage tracking with warning thresholds
3780 | - Critical alerts at 95% capacity, warnings at 80%
3781 | - Proactive limit detection and graceful handling
3782 | - **Enhanced Limit Error Handling**
3783 | - Detection of 413, 507, and quota exceeded responses
3784 | - Automatic capacity status updates on limit errors
3785 | - Permanent failure classification for hard limits
3786 |
3787 | #### Configuration & Deployment
3788 | - **Simple Setup**: Just set `MCP_MEMORY_STORAGE_BACKEND=hybrid` + Cloudflare credentials
3789 | - **Advanced Tuning Options**:
3790 | - `MCP_HYBRID_SYNC_INTERVAL`: Background sync frequency (default: 300s)
3791 | - `MCP_HYBRID_BATCH_SIZE`: Sync batch size (default: 50)
3792 | - `MCP_HYBRID_MAX_QUEUE_SIZE`: Queue capacity (default: 1000)
3793 | - Health check intervals and retry configurations
3794 |
3795 | #### Benefits
3796 | - **For Users**:
3797 | - Instant memory operations (no more waiting for cloud responses)
3798 | - Reliable offline functionality with automatic sync when online
3799 | - Seamless multi-device access to memories
3800 | - **For Production**:
3801 | - Handles Cloudflare's strict limits intelligently
3802 | - Robust error recovery and monitoring
3803 | - Scales from single-user to enterprise deployments
3804 |
3805 | ### 🧪 **Comprehensive Testing & Validation**
3806 | - **347 lines of Cloudflare limit testing** (`tests/test_hybrid_cloudflare_limits.py`)
3807 | - **Performance characteristic validation**
3808 | - **Background sync verification scripts**
3809 | - **Live testing utilities for production validation**
3810 |
3811 | ### 📖 **Documentation & Setup**
3812 | - **CLAUDE.md**: Hybrid marked as **RECOMMENDED** default for new installations
3813 | - **Installation Script Updates**: Interactive hybrid backend selection
3814 | - **Configuration Validation**: Enhanced diagnostic tools for setup verification
3815 |
3816 | **🎯 Recommendation**: This should become the **default backend for all new installations** due to its superior performance and reliability characteristics.
3817 |
3818 | ## [6.20.1] - 2024-09-24
3819 |
3820 | ### 🐛 **Critical Bug Fixes**
3821 |
3822 | #### SQLite-vec Backend Regression Fix
3823 | - **Fixed MCP Server Initialization**: Corrected critical regression that prevented sqlite_vec backend from working
3824 | - ✅ Fixed class name mismatch: `SqliteVecStorage` → `SqliteVecMemoryStorage`
3825 | - ✅ Fixed constructor parameters: Updated to use correct `db_path` and `embedding_model` parameters
3826 | - ✅ Fixed database path: Use `SQLITE_VEC_PATH` instead of incorrect ChromaDB path
3827 | - ✅ Added missing imports: `SQLITE_VEC_PATH` and `EMBEDDING_MODEL_NAME` from config
3828 | - ✅ Code quality improvements: Added `_get_sqlite_vec_storage()` helper function to reduce duplication
3829 |
3830 | #### Impact
3831 | - **Restores Default Backend**: sqlite_vec backend (default) now works correctly with MCP server
3832 | - **Fixes Memory Operations**: Resolves "No embedding model available" errors during memory operations
3833 | - **Claude Desktop Integration**: Enables proper memory storage and retrieval functionality
3834 | - **Embedding Support**: Ensures embedding model loads and generates embeddings successfully
3835 |
3836 | Thanks to @ergut for identifying and fixing this critical regression!
3837 |
3838 | ## [6.20.0] - 2024-09-24
3839 |
3840 | ### 🚀 **Claude Code Dual Protocol Memory Hooks**
3841 |
3842 | #### Major New Features
3843 | - **Dual Protocol Memory Hook Support** - Revolutionary enhancement to Claude Code memory hooks
3844 | - ✅ **HTTP Protocol Support**: Full compatibility with web-based memory services at `https://localhost:8443`
3845 | - ✅ **MCP Protocol Support**: Direct integration with MCP server processes via `uv run memory server`
3846 | - ✅ **Smart Auto-Detection**: Automatically selects best available protocol (MCP preferred, HTTP fallback)
3847 | - ✅ **Graceful Fallback Chain**: MCP → HTTP → Environment-based storage detection
3848 | - ✅ **Protocol Flexibility**: Choose specific protocols (`http`, `mcp`) or auto-selection (`auto`)
3849 |
3850 | #### Enhanced Architecture
3851 | - **Unified MemoryClient Class** (`claude-hooks/utilities/memory-client.js`)
3852 | - Transparent protocol switching with single interface
3853 | - Connection pooling and error recovery
3854 | - Protocol-specific optimizations (MCP direct communication, HTTP REST API)
3855 | - Comprehensive error handling and timeout management
3856 | - **Enhanced Configuration System** (`claude-hooks/config.json`)
3857 | - Protocol-specific settings (HTTP endpoint/API keys, MCP server commands)
3858 | - Configurable fallback behavior and connection timeouts
3859 | - Backward compatibility with existing configurations
3860 |
3861 | #### Reliability Improvements
3862 | - **Multi-Protocol Resilience**: Hooks work across diverse deployment scenarios
3863 | - Local development (MCP direct), production servers (HTTP), hybrid setups
3864 | - Network connectivity issues gracefully handled
3865 | - Service unavailability doesn't break git analysis or project detection
3866 | - **Enhanced Error Handling**: Clear protocol-specific error messages and fallback reporting
3867 | - **Connection Management**: Proper cleanup and resource management for both protocols
3868 |
3869 | #### Developer Experience
3870 | - **Comprehensive Testing Suite** (`claude-hooks/test-dual-protocol-hook.js`)
3871 | - Tests all protocol combinations: auto-MCP-preferred, auto-HTTP-preferred, MCP-only, HTTP-only
3872 | - Validates protocol detection, fallback behavior, and error handling
3873 | - Demonstrates graceful degradation capabilities
3874 | - **Backward Compatibility**: Existing hook configurations continue working unchanged
3875 | - **Enhanced Debugging**: Protocol selection and connection status clearly reported
3876 |
3877 | #### Technical Implementation
3878 | - **Protocol Abstraction Layer**: Single interface for memory operations regardless of protocol
3879 | - **Smart Connection Logic**: Connection attempts with timeouts, fallback sequencing
3880 | - **Memory Query Unification**: Semantic search, time-based queries work identically across protocols
3881 | - **Storage Backend Detection**: Enhanced parsing for both HTTP JSON responses and MCP tool output
3882 |
3883 | #### Benefits for Different Use Cases
3884 | - **Claude Desktop Users**: Better reliability with HTTP fallback when MCP struggles
3885 | - **VS Code Extension Users**: Optimized for HTTP-based deployments
3886 | - **CI/CD Systems**: More robust memory operations in automated environments
3887 | - **Development Workflows**: Local MCP for speed, HTTP for production consistency
3888 |
3889 | ## [6.19.0] - 2024-09-24
3890 |
3891 | ### 🔧 **Configuration Validation Scripts Consolidation**
3892 |
3893 | #### Improvements
3894 | - **Consolidated validation scripts** - Merged `validate_config.py` and `validate_configuration.py` into comprehensive `validate_configuration_complete.py`
3895 | - ✅ Multi-platform support (Windows/macOS/Linux)
3896 | - ✅ All configuration sources validation (.env, Claude Desktop, Claude Code)
3897 | - ✅ Cross-configuration consistency checking
3898 | - ✅ Enhanced API token validation with known invalid token detection
3899 | - ✅ Improved error reporting and recommendations
3900 | - ✅ Windows console compatibility (no Unicode issues)
3901 |
3902 | #### Removed
3903 | - ❌ **Deprecated scripts**: `validate_config.py` and `validate_configuration.py` (redundant)
3904 |
3905 | #### Fixed
3906 | - **Cloudflare Backend Critical Issue**: Implemented missing `recall` method in CloudflareStorage class
3907 | - ✅ Dual search strategy (semantic + time-based)
3908 | - ✅ Graceful fallback mechanism
3909 | - ✅ Comprehensive error handling
3910 | - ✅ Time filtering support
3911 |
3912 | #### Documentation Updates
3913 | - **Updated all documentation references** to use new consolidated validation script
3914 | - **Created comprehensive API token setup guide** (`docs/troubleshooting/cloudflare-api-token-setup.md`)
3915 |
3916 | ## [6.18.0] - 2025-09-23
3917 |
3918 | ### 🚀 **Cloudflare Dual-Environment Configuration Suite**
3919 |
3920 | #### New Diagnostic Tools
3921 | - **Added comprehensive backend configuration diagnostic script** (`scripts/validation/diagnose_backend_config.py`)
3922 | - Environment file validation with masked sensitive data display
3923 | - Environment variable loading verification with dotenv support
3924 | - Configuration module import testing with clear error reporting
3925 | - Storage backend creation testing with full traceback on failures
3926 | - Status indicators with clear success/warning/error messaging
3927 | - **Enhanced troubleshooting workflow** with step-by-step validation process
3928 |
3929 | #### Documentation Improvements
3930 | - **Created streamlined 5-minute setup guide** (`docs/quick-setup-cloudflare-dual-environment.md`)
3931 | - Comprehensive dual-environment configuration for Claude Desktop + Claude Code
3932 | - Configuration templates with explicit environment variable examples
3933 | - Validation commands with expected health check results
3934 | - Troubleshooting section for common configuration issues
3935 | - Migration guide from SQLite-vec to Cloudflare backend
3936 | - **Fixed incorrect CLAUDE.md documentation** that suggested SQLite-vec as "expected behavior"
3937 | - **Added configuration management best practices** with environment variable precedence
3938 | - **Enhanced troubleshooting sections** with specific solutions for environment variable loading issues
3939 |
3940 | #### Configuration Enhancements
3941 | - **Improved environment variable loading reliability** with explicit MCP server configuration
3942 | - **Added execution context guidance** for different environments (Claude Desktop vs Claude Code)
3943 | - **Enhanced working directory awareness** for proper .env file loading
3944 | - **Better configuration validation** with clear error messages for missing required variables
3945 |
3946 | #### Technical Improvements
3947 | - **Unified diagnostic approach** for both Cloudflare and SQLite-vec backends
3948 | - **Enhanced error reporting** with masked sensitive data for security
3949 | - **Improved configuration precedence handling** between global and project settings
3950 | - **Better cross-platform path handling** for Windows environments
3951 |
3952 | #### Benefits for Users
3953 | - **Eliminates configuration confusion** between different execution environments
3954 | - **Provides clear validation tools** to quickly identify and resolve setup issues
3955 | - **Ensures consistent backend usage** across Claude Desktop and Claude Code
3956 | - **Streamlines Cloudflare backend adoption** with comprehensive setup guidance
3957 | - **Reduces setup time** from complex debugging to 5-minute guided process
3958 |
3959 | ## [6.17.2] - 2025-09-23
3960 |
3961 | ### 🔧 **Development Environment Stability Fix**
3962 |
3963 | #### Module Isolation Improvements
3964 | - **Enhanced script module loading** in `scripts/server/run_memory_server.py` to prevent version conflicts
3965 | - **Added module cache clearing** to remove conflicting cached imports before loading local development code
3966 | - **Improved path prioritization** to ensure local `src/` directory takes precedence over installed packages
3967 | - **Better logging** shows exactly which modules are being cleared and paths being added for debugging
3968 |
3969 | #### Technical Improvements
3970 | - **Prevents import conflicts** between development code and installed package versions
3971 | - **Ensures consistent behavior** when switching between development and production environments
3972 | - **Fixes version mismatch issues** that could cause `ImportError` for missing attributes like `INCLUDE_HOSTNAME`
3973 | - **More robust script execution** with conditional path management based on environment
3974 |
3975 | #### Benefits for Developers
3976 | - **Reliable development environment** - Local changes always take precedence
3977 | - **Easier debugging** - Clear logging of module loading process
3978 | - **Consistent Cloudflare backend** - No more fallback to ChromaDB due to version conflicts
3979 | - **Zero breaking changes** - Maintains compatibility with all existing configurations
3980 |
3981 | ## [6.17.1] - 2025-09-23
3982 |
3983 | ### 🔧 **Script Reorganization Compatibility Hotfix**
3984 |
3985 | #### Backward Compatibility Added
3986 | - **Added compatibility stub** at `scripts/run_memory_server.py` that redirects to new location with helpful migration notices
3987 | - **Updated configuration templates** to use Python module approach as primary method for maximum stability
3988 | - **Added comprehensive migration documentation** for users updating from pre-v6.17.0 versions
3989 | - **Zero disruption approach**: Existing configurations continue working immediately
3990 |
3991 | #### Recommended Launch Methods (in order of stability)
3992 | 1. **`python -m mcp_memory_service.server`** - Most stable, no path dependencies, works across all reorganizations
3993 | 2. **`uv run memory server`** - Integrated with UV tooling, already documented as preferred
3994 | 3. **`scripts/server/run_memory_server.py`** - Direct script execution at new location
3995 | 4. **`scripts/run_memory_server.py`** - Legacy location with backward compatibility (shows migration notice)
3996 |
3997 | #### Documentation Improvements
3998 | - **Enhanced README**: Clear migration notice with multiple working options
3999 | - **Updated examples**: Python module approach as primary recommendation
4000 | - **Migration guide**: Created comprehensive GitHub issue ([#108](https://github.com/doobidoo/mcp-memory-service/issues/108)) with all approaches
4001 | - **Template updates**: Configuration templates now show most stable approaches first
4002 |
4003 | #### Why This Approach
4004 | - **Immediate relief**: No users are blocked during v6.17.0 update
4005 | - **Multiple pathways**: Users can choose the approach that fits their setup
4006 | - **Future-proof**: Python module approach survives any future directory changes
4007 | - **Clear migration path**: Informational notices guide users to better practices without forcing changes
4008 |
4009 | ## [6.17.0] - 2025-09-22
4010 |
4011 | ### 🚀 **Enhanced Installer with Cloudflare Backend Support**
4012 |
4013 | #### Major Installer Improvements
4014 | - **Added Cloudflare backend to installer**: Full support for cloud-first installation workflow
4015 | - **Interactive credential setup**: Guided collection of API token, Account ID, D1 database, and Vectorize index
4016 | - **Automatic .env generation**: Securely saves credentials to project environment file
4017 | - **Connection testing**: Validates Cloudflare API during installation process
4018 | - **Graceful fallbacks**: Falls back to local backends if cloud setup fails
4019 | - **Enhanced backend selection logic**: Usage-based recommendations for optimal backend choice
4020 | - **Production scenarios**: Cloudflare for shared access and cloud storage
4021 | - **Development scenarios**: SQLite-vec for single-user, lightweight setup
4022 | - **Team scenarios**: ChromaDB for multi-client local collaboration
4023 | - **Improved CLI options**: Updated `--storage-backend` with clear use case descriptions
4024 | - **New choices**: `cloudflare` (production), `sqlite_vec` (development), `chromadb` (team), `auto_detect`
4025 | - **Better help text**: Explains when to use each backend option
4026 |
4027 | #### User Experience Enhancements
4028 | - **Interactive backend selection**: Guided setup with compatibility analysis and recommendations
4029 | - **Clear usage guidance**: Backend selection now includes use case scenarios and performance characteristics
4030 | - **Enhanced auto-detection**: Prioritizes most reliable backends for the detected system
4031 | - **Comprehensive documentation**: Updated installation commands and backend comparison table
4032 |
4033 | #### Technical Improvements
4034 | - **Robust error handling**: Comprehensive fallback mechanisms for failed setups
4035 | - **Modular design**: Separate functions for credential collection, validation, and environment setup
4036 | - **Connection validation**: Real-time API testing during Cloudflare backend configuration
4037 | - **Environment file management**: Smart .env file handling that preserves existing settings
4038 |
4039 | #### Benefits for Users
4040 | - **Seamless production setup**: Single command path from installation to Cloudflare backend
4041 | - **Reduced configuration errors**: Automated credential setup eliminates manual .env file creation
4042 | - **Better backend choice**: Clear guidance helps users select optimal storage for their use case
4043 | - **Improved reliability**: Fallback mechanisms ensure installation succeeds even with setup issues
4044 |
4045 | ## [6.16.1] - 2025-09-22
4046 |
4047 | ### 🔧 **Docker Build Hotfix**
4048 |
4049 | #### Infrastructure Fix
4050 | - **Fixed Docker build failure**: Updated Dockerfile script path after v6.15.0 scripts reorganization
4051 | - **Issue**: Docker build failing due to `scripts/install_uv.py` not found
4052 | - **Solution**: Updated path to `scripts/installation/install_uv.py`
4053 | - **Impact**: Restores automated Docker publishing workflows
4054 | - **No functional changes**: Pure infrastructure fix for CI/CD
4055 |
4056 | ## [6.16.0] - 2025-09-22
4057 |
4058 | ### 🔧 **Configuration Management & Backend Selection Fixes**
4059 |
4060 | #### Critical Configuration Issues Resolved
4061 | - **Fixed Cloudflare backend fallback issue**: Resolved service falling back to SQLite-vec despite correct Cloudflare configuration
4062 | - **Root cause**: Configuration module wasn't loading `.env` file automatically
4063 | - **CLI override issue**: CLI default parameter was overriding environment variables
4064 | - **Solution**: Added automatic `.env` loading and fixed CLI parameter precedence
4065 | - **Enhanced environment loading**: Added `load_dotenv()` to configuration initialization
4066 | - **Automatic detection**: Config module now automatically loads `.env` file when present
4067 | - **Backward compatibility**: Graceful fallback if python-dotenv not available
4068 | - **Logging**: Added confirmation logging when environment file is loaded
4069 | - **Fixed CLI parameter precedence**: Changed CLI defaults to respect environment configuration
4070 | - **Server command**: Changed `--storage-backend` default from `'sqlite_vec'` to `None`
4071 | - **Environment priority**: Environment variables now take precedence over CLI defaults
4072 | - **Explicit overrides**: CLI parameters only override when explicitly provided
4073 |
4074 | #### Content Size Management Improvements
4075 | - **Added Cloudflare content limits to context provider**: Enhanced memory management guidance
4076 | - **Content size warnings**: Added ~1500 character limit documentation
4077 | - **Embedding model constraints**: Documented `@cf/baai/bge-base-en-v1.5` strict input limits
4078 | - **Best practices**: Guidance for chunking large content and using document ingestion
4079 | - **Error recognition**: Help identifying "Failed to store vector" errors from size issues
4080 | - **Enhanced troubleshooting**: Better error messages and debugging capabilities for configuration issues
4081 |
4082 | #### Technical Improvements
4083 | - **Configuration validation**: Improved environment variable loading and validation
4084 | - **Error handling**: Better error messages when storage backend initialization fails
4085 | - **Documentation**: Updated context provider with Cloudflare-specific constraints and best practices
4086 |
4087 | #### Benefits for Users
4088 | - **Seamless backend switching**: Cloudflare configuration now works reliably out of the box
4089 | - **Fewer configuration errors**: Automatic environment loading reduces setup friction
4090 | - **Better error diagnosis**: Clear guidance on content size limits and chunking strategies
4091 | - **Improved reliability**: Configuration precedence issues eliminated
4092 |
4093 |
4094 | ---
4095 |
4096 | ## Historic Releases
4097 |
4098 | For older releases (v6.15.1 and earlier), see [CHANGELOG-HISTORIC.md](./CHANGELOG-HISTORIC.md).
4099 |
4100 | **Historic Version Range**: v0.1.0 through v6.15.1 (2025-07-XX through 2025-09-22)
4101 | ## [6.15.1] - 2025-09-22
4102 |
4103 | ### 🔧 **Enhanced Cloudflare Backend Initialization & Diagnostics**
4104 |
4105 | #### Cloudflare Backend Issue Resolution
4106 | - **Fixed silent fallback issue**: Resolved Cloudflare backend falling back to SQLite-vec during MCP startup
4107 | - **Root cause identified**: Silent failures in eager initialization phase were not properly logged
4108 | - **Enhanced error reporting**: Added comprehensive logging with visual indicators for all initialization phases
4109 | - **Improved timeout handling**: Better error messages when Cloudflare initialization times out
4110 | - **Enhanced initialization logging**: Added detailed logging for both eager and lazy initialization paths
4111 | - **Phase indicators**: 🚀 SERVER INIT, ☁️ Cloudflare-specific, ✅ Success markers, ❌ Error indicators
4112 | - **Configuration validation**: Logs all Cloudflare environment variables for troubleshooting
4113 | - **Storage type verification**: Confirms final storage backend type after initialization
4114 | - **Diagnostic improvements**: Created comprehensive diagnostic tools for Cloudflare backend issues
4115 | - **Enhanced diagnostic script**: `debug_server_initialization.py` for testing initialization flows
4116 | - **MCP environment testing**: `tests/integration/test_mcp_environment.py` for testing Claude Desktop integration
4117 | - **Fixed test syntax errors**: Corrected f-string and async function issues in test files
4118 |
4119 | #### Technical Improvements
4120 | - **Fixed `db_utils.py` async issue**: Changed `get_database_stats()` to async function to support Cloudflare storage
4121 | - **Enhanced error tracebacks**: Full exception details now logged for initialization failures
4122 | - **Better fallback documentation**: Clear distinction between eager vs lazy initialization behaviors
4123 |
4124 | #### Troubleshooting Benefits
4125 | - **Faster issue diagnosis**: Clear visual indicators help identify where initialization fails
4126 | - **Better error messages**: Specific error details for common Cloudflare setup issues
4127 | - **Proactive debugging**: Enhanced logging appears in Claude Desktop MCP logs for easier troubleshooting
4128 |
4129 | ## [6.15.0] - 2025-09-22
4130 |
4131 | ### 🗂️ **Scripts Directory Reorganization & Professional Tooling**
4132 |
4133 | #### Major Reorganization
4134 | - **Complete Scripts Restructuring**:
4135 | - ✅ **Organized 62 loose scripts** into 12 logical categories for professional navigation
4136 | - ✅ **Created systematic directory structure** with clear functional grouping
4137 | - ✅ **Zero loose scripts remaining** in root directory - all properly categorized
4138 | - ✅ **Maintained full backward compatibility** - all scripts work exactly as before
4139 | - ✅ **Updated all documentation references** to reflect new paths
4140 |
4141 | #### New Directory Structure
4142 | - **🔄 `sync/`** (4 scripts) - Backend synchronization utilities
4143 | - **🛠️ `service/`** (5 scripts) - Service management and deployment
4144 | - **✅ `validation/`** (7 scripts) - Configuration and system validation
4145 | - **🗄️ `database/`** (4 scripts) - Database analysis and health monitoring
4146 | - **🧹 `maintenance/`** (7 scripts) - Database cleanup and repair operations
4147 | - **💾 `backup/`** (4 scripts) - Backup and restore operations
4148 | - **🔄 `migration/`** (11 scripts) - Data migration and schema updates
4149 | - **🏠 `installation/`** (8 scripts) - Setup and installation scripts
4150 | - **🖥️ `server/`** (5 scripts) - Server runtime and operational scripts
4151 | - **🧪 `testing/`** (15 scripts) - Test scripts and validation
4152 | - **🔧 `utils/`** (7 scripts) - General utility scripts and wrappers
4153 | - **🛠️ `development/`** (6 scripts) - Development tools and debugging utilities
4154 |
4155 | #### Enhanced Documentation
4156 | - **✅ Complete README.md rewrite** with comprehensive script index and usage examples
4157 | - **✅ Quick reference guide** for essential daily operations
4158 | - **✅ Detailed directory explanations** with purpose and key features
4159 | - **✅ Safety guidelines** and execution best practices
4160 | - **✅ Common use case workflows** for setup, operations, troubleshooting, and migration
4161 | - **✅ Integration documentation** linking to project wiki and guides
4162 |
4163 | #### User Experience Improvements
4164 | - **🎯 Faster script discovery** - find tools by logical function instead of hunting through 62 files
4165 | - **📚 Professional documentation** with tables, examples, and clear categorization
4166 | - **🚀 Quick-start examples** for common operations and troubleshooting
4167 | - **🛡️ Safety-first approach** with dry-run recommendations and backup guidelines
4168 | - **🔗 Seamless integration** with existing CLAUDE.md, AGENTS.md, and documentation
4169 |
4170 | #### Maintainability Enhancements
4171 | - **🏗️ Logical organization** makes adding new scripts intuitive
4172 | - **📝 Clear naming conventions** and directory purposes
4173 | - **🔄 Future-proof structure** that scales with project growth
4174 | - **✅ Consistent documentation patterns** across all categories
4175 | - **🧪 Verified functionality** - all critical scripts tested post-reorganization
4176 |
4177 | #### Files Updated (4):
4178 | - **`scripts/README.md`** - COMPLETE REWRITE: Professional documentation with comprehensive index
4179 | - **`CLAUDE.md`** - UPDATED: All script paths updated to new locations
4180 | - **`AGENTS.md`** - UPDATED: Development workflow script references
4181 | - **`CHANGELOG.md`** - UPDATED: Historical script references to new paths
4182 |
4183 | #### Impact
4184 | - 🎯 **Transforms user experience** from cluttered file hunting to professional navigation
4185 | - 🚀 **Enables faster development** with logical script organization
4186 | - 💻 **Simplifies maintenance** with clear categorization and documentation
4187 | - ✅ **Professional appearance** suitable for enterprise deployments
4188 | - 🔄 **Supports scalable growth** with extensible directory structure
4189 | - 🛡️ **Improves safety** with comprehensive usage guidelines and best practices
4190 |
4191 | This release transforms the scripts directory from a disorganized collection into a professional, enterprise-ready toolkit that significantly improves developer and user experience while maintaining full functionality.
4192 |
4193 | ## [6.14.0] - 2025-09-22
4194 |
4195 | ### 🛠️ **Operational Utilities & Backend Synchronization**
4196 |
4197 | #### New Backend Synchronization Capabilities
4198 | - **Bidirectional Sync Engine**:
4199 | - ✅ `sync_memory_backends.py` - Core sync logic with intelligent deduplication
4200 | - ✅ `claude_sync_commands.py` - User-friendly CLI wrapper for sync operations
4201 | - ✅ Supports Cloudflare ↔ SQLite-vec synchronization with dry-run mode
4202 | - ✅ Content-based hashing prevents duplicates across backends
4203 | - ✅ Comprehensive status reporting and error handling
4204 | - **Service Management**:
4205 | - ✅ `memory_service_manager.sh` - Linux service management for dual-backend deployments
4206 | - ✅ State-based backend detection using `/tmp/memory-service-backend.state`
4207 | - ✅ Environment file management for Cloudflare and SQLite configurations
4208 | - ✅ Integrated sync operations and health monitoring
4209 | - **Configuration Validation**:
4210 | - ✅ `validate_config.py` - Comprehensive configuration validator
4211 | - ✅ Validates Claude Code global configuration (~/.claude.json)
4212 | - ✅ Checks Cloudflare credentials and environment setup
4213 | - ✅ Detects configuration conflicts and provides solutions
4214 | - **Documentation & Guides**:
4215 | - ✅ Updated `scripts/README.md` with comprehensive utility documentation
4216 | - ✅ Added backend sync references to main `README.md` and `CLAUDE.md`
4217 | - ✅ Created `Backend-Synchronization-Guide.md` wiki page with complete setup guide
4218 |
4219 | #### Code Quality Improvements (Gemini Code Assist Feedback)
4220 | - **Eliminated Code Duplication**:
4221 | - ✅ Refactored `sync_memory_backends.py` to use shared `_sync_between_backends()` method
4222 | - ✅ Reduced ~80 lines of duplicate code, improved maintainability
4223 | - **Cross-Platform Compatibility**:
4224 | - ✅ Replaced hardcoded `/home/hkr/` paths with `$HOME` variable
4225 | - ✅ Added missing final newlines to all utility scripts
4226 | - **Enhanced Validation & Robustness**:
4227 | - ✅ Improved configuration validation with regex patterns instead of string matching
4228 | - ✅ Added UTF-8 encoding to all file operations in `validate_config.py`
4229 | - ✅ Fixed `.env.sqlite` conflict detection logic
4230 | - **Better Code Organization**:
4231 | - ✅ Refactored command handling to dictionary-based dispatch pattern
4232 | - ✅ Improved scalability for future command additions
4233 |
4234 | #### Production Deployment Features
4235 | - **Hybrid Cloud/Local Deployments**: Enable Cloudflare primary with SQLite backup
4236 | - **Disaster Recovery**: Automated backup and restore capabilities
4237 | - **Multi-Machine Sync**: Consistent memory sharing across devices
4238 | - **Development/Production Workflows**: Seamless sync between environments
4239 | - **Troubleshooting Tools**: Configuration validation and service management
4240 |
4241 | #### Impact
4242 | - 🎯 **Fills critical operational gaps** for production deployments
4243 | - 🚀 **Enables advanced deployment strategies** (hybrid cloud/local)
4244 | - 💻 **Simplifies troubleshooting** with validation and management tools
4245 | - ✅ **Professional code quality** meeting all review standards
4246 | - 🔄 **Supports complex workflows** for distributed teams
4247 |
4248 | #### Files Added/Modified (8):
4249 | - `scripts/sync/sync_memory_backends.py` - NEW: Bidirectional sync engine
4250 | - `scripts/sync/claude_sync_commands.py` - NEW: CLI wrapper for sync operations
4251 | - `scripts/service/memory_service_manager.sh` - NEW: Linux service manager
4252 | - `scripts/validation/validate_config.py` - NEW: Configuration validator
4253 | - `scripts/README.md` - UPDATED: Comprehensive utility documentation
4254 | - `README.md` - UPDATED: Added troubleshooting references
4255 | - `CLAUDE.md` - UPDATED: Added sync and validation commands
4256 | - Wiki: `Backend-Synchronization-Guide.md` - NEW: Complete sync setup guide
4257 |
4258 | ## [6.13.8] - 2025-09-21
4259 |
4260 | ### 🔧 **Integration Completion**
4261 |
4262 | #### Cloudflare Storage Backend Full Integration
4263 | - **Fixed critical integration gaps**: Cloudflare backend now has complete feature parity with sqlite_vec and chroma
4264 | - **Health Check Recognition**:
4265 | - ✅ **Resolved "Unknown storage type: CloudflareStorage" errors**
4266 | - ✅ Health check now properly validates Cloudflare storage and returns "healthy" status
4267 | - ✅ Added Cloudflare support to `server.py` health validation (lines 3410-3450)
4268 | - ✅ Added Cloudflare support to `db_utils.py` validation, stats, and repair functions
4269 | - **Complete CLI Integration**:
4270 | - ✅ Added 'cloudflare' option to all CLI storage backend choices
4271 | - ✅ Updated `cli/main.py`, `cli/ingestion.py` with cloudflare backend support
4272 | - ✅ Added CloudflareStorage initialization logic to `cli/utils.py`
4273 | - ✅ Updated configuration documentation to include cloudflare option
4274 | - **Documentation & Startup Guidance**:
4275 | - ✅ **Critical**: Added warning about inappropriate use of `memory_offline.py` with Cloudflare backend
4276 | - ✅ Cloudflare uses Workers AI for embeddings - offline mode breaks this functionality
4277 | - ✅ Added proper startup script recommendations in `docs/cloudflare-setup.md`
4278 | - ✅ Recommended: `uv run memory server`, `python scripts/run_memory_server.py`
4279 | - **Enhanced Test Coverage**:
4280 | - ✅ Added comprehensive tests for tag sanitization method
4281 | - ✅ Verified existing extensive test suite covers all major functionality
4282 | - **Impact**:
4283 | - 🎯 **Cloudflare backend is now a first-class citizen** alongside sqlite_vec and chroma
4284 | - 🚀 **Complete health check integration** - no more "Unknown storage type" errors
4285 | - 💻 **Full CLI support** for cloudflare backend selection
4286 | - 📚 **Clear startup guidance** prevents Workers AI compatibility issues
4287 | - ✅ **Production ready** for distributed teams and cloud-native deployments
4288 |
4289 | #### Files Modified (11):
4290 | - `src/mcp_memory_service/server.py` - Added Cloudflare health check case
4291 | - `src/mcp_memory_service/utils/db_utils.py` - Added validation, stats, repair support
4292 | - `src/mcp_memory_service/cli/main.py` - Added cloudflare CLI option
4293 | - `src/mcp_memory_service/cli/ingestion.py` - Added cloudflare CLI option
4294 | - `src/mcp_memory_service/cli/utils.py` - Added CloudflareStorage initialization
4295 | - `src/mcp_memory_service/config.py` - Updated backend documentation
4296 | - `docs/cloudflare-setup.md` - Added startup script guidance and warnings
4297 | - `tests/unit/test_cloudflare_storage.py` - Enhanced test coverage
4298 | - `src/mcp_memory_service/__init__.py` - Version bump to 6.13.8
4299 | - `pyproject.toml` - Version bump to 6.13.8
4300 |
4301 | ## [6.13.7] - 2025-09-20
4302 |
4303 | ### 🐛 **Critical Bug Fixes**
4304 |
4305 | #### Cloudflare Vectorize ID Length Issue Fixed
4306 | - **Fixed critical bug**: Resolved Cloudflare Vectorize vector ID length limit error
4307 | - **Root Cause**: CloudflareStorage was using `"mem_" + content_hash` format for vector IDs (68 characters)
4308 | - **Cloudflare Limit**: Vectorize has a 64-byte maximum ID length restriction
4309 | - **Solution**: Removed "mem_" prefix, now using `content_hash` directly (64 characters)
4310 | - **Impact**: **Enables proper bidirectional sync** between multiple machines using Cloudflare backend
4311 | - **Error Fixed**: `"id too long; max is 64 bytes, got 68 bytes"` when storing memories
4312 | - **Affects**: All users using Cloudflare backend for memory storage
4313 | - **Backward Compatibility**: ⚠️ **Breaking change** - existing Cloudflare vector IDs will have different format
4314 | - **Migration**: Users with existing Cloudflare deployments may need to re-import memories
4315 | - **Benefits**:
4316 | - ✅ Cloudflare backend now works reliably for memory storage
4317 | - ✅ Multi-machine sync scenarios (e.g., replacing failed servers) now supported
4318 | - ✅ Consistent vector ID format aligns with Cloudflare specifications
4319 | - **Files Modified**: `src/mcp_memory_service/storage/cloudflare.py:295`
4320 |
4321 | #### Multi-Machine Sync Capability
4322 | - **New capability**: Cloudflare can now serve as central memory hub for multiple machines
4323 | - **Use case**: Replacement for failed centralized servers (e.g., narrowbox failures)
4324 | - **Implementation**: Dual storage strategy with Cloudflare primary + local sqlite_vec backup
4325 | - **Tested**: Bidirectional sync verified between macOS machines using Cloudflare D1 + Vectorize
4326 |
4327 | ## [6.13.6] - 2025-09-16
4328 |
4329 | ### 📚 **Documentation**
4330 |
4331 | #### Added AGENTS.md for AI Coding Agents
4332 | - **New standard format**: Added `AGENTS.md` following the industry-standard [agents.md](https://agents.md/) specification
4333 | - **Purpose**: Provides AI coding agents with project-specific instructions and context
4334 | - **Compatibility**: Works with GitHub Copilot, Cursor, VS Code, Continue, and other AI tools
4335 | - **Complements CLAUDE.md**: Generic instructions for all AI agents vs Claude-specific in CLAUDE.md
4336 | - **Content includes**:
4337 | - Setup commands and testing procedures
4338 | - Project structure and key files overview
4339 | - Code style guidelines and conventions
4340 | - Common development tasks and patterns
4341 | - Security guidelines and debugging tips
4342 | - **Benefits**:
4343 | - Standardized location for AI agent instructions (becoming industry standard)
4344 | - Improved developer experience when using AI coding assistants
4345 | - Better onboarding for contributors using AI tools
4346 | - **Files Added**: `AGENTS.md`
4347 |
4348 | #### Added CONTRIBUTING.md for Contributor Guidelines
4349 | - **Fixed dead link**: Resolved broken reference in README.md line 195
4350 | - **Comprehensive guidelines**: Added detailed contribution instructions including:
4351 | - Development environment setup with platform-specific notes
4352 | - Code style and Python conventions following PEP 8
4353 | - Testing requirements with pytest examples
4354 | - Semantic commit message format
4355 | - Pull request process and review guidelines
4356 | - **Code of Conduct**: Included basic behavioral guidelines for inclusive community
4357 | - **Multiple contribution paths**: Documented various ways to contribute (code, docs, testing, support)
4358 | - **Integration**: Links to existing documentation (AGENTS.md, CLAUDE.md, Wiki)
4359 | - **Files Added**: `CONTRIBUTING.md`
4360 |
4361 | ## [6.13.5] - 2025-09-15
4362 |
4363 | ### 🐛 **Bug Fixes**
4364 |
4365 | #### macOS Service Installation Script Fix (PR #101)
4366 | - **Fixed NameError**: Resolved `NameError: name 'paths' is not defined` in `install_macos_service.py` at line 238
4367 | - **Root Cause**: Variable `paths` was referenced in `platform_info` dictionary without being initialized
4368 | - **Solution**: Added `paths = get_service_paths()` call before usage, following existing code patterns
4369 | - **Impact**: macOS service installation now works reliably without runtime errors
4370 | - **Credit**: Thanks to @hex for identifying and fixing this issue
4371 | - **Files Modified**: `scripts/install_macos_service.py`
4372 |
4373 | ## [6.13.4] - 2025-09-14
4374 |
4375 | ### 🐛 **Critical Bug Fixes**
4376 |
4377 | #### Memory Search Timezone Inconsistency (Fixes Issue #99)
4378 | - **Fixed timezone handling bug**: Resolved critical inconsistency in timestamp validation between hook-generated and manual memories
4379 | - **Root Cause**: Memory model was incorrectly interpreting ISO timestamps without 'Z' suffix as local time instead of UTC
4380 | - **Solution**: Enhanced `iso_to_float()` function with explicit UTC handling using `calendar.timegm()`
4381 | - **Impact**: Time-based memory searches (e.g., "yesterday", "last week") now consistently find all memories regardless of storage method
4382 | - **Improved timestamp validation**: Enhanced `_sync_timestamps()` method with better timezone mismatch detection
4383 | - Added logic to detect timezone offset discrepancies between float and ISO timestamps
4384 | - Automatic correction when timezone issues detected (prefers float timestamp as authoritative)
4385 | - Better logging for timezone validation issues during memory creation
4386 | - **Comprehensive test coverage**: Added extensive test suite validating fix effectiveness
4387 | - `test_hook_vs_manual_storage.py`: Validates consistency between hook and manual memory storage
4388 | - `test_issue99_final_validation.py`: Confirms timezone fix resolves the original issue
4389 | - `test_search_retrieval_inconsistency.py`: Root cause analysis and validation tests
4390 | - `test_data_serialization_consistency.py`: Memory serialization consistency validation
4391 |
4392 | ### 🔧 **Technical Improvements**
4393 | - **Memory Model Enhancement**: Strengthened timestamp handling throughout the memory lifecycle
4394 | - More robust ISO string parsing with fallback mechanisms
4395 | - Better error handling for edge cases in timestamp conversion
4396 | - Consistent UTC interpretation across all timestamp operations
4397 |
4398 | ### 📚 **Documentation Updates**
4399 | - **Issue Resolution**: GitHub Issue #99 documented and resolved with comprehensive technical analysis
4400 | - **Test Documentation**: Added detailed test suite documentation for memory storage consistency
4401 |
4402 | ## [6.13.3] - 2025-09-03
4403 |
4404 | ### 🐛 **Critical Bug Fixes**
4405 |
4406 | #### macOS SQLite Extension Support (Fixes Issue #97)
4407 | - **Fixed AttributeError**: Resolved `'sqlite3.Connection' object has no attribute 'enable_load_extension'` error on macOS
4408 | - Added comprehensive extension support detection before attempting to load sqlite-vec
4409 | - Graceful error handling with clear, actionable error messages
4410 | - Platform-specific guidance for macOS users (Homebrew Python, pyenv with extension support)
4411 | - Interactive prompt to switch to ChromaDB backend when extensions unavailable
4412 | - **Enhanced sqlite_vec.py**: Added `_check_extension_support()` method with robust error handling
4413 | - **Improved install.py**: Added SQLite extension support detection and warnings during installation
4414 |
4415 | ### 📚 **Documentation Updates**
4416 |
4417 | #### macOS Extension Loading Documentation
4418 | - **README Updates**: Added dedicated macOS SQLite extension support section with solutions
4419 | - **First-Time Setup Guide**: Comprehensive macOS extension issues section with verification commands
4420 | - **Troubleshooting Guide**: Detailed troubleshooting for `enable_load_extension` AttributeError
4421 | - **Clear Solutions**: Step-by-step instructions for Homebrew Python and pyenv with extension support
4422 |
4423 | ### 🔧 **Installation Improvements**
4424 | - **Proactive Detection**: Installer now checks SQLite extension support before attempting sqlite-vec installation
4425 | - **Interactive Fallback**: Option to automatically switch to ChromaDB when sqlite-vec cannot work
4426 | - **Better Error Messages**: Platform-specific solutions instead of cryptic errors
4427 | - **System Information**: Enhanced system info display includes SQLite extension support status
4428 |
4429 | ### 🏥 **Error Handling**
4430 | - **Runtime Protection**: sqlite-vec backend now fails gracefully with helpful error messages
4431 | - **Clear Guidance**: Detailed error messages explain why the error occurs and provide multiple solutions
4432 | - **Automatic Detection**: System automatically detects extension support capabilities
4433 |
4434 | ## [6.13.2] - 2025-09-03
4435 |
4436 | ### 🐛 **Bug Fixes**
4437 |
4438 | #### Python 3.13 Compatibility (Fixes Issue #96)
4439 | - **Enhanced sqlite-vec Installation**: Added intelligent fallback strategies for Python 3.13 where pre-built wheels are not yet available
4440 | - Automatic retry with multiple installation methods (uv pip, standard pip, source build, GitHub install)
4441 | - Clear guidance for alternative solutions (Python 3.12, ChromaDB backend)
4442 | - Interactive prompt to switch backends if sqlite-vec installation fails
4443 | - **Improved Error Messages**: Better error reporting with actionable manual installation options
4444 | - **uv Package Manager Support**: Prioritizes uv pip when available for better dependency resolution
4445 |
4446 | ### 📚 **Documentation Updates**
4447 |
4448 | #### Python 3.13 Support Documentation
4449 | - **README Updates**: Added Python 3.13 compatibility note with recommended solutions
4450 | - **First-Time Setup Guide**: New section on Python 3.13 known issues and workarounds
4451 | - **Troubleshooting Guide**: Comprehensive sqlite-vec installation troubleshooting for Python 3.13
4452 | - **Clear Migration Path**: Step-by-step instructions for using Python 3.12 or switching to ChromaDB
4453 |
4454 | ### 🔧 **Installation Improvements**
4455 | - **Multi-Strategy Installation**: Installer now tries 5 different methods before failing
4456 | - **Source Build Fallback**: Attempts to build from source when wheels are unavailable
4457 | - **GitHub Direct Install**: Falls back to installing directly from sqlite-vec repository
4458 | - **Backend Switching**: Option to automatically switch to ChromaDB if sqlite-vec fails
4459 |
4460 | ## [6.13.1] - 2025-09-03
4461 |
4462 | ### 📚 **Documentation & User Experience**
4463 |
4464 | #### First-Time Setup Documentation (Addresses Issue #95)
4465 | - **Added First-Time Setup Section**: New prominent section in README.md explaining expected warnings on initial run
4466 | - **Created Comprehensive Guide**: New `docs/first-time-setup.md` with detailed explanations of:
4467 | - Normal warnings vs actual errors
4468 | - Model download process (~25MB, 1-2 minutes)
4469 | - Success indicators and verification steps
4470 | - Ubuntu 24-specific installation instructions
4471 | - **Enhanced Troubleshooting**: Updated `docs/troubleshooting/general.md` with first-time warnings section
4472 | - **Improved Installer Messages**: Enhanced `install.py` with clear first-time setup expectations and progress indicators
4473 |
4474 | ### 🐛 **Bug Fixes**
4475 |
4476 | #### User Experience Improvements
4477 | - **Fixed Issue #95**: Clarified that "No snapshots directory" warning is normal on first run
4478 | - **Addressed Confusion**: Distinguished between expected initialization warnings and actual errors
4479 | - **Ubuntu 24 Support**: Added specific documentation for Ubuntu 24 installation issues
4480 |
4481 | ### 📝 **Changes**
4482 | - Added clear messaging that warnings disappear after first successful run
4483 | - Included estimated download times and model sizes in documentation
4484 | - Improved installer output to set proper expectations for first-time users
4485 |
4486 | ## [6.13.0] - 2025-08-25
4487 |
4488 | ### ⚡ **Major Features**
4489 |
4490 | #### Enhanced Storage Backend Visibility & Health Integration
4491 | - **Health Check Integration**: Claude Code hooks now use `/api/health/detailed` endpoint for **authoritative storage information**
4492 | - **Real-time Backend Detection**: Queries live health data instead of environment variables
4493 | - **Rich Storage Information**: Displays memory count, database size, connection status, and embedding model
4494 | - **Comprehensive Database Stats**: Shows unique tags, file paths, platform info, and uptime
4495 | - **Fallback Strategy**: Health check → Environment variables → Configuration inference
4496 |
4497 | - **Enhanced Console Output**:
4498 | - **Brief Mode**: `💾 Storage → 🪶 sqlite-vec (Connected) • 990 memories • 5.21MB`
4499 | - **Detailed Mode**: Separate lines for storage type, location, and database statistics
4500 | - **Icon-Only Mode**: Minimal display with backend type and memory count
4501 | - **Path Display**: Shows actual database file locations from health data
4502 |
4503 | - **Context Message Enhancement**:
4504 | - **Storage Section**: Includes backend type, connection status, memory count, and database size
4505 | - **Location Info**: Real file paths from health endpoint rather than configuration guesses
4506 | - **Model Information**: Displays active embedding model (e.g., all-MiniLM-L6-v2)
4507 | - **Health Metadata**: Platform info and database accessibility status
4508 |
4509 | ### 🔧 **Configuration Enhancements**
4510 |
4511 | #### New Health Check Settings
4512 | - **`memoryService.healthCheckEnabled`**: Enable/disable health endpoint queries (default: true)
4513 | - **`memoryService.healthCheckTimeout`**: Timeout for health requests in milliseconds (default: 3000)
4514 | - **`memoryService.useDetailedHealthCheck`**: Use `/api/health/detailed` vs `/api/health` (default: true)
4515 | - **Enhanced Display Modes**: `sourceDisplayMode` supports "brief", "detailed", "icon-only"
4516 |
4517 | ### 🐛 **Critical Bug Fixes**
4518 |
4519 | #### Windows Path Resolution Issues
4520 | - **Git Analyzer**: Fixed Windows path handling in `execSync` calls using `path.resolve()`
4521 | - **Project Detector**: Resolved Windows path issues in git command execution
4522 | - **Path Normalization**: All working directory paths properly normalized for cross-platform compatibility
4523 |
4524 | #### Memory Context Display Improvements
4525 | - **Content Length Limits**: Increased from 300→500 characters to prevent truncation
4526 | - **CLI Formatting**: Enhanced from 180→400 chars for better context visibility
4527 | - **Categorized Display**: Improved from 160→350 chars for categorized memories
4528 | - **Deduplication Logging**: Fixed misleading "8 → 2" messages, now shows actual selection counts
4529 |
4530 | #### Output Cleaning & Visual Improvements
4531 | - **Session Hook Tags**: Added cleaning logic to remove `<session-start-hook>` wrapper tags
4532 | - **Memory Categories**: Enhanced category titles (e.g., "Recent Work (Last 7 days)", "Bug Fixes & Issues")
4533 | - **Better Hierarchy**: Improved visual organization and color coding
4534 | - **Configurable Limits**: All content length limits now configurable via config.json
4535 |
4536 | ### 💡 **Smart Detection Improvements**
4537 |
4538 | #### Backend Detection Hierarchy
4539 | 1. **Health Endpoint** (Primary): Authoritative data from running service
4540 | 2. **Environment Variables** (Secondary): MCP_MEMORY_STORAGE_BACKEND detection
4541 | 3. **Configuration Inference** (Fallback): Endpoint-based local/remote classification
4542 |
4543 | #### Supported Backend Types
4544 | - **SQLite-vec**: 🪶 Local database with file path and size information
4545 | - **ChromaDB**: 📦 Local or 🌐 Remote with endpoint details
4546 | - **Cloudflare**: ☁️ Cloud service with account information
4547 | - **Generic Services**: 💾 Local or 🌐 Remote MCP services
4548 |
4549 | ### 🎯 **Performance & Reliability**
4550 |
4551 | #### Health Check Implementation
4552 | - **Non-blocking**: Async health queries don't slow session start
4553 | - **Timeout Protection**: 3-second default timeout prevents hanging
4554 | - **Error Handling**: Graceful fallback to configuration-based detection
4555 | - **Caching**: Health info cached during session to avoid repeated calls
4556 |
4557 | ## [6.12.0] - 2025-08-25
4558 |
4559 | ### ⚡ **Major Features**
4560 |
4561 | #### Git-Aware Memory Retrieval System
4562 | - **Repository Context Analysis**: Session hooks now analyze git commit history and changelog entries
4563 | - **Git Context Analyzer**: New utility (`git-analyzer.js`) extracts development keywords from recent commits
4564 | - **Commit Mining**: Analyzes last 14 days of commits to understand development patterns
4565 | - **Changelog Integration**: Parses CHANGELOG.md to identify recent development themes
4566 | - **Smart Query Generation**: Creates git-informed semantic queries for memory retrieval
4567 |
4568 | - **Multi-Phase Memory Retrieval Enhancement**:
4569 | - **Phase 0 (NEW)**: Git-aware memory search using repository context (highest priority)
4570 | - **Phase 1**: Recent memories enhanced with git development keywords
4571 | - **Phase 2**: Important tagged memories with framework/language context
4572 | - **Phase 3**: Fallback general context with extended time windows
4573 |
4574 | - **Enhanced Context Categorization**:
4575 | - **"Current Development" Category**: New category for git-context derived memories
4576 | - **Repository-Aware Scoring**: Memories aligned with recent commits get higher relevance scores
4577 | - **Development Timeline Integration**: Memory selection based on actual coding activity
4578 |
4579 | ### 🔧 **Configuration Enhancements**
4580 |
4581 | #### New Git Analysis Settings
4582 | - **`gitAnalysis.enabled`**: Enable/disable git context analysis (default: true)
4583 | - **`gitAnalysis.commitLookback`**: Days of commit history to analyze (default: 14)
4584 | - **`gitAnalysis.maxCommits`**: Maximum commits to process (default: 20)
4585 | - **`gitAnalysis.includeChangelog`**: Parse changelog for context (default: true)
4586 | - **`gitAnalysis.maxGitMemories`**: Memory slots reserved for git context (default: 3)
4587 | - **`gitAnalysis.gitContextWeight`**: Relevance multiplier for git-derived memories (default: 1.2)
4588 |
4589 | #### Enhanced Output Control
4590 | - **`output.showGitAnalysis`**: Display git analysis information (default: true)
4591 | - **`output.showPhaseDetails`**: Show detailed phase execution info (default: true)
4592 | - **Improved Memory Ratio Configuration**: `recentMemoryRatio`, `recentTimeWindow`, `fallbackTimeWindow`
4593 |
4594 | ### 💡 **Smart Query Improvements**
4595 |
4596 | #### Development-Aware Semantic Queries
4597 | - **Commit Message Context**: Latest commit messages influence memory search
4598 | - **File Pattern Recognition**: Recently changed files inform query building
4599 | - **Technical Keyword Extraction**: Action words (feat, fix, refactor) enhance search relevance
4600 | - **Branch-Aware Queries**: Git branch context integrated into semantic search
4601 |
4602 | ### 🎯 **Memory Relevance Enhancements**
4603 |
4604 | #### Repository Activity Integration
4605 | - **Development Intensity Scoring**: High commit activity increases recent memory priority
4606 | - **File-Based Context**: Memories related to recently changed files get boosted relevance
4607 | - **Changelog Correlation**: Memory selection aligned with documented changes
4608 | - **Temporal Context Weighting**: Recent development activity influences memory scoring
4609 |
4610 | ### 🚀 **Performance & Reliability**
4611 |
4612 | #### Git Integration Optimizations
4613 | - **Lazy Git Analysis**: Only processes git context when repository detected
4614 | - **Performance Limits**: Configurable commit analysis limits to prevent slowdowns
4615 | - **Graceful Degradation**: Falls back to standard retrieval if git analysis fails
4616 | - **Async Processing**: Non-blocking git analysis for faster session startup
4617 |
4618 | ### 📊 **Enhanced Debugging & Monitoring**
4619 |
4620 | #### Git Analysis Visibility
4621 | - **Git Context Reporting**: Shows analyzed commits, changelog entries, and extracted keywords
4622 | - **Phase Execution Details**: Clear indication of which phase found which memories
4623 | - **Query Source Tracking**: Memories tagged with their retrieval source (git-commits, git-files, etc.)
4624 | - **Development Keywords Display**: Shows extracted technical terms from recent activity
4625 |
4626 | ### 🔄 **Backward Compatibility**
4627 |
4628 | #### Seamless Integration
4629 | - **Legacy Mode Support**: `recentFirstMode: false` preserves original behavior
4630 | - **Configuration Migration**: All existing configurations continue to work
4631 | - **Optional Git Features**: Git analysis can be completely disabled if needed
4632 | - **Incremental Adoption**: Features can be enabled progressively
4633 |
4634 | ---
4635 |
4636 | ## [6.11.1] - 2025-08-25
4637 |
4638 | ### 🐛 **Bug Fixes**
4639 |
4640 | #### Windows Path Configuration Issues
4641 | - **Claude Code Hooks Installation**: Fixed Windows-specific path configuration issues
4642 | - **Legacy Path Cleanup**: Removed outdated `.claude-code` references from installation scripts
4643 | - **Windows Batch File**: Updated help text to use correct `.claude\hooks` directory structure
4644 | - **PowerShell Script**: Cleaned up legacy path alternatives for better reliability
4645 | - **Impact**: Windows users no longer encounter `.claude-code` vs `.claude` directory confusion
4646 |
4647 | #### Enhanced Documentation
4648 | - **Windows Installation Guide**: Added comprehensive Windows-specific installation and troubleshooting section
4649 | - **Path Format Guidance**: Clear instructions for JSON path formatting (forward slashes vs backslashes)
4650 | - **Common Issues**: Solutions for `session-start-wrapper.bat` errors and legacy directory migration
4651 | - **Settings Examples**: Proper Windows configuration examples with correct Node.js script paths
4652 | - **Impact**: Windows users have clear guidance for resolving path configuration issues
4653 |
4654 | #### Path Validation Utilities
4655 | - **Automated Detection**: Added path validation functions to detect and warn about configuration issues
4656 | - **Legacy Path Detection**: Automatically identifies old `.claude-code` directories and provides migration steps
4657 | - **Settings Validation**: Validates JSON settings files for Windows path issues and missing files
4658 | - **Path Normalization**: Utility to convert Windows backslash paths to JSON-compatible format
4659 | - **Validation Command**: New `python scripts/claude_commands_utils.py --validate` command for configuration checking
4660 | - **Impact**: Proactive detection and resolution of Windows path issues during installation
4661 |
4662 | ## [6.10.1] - 2025-08-25
4663 |
4664 | ### 🐛 **Bug Fixes**
4665 |
4666 | #### Fixed Claude Code Memory Commands
4667 | - **API Key Update**: Updated all Claude Code memory commands with current production API key
4668 | - Fixed `/memory-context`, `/memory-store`, `/memory-recall`, `/memory-search`, `/memory-health` commands
4669 | - Replaced outdated `test-key-123` with current production API key
4670 | - **Impact**: All memory commands now work correctly with remote memory service
4671 |
4672 | #### Enhanced `/memory-context` Command
4673 | - **Dynamic Session Capture**: Removed hardcoded session content, now captures real-time context
4674 | - **Real-time Info**: Includes current timestamp, working directory, git branch, and recent commits
4675 | - **Dynamic Tags**: Automatically includes current project name as tag
4676 | - **User Context**: Properly captures user-provided session description via `$ARGUMENTS`
4677 | - **Impact**: `/memory-context` now stores actual session context instead of static placeholder text
4678 |
4679 | ## [6.10.0] - 2025-08-25
4680 |
4681 | ### ✨ **New Features**
4682 |
4683 | #### Markdown-to-ANSI Conversion for Clean CLI Output
4684 | - **Automatic Markdown Processing**: Memory content with markdown formatting is now automatically converted to ANSI colors
4685 | - **Headers**: `## Header` → Bold Cyan, `### Subheader` → Bold for visual hierarchy
4686 | - **Emphasis**: `**bold**` → Bold, `*italic*` → Dim for text emphasis
4687 | - **Code**: `` `inline code` `` → Gray, code blocks properly formatted with gray text
4688 | - **Lists**: Markdown bullets (`-`, `*`) → Cyan bullet points (`•`), numbered lists → Cyan arrows (`›`)
4689 | - **Links**: `[text](url)` → Cyan text without URL clutter
4690 | - **Blockquotes**: `> quote` → Dimmed with visual indicator (`│`)
4691 | - **Impact**: Raw markdown syntax no longer appears in CLI output, providing clean and professional display
4692 |
4693 | #### Smart Content Processing
4694 | - **Environment-Aware**: Automatically detects CLI environment and applies appropriate formatting
4695 | - **Configuration Option**: Can be disabled via `CLAUDE_MARKDOWN_TO_ANSI=false` environment variable
4696 | - **Strip-Only Mode**: Option to remove markdown without adding ANSI colors for plain text output
4697 | - **Performance**: Minimal overhead (<5ms) with single-pass regex transformation
4698 |
4699 | ## [6.9.0] - 2025-08-25
4700 |
4701 | ### ✨ **New Features**
4702 |
4703 | #### Enhanced Claude Code Hook Visual Output
4704 | - **Professional CLI Formatting**: Completely redesigned hook output with ANSI color coding and clean typography
4705 | - **ANSI Color Support**: Full color coding with cyan, green, blue, yellow, gray, and red for different components
4706 | - **Clean Typography**: Removed all markdown syntax (`**`, `#`, `##`) and HTML-like tags from CLI output
4707 | - **Consistent Visual Pattern**: Standardized `icon component → description` format throughout all hook messages
4708 | - **Unicode Box Drawing**: Enhanced use of `┌─`, `├─`, `└─`, and `│` characters for better visual structure
4709 | - **Impact**: Hook output now looks professional and readable in Claude Code terminal sessions
4710 |
4711 | #### Color-Coded Memory Content
4712 | - **Type-Based Coloring**: Different colors for memory types (decisions=yellow, insights=magenta, bugs=green, features=blue)
4713 | - **Visual Hierarchy**: Important information highlighted with bright colors, metadata dimmed with gray
4714 | - **Date Formatting**: Consistent gray coloring for dates and timestamps
4715 | - **Category Icons**: Enhanced category display with colored section headers
4716 |
4717 | #### Improved Console Logging
4718 | - **Structured Messages**: All console output now follows consistent visual patterns
4719 | - **Progress Indicators**: Clear visual feedback for memory search, scoring, and processing steps
4720 | - **Error Handling**: Enhanced error messages with proper color coding and clear descriptions
4721 | - **Success Confirmation**: Prominent success indicators with checkmarks and summary information
4722 |
4723 | #### Enhanced Project Detection
4724 | - **Confidence Visualization**: Color-coded confidence scores (green >80%, yellow >60%, gray <60%)
4725 | - **Clean Project Info**: Streamlined project detection output with proper visual hierarchy
4726 | - **Technology Stack Display**: Clear formatting for detected languages, frameworks, and tools
4727 |
4728 | ## [6.8.0] - 2025-08-25
4729 |
4730 | ### ✨ **New Features**
4731 |
4732 | #### Enhanced Claude Code CLI Formatting
4733 | - **Beautiful CLI Output**: Claude Code hooks now feature enhanced visual formatting with Unicode box-drawing characters
4734 | - **Visual Hierarchy**: Clean tree structure using `├─`, `└─`, and `│` characters for better readability
4735 | - **Contextual Icons**: Memory context (🧠), project info (📂, 📝), and category-specific icons (🏗️, 🐛, ✨)
4736 | - **Smart Environment Detection**: Automatically switches between Markdown (web) and enhanced CLI formatting
4737 | - **Improved Categorization**: Visual grouping of memories by type with proper indentation and spacing
4738 | - **Impact**: Dramatically improved readability of hook output in Claude Code terminal sessions
4739 |
4740 | #### CLI Environment Detection
4741 | - **Automatic Detection**: Uses multiple detection methods including `CLAUDE_CODE_CLI` environment variable
4742 | - **Terminal Compatibility**: Enhanced formatting works seamlessly across different terminal emulators
4743 | - **Fallback Support**: Graceful degradation to standard formatting when enhanced features unavailable
4744 |
4745 | #### Visual Design Improvements
4746 | - **Category Icons**: 🏗️ Architecture & Design, 🐛 Bug Fixes & Issues, ✨ Features & Implementation, 📝 Additional Context
4747 | - **Project Status Display**: Git branch (📂) and commit info (📝) with clean formatting
4748 | - **Memory Count Indicators**: Clear display of loaded memory count with 📚 icon
4749 | - **Empty State Handling**: Elegant display when no memories available
4750 |
4751 | ## [6.7.2] - 2025-08-25
4752 |
4753 | ### 🔧 **Enhancement**
4754 |
4755 | #### Deduplication Script Configuration-Aware Refactoring
4756 | - **Enhanced API Integration**: Deduplication script now reads Claude Code hooks configuration for seamless integration
4757 | - **Configuration Auto-Detection**: Automatically reads `~/.claude/hooks/config.json` for memory service endpoint and API key
4758 | - **API-Based Analysis**: Supports remote memory service analysis via HTTPS API with self-signed certificate support
4759 | - **Intelligent Pagination**: Handles large memory collections (972+ memories) with automatic page-by-page retrieval
4760 | - **Backward Compatibility**: Maintains support for direct database access with `--db-path` parameter
4761 | - **Impact**: Users can now run deduplication on remote memory services without manual configuration
4762 |
4763 | #### New Command-Line Options
4764 | - **`--use-api`**: Force API-based analysis using configuration endpoint
4765 | - **Smart Fallback**: Automatically detects available options and suggests alternatives when paths missing
4766 | - **Enhanced Error Messages**: Clear guidance on configuration requirements and troubleshooting steps
4767 |
4768 | #### Technical Improvements
4769 | - **SSL Context Configuration**: Proper handling of self-signed certificates for secure remote connections
4770 | - **Memory Format Normalization**: Converts API response format to internal analysis format seamlessly
4771 | - **Progress Reporting**: Real-time feedback during multi-page memory retrieval operations
4772 |
4773 | #### Validation Results
4774 | - **✅ 972 Memories Analyzed**: Successfully processed complete memory collection via API
4775 | - **✅ No Duplicates Detected**: Confirms v6.7.0 content quality filters are preventing duplicate creation
4776 | - **✅ Configuration Integration**: Seamless integration with existing Claude Code hooks setup
4777 | - **✅ Performance Maintained**: Efficient pagination and processing of large memory collections
4778 |
4779 | > **Usage**: Run `python scripts/find_duplicates.py --use-api` to analyze memories using your configured remote memory service
4780 |
4781 | ## [6.7.1] - 2025-08-25
4782 |
4783 | ### 🔧 **Critical Bug Fix**
4784 |
4785 | #### Claude Code Hooks Installation Script Fix
4786 | - **Fixed Missing v6.7.0 Files in Installation**: Resolved critical installation script bug that prevented complete v6.7.0 setup
4787 | - **Added Missing Core Hook**: `memory-retrieval.js` now properly copied during installation
4788 | - **Added Missing Utility**: `context-shift-detector.js` now properly copied during installation
4789 | - **Updated Install Messages**: Installation logs now accurately reflect all installed files
4790 | - **Impact**: Eliminates "Cannot find module" errors on fresh v6.7.0 installations
4791 |
4792 | #### Problem Resolved
4793 | - **Issue**: Installation script (`install.sh`) used hardcoded file list that was missing new v6.7.0 files
4794 | - **Symptoms**: Users experienced module import errors and incomplete feature sets after installation
4795 | - **Root Cause**: Script copied only `session-start.js`, `session-end.js` but missed `memory-retrieval.js` and `context-shift-detector.js`
4796 | - **Solution**: Added missing file copy commands and updated installation messaging
4797 |
4798 | #### Validation
4799 | - **✅ Complete Installation**: All v6.7.0 files now properly installed
4800 | - **✅ Integration Tests**: 14/14 tests pass immediately after fresh installation
4801 | - **✅ No Module Errors**: All dependencies resolved correctly
4802 | - **✅ Full Feature Set**: On-demand memory retrieval and smart timing work out-of-the-box
4803 |
4804 | > **Note**: This is a critical patch for v6.7.0 users. If you installed v6.7.0 and experienced module errors, please reinstall using v6.7.1.
4805 |
4806 | ## [6.7.0] - 2025-08-25
4807 |
4808 | ### 🧠 **Claude Code Memory Awareness - Major Enhancement**
4809 |
4810 | #### Smart Memory Context Presentation ([#Memory-Presentation-Fix](https://github.com/doobidoo/mcp-memory-service/issues/memory-presentation))
4811 | - **Eliminated Generic Content Fluff**: Complete overhaul of session-start hook memory presentation
4812 | - **Smart Content Extraction**: Extracts meaningful content from session summaries (decisions, insights, code changes) instead of truncating at 200 chars
4813 | - **Section-Aware Parsing**: Prioritizes showing actual decisions/insights over generic headers like "Topics Discussed - implementation..."
4814 | - **Deduplication Logic**: Automatically filters out repetitive session summaries with 80% similarity threshold
4815 | - **Impact**: Users now see actionable memory content instead of truncated generic summaries
4816 |
4817 | #### Enhanced Memory Quality Scoring
4818 | - **Content Quality Factor**: New scoring dimension that heavily penalizes generic/empty content
4819 | - **Meaningful Indicators**: Detects substantial content using decision words (decided, implemented, fixed, learned)
4820 | - **Information Density**: Analyzes word diversity and content richness
4821 | - **Generic Pattern Detection**: Automatically identifies and demotes "implementation..." session summaries
4822 | - **Impact**: Quality memories now outrank recent-but-empty summaries
4823 |
4824 | #### Smart Context Management
4825 | - **Post-Compacting Control**: Added `injectAfterCompacting: false` configuration option
4826 | - **Problem Solved**: Stops disruptive mid-session memory injection after compacting events
4827 | - **User-Controlled**: Can be enabled via `config.json` for users who prefer the old behavior
4828 | - **Context Shift Detection**: Intelligent timing for when to refresh memory context
4829 | - **Project Change Detection**: Auto-refreshes when switching between projects/directories
4830 | - **Topic Shift Analysis**: Detects significant conversation topic changes
4831 | - **User Request Recognition**: Responds to explicit memory requests ("remind me", "what did we decide")
4832 | - **Impact**: Memory context appears only when contextually appropriate, not disruptively
4833 |
4834 | #### New Features
4835 | - **On-Demand Memory Retrieval**: New `memory-retrieval.js` hook for manual context requests
4836 | - **User-Triggered**: Allows manual memory refresh when needed
4837 | - **Query-Based**: Supports semantic search with user-provided queries
4838 | - **Relevance Scoring**: Shows confidence scores for manual retrieval
4839 | - **Streamlined Presentation**: Cleaner formatting with reduced metadata clutter
4840 | - **Smart Categorization**: Only groups memories when there's meaningful diverse content
4841 | - **Relevant Tags Only**: Filters out machine-generated and generic tags
4842 | - **Concise Dating**: More compact date formatting (Aug 25 vs full timestamps)
4843 |
4844 | #### Technical Improvements
4845 | - **Enhanced Memory Scoring Weights**:
4846 | ```json
4847 | {
4848 | "timeDecay": 0.25, // Reduced from 0.30
4849 | "tagRelevance": 0.35, // Maintained
4850 | "contentRelevance": 0.15, // Reduced from 0.20
4851 | "contentQuality": 0.25, // NEW quality factor
4852 | "conversationRelevance": 0.25 // Maintained
4853 | }
4854 | ```
4855 | - **New Utility Files**:
4856 | - `context-shift-detector.js`: Intelligent context change detection
4857 | - Enhanced `context-formatter.js` with smart content extraction
4858 | - Quality-aware scoring in `memory-scorer.js`
4859 |
4860 | #### Breaking Changes
4861 | - **Session-Start Hook**: Upgraded to v2.0.0 with smart timing and quality filtering
4862 | - **Configuration Schema**: Added new options for memory quality control and compacting behavior
4863 | - **Memory Filtering**: Generic session summaries are now automatically filtered out
4864 |
4865 | #### Migration Guide
4866 | - **Automatic**: No user action required - existing configurations work with sensible defaults
4867 | - **Optional**: Users can enable `injectAfterCompacting: true` in config.json if they prefer old behavior
4868 | - **Benefit**: Immediate improvement in memory context quality and relevance
4869 |
4870 | ## [6.6.4] - 2025-08-25
4871 |
4872 | ### 🔧 **Installation Experience Improvements**
4873 |
4874 | #### Universal Installer Bug Fixes ([#92](https://github.com/doobidoo/mcp-memory-service/issues/92))
4875 | - **Fixed "Installer Gets Stuck" Issues**: Resolved multiple causes of installation appearing frozen
4876 | - Added prominent visual separators (`⚠️ USER INPUT REQUIRED`) around all input prompts
4877 | - Extended system detection timeouts from 10 to 30 seconds (macOS `system_profiler`, Homebrew checks)
4878 | - Added progress indicators for long-running operations (package installations, hardware detection)
4879 | - **Impact**: Users now clearly understand when installer needs input vs. processing in background
4880 |
4881 | #### New Non-Interactive Installation Mode
4882 | - **Added `--non-interactive` Flag**: Enables fully automated installations using sensible defaults
4883 | - Automatically selects SQLite-vec backend (recommended)
4884 | - Skips optional components (Claude Code commands, multi-client setup)
4885 | - Perfect for CI/CD, Docker builds, and scripted deployments
4886 | - **Usage**: `python install.py --non-interactive`
4887 |
4888 | #### Enhanced User Experience
4889 | - **Better Progress Feedback**: Clear messaging during system detection and package installation phases
4890 | - **Improved Timeout Handling**: More resilient system detection with graceful fallbacks
4891 | - **Log File Visibility**: Prominently displays location of `installation.log` for troubleshooting
4892 |
4893 | ## [6.6.3] - 2025-08-24
4894 |
4895 | ### 🔧 **CI/CD Infrastructure Improvements**
4896 |
4897 | #### GitHub Actions Workflow Fixes
4898 | - **Fixed npm dependency management**: Created proper `package.json` files for test directories
4899 | - **Simplified YAML structure**: Replaced complex multi-line scripts with focused single-step commands
4900 | - **Improved error reporting**: Split validation steps for clearer failure identification
4901 | - **Fixed false positives**: Updated status code validation to avoid flagging legitimate 200/201 handling
4902 | - **Enhanced reliability**: Used `working-directory` instead of embedded `cd` commands
4903 | - **Impact**: GitHub Actions CI/CD now properly installs dependencies and validates bridge fixes
4904 |
4905 | #### Test Infrastructure Enhancements
4906 | - **Added dedicated test packages**: Separate `package.json` for bridge and integration tests
4907 | - **Improved module resolution**: Confirmed correct relative path handling in test files
4908 | - **Better validation coverage**: Enhanced API contract and smoke test verification
4909 |
4910 | ## [6.6.2] - 2025-08-24
4911 |
4912 | ### 🐛 **Critical Bug Fixes**
4913 |
4914 | #### HTTP-MCP Bridge Complete Repair
4915 | - **Fixed Status Code Handling**: Corrected bridge expectation from HTTP 201 to HTTP 200 with success field check
4916 | - Server returns HTTP 200 for both successful storage and duplicates
4917 | - Bridge now properly checks `response.data.success` field to determine actual result
4918 | - Supports both HTTP 200 and 201 for backward compatibility
4919 | - **Impact**: Memory storage operations now work correctly instead of always failing
4920 |
4921 | - **Fixed URL Construction Bug**: Resolved critical path construction issue in `makeRequestInternal`
4922 | - `new URL(path, baseUrl)` was incorrectly replacing `/api` base path
4923 | - Now properly concatenates base URL with API paths: `baseUrl + fullPath`
4924 | - **Impact**: All API operations now reach correct endpoints instead of returning 404
4925 |
4926 | #### Root Cause Analysis
4927 | - **Memory Storage**: Bridge expected HTTP 201 but server returns 200 → always interpreted as failure
4928 | - **All API Calls**: URL construction bug caused `/api` path to be lost → all requests returned 404
4929 | - **Combined Effect**: Made entire bridge non-functional despite server working correctly
4930 |
4931 | ### 🧪 **Major Enhancement: Comprehensive Test Infrastructure**
4932 |
4933 | #### Test Suite Addition
4934 | - **Bridge Unit Tests** (`tests/bridge/test_http_mcp_bridge.js`): 20+ test cases covering:
4935 | - URL construction with various base path scenarios
4936 | - Status code handling for success, duplicates, and errors
4937 | - MCP protocol compliance and error conditions
4938 | - Authentication and retry logic
4939 |
4940 | - **Integration Tests** (`tests/integration/test_bridge_integration.js`): End-to-end testing with:
4941 | - Real server connectivity simulation
4942 | - Complete MCP protocol flow validation
4943 | - Authentication and error recovery testing
4944 | - Critical bug scenario reproduction
4945 |
4946 | - **Mock Response System** (`tests/bridge/mock_responses.js`): Accurate server behavior simulation
4947 | - Matches actual API responses (HTTP 200 with success field)
4948 | - Covers all edge cases and error conditions
4949 | - Prevents future assumption-based bugs
4950 |
4951 | #### CI/CD Pipeline Enhancement
4952 | - **Dedicated Bridge Testing** (`.github/workflows/bridge-tests.yml`):
4953 | - Automated testing on every bridge-related change
4954 | - Multiple Node.js version compatibility testing
4955 | - Contract validation against API specification
4956 | - Blocks merges if bridge tests fail
4957 |
4958 | #### Documentation & Contracts
4959 | - **API Contract Specification** (`tests/contracts/api-specification.yml`):
4960 | - Documents ACTUAL server behavior vs assumptions
4961 | - Critical notes about HTTP 200 status codes and success fields
4962 | - URL path requirements and authentication details
4963 |
4964 | - **Release Process** (`RELEASE_CHECKLIST.md`):
4965 | - 50+ item checklist preventing critical bugs
4966 | - Manual and automated testing requirements
4967 | - Post-release monitoring procedures
4968 |
4969 | ### 🔧 **Technical Details**
4970 |
4971 | **Files Modified:**
4972 | - `examples/http-mcp-bridge.js` - Status code and URL construction fixes
4973 | - `src/mcp_memory_service/__init__.py` - Version bump
4974 | - `pyproject.toml` - Version bump
4975 |
4976 | **Files Added:**
4977 | - Complete test infrastructure (6 new files)
4978 | - CI/CD pipeline configuration
4979 | - API contract documentation
4980 | - Release process documentation
4981 |
4982 | **Backward Compatibility**:
4983 | - All existing configurations continue working
4984 | - Bridge now accepts both HTTP 200 and 201 responses
4985 | - No breaking changes to client interfaces
4986 |
4987 | ### 🎯 **Impact**
4988 |
4989 | **Before v6.6.2:**
4990 | - ❌ Health check: "unhealthy" → Fixed in v6.6.1
4991 | - ❌ Memory storage: "Not Found" errors
4992 | - ❌ Memory retrieval: 404 failures
4993 | - ❌ All bridge operations non-functional
4994 |
4995 | **After v6.6.2:**
4996 | - ✅ Health check: Returns "healthy" status
4997 | - ✅ Memory storage: Works correctly with proper success/duplicate handling
4998 | - ✅ Memory retrieval: Functions normally with semantic search
4999 | - ✅ All bridge operations fully functional
5000 |
5001 | **Future Prevention:**
5002 | - ✅ Comprehensive test coverage prevents regression
5003 | - ✅ API contract validation catches assumption mismatches
5004 | - ✅ Automated CI/CD testing on every change
5005 | - ✅ Detailed release checklist ensures quality
5006 |
5007 | This release completes the HTTP-MCP bridge repair, making it fully functional while establishing comprehensive testing infrastructure to prevent similar critical bugs in the future.
5008 |
5009 | ## [6.6.1] - 2025-08-24
5010 |
5011 | ### 🐛 **Bug Fixes**
5012 |
5013 | #### HTTP-MCP Bridge Health Check Endpoint
5014 | - **Fixed Health Check URLs**: Corrected incorrect endpoint paths in `examples/http-mcp-bridge.js`
5015 | - `testEndpoint()` method: Fixed `/health` → `/api/health` path (line 241)
5016 | - `checkHealth()` method: Fixed `/health` → `/api/health` path (line 501)
5017 | - **Impact**: Health checks now return "healthy" status instead of 404 errors
5018 | - **Root Cause**: Bridge was requesting wrong endpoint causing false "unhealthy" status
5019 | - **Verification**: Remote memory service connectivity confirmed working correctly
5020 |
5021 | #### Technical Details
5022 | - Fixed endpoint inconsistencies that caused health checks to fail
5023 | - Remote memory service functionality was working correctly - issue was purely endpoint path mismatch
5024 | - All memory operations (store/retrieve) continue to work without changes
5025 | - Health check now properly reports service status to MCP clients
5026 |
5027 | **Files Modified**: `examples/http-mcp-bridge.js`
5028 |
5029 | ## [6.6.0] - 2025-08-23
5030 |
5031 | ### 🔧 **Memory Awareness Hooks: Fully Functional Installation**
5032 |
5033 | #### Major Improvements
5034 | - **Installation Scripts Fixed** - Memory Awareness Hooks now install and work end-to-end without manual intervention
5035 | - **Claude Code Integration** - Automatic `~/.claude/settings.json` configuration for seamless hook detection
5036 | - **JSON Parsing Fixed** - Resolved Python dict conversion errors that caused runtime failures
5037 | - **Enhanced Testing** - Added 4 new integration tests (total: 14 tests, 100% pass rate)
5038 |
5039 | #### Added
5040 | - **Automated Claude Code Settings Integration** - Installation script now configures `~/.claude/settings.json` automatically
5041 | - **Comprehensive Troubleshooting Guide** - Complete wiki documentation with diagnosis commands and solutions
5042 | - **Installation Verification** - Post-install connectivity tests and hook detection validation
5043 | - **GitHub Wiki Documentation** - Detailed 500+ line guide for advanced users and developers
5044 |
5045 | #### Fixed
5046 | - **Installation Directory** - Changed from `~/.claude-code/hooks/` to correct `~/.claude/hooks/` location
5047 | - **JSON Parsing Errors** - Added Python dict to JSON conversion (single quotes, True/False/None handling)
5048 | - **Hook Detection** - Claude Code now properly detects installed hooks via settings configuration
5049 | - **Memory Service Connectivity** - Enhanced error handling and connection testing
5050 |
5051 | #### Enhanced
5052 | - **Integration Tests** - Expanded test suite from 10 to 14 tests (40% increase):
5053 | - Claude Code settings validation
5054 | - Hook files location verification
5055 | - Claude Code CLI availability check
5056 | - Memory service connectivity testing
5057 | - **Documentation Structure** - README streamlined (47% size reduction), detailed content moved to wiki
5058 | - **Error Messages** - Improved debugging output and user-friendly error reporting
5059 |
5060 | #### Developer Experience
5061 | - **Quick Start** - Single command installation: `./install.sh`
5062 | - **Verification Commands** - Easy testing with `claude --debug hooks`
5063 | - **Troubleshooting** - Comprehensive guide covers all common issues
5064 | - **Custom Development** - Examples for extending hooks and memory integration
5065 |
5066 | **Impact**: Memory Awareness Hooks are now publicly usable without the manual debugging sessions that were previously required. Users can run `./install.sh` and get fully functional automatic memory awareness in Claude Code.
5067 |
5068 | ## [6.5.0] - 2025-08-23
5069 |
5070 | ### 🗂️ **Repository Structure: Root Directory Cleanup**
5071 |
5072 | #### Added
5073 | - **`deployment/` Directory** - Centralized location for service and configuration files
5074 | - **`sync/` Directory** - Organized synchronization scripts in dedicated folder
5075 | - **Dependency-Safe Reorganization** - All file references properly updated
5076 |
5077 | #### Changed
5078 | - **Root Directory Cleanup** - Reduced clutter from 80+ files to ~65 files (19% reduction)
5079 | - **File Organization** - Moved deployment configs and sync scripts to logical subdirectories
5080 | - **Path References Updated** - All scripts and configurations point to new file locations
5081 | - **Claude Code Settings** - Updated paths in `.claude/settings.local.json` for moved scripts
5082 |
5083 | #### Moved Files
5084 | **To `deployment/`:**
5085 | - `mcp-memory.service` - Systemd service configuration
5086 | - `smithery.yaml` - Smithery package configuration
5087 | - `io.litestream.replication.plist` - macOS LaunchDaemon configuration
5088 | - `staging_db_init.sql` - Database initialization schema
5089 | - `empty_config.yml` - Template configuration file
5090 |
5091 | **To `sync/`:**
5092 | - `manual_sync.sh`, `memory_sync.sh` - Core synchronization scripts
5093 | - `pull_remote_changes.sh`, `push_to_remote.sh` - Remote sync operations
5094 | - `sync_from_remote.sh`, `sync_from_remote_noconfig.sh` - Remote pull variants
5095 | - `apply_local_changes.sh`, `stash_local_changes.sh`, `resolve_conflicts.sh` - Local sync operations
5096 |
5097 | #### Fixed
5098 | - **Broken References** - Updated all hardcoded paths in scripts and configurations
5099 | - **Claude Code Integration** - Fixed manual_sync.sh path reference
5100 | - **Installation Scripts** - Updated service file and SQL schema paths
5101 | - **Litestream Setup** - Fixed LaunchDaemon plist file reference
5102 |
5103 | #### Repository Impact
5104 | This release significantly improves repository navigation and organization while maintaining full backward compatibility through proper reference updates. Users benefit from cleaner root directory structure, while developers gain logical file organization that reflects functional groupings.
5105 |
5106 | ## [6.4.0] - 2025-08-23
5107 |
5108 | ### 📚 **Documentation Revolution: Major UX Transformation**
5109 |
5110 | #### Added
5111 | - **Comprehensive Installation Guide** in wiki consolidating 6+ previous scattered guides
5112 | - **Platform-Specific Setup Guide** with optimizations for Windows, macOS, and Linux
5113 | - **Complete Integration Guide** covering Claude Desktop, Claude Code, VS Code, and 13+ tools
5114 | - **Streamlined README.md** with clear quick start and wiki navigation (56KB → 8KB)
5115 | - **Safe Documentation Archive** preserving all removed files for reference
5116 |
5117 | #### Changed
5118 | - **Major Documentation Restructuring** for improved user experience and maintainability
5119 | - **Single Source of Truth** established for installation, platform setup, and integrations
5120 | - **Wiki Home Page** updated with organized navigation to consolidated guides
5121 | - **User Onboarding Journey** simplified from overwhelming choice to clear path
5122 |
5123 | #### Removed
5124 | - **26+ Redundant Documentation Files** safely archived while preserving git history
5125 | - **Choice Paralysis** from 6 installation guides, 5 integration guides, 4 platform guides
5126 | - **Maintenance Burden** of updating multiple files for single concept changes
5127 | - **Inconsistent Information** across overlapping documentation
5128 |
5129 | #### Fixed
5130 | - **User Confusion** from overwhelming documentation choices and unclear paths
5131 | - **Maintenance Complexity** requiring updates to 6+ files for installation changes
5132 | - **Professional Image** with organized structure reflecting code quality
5133 | - **Information Discovery** through logical wiki organization vs scattered files
5134 |
5135 | #### Documentation Impact
5136 | This release transforms MCP Memory Service from having overwhelming documentation chaos to organized, professional, maintainable structure. Users now have clear paths from discovery to success (README → Quick Start → Wiki → Success), while maintainers benefit from single-source-of-truth updates. **90% reduction in repository documentation files** while **improving comprehensiveness** through organized wiki structure.
5137 |
5138 | **Key Achievements:**
5139 | - Installation guides: 6 → 1 comprehensive wiki page
5140 | - Integration guides: 5 → 1 complete reference
5141 | - Platform guides: 4 → 1 optimized guide
5142 | - User experience: Confusion → Clarity
5143 | - Maintenance: 6+ places → 1 place per topic
5144 |
5145 | ## [6.3.3] - 2025-08-22
5146 |
5147 | ### 🔧 **Enhancement: Version Synchronization**
5148 |
5149 | #### Fixed
5150 | - **API Documentation Version**: Fixed API docs dashboard showing outdated version `1.0.0` instead of current version
5151 | - **Version Inconsistencies**: Synchronized hardcoded versions across FastAPI app, web module, and server configuration
5152 | - **Maintenance Overhead**: Established single source of truth for version management
5153 |
5154 | #### Enhanced
5155 | - **Dynamic Version Management**: All version references now import from main `__version__` variable
5156 | - **Future-Proofing**: Version updates now only require changes in 2 files (pyproject.toml + __init__.py)
5157 | - **Developer Experience**: Consistent version display across all interfaces and documentation
5158 |
5159 | #### Technical Details
5160 | - **FastAPI App**: Changed from hardcoded `version="1.0.0"` to dynamic `version=__version__`
5161 | - **Web Module**: Removed separate version `0.2.0`, now imports from parent package
5162 | - **Server Config**: Updated `SERVER_VERSION` from `0.2.2` to use main version import
5163 | - **Impact**: All dashboards, API docs, and mDNS advertisements now show consistent version
5164 |
5165 | ## [6.3.2] - 2025-08-22
5166 |
5167 | ### 🚨 **Critical Fix: Claude Desktop Compatibility Regression**
5168 |
5169 | #### Fixed
5170 | - **Claude Desktop Integration**: Restored backward compatibility for `uv run memory` command
5171 | - **MCP Protocol Errors**: Fixed JSON parsing errors when Claude Desktop tried to parse CLI help text as MCP messages
5172 | - **Regression from v6.3.1**: CLI consolidation accidentally broke existing Claude Desktop configurations
5173 |
5174 | #### Technical Details
5175 | - **Root Cause**: CLI consolidation removed ability to start MCP server with `uv run memory` (without `server` subcommand)
5176 | - **Impact**: Claude Desktop configurations calling `uv run memory` received help text instead of MCP server
5177 | - **Solution**: Added backward compatibility logic to default to `server` command when no subcommand provided
5178 |
5179 | #### Added
5180 | - **Backward Compatibility**: `uv run memory` now starts MCP server automatically for existing integrations
5181 | - **Deprecation Warning**: Informative warning guides users to explicit `memory server` syntax
5182 | - **Integration Test**: New test case verifies backward compatibility warning functionality
5183 | - **MCP Protocol Validation**: Confirmed proper JSON-RPC responses instead of help text parsing errors
5184 |
5185 | #### For Users
5186 | - **Claude Desktop works again**: Existing configurations continue working without changes
5187 | - **Migration Encouraged**: Warning message guides users toward preferred `memory server` syntax
5188 | - **No Breaking Changes**: All existing usage patterns maintained while encouraging modern syntax
5189 |
5190 | ## [6.3.1] - 2025-08-22
5191 |
5192 | ### 🔧 **Major Enhancement: CLI Architecture Consolidation**
5193 |
5194 | #### Fixed
5195 | - **CLI Conflicts Eliminated**: Resolved installation conflicts between argparse and Click CLI implementations
5196 | - **Command Consistency**: Established `uv run memory server` as the single, reliable server start pattern
5197 | - **Installation Issues**: Fixed stale entry point problems that caused "command not found" errors
5198 |
5199 | #### Enhanced
5200 | - **Unified CLI Interface**: All server commands now route through Click-based CLI for consistency
5201 | - **Deprecation Warnings**: Added graceful migration path with informative deprecation warnings for `memory-server`
5202 | - **Error Handling**: Improved error messages and graceful failure handling across all CLI commands
5203 | - **Documentation**: Added comprehensive CLI Migration Guide with clear upgrade paths
5204 |
5205 | #### Added
5206 | - **CLI Integration Tests**: 16 comprehensive test cases covering all CLI interfaces and edge cases
5207 | - **Performance Testing**: CLI startup time validation and version command performance monitoring
5208 | - **Backward Compatibility**: `memory-server` command maintained with deprecation warnings
5209 | - **Migration Guide**: Complete documentation for transitioning from legacy commands
5210 |
5211 | #### Technical Improvements
5212 | - **Environment Variable Integration**: Seamless config passing via MCP_MEMORY_CHROMA_PATH
5213 | - **Code Cleanup**: Removed duplicate argparse implementation from server.py
5214 | - **Entry Point Simplification**: Streamlined from 3 conflicting implementations to 1 clear interface
5215 | - **Robustness Testing**: Added error handling, argument parity, and isolation testing
5216 |
5217 | #### Benefits for Users
5218 | - **Eliminates MCP startup failures** that were caused by CLI conflicts
5219 | - **Clear command interface**: `uv run memory server` works reliably every time
5220 | - **Better error messages** when something goes wrong
5221 | - **Smooth migration path** from legacy patterns
5222 | - **Full Claude Code compatibility** confirmed and tested
5223 |
5224 | ## [6.3.0] - 2025-08-22
5225 |
5226 | ### 🚀 **Major Feature: Distributed Memory Synchronization**
5227 |
5228 | #### Added
5229 | - **Git-like Sync Workflow**: Complete distributed synchronization system with offline capabilities
5230 | - `memory_sync.sh` - Main orchestrator for sync operations with colored output and status reporting
5231 | - **Stash → Pull → Apply → Push** workflow similar to Git's distributed version control
5232 | - Intelligent conflict detection and resolution with user control
5233 | - Remote-first architecture with automatic fallback to local staging
5234 |
5235 | - **Enhanced Memory Store**: `enhanced_memory_store.sh` with hybrid remote-first approach
5236 | - **Primary**: Direct storage to remote API (`https://narrowbox.local:8443/api/memories`)
5237 | - **Fallback**: Automatic local staging when remote is unavailable
5238 | - Smart context detection (project, git branch, hostname, tags)
5239 | - Seamless offline-to-online transition with automatic sync
5240 |
5241 | - **Real-time Database Replication**: Litestream-based synchronization infrastructure
5242 | - **Master/Replica Setup**: Remote server as master with HTTP-served replica data
5243 | - **Automatic Replication**: 10-second sync intervals for near real-time updates
5244 | - **Lightweight HTTP Server**: Python built-in server for serving replica files
5245 | - **Cross-platform Compatibility**: macOS LaunchDaemon and Linux systemd services
5246 |
5247 | - **Staging Database System**: SQLite-based local change tracking
5248 | - `staging_db_init.sql` - Complete schema with triggers and status tracking
5249 | - **Conflict Detection**: Content hash-based duplicate detection
5250 | - **Operation Tracking**: INSERT/UPDATE/DELETE operation logging
5251 | - **Source Attribution**: Machine hostname and timestamp tracking
5252 |
5253 | - **Comprehensive Sync Scripts**: Complete workflow automation
5254 | - `stash_local_changes.sh` - Capture local changes before remote sync
5255 | - `pull_remote_changes.sh` - Download remote changes with conflict awareness
5256 | - `apply_local_changes.sh` - Intelligent merge of staged changes
5257 | - `push_to_remote.sh` - Upload changes via HTTPS API with retry logic
5258 | - `resolve_conflicts.sh` - Interactive conflict resolution helper
5259 |
5260 | - **Litestream Integration**: Production-ready replication setup
5261 | - **Automated Setup Scripts**: `setup_remote_litestream.sh` and `setup_local_litestream.sh`
5262 | - **Service Configurations**: systemd and LaunchDaemon service files
5263 | - **Master/Replica Configs**: Complete Litestream YAML configurations
5264 | - **Comprehensive Documentation**: `LITESTREAM_SETUP_GUIDE.md` with troubleshooting
5265 |
5266 | #### Enhanced
5267 | - **Claude Commands**: Updated `memory-store.md` to document remote-first approach
5268 | - **Hybrid Strategy**: Remote API primary, local staging fallback
5269 | - **Sync Status**: Integration with `./sync/memory_sync.sh status` for pending changes
5270 | - **Automatic Context**: Git branch, project, and hostname detection
5271 |
5272 | #### Architecture
5273 | - **Remote-first Design**: Single source of truth on remote server with local caching
5274 | - **Conflict Resolution**: Last-write-wins with comprehensive logging and user notification
5275 | - **Network Resilience**: Graceful degradation from online → staging → read-only local
5276 | - **Git-like Workflow**: Familiar distributed workflow for developers
5277 |
5278 | #### Technical Details
5279 | - **Database Schema**: New staging database with triggers for change counting
5280 | - **HTTP Integration**: Secure HTTPS API communication with bearer token auth
5281 | - **Platform Support**: Cross-platform service management (systemd/LaunchDaemon)
5282 | - **Performance**: Lz4 compression for efficient snapshot transfers
5283 | - **Security**: Content hash verification and source machine tracking
5284 |
5285 | This release transforms MCP Memory Service from a local-only system into a fully distributed memory platform, enabling seamless synchronization across multiple devices while maintaining robust offline capabilities.
5286 |
5287 | ## [6.2.5] - 2025-08-21
5288 |
5289 | ### 🐛 **Bug Fix: SQLite-Vec Backend Debug Utilities**
5290 |
5291 | This release fixes a critical AttributeError in debug utilities when using the SQLite-Vec storage backend.
5292 |
5293 | #### Fixed
5294 | - **Debug Utilities Compatibility** ([#89](https://github.com/doobidoo/mcp-memory-service/issues/89)): Fixed `'SqliteVecMemoryStorage' object has no attribute 'model'` error
5295 | - Added compatibility helper `_get_embedding_model()` to handle different attribute names between storage backends
5296 | - ChromaDB backend uses `storage.model` while SQLite-Vec uses `storage.embedding_model`
5297 | - Updated all debug functions (`get_raw_embedding`, `check_embedding_model`, `debug_retrieve_memory`) to use the compatibility helper
5298 |
5299 | #### Technical Details
5300 | - **Affected Functions**:
5301 | - `get_raw_embedding()` - Now works with both backends
5302 | - `check_embedding_model()` - Properly detects model regardless of backend
5303 | - `debug_retrieve_memory()` - Semantic search debugging works for SQLite-Vec users
5304 |
5305 | #### Impact
5306 | - Users with SQLite-Vec backend can now use all MCP debug operations
5307 | - Semantic search and embedding inspection features work correctly
5308 | - No breaking changes for ChromaDB backend users
5309 |
5310 | ## [6.2.4] - 2025-08-21
5311 |
5312 | ### 🐛 **CRITICAL BUG FIXES: Claude Code Hooks Compatibility**
5313 |
5314 | This release fixes critical compatibility issues with Claude Code hooks that prevented automatic memory injection at session start.
5315 |
5316 | #### Fixed
5317 | - **Claude Code Hooks API Parameters**: Fixed incorrect API parameters in `claude-hooks/core/session-start.js`
5318 | - Replaced invalid `tags`, `limit`, `time_filter` parameters with correct `n_results` for `retrieve_memory` API
5319 | - Hooks now work correctly with MCP Memory Service API without parameter errors
5320 |
5321 | - **Python Dict Response Parsing**: Fixed critical parsing bug where hooks couldn't process MCP service responses
5322 | - Added proper Python dictionary format to JavaScript object conversion
5323 | - Implemented fallback parsing for different response formats
5324 | - Hooks now successfully parse memory service responses and inject context
5325 |
5326 | - **Memory Export Security**: Enhanced security for memory export files
5327 | - Added `local_export*.json` to .gitignore to prevent accidental commits of sensitive data
5328 | - Created safe template files in `examples/` directory for documentation and testing
5329 |
5330 | #### Added
5331 | - **Memory Export Templates**: New example files showing export format structure
5332 | - `examples/memory_export_template.json`: Basic example with 3 sample memories
5333 | - Clean, sanitized examples safe for sharing and documentation
5334 |
5335 | #### Technical Details
5336 | - **Response Format Handling**: Hooks now handle Python dict format responses with proper conversion to JavaScript objects
5337 | - **Error Handling**: Added multiple fallback mechanisms for response parsing
5338 | - **API Compatibility**: Updated to use correct MCP protocol parameters for memory retrieval
5339 |
5340 | #### Impact
5341 | - Claude Code hooks will now work out-of-the-box without manual fixes
5342 | - Memory context injection at session start now functions correctly
5343 | - Users can install hooks directly from repository without encountering parsing errors
5344 | - Enhanced security prevents accidental exposure of sensitive data in exports
5345 |
5346 | ## [6.2.3] - 2025-08-20
5347 |
5348 | ### 🛠️ **Cross-Platform Path Detection & Claude Code Integration**
5349 |
5350 | This release provides comprehensive cross-platform fixes for path detection issues and complete Claude Code hooks integration across Linux, macOS, and Windows.
5351 |
5352 | #### Fixed
5353 | - **Linux Path Detection**: Enhanced `scripts/remote_ingest.sh` to auto-detect mcp-memory-service repository location anywhere in user's home directory
5354 | - Resolves path case sensitivity issues (Repositories vs repositories)
5355 | - Works regardless of where users clone the repository
5356 | - Validates found directory contains pyproject.toml to ensure correct repository
5357 |
5358 | - **Windows Path Detection**: Added comprehensive Windows support with PowerShell and batch scripts
5359 | - New: `claude-hooks/install_claude_hooks_windows.ps1` - Full-featured PowerShell installation
5360 | - New: `claude-hooks/install_claude_hooks_windows.bat` - Batch wrapper for easy execution
5361 | - Dynamic repository location detection using PSScriptRoot resolution
5362 | - Comprehensive Claude Code hooks directory detection with fallbacks
5363 | - Improved error handling and validation for source/target directories
5364 | - Resolves hardcoded Unix path issues (`\home\hkr\...`) on Windows systems
5365 | - Tested with 100% success rate across Windows environments
5366 |
5367 | - **Claude Code Commands Documentation**: Fixed and enhanced memory commands documentation
5368 | - Updated command usage from `/memory-store` to `claude /memory-store`
5369 | - Added comprehensive troubleshooting section for command installation issues
5370 | - Documented both Claude Code commands and direct API alternatives
5371 | - Added installation instructions and quick fixes for common problems
5372 |
5373 | #### Technical Improvements
5374 | - Repository detection now works on any platform and directory structure
5375 | - Claude Code hooks installation handles Windows-specific path formats
5376 | - Improved error messages and debug output across all platforms
5377 | - Consistent behavior across Windows, Linux, and macOS platforms
5378 |
5379 | ## [6.2.2] - 2025-08-20
5380 |
5381 | ### 🔧 Fixed
5382 | - **Remote Ingestion Script Path Detection**: Enhanced `scripts/remote_ingest.sh` to auto-detect mcp-memory-service repository location anywhere in user's home directory instead of hardcoded path assumptions
5383 | - Resolves path case sensitivity issues (Repositories vs repositories)
5384 | - Works regardless of where users clone the repository
5385 | - Validates found directory contains pyproject.toml to ensure correct repository
5386 |
5387 | ## [6.2.1] - 2025-08-20
5388 |
5389 | ### 🐛 **CRITICAL BUG FIXES: Memory Listing and Search Index**
5390 |
5391 | This patch release resolves critical issues with memory pagination and search functionality that were preventing users from accessing the full dataset.
5392 |
5393 | #### Fixed
5394 | - **Memory API Pagination**: Fixed `/api/memories` endpoint returning only 82 of 904 total memories
5395 | - **Root Cause**: API was using semantic search fallback instead of proper chronological listing
5396 | - **Solution**: Implemented dedicated `get_all_memories()` method with SQL-based LIMIT/OFFSET pagination
5397 | - **Impact**: Web dashboard and API clients now see accurate memory counts and can access complete dataset
5398 |
5399 | - **Missing Storage Backend Methods**: Added missing pagination methods in SqliteVecMemoryStorage
5400 | - `get_all_memories(limit, offset)` - Chronological memory listing with pagination support
5401 | - `get_recent_memories(n)` - Get n most recent memories efficiently
5402 | - `count_all_memories()` - Accurate total count for pagination calculations
5403 | - `_row_to_memory(row)` - Proper database row to Memory object conversion with JSON parsing
5404 |
5405 | - **Search Index Issues**: Resolved problems with recently stored memories not appearing in searches
5406 | - **Tag Search**: Newly stored memories now immediately appear in tag-based filtering
5407 | - **Semantic Search**: MCP protocol semantic search verified working with similarity scoring
5408 | - **Memory Context**: `/memory-context` command functionality confirmed end-to-end
5409 |
5410 | #### Technical Details
5411 | - **Files Modified**:
5412 | - `src/mcp_memory_service/storage/sqlite_vec.py` - Added 75+ lines of pagination methods
5413 | - `src/mcp_memory_service/web/api/memories.py` - Fixed pagination logic to use proper SQL queries
5414 | - **Database Access**: Replaced unreliable semantic search with direct SQL `ORDER BY created_at DESC`
5415 | - **Error Handling**: Added comprehensive JSON parsing for tags and metadata with graceful fallbacks
5416 | - **Verification**: All 904 memories now accessible via REST API with proper page navigation
5417 |
5418 | #### Verification Results
5419 | - ✅ **API Pagination**: Returns accurate 904 total count (was showing 82)
5420 | - ✅ **Search Functionality**: Tag searches work immediately after storage
5421 | - ✅ **Memory Context**: Session storage and retrieval verified end-to-end
5422 | - ✅ **Semantic Search**: MCP protocol search confirmed functional with similarity scoring
5423 | - ✅ **Performance**: No performance degradation despite handling full dataset
5424 |
5425 | This release ensures reliable access to the complete memory dataset with proper pagination and search capabilities.
5426 |
5427 | ---
5428 |
5429 | ## [6.2.0] - 2025-08-20
5430 |
5431 | ### 🚀 **MAJOR FEATURE: Native Cloudflare Backend Integration**
5432 |
5433 | This major release introduces native Cloudflare integration as a third storage backend option alongside SQLite-vec and ChromaDB, providing global distribution, automatic scaling, and enterprise-grade infrastructure, integrated with the existing Memory Awareness system.
5434 |
5435 | #### Added
5436 | - **Native Cloudflare Backend Support**: Complete implementation using Cloudflare's edge computing platform
5437 | - **Vectorize**: 768-dimensional vector storage with cosine similarity for semantic search
5438 | - **D1 Database**: SQLite-compatible database for metadata storage
5439 | - **Workers AI**: Embedding generation using @cf/baai/bge-base-en-v1.5 model
5440 | - **R2 Storage** (optional): Object storage for large content exceeding 1MB threshold
5441 |
5442 | - **Implementation Files**:
5443 | - `src/mcp_memory_service/storage/cloudflare.py` - Complete CloudflareStorage implementation (740 lines)
5444 | - `scripts/migrate_to_cloudflare.py` - Migration tool for existing SQLite-vec and ChromaDB users
5445 | - `scripts/test_cloudflare_backend.py` - Comprehensive test suite with automated validation
5446 | - `scripts/setup_cloudflare_resources.py` - Automated Cloudflare resource provisioning
5447 | - `docs/cloudflare-setup.md` - Complete setup, configuration, and troubleshooting guide
5448 | - `tests/unit/test_cloudflare_storage.py` - 15 unit tests for CloudflareStorage class
5449 |
5450 | - **Features**:
5451 | - Automatic retry logic with exponential backoff for API rate limiting
5452 | - Connection pooling for optimal HTTP performance
5453 | - NDJSON format support for Vectorize v2 API endpoints
5454 | - LRU caching (1000 entries) for embedding deduplication
5455 | - Batch operations support for efficient data processing
5456 | - Global distribution with <100ms latency from most locations
5457 | - Pay-per-use pricing model with no upfront costs
5458 |
5459 | #### Changed
5460 | - Updated `config.py` to include 'cloudflare' in SUPPORTED_BACKENDS
5461 | - Enhanced server initialization in `mcp_server.py` to support Cloudflare backend
5462 | - Updated storage factory in `storage/__init__.py` to create CloudflareStorage instances
5463 | - Consolidated documentation, removing redundant setup files
5464 |
5465 | #### Technical Details
5466 | - **Environment Variables**:
5467 | - `MCP_MEMORY_STORAGE_BACKEND=cloudflare` - Activate Cloudflare backend
5468 | - `CLOUDFLARE_API_TOKEN` - API token with Vectorize, D1, Workers AI permissions
5469 | - `CLOUDFLARE_ACCOUNT_ID` - Cloudflare account identifier
5470 | - `CLOUDFLARE_VECTORIZE_INDEX` - Name of Vectorize index (768 dimensions)
5471 | - `CLOUDFLARE_D1_DATABASE_ID` - D1 database UUID
5472 | - `CLOUDFLARE_R2_BUCKET` (optional) - R2 bucket for large content
5473 |
5474 | - **Performance Characteristics**:
5475 | - Storage: ~200ms per memory (including embedding generation)
5476 | - Search: ~100ms for semantic search (5 results)
5477 | - Batch operations: ~50ms per memory in batches of 100
5478 | - Global latency: <100ms from most global locations
5479 |
5480 | #### Migration Path
5481 | Users can migrate from existing backends using provided scripts:
5482 | ```bash
5483 | # From SQLite-vec
5484 | python scripts/migrate_to_cloudflare.py --source sqlite
5485 |
5486 | # From ChromaDB
5487 | python scripts/migrate_to_cloudflare.py --source chroma
5488 | ```
5489 |
5490 | #### Memory Awareness Integration
5491 | - **Full Compatibility**: Cloudflare backend works seamlessly with Phase 1 and Phase 2 Memory Awareness
5492 | - **Cross-Session Intelligence**: Session tracking and conversation threading supported
5493 | - **Dynamic Context Updates**: Real-time memory loading during conversations
5494 | - **Global Performance**: Enhances Memory Awareness with <100ms global response times
5495 |
5496 | #### Compatibility
5497 | - Fully backward compatible with existing SQLite-vec and ChromaDB backends
5498 | - No breaking changes to existing APIs or configurations
5499 | - Supports all existing MCP operations and features
5500 | - Compatible with all existing Memory Awareness hooks and functionality
5501 |
5502 | ## [6.1.1] - 2025-08-20
5503 |
5504 | ### 🐛 **CRITICAL BUG FIX: Memory Retrieval by Hash**
5505 |
5506 | #### Fixed
5507 | - **Memory Retrieval 404 Issue**: Fixed HTTP API returning 404 errors for valid memory hashes
5508 | - **Direct Hash Lookup**: Added `get_by_hash()` method to `SqliteVecMemoryStorage` for proper content hash retrieval
5509 | - **API Endpoint Correction**: Updated `/api/memories/{content_hash}` to use direct hash lookup instead of semantic search
5510 | - **Production Deployment**: Successfully deployed fix to production servers and verified functionality
5511 |
5512 | #### Technical Details
5513 | - **Root Cause**: HTTP API was incorrectly using `storage.retrieve()` (semantic search) instead of direct hash-based lookup
5514 | - **Solution**: Implemented dedicated hash lookup method that queries database directly using content hash as primary key
5515 | - **Impact**: Web dashboard memory retrieval by hash now works correctly without SSL certificate issues or false 404 responses
5516 | - **Testing**: Verified with multiple memory hashes including previously failing hash `812d361cbfd1b79a49737e6ea34e24459b4d064908e222d98af6a504aa09ff19`
5517 |
5518 | #### Deployment
5519 | - Version 6.1.1 deployed to production server `10.0.1.30:8443`
5520 | - Service restart completed successfully
5521 | - Health check confirmed: Version 6.1.1 running with full functionality
5522 |
5523 | ## [6.1.0] - 2025-08-20
5524 |
5525 | ### 🚀 **MAJOR FEATURE: Intelligent Context Updates (Phase 2)**
5526 |
5527 | #### Conversation-Aware Dynamic Memory Loading
5528 | This release introduces **Phase 2 of Claude Code Memory Awareness** - transforming the system from static memory injection to intelligent, real-time conversation analysis with dynamic context updates during active coding sessions.
5529 |
5530 | #### Added
5531 |
5532 | ##### 🧠 **Dynamic Memory Loading System**
5533 | - **Real-time Topic Detection**: Analyzes conversation flow to detect significant topic shifts
5534 | - **Automatic Context Updates**: Injects relevant memories as conversations evolve naturally
5535 | - **Smart Deduplication**: Prevents re-injection of already loaded memories
5536 | - **Intelligent Rate Limiting**: 30-second cooldown and session limits prevent context overload
5537 | - **Cross-Session Intelligence**: Links related conversations across different sessions
5538 |
5539 | ##### 🔍 **Advanced Conversation Analysis Engine**
5540 | - **Natural Language Processing**: Extracts topics, entities, intent, and code context from conversations
5541 | - **15+ Technical Topic Categories**: database, debugging, architecture, testing, deployment, etc.
5542 | - **Entity Recognition**: Technologies, frameworks, languages, tools (JavaScript, Python, React, etc.)
5543 | - **Intent Classification**: learning, problem-solving, development, optimization, review, planning
5544 | - **Code Context Detection**: Identifies code blocks, file paths, error messages, commands
5545 |
5546 | ##### 📊 **Enhanced Memory Scoring with Conversation Context**
5547 | - **Multi-Factor Relevance Algorithm**: 5-factor scoring system including conversation context (25% weight)
5548 | - **Dynamic Weight Adjustment**: Adapts scoring based on conversation analysis
5549 | - **Topic Alignment Matching**: Prioritizes memories matching current conversation topics
5550 | - **Intent-Based Scoring**: Aligns memory relevance with conversation purpose
5551 | - **Semantic Content Analysis**: Advanced content matching with conversation context
5552 |
5553 | ##### 🔗 **Cross-Session Intelligence & Conversation Threading**
5554 | - **Session Tracking**: Links related sessions across time with unique thread IDs
5555 | - **Conversation Continuity**: Builds conversation threads over multiple sessions
5556 | - **Progress Context**: Connects outcomes from previous sessions to current work
5557 | - **Pattern Recognition**: Identifies recurring topics and workflow patterns
5558 | - **Historical Context**: Includes insights from recent related sessions (up to 3 sessions, 7 days back)
5559 |
5560 | ##### ⚡ **Performance & Reliability**
5561 | - **Efficient Processing**: <500ms response time for topic detection and memory queries
5562 | - **Scalable Architecture**: Handles 100+ active memories per session
5563 | - **Smart Debouncing**: 5-second debounce prevents rapid-fire updates
5564 | - **Resource Optimization**: Intelligent memory management and context deduplication
5565 | - **Comprehensive Testing**: 100% test pass rate (15/15 tests) with full integration coverage
5566 |
5567 | #### Technical Implementation
5568 |
5569 | ##### Core Phase 2 Components
5570 | - **conversation-analyzer.js**: NLP engine for topic/entity/intent detection
5571 | - **topic-change.js**: Monitors conversation flow and triggers dynamic updates
5572 | - **memory-scorer.js**: Enhanced scoring with conversation context awareness
5573 | - **session-tracker.js**: Cross-session intelligence and conversation threading
5574 | - **dynamic-context-updater.js**: Orchestrates all Phase 2 components with rate limiting
5575 |
5576 | ##### Configuration Enhancements
5577 | - **Phase 2 Settings**: New configuration sections for conversation analysis, dynamic updates, session tracking
5578 | - **Flexible Thresholds**: Configurable significance scores, update limits, and confidence levels
5579 | - **Feature Toggles**: Independent enable/disable for each Phase 2 capability
5580 |
5581 | #### User Experience Improvements
5582 | - **Zero Cognitive Load**: Context updates happen automatically during conversations
5583 | - **Perfect Timing**: Memories appear exactly when relevant to current discussion
5584 | - **Seamless Integration**: Works transparently during normal coding sessions
5585 | - **Progressive Learning**: Each conversation builds upon previous knowledge intelligently
5586 |
5587 | #### Migration from Phase 1
5588 | - **Backward Compatible**: Phase 1 features remain fully functional
5589 | - **Additive Enhancement**: Phase 2 builds upon Phase 1 session-start memory injection
5590 | - **Unified Configuration**: Single config.json manages both Phase 1 and Phase 2 settings
5591 |
5592 | ## [6.0.0] - 2025-08-19
5593 |
5594 | ### 🧠 **MAJOR FEATURE: Claude Code Memory Awareness (Phase 1)**
5595 |
5596 | #### Revolutionary Memory-Aware Development Experience
5597 | This major release introduces **automatic memory awareness for Claude Code** - a sophisticated hook system that transforms how developers interact with their project knowledge and conversation history.
5598 |
5599 | #### Added
5600 |
5601 | ##### 🔄 **Session Lifecycle Hooks**
5602 | - **Session-Start Hook**: Automatically injects relevant memories when starting Claude Code sessions
5603 | - Intelligent project detection supporting JavaScript, Python, Rust, Go, Java, C++, and more
5604 | - Multi-factor memory relevance scoring with time decay, tag matching, and content analysis
5605 | - Context-aware memory selection (up to 8 most relevant memories per session)
5606 | - Beautiful markdown formatting for seamless context integration
5607 |
5608 | - **Session-End Hook**: Captures and consolidates session outcomes automatically
5609 | - Conversation analysis and intelligent summarization
5610 | - Automatic tagging with project context and session insights
5611 | - Long-term knowledge building through outcome storage
5612 | - Session relationship tracking for continuity
5613 |
5614 | ##### 🎯 **Advanced Project Detection System**
5615 | - **Multi-Language Support**: Detects 15+ project types and frameworks
5616 | - Package managers: `package.json`, `Cargo.toml`, `go.mod`, `requirements.txt`, `pom.xml`
5617 | - Build systems: `Makefile`, `CMakeLists.txt`, `build.gradle`, `setup.py`
5618 | - Configuration files: `tsconfig.json`, `pyproject.toml`, `.gitignore`
5619 | - **Git Integration**: Repository context analysis with branch and commit information
5620 | - **Framework Detection**: React, Vue, Angular, Django, Flask, Express, and more
5621 | - **Technology Stack Analysis**: Automatic identification of languages, databases, and tools
5622 |
5623 | ##### 🧮 **Intelligent Memory Scoring System**
5624 | - **Time Decay Algorithm**: Recent memories weighted higher with configurable decay curves
5625 | - **Tag Relevance Matching**: Project-specific and technology-specific tag scoring
5626 | - **Content Similarity Analysis**: Semantic matching with current project context
5627 | - **Memory Type Bonuses**: Prioritizes decisions, insights, and architecture notes
5628 | - **Relevance Threshold**: Only injects memories above significance threshold (>0.3)
5629 |
5630 | ##### 🎨 **Context Formatting & Presentation**
5631 | - **Categorized Memory Display**: Organized by Recent Insights, Key Decisions, and Project Context
5632 | - **Markdown-Rich Formatting**: Beautiful presentation with metadata, timestamps, and tags
5633 | - **Configurable Limits**: Prevents context overload with smart memory selection
5634 | - **Source Attribution**: Clear memory source tracking with content hashes
5635 |
5636 | ##### 💻 **Complete Installation & Testing System**
5637 | - **One-Command Installation**: `./install.sh` deploys entire system to Claude Code hooks
5638 | - **Comprehensive Test Suite**: 10 integration tests with 100% pass rate
5639 | - Project detection testing across multiple languages
5640 | - Memory scoring algorithm validation
5641 | - Context formatting verification
5642 | - Hook structure and configuration validation
5643 | - MCP service connectivity testing
5644 | - **Configuration Management**: Production-ready config with memory service endpoints
5645 | - **Backup and Recovery**: Automatic backup of existing hooks during installation
5646 |
5647 | #### Technical Architecture
5648 |
5649 | ##### 🏗️ **Claude Code Hooks System**
5650 | ```javascript
5651 | claude-hooks/
5652 | ├── core/
5653 | │ ├── session-start.js # Automatic memory injection hook
5654 | │ └── session-end.js # Session consolidation hook
5655 | ├── utilities/
5656 | │ ├── project-detector.js # Multi-language project detection
5657 | │ ├── memory-scorer.js # Relevance scoring algorithms
5658 | │ └── context-formatter.js # Memory presentation utilities
5659 | ├── tests/
5660 | │ └── integration-test.js # Complete test suite (100% pass)
5661 | ├── config.json # Production configuration
5662 | └── install.sh # One-command installation
5663 | ```
5664 |
5665 | ##### 🔗 **MCP Memory Service Integration**
5666 | - **JSON-RPC Protocol**: Direct communication with MCP Memory Service
5667 | - **Error Handling**: Graceful degradation when memory service unavailable
5668 | - **Performance Optimization**: Efficient memory querying with result caching
5669 | - **Security**: Content hash verification and safe JSON parsing
5670 |
5671 | ##### 📊 **Memory Selection Algorithm**
5672 | ```javascript
5673 | // Multi-factor scoring system
5674 | const relevanceScore = (
5675 | timeDecayScore * 0.4 + // Recent memories preferred
5676 | tagRelevanceScore * 0.3 + // Project-specific tags
5677 | contentSimilarityScore * 0.2 + // Semantic matching
5678 | memoryTypeBonusScore * 0.1 // Decision/insight bonus
5679 | );
5680 | ```
5681 |
5682 | #### Usage Examples
5683 |
5684 | ##### Automatic Session Context
5685 | ```markdown
5686 | # 🧠 Relevant Memory Context
5687 |
5688 | ## Recent Insights (Last 7 days)
5689 | - **Database Performance Issue** - Resolved SQLite-vec query optimization (yesterday)
5690 | - **Authentication Flow** - Implemented JWT token validation in API (3 days ago)
5691 |
5692 | ## Key Decisions
5693 | - **Architecture Decision** - Chose React over Vue for frontend consistency (1 week ago)
5694 | - **Database Choice** - Selected PostgreSQL for production scalability (2 weeks ago)
5695 |
5696 | ## Project Context: mcp-memory-service
5697 | - **Language**: JavaScript, Python
5698 | - **Frameworks**: Node.js, FastAPI
5699 | - **Recent Activity**: Bug fixes, feature implementation
5700 | ```
5701 |
5702 | ##### Session Outcome Storage
5703 | ```markdown
5704 | Session consolidated and stored with tags:
5705 | - mcp-memory-service, claude-code-session
5706 | - bug-fix, performance-optimization
5707 | - javascript, api-development
5708 | Content hash: abc123...def456
5709 | ```
5710 |
5711 | #### Benefits & Impact
5712 |
5713 | ##### 🚀 **Productivity Enhancements**
5714 | - **Zero Cognitive Load**: Memory context appears automatically without user intervention
5715 | - **Perfect Continuity**: Never lose track of decisions, insights, or architectural choices
5716 | - **Intelligent Context**: Only relevant memories shown, preventing information overload
5717 | - **Session Learning**: Each coding session builds upon previous knowledge automatically
5718 |
5719 | ##### 🧠 **Memory-Aware Development**
5720 | - **Decision Tracking**: Automatic capture of technical decisions and rationale
5721 | - **Knowledge Building**: Progressive accumulation of project understanding
5722 | - **Context Preservation**: Important insights never get lost between sessions
5723 | - **Team Knowledge Sharing**: Shareable memory context across team members
5724 |
5725 | ##### ⚡ **Performance Optimized**
5726 | - **Fast Startup**: Memory injection adds <2 seconds to session startup
5727 | - **Smart Caching**: Efficient memory retrieval with minimal API calls
5728 | - **Configurable Limits**: Prevents memory service overload with request throttling
5729 | - **Graceful Fallback**: Works with or without memory service availability
5730 |
5731 | #### Migration & Compatibility
5732 |
5733 | ##### 🔄 **Seamless Integration**
5734 | - **Non-Intrusive**: Works alongside existing Claude Code workflows
5735 | - **Backward Compatible**: No changes required to existing development processes
5736 | - **Optional Feature**: Can be enabled/disabled per project or globally
5737 | - **Multi-Environment**: Works with local, remote, and distributed memory services
5738 |
5739 | ##### 📋 **Installation Requirements**
5740 | - Claude Code CLI installed and configured
5741 | - MCP Memory Service running (local or remote)
5742 | - Node.js environment for hook execution
5743 | - Git repository for optimal project detection
5744 |
5745 | #### Roadmap Integration
5746 |
5747 | This release completes **Phase 1** of the Memory Awareness Enhancement Roadmap (Issue #14):
5748 | - ✅ Session startup hooks with automatic memory injection
5749 | - ✅ Project-aware memory selection algorithms
5750 | - ✅ Context formatting and injection utilities
5751 | - ✅ Comprehensive testing and installation system
5752 | - ✅ Production-ready configuration and deployment
5753 |
5754 | **Next Phase**: Dynamic memory loading, cross-session intelligence, and advanced consolidation features.
5755 |
5756 | #### Breaking Changes
5757 | None - This is a purely additive feature that enhances existing Claude Code functionality.
5758 |
5759 | ---
5760 |
5761 | ## [5.2.0] - 2025-08-18
5762 |
5763 | ### 🚀 **New Features**
5764 |
5765 | #### Command Line Interface (CLI)
5766 | - **Comprehensive CLI**: Added `memory` command with subcommands for document ingestion and management
5767 | - **Document Ingestion Commands**:
5768 | - `memory ingest-document <file>` - Ingest single documents with customizable chunking
5769 | - `memory ingest-directory <path>` - Batch process entire directories
5770 | - `memory list-formats` - Show all supported document formats
5771 | - **Management Commands**:
5772 | - `memory server` - Start the MCP server (replaces old `memory` command)
5773 | - `memory status` - Show service status and statistics
5774 | - **Advanced Options**: Tags, chunk sizing, storage backend selection, verbose output, dry-run mode
5775 | - **Progress Tracking**: Real-time progress bars and detailed error reporting
5776 | - **Cross-Platform**: Works on Windows, macOS, and Linux with proper path handling
5777 |
5778 | #### Enhanced Document Processing
5779 | - **Click Framework**: Professional CLI with help system and tab completion support
5780 | - **Async Operations**: Non-blocking document processing with proper resource management
5781 | - **Error Recovery**: Graceful handling of processing errors with detailed diagnostics
5782 | - **Batch Limits**: Configurable file limits and extension filtering for large directories
5783 |
5784 | **New Dependencies**: `click>=8.0.0` for CLI framework
5785 |
5786 | **Examples**:
5787 | ```bash
5788 | memory ingest-document manual.pdf --tags documentation,manual --verbose
5789 | memory ingest-directory ./docs --recursive --max-files 50
5790 | memory list-formats
5791 | memory status
5792 | ```
5793 |
5794 | **Backward Compatibility**: Old `memory` server command now available as `memory server` and `memory-server`
5795 |
5796 | ## [5.1.0] - 2025-08-18
5797 |
5798 | ### 🚀 **New Features**
5799 |
5800 | #### Remote ChromaDB Support
5801 | - **Enterprise-Ready**: Connect to remote ChromaDB servers, Chroma Cloud, or self-hosted instances
5802 | - **HttpClient Implementation**: Full support for remote ChromaDB connectivity
5803 | - **Authentication**: API key authentication via `X_CHROMA_TOKEN` header
5804 | - **SSL/HTTPS Support**: Secure connections to remote ChromaDB servers
5805 | - **Custom Collections**: Specify collection names for multi-tenant deployments
5806 |
5807 | **New Environment Variables:**
5808 | - `MCP_MEMORY_CHROMADB_HOST`: Remote server hostname (enables remote mode)
5809 | - `MCP_MEMORY_CHROMADB_PORT`: Server port (default: 8000)
5810 | - `MCP_MEMORY_CHROMADB_SSL`: Use HTTPS ('true'/'false')
5811 | - `MCP_MEMORY_CHROMADB_API_KEY`: Authentication token
5812 | - `MCP_MEMORY_COLLECTION_NAME`: Custom collection name (default: 'memory_collection')
5813 |
5814 | **Perfect Timing**: Arrives just as Chroma Cloud launches Q1 2025 (early access available)
5815 |
5816 | **Resolves**: #36 (Remote ChromaDB support request)
5817 |
5818 | ## [5.0.5] - 2025-08-18
5819 |
5820 | ### 🐛 **Bug Fixes**
5821 |
5822 | #### Code Quality & Future Compatibility
5823 | - **Fixed datetime deprecation warnings**: Replaced all `datetime.utcnow()` usage with `datetime.now(timezone.utc)`
5824 | - Updated `src/mcp_memory_service/web/api/health.py` (2 occurrences)
5825 | - Updated `src/mcp_memory_service/web/sse.py` (3 occurrences)
5826 | - Eliminates deprecation warnings in Python 3.12+
5827 | - Future-proof timezone-aware datetime handling
5828 |
5829 | ### 🎨 **UI Improvements**
5830 |
5831 | #### Dashboard Mobile Responsiveness
5832 | - **Enhanced mobile UX**: Added responsive design for action buttons
5833 | - Buttons now stack vertically on screens < 768px width
5834 | - Improved touch-friendly spacing and sizing
5835 | - Better mobile experience for API documentation links
5836 | - Maintains desktop horizontal layout on larger screens
5837 |
5838 | **Issues Resolved**: #68 (Code Quality & Deprecation Fixes), #80 (Dashboard Mobile Responsiveness)
5839 |
5840 | ## [5.0.4] - 2025-08-18
5841 |
5842 | ### 🐛 **Critical Bug Fixes**
5843 |
5844 | #### SQLite-vec Embedding Model Loading
5845 | - **Fixed UnboundLocalError**: Removed redundant `import os` statement at line 285 in `sqlite_vec.py`
5846 | - Variable shadowing prevented ONNX embedding model initialization
5847 | - Caused "cannot access local variable 'os'" error in production
5848 | - Restored full embedding functionality for memory storage
5849 |
5850 | #### Docker HTTP Server Support
5851 | - **Fixed Missing Files**: Added `run_server.py` to Docker image (reported by Joe Esposito)
5852 | - HTTP server wouldn't start without this critical file
5853 | - Now properly copied in Dockerfile for HTTP/API mode
5854 | - **Fixed Python Path**: Corrected `PYTHONPATH` from `/app` to `/app/src`
5855 | - Modules couldn't be found with incorrect path
5856 | - Essential for both MCP and HTTP modes
5857 |
5858 | ### 🚀 **Major Docker Improvements**
5859 |
5860 | #### Simplified Docker Architecture
5861 | - **Reduced Complexity by 60%**: Consolidated from 4 confusing compose files to 2 clear options
5862 | - `docker-compose.yml` for MCP protocol mode (Claude Desktop, VS Code)
5863 | - `docker-compose.http.yml` for HTTP/API mode (REST API, Web Dashboard)
5864 | - **Unified Entrypoint**: Created single smart entrypoint script
5865 | - Auto-detects mode from `MCP_MODE` environment variable
5866 | - Eliminates confusion about which script to use
5867 | - **Pre-download Models**: Embedding models now downloaded during Docker build
5868 | - Prevents runtime failures from network/DNS issues
5869 | - Makes containers fully self-contained
5870 | - Faster startup times
5871 |
5872 | #### Deprecated Docker Files
5873 | - Marked 4 redundant Docker files as deprecated:
5874 | - `docker-compose.standalone.yml` → Use `docker-compose.http.yml`
5875 | - `docker-compose.uv.yml` → UV now built into main Dockerfile
5876 | - `docker-compose.pythonpath.yml` → Fix applied to main Dockerfile
5877 | - `docker-entrypoint-persistent.sh` → Replaced by unified entrypoint
5878 |
5879 | ### 📝 **Documentation**
5880 |
5881 | #### Docker Documentation Overhaul
5882 | - **Added Docker README**: Clear instructions for both MCP and HTTP modes
5883 | - **Created DEPRECATED.md**: Migration guide for old Docker setups
5884 | - **Added Test Script**: `test-docker-modes.sh` to verify both modes work
5885 | - **Troubleshooting Guide**: Added comprehensive debugging section to CLAUDE.md
5886 | - Web frontend debugging (CSS/format string conflicts)
5887 | - Cache clearing procedures
5888 | - Environment reset steps
5889 | - Backend method compatibility
5890 |
5891 | ### 🙏 **Credits**
5892 | - Special thanks to **Joe Esposito** for identifying and helping fix critical Docker issues
5893 |
5894 | ## [5.0.3] - 2025-08-17
5895 |
5896 | ### 🐛 **Bug Fixes**
5897 |
5898 | #### SQLite-vec Backend Method Support
5899 | - **Fixed Missing Method**: Added `search_by_tags` method to SQLite-vec backend
5900 | - Web API was calling `search_by_tags` (plural) but backend only had `search_by_tag` (singular)
5901 | - This caused 500 errors when using tag-based search via HTTP/MCP endpoints
5902 | - New method supports both AND/OR operations for tag matching
5903 | - Fixes network distribution and memory retrieval functionality
5904 |
5905 | ### 🚀 **Enhancements**
5906 |
5907 | #### Version Information in Health Checks
5908 | - **Added Version Field**: All health endpoints now return service version
5909 | - Basic health endpoint (`/api/health`) includes version field
5910 | - Detailed health endpoint (`/api/health/detailed`) includes version field
5911 | - MCP `check_database_health` tool returns version in response
5912 | - Enables easier debugging and version tracking across deployments
5913 |
5914 | ### 🚀 **New Features**
5915 |
5916 | #### Memory Distribution and Network Sharing
5917 | - **Export Tool**: Added `scripts/export_distributable_memories.sh` for memory export
5918 | - Export memories tagged with `distributable-reference` for team sharing
5919 | - JSON format for easy import to other MCP instances
5920 | - Support for cross-network memory synchronization
5921 | - **Personalized CLAUDE.md Generator**: Added `scripts/generate_personalized_claude_md.sh`
5922 | - Generate CLAUDE.md with embedded memory service endpoints
5923 | - Customize for different network deployments
5924 | - Include memory retrieval commands for each environment
5925 | - **Memory Context Templates**: Added `prompts/load_memory_context.md`
5926 | - Ready-to-use prompts for loading project context
5927 | - Quick retrieval commands for Claude Code sessions
5928 | - Network distribution instructions
5929 |
5930 | ### 📝 **Documentation**
5931 |
5932 | #### Network Distribution Updates
5933 | - **Fixed Memory Retrieval Commands**: Updated scripts to use working API methods
5934 | - Changed from non-existent `search_by_tag` to `retrieve_memory` for current deployments
5935 | - Updated prompt templates and distribution scripts
5936 | - Improved error handling for memory context loading
5937 | - **CLAUDE.md Enhancements**: Added optional memory context section
5938 | - Instructions for setting up local memory service integration
5939 | - Guidelines for creating CLAUDE_MEMORY.md (git-ignored) for local configurations
5940 | - Best practices for memory management and quarterly reviews
5941 |
5942 | ## [5.0.2] - 2025-08-17
5943 |
5944 | ### 🚀 **New Features**
5945 |
5946 | #### ONNX Runtime Support
5947 | - **PyTorch-free operation**: True PyTorch-free embedding generation using ONNX Runtime
5948 | - Reduced dependencies (~500MB less disk space without PyTorch)
5949 | - Faster startup with pre-optimized ONNX models
5950 | - Automatic fallback to SentenceTransformers when needed
5951 | - Compatible with the same `all-MiniLM-L6-v2` model embeddings
5952 | - Enable with `export MCP_MEMORY_USE_ONNX=true`
5953 |
5954 | ### 🐛 **Bug Fixes**
5955 |
5956 | #### SQLite-vec Consolidation Support (Issue #84)
5957 | - **Missing Methods Fixed**: Added all required methods for consolidation support
5958 | - Implemented `get_memories_by_time_range()` for time-based queries
5959 | - Added `get_memory_connections()` for relationship tracking statistics
5960 | - Added `get_access_patterns()` for access pattern analysis
5961 | - Added `get_all_memories()` method with proper SQL implementation
5962 |
5963 | #### Installer Accuracy
5964 | - **False ONNX Claims**: Fixed misleading installer messages about ONNX support
5965 | - Removed false claims about "ONNX runtime for embeddings" when no implementation existed
5966 | - Updated installer messages to accurately reflect capabilities
5967 | - Now actually implements the ONNX support that was previously claimed
5968 |
5969 | #### Docker Configuration
5970 | - **SQLite-vec Defaults**: Updated Docker configuration to reflect SQLite-vec as default backend
5971 | - Updated `Dockerfile` environment variables to use `MCP_MEMORY_STORAGE_BACKEND=sqlite_vec`
5972 | - Changed paths from `/app/chroma_db` to `/app/sqlite_db`
5973 | - Updated `docker-compose.yml` with SQLite-vec configuration
5974 | - Fixed volume mounts and environment variables
5975 |
5976 | ### 📝 **Documentation**
5977 |
5978 | #### Enhanced README
5979 | - **ONNX Feature Documentation**: Added comprehensive ONNX Runtime feature section
5980 | - **Installation Updates**: Updated installation instructions with ONNX dependencies
5981 | - **Feature Visibility**: Highlighted ONNX support in main features list
5982 |
5983 | #### Technical Implementation
5984 | - **New Module**: Created `src/mcp_memory_service/embeddings/onnx_embeddings.py`
5985 | - Complete ONNX embedding implementation based on ChromaDB's ONNXMiniLM_L6_V2
5986 | - Automatic model downloading and caching
5987 | - Hardware-aware provider selection (CPU, CUDA, DirectML, CoreML)
5988 | - Error handling with graceful fallbacks
5989 |
5990 | - **Enhanced Configuration**: Added ONNX configuration support in `config.py`
5991 | - `USE_ONNX` configuration option
5992 | - ONNX model cache directory management
5993 | - Environment variable support for `MCP_MEMORY_USE_ONNX`
5994 |
5995 | ### Technical Notes
5996 | - Full backward compatibility maintained for existing SQLite-vec users
5997 | - ONNX support is optional and falls back gracefully to SentenceTransformers
5998 | - All consolidation methods implemented with proper error handling
5999 | - Docker images now correctly reflect the SQLite-vec default backend
6000 |
6001 | This release resolves all issues reported in GitHub issue #84, implementing true ONNX support and completing the SQLite-vec consolidation feature set.
6002 | ## [6.2.0] - 2025-08-20
6003 |
6004 | ### 🚀 **MAJOR FEATURE: Native Cloudflare Backend Integration**
6005 |
6006 | This major release introduces native Cloudflare integration as a third storage backend option alongside SQLite-vec and ChromaDB, providing global distribution, automatic scaling, and enterprise-grade infrastructure, integrated with the existing Memory Awareness system.
6007 |
6008 | #### Added
6009 | - **Native Cloudflare Backend Support**: Complete implementation using Cloudflare's edge computing platform
6010 | - **Vectorize**: 768-dimensional vector storage with cosine similarity for semantic search
6011 | - **D1 Database**: SQLite-compatible database for metadata storage
6012 | - **Workers AI**: Embedding generation using @cf/baai/bge-base-en-v1.5 model
6013 | - **R2 Storage** (optional): Object storage for large content exceeding 1MB threshold
6014 |
6015 | - **Implementation Files**:
6016 | - `src/mcp_memory_service/storage/cloudflare.py` - Complete CloudflareStorage implementation (740 lines)
6017 | - `scripts/migrate_to_cloudflare.py` - Migration tool for existing SQLite-vec and ChromaDB users
6018 | - `scripts/test_cloudflare_backend.py` - Comprehensive test suite with automated validation
6019 | - `scripts/setup_cloudflare_resources.py` - Automated Cloudflare resource provisioning
6020 | - `docs/cloudflare-setup.md` - Complete setup, configuration, and troubleshooting guide
6021 | - `tests/unit/test_cloudflare_storage.py` - 15 unit tests for CloudflareStorage class
6022 |
6023 | - **Features**:
6024 | - Automatic retry logic with exponential backoff for API rate limiting
6025 | - Connection pooling for optimal HTTP performance
6026 | - NDJSON format support for Vectorize v2 API endpoints
6027 | - LRU caching (1000 entries) for embedding deduplication
6028 | - Batch operations support for efficient data processing
6029 | - Global distribution with <100ms latency from most locations
6030 | - Pay-per-use pricing model with no upfront costs
6031 |
6032 | #### Changed
6033 | - Updated `config.py` to include 'cloudflare' in SUPPORTED_BACKENDS
6034 | - Enhanced server initialization in `mcp_server.py` to support Cloudflare backend
6035 | - Updated storage factory in `storage/__init__.py` to create CloudflareStorage instances
6036 | - Consolidated documentation, removing redundant setup files
6037 |
6038 | #### Technical Details
6039 | - **Environment Variables**:
6040 | - `MCP_MEMORY_STORAGE_BACKEND=cloudflare` - Activate Cloudflare backend
6041 | - `CLOUDFLARE_API_TOKEN` - API token with Vectorize, D1, Workers AI permissions
6042 | - `CLOUDFLARE_ACCOUNT_ID` - Cloudflare account identifier
6043 | - `CLOUDFLARE_VECTORIZE_INDEX` - Name of Vectorize index (768 dimensions)
6044 | - `CLOUDFLARE_D1_DATABASE_ID` - D1 database UUID
6045 | - `CLOUDFLARE_R2_BUCKET` (optional) - R2 bucket for large content
6046 |
6047 | - **Performance Characteristics**:
6048 | - Storage: ~200ms per memory (including embedding generation)
6049 | - Search: ~100ms for semantic search (5 results)
6050 | - Batch operations: ~50ms per memory in batches of 100
6051 | - Global latency: <100ms from most global locations
6052 |
6053 | #### Migration Path
6054 | Users can migrate from existing backends using provided scripts:
6055 | ```bash
6056 | # From SQLite-vec
6057 | python scripts/migrate_to_cloudflare.py --source sqlite
6058 |
6059 | # From ChromaDB
6060 | python scripts/migrate_to_cloudflare.py --source chroma
6061 | ```
6062 |
6063 | #### Memory Awareness Integration
6064 | - **Full Compatibility**: Cloudflare backend works seamlessly with Phase 1 and Phase 2 Memory Awareness
6065 | - **Cross-Session Intelligence**: Session tracking and conversation threading supported
6066 | - **Dynamic Context Updates**: Real-time memory loading during conversations
6067 | - **Global Performance**: Enhances Memory Awareness with <100ms global response times
6068 |
6069 | #### Compatibility
6070 | - Fully backward compatible with existing SQLite-vec and ChromaDB backends
6071 | - No breaking changes to existing APIs or configurations
6072 | - Supports all existing MCP operations and features
6073 | - Compatible with all existing Memory Awareness hooks and functionality
6074 |
6075 | ## [5.0.1] - 2025-08-15
6076 |
6077 | ### 🐛 **Critical Migration Fixes**
6078 |
6079 | This patch release addresses critical issues in the v5.0.0 ChromaDB to SQLite-vec migration process reported in [Issue #83](https://github.com/doobidoo/mcp-memory-service/issues/83).
6080 |
6081 | #### Fixed
6082 | - **Custom Data Paths**: Migration scripts now properly support custom ChromaDB locations via CLI arguments and environment variables
6083 | - Added `--chroma-path` and `--sqlite-path` arguments to migration scripts
6084 | - Support for `MCP_MEMORY_CHROMA_PATH` and `MCP_MEMORY_SQLITE_PATH` environment variables
6085 | - Fixed hardcoded path assumptions that ignored user configurations
6086 |
6087 | - **Content Hash Generation**: Fixed critical bug where ChromaDB document IDs were used instead of proper SHA256 hashes
6088 | - Now generates correct content hashes using SHA256 algorithm
6089 | - Prevents "NOT NULL constraint failed" errors during migration
6090 | - Ensures data integrity and proper deduplication
6091 |
6092 | - **Tag Format Corruption**: Fixed issue where 60% of tags became malformed during migration
6093 | - Improved tag validation and format conversion
6094 | - Handles comma-separated strings, arrays, and single tags correctly
6095 | - Prevents array syntax from being stored as strings
6096 |
6097 | - **Migration Progress**: Added progress indicators and better error reporting
6098 | - Shows percentage completion during migration
6099 | - Batch processing with configurable batch size
6100 | - Verbose mode for detailed debugging
6101 | - Clear error messages for troubleshooting
6102 |
6103 | #### Added
6104 | - **Enhanced Migration Script** (`scripts/migrate_v5_enhanced.py`):
6105 | - Comprehensive migration tool with all fixes
6106 | - Dry-run mode for testing migrations
6107 | - Transaction-based migration with rollback support
6108 | - Progress bars with `tqdm` support
6109 | - JSON backup creation
6110 | - Automatic path detection for common installations
6111 |
6112 | - **Migration Validator** (`scripts/validate_migration.py`):
6113 | - Validates migrated SQLite database integrity
6114 | - Checks for missing fields and corrupted data
6115 | - Compares with original ChromaDB data
6116 | - Generates detailed validation report
6117 | - Identifies specific issues like hash mismatches and tag corruption
6118 |
6119 | - **Comprehensive Documentation**:
6120 | - Updated migration guide with troubleshooting section
6121 | - Documented all known v5.0.0 issues and solutions
6122 | - Added recovery procedures for failed migrations
6123 | - Migration best practices and validation steps
6124 |
6125 | #### Enhanced
6126 | - **Original Migration Script** (`scripts/migrate_chroma_to_sqlite.py`):
6127 | - Added CLI argument support for custom paths
6128 | - Fixed content hash generation
6129 | - Improved tag handling
6130 | - Better duplicate detection
6131 | - Progress percentage display
6132 |
6133 | #### Documentation
6134 | - **Migration Troubleshooting Guide**: Added comprehensive troubleshooting section covering:
6135 | - Custom data location issues
6136 | - Content hash errors
6137 | - Tag corruption problems
6138 | - Migration hangs
6139 | - Dependency conflicts
6140 | - Recovery procedures
6141 |
6142 | ## [5.0.0] - 2025-08-15
6143 |
6144 | ### ⚠️ **BREAKING CHANGES**
6145 |
6146 | #### ChromaDB Deprecation
6147 | - **DEPRECATED**: ChromaDB backend is now deprecated and will be removed in v6.0.0
6148 | - **DEFAULT CHANGE**: SQLite-vec is now the default storage backend (previously ChromaDB)
6149 | - **MIGRATION REQUIRED**: Users with existing ChromaDB data should migrate to SQLite-vec
6150 | - Run `python scripts/migrate_to_sqlite_vec.py` to migrate your data
6151 | - Migration is one-way only (ChromaDB → SQLite-vec)
6152 | - Backup your data before migration
6153 |
6154 | #### Why This Change?
6155 | - **Network Issues**: ChromaDB requires downloading models from Hugging Face, causing frequent failures
6156 | - **Performance**: SQLite-vec is 10x faster at startup (2-3 seconds vs 15-30 seconds)
6157 | - **Resource Usage**: SQLite-vec uses 75% less memory than ChromaDB
6158 | - **Reliability**: Zero network dependencies means no download failures or connection issues
6159 | - **Simplicity**: Single-file database, easier backup and portability
6160 |
6161 | #### Changed
6162 | - **Default Backend**: Changed from ChromaDB to SQLite-vec in all configurations
6163 | - **Installation**: `install.py` now installs SQLite-vec dependencies by default
6164 | - **Documentation**: Updated all guides to recommend SQLite-vec as primary backend
6165 | - **Warnings**: Added deprecation warnings when ChromaDB backend is used
6166 | - **Migration Prompts**: Server now prompts for migration when ChromaDB data is detected
6167 |
6168 | #### Migration Guide
6169 | 1. **Backup your data**: `python scripts/create_backup.py`
6170 | 2. **Run migration**: `python scripts/migrate_to_sqlite_vec.py`
6171 | 3. **Update configuration**: Set `MCP_MEMORY_STORAGE_BACKEND=sqlite_vec`
6172 | 4. **Restart server**: Your memories are now in SQLite-vec format
6173 |
6174 | #### Backward Compatibility
6175 | - ChromaDB backend still functions but displays deprecation warnings
6176 | - Existing ChromaDB installations continue to work until v6.0.0
6177 | - Migration tools provided for smooth transition
6178 | - All APIs remain unchanged regardless of backend
6179 |
6180 | ## [4.6.1] - 2025-08-14
6181 |
6182 | ### 🐛 **Bug Fixes**
6183 |
6184 | #### Fixed
6185 | - **Export/Import Script Database Path Detection**: Fixed critical bug in memory export and import scripts
6186 | - Export script now properly respects `SQLITE_VEC_PATH` configuration from `config.py`
6187 | - Import script now properly respects `SQLITE_VEC_PATH` configuration from `config.py`
6188 | - Scripts now use environment variables like `MCP_MEMORY_SQLITE_PATH` correctly
6189 | - Fixed issue where export/import would use wrong database path, missing actual memories
6190 | - Added support for custom database paths via `--db-path` argument
6191 | - Ensures export captures all memories from the configured database location
6192 | - Ensures import writes to the correct configured database location
6193 |
6194 | #### Enhanced
6195 | - **Export/Import Script Configuration**: Improved database path detection logic
6196 | - Falls back gracefully when SQLite-vec backend is not configured
6197 | - Maintains compatibility with different storage backend configurations
6198 | - Added proper imports for configuration variables
6199 |
6200 | #### Technical Details
6201 | - Modified `scripts/sync/export_memories.py` to use `SQLITE_VEC_PATH` instead of `BASE_DIR`
6202 | - Modified `scripts/sync/import_memories.py` to use `SQLITE_VEC_PATH` instead of `BASE_DIR`
6203 | - Updated `get_default_db_path()` functions in both scripts to check storage backend configuration
6204 | - Added version bump to exporter metadata for tracking
6205 | - Added `get_all_memories()` method to `SqliteVecMemoryStorage` for proper export functionality
6206 |
6207 | ## [4.6.0] - 2025-08-14
6208 |
6209 | ### ✨ **New Features**
6210 |
6211 | #### Added
6212 | - **Custom SSL Certificate Support**: Added environment variable configuration for SSL certificates
6213 | - New `MCP_SSL_CERT_FILE` environment variable for custom certificate path
6214 | - New `MCP_SSL_KEY_FILE` environment variable for custom private key path
6215 | - Maintains backward compatibility with self-signed certificate generation
6216 | - Enables production deployments with proper SSL certificates (e.g., mkcert, Let's Encrypt)
6217 |
6218 | #### Enhanced
6219 | - **HTTPS Server Configuration**: Improved certificate validation and error handling
6220 | - Certificate file existence validation before server startup
6221 | - Clear error messages for missing certificate files
6222 | - Logging improvements for certificate source identification
6223 |
6224 | #### Documentation
6225 | - **SSL/TLS Setup Guide**: Added comprehensive SSL configuration documentation
6226 | - Integration guide for [mkcert](https://github.com/FiloSottile/mkcert) for local development
6227 | - Example HTTPS startup script template
6228 | - Client CA installation instructions for multiple operating systems
6229 |
6230 | ## [4.5.2] - 2025-08-14
6231 |
6232 | ### 🐛 **Bug Fixes & Documentation**
6233 |
6234 | #### Fixed
6235 | - **JSON Protocol Compatibility**: Resolved debug output contaminating MCP JSON-RPC communication
6236 | - Fixed unconditional debug print statements causing "Unexpected token" errors in Claude Desktop logs
6237 | - Added client detection checks to `TOOL CALL INTERCEPTED` and `Processing tool` debug messages
6238 | - Ensures clean JSON-only output for Claude Desktop while preserving debug output for LM Studio
6239 |
6240 | #### Enhanced
6241 | - **Universal README Documentation**: Transformed from Claude Desktop-specific to universal AI client focus
6242 | - Updated opening description to emphasize compatibility with "AI applications and development environments"
6243 | - Added prominent compatibility badges for Cursor, WindSurf, LM Studio, Zed, and other AI clients
6244 | - Moved comprehensive client compatibility table to prominent position in documentation
6245 | - Expanded client support details for 13+ different AI applications and IDEs
6246 | - Added multi-client benefits section highlighting cross-tool memory sharing capabilities
6247 | - Updated examples and Docker configurations to be client-agnostic
6248 |
6249 | #### Documentation
6250 | - **Improved Client Visibility**: Enhanced documentation structure for broader MCP ecosystem appeal
6251 | - **Balanced Examples**: Updated API examples to focus on universal MCP access rather than specific clients
6252 | - **Clear Compatibility Matrix**: Detailed status and configuration for each supported AI client
6253 |
6254 | ## [4.5.1] - 2025-08-13
6255 |
6256 | ### 🎯 **Enhanced Multi-Client Support**
6257 |
6258 | #### Added
6259 | - **Intelligent Client Detection**: Automatic detection of MCP client type
6260 | - Detects Claude Desktop, LM Studio, and other MCP clients
6261 | - Uses process inspection and environment variables for robust detection
6262 | - Falls back to strict JSON mode for unknown clients
6263 |
6264 | - **Client-Aware Logging System**: Optimized output for different MCP clients
6265 | - **Claude Desktop Mode**: Pure JSON-RPC protocol compliance
6266 | - Suppresses diagnostic output to maintain clean JSON communication
6267 | - Routes only WARNING/ERROR messages to stderr
6268 | - Ensures maximum compatibility with Claude's strict parsing
6269 | - **LM Studio Mode**: Enhanced diagnostic experience
6270 | - Shows system diagnostics, dependency checks, and initialization status
6271 | - Provides detailed feedback for troubleshooting
6272 | - Maintains full INFO/DEBUG output to stdout
6273 |
6274 | #### Enhanced
6275 | - **Improved Stability**: All diagnostic output is now conditional based on client type
6276 | - 15+ print statements updated with client-aware logic
6277 | - System diagnostics, dependency checks, and initialization messages
6278 | - Docker mode detection and standalone mode indicators
6279 |
6280 | #### Technical Details
6281 | - Added `psutil` dependency for process-based client detection
6282 | - Implemented `DualStreamHandler` with client-aware routing
6283 | - Environment variable support: `CLAUDE_DESKTOP=1` or `LM_STUDIO=1` for manual override
6284 | - Maintains full backward compatibility with existing integrations
6285 |
6286 | ## [4.5.0] - 2025-08-12
6287 |
6288 | ### 🔄 **Database Synchronization System**
6289 |
6290 | #### Added
6291 | - **Multi-Node Database Sync**: Complete Litestream-based synchronization for SQLite-vec databases
6292 | - **JSON Export/Import**: Preserve timestamps and metadata across database migrations
6293 | - **Litestream Integration**: Real-time database replication with conflict resolution
6294 | - **3-Node Architecture**: Central server with replica nodes for distributed workflows
6295 | - **Deduplication Logic**: Content hash-based duplicate prevention during imports
6296 | - **Source Tracking**: Automatic tagging to identify memory origin machines
6297 |
6298 | - **New Sync Module**: `src/mcp_memory_service/sync/`
6299 | - `MemoryExporter`: Export memories to JSON with full metadata preservation
6300 | - `MemoryImporter`: Import with intelligent deduplication and source tracking
6301 | - `LitestreamManager`: Automated Litestream configuration and management
6302 |
6303 | - **Sync Scripts Suite**: `scripts/sync/`
6304 | - `export_memories.py`: Platform-aware memory export utility
6305 | - `import_memories.py`: Central server import with merge statistics
6306 | - `README.md`: Comprehensive usage documentation
6307 |
6308 | #### Enhanced
6309 | - **Migration Tools**: Extended existing migration scripts to support sync workflows
6310 | - **Backup Integration**: Sync capabilities integrate with existing backup system
6311 | - **Health Monitoring**: Added sync status to health endpoints and monitoring
6312 |
6313 | #### Documentation
6314 | - **Complete Sync Guide**: `docs/deployment/database-synchronization.md`
6315 | - **Technical Architecture**: Detailed setup and troubleshooting documentation
6316 | - **Migration Examples**: Updated migration documentation with sync procedures
6317 |
6318 | #### Use Cases
6319 | - **Multi-Device Workflows**: Keep memories synchronized across Windows, macOS, and server
6320 | - **Team Collaboration**: Shared memory databases with individual client access
6321 | - **Backup and Recovery**: Real-time replication provides instant backup capability
6322 | - **Offline Capability**: Local replicas work offline, sync when reconnected
6323 |
6324 | This release enables seamless database synchronization across multiple machines while preserving all memory metadata, timestamps, and source attribution.
6325 |
6326 | ## [4.4.0] - 2025-08-12
6327 |
6328 | ### 🚀 **Backup System Enhancements**
6329 |
6330 | #### Added
6331 | - **SQLite-vec Backup Support**: Enhanced MCP backup system to fully support SQLite-vec backend
6332 | - **Multi-Backend Support**: `dashboard_create_backup` now handles both ChromaDB and SQLite-vec databases
6333 | - **Complete File Coverage**: Backs up main database, WAL, and SHM files for data integrity
6334 | - **Metadata Generation**: Creates comprehensive backup metadata with size, file count, and backend info
6335 | - **Error Handling**: Robust error handling and validation during backup operations
6336 |
6337 | - **Automated Backup Infrastructure**: Complete automation solution for production deployments
6338 | - **Backup Script**: `scripts/backup_sqlite_vec.sh` with 7-day retention policy
6339 | - **Cron Setup**: `scripts/setup_backup_cron.sh` for easy daily backup scheduling
6340 | - **Metadata Tracking**: JSON metadata files with backup timestamp, size, and source information
6341 | - **Automatic Cleanup**: Old backup removal to prevent disk space issues
6342 |
6343 | #### Enhanced
6344 | - **Backup Reliability**: Improved backup system architecture for production use
6345 | - **Backend Detection**: Automatic detection and appropriate handling of storage backend
6346 | - **File Integrity**: Proper handling of SQLite WAL mode with transaction log files
6347 | - **Consistent Naming**: Standardized backup naming with timestamps
6348 | - **Validation**: Pre-backup validation of source files and post-backup verification
6349 |
6350 | #### Technical Details
6351 | - **Storage Backend**: Seamless support for both `sqlite_vec` and `chroma` backends
6352 | - **File Operations**: Safe file copying with proper permission handling
6353 | - **Scheduling**: Cron integration for hands-off automated backups
6354 | - **Monitoring**: Backup logs and status tracking for operational visibility
6355 |
6356 | ## [4.3.5] - 2025-08-12
6357 |
6358 | ### 🔧 **Critical Fix: Client Hostname Capture**
6359 |
6360 | #### Fixed
6361 | - **Architecture Correction**: Fixed hostname capture to identify CLIENT machine instead of server machine
6362 | - **Before**: Always captured server hostname (`narrowbox`) regardless of client
6363 | - **After**: Prioritizes client-provided hostname, fallback to server hostname
6364 | - **HTTP API**: Supports `client_hostname` in request body + `X-Client-Hostname` header
6365 | - **MCP Server**: Added `client_hostname` parameter to store_memory tool
6366 | - **Legacy Server**: Supports `client_hostname` in arguments dictionary
6367 | - **Priority Order**: request body > HTTP header > server hostname fallback
6368 |
6369 | #### Changed
6370 | - **Client Detection Logic**: Updated all three interfaces with proper client hostname detection
6371 | - `memories.py`: Added Request parameter and header/body hostname extraction
6372 | - `mcp_server.py`: Added client_hostname parameter with priority logic
6373 | - `server.py`: Added client_hostname argument extraction with fallback
6374 | - Maintains backward compatibility when `MCP_MEMORY_INCLUDE_HOSTNAME=false`
6375 |
6376 | #### Documentation
6377 | - **Command Templates**: Updated repository templates with client hostname detection guidance
6378 | - **API Documentation**: Enhanced descriptions to clarify client vs server hostname capture
6379 | - **Test Documentation**: Added comprehensive test scenarios and verification steps
6380 |
6381 | #### Technical Impact
6382 | - ✅ **Multi-device workflows**: Memories now correctly identify originating client machine
6383 | - ✅ **Audit trails**: Proper source attribution across different client connections
6384 | - ✅ **Remote deployments**: Works correctly when client and server are different machines
6385 | - ✅ **Backward compatible**: No breaking changes, respects environment variable setting
6386 |
6387 | ## [4.3.4] - 2025-08-12
6388 |
6389 | ### 🔧 **Optional Machine Identification**
6390 |
6391 | #### Added
6392 | - **Environment-Controlled Machine Tracking**: Made machine identification optional via environment variable
6393 | - New environment variable: `MCP_MEMORY_INCLUDE_HOSTNAME` (default: `false`)
6394 | - When enabled, automatically adds machine hostname to all stored memories
6395 | - Adds both `source:hostname` tag and hostname metadata field
6396 | - Supports all interfaces: MCP server, HTTP API, and legacy server
6397 | - Privacy-focused: disabled by default, enables multi-device workflows when needed
6398 |
6399 | #### Changed
6400 | - **Memory Storage Enhancement**: All memory storage operations now support optional machine tracking
6401 | - Updated `mcp_server.py` store_memory function with hostname logic
6402 | - Enhanced HTTP API `/memories` endpoint with machine identification
6403 | - Updated legacy `server.py` with consistent hostname tracking
6404 | - Maintains backward compatibility with existing memory operations
6405 |
6406 | #### Documentation
6407 | - **CLAUDE.md Updated**: Added `MCP_MEMORY_INCLUDE_HOSTNAME` environment variable documentation
6408 | - **Configuration Guide**: Explains optional hostname tracking for audit trails and multi-device setups
6409 |
6410 | ## [4.3.3] - 2025-08-12
6411 |
6412 | ### 🎯 **Claude Code Command Templates Enhancement**
6413 |
6414 | #### Added
6415 | - **Machine Source Tracking**: All memory storage commands now automatically include machine hostname as a tag
6416 | - Enables filtering memories by originating machine (e.g., `source:machine-name`)
6417 | - Adds hostname to both tags and metadata for redundancy
6418 | - Supports multi-device workflows and audit trails
6419 |
6420 | #### Changed
6421 | - **Command Templates Updated**: All five memory command templates enhanced with:
6422 | - Updated to use generic HTTPS endpoint (`https://memory.local:8443/`)
6423 | - Proper API endpoint paths documented for all operations
6424 | - Auto-save functionality without confirmation prompts
6425 | - curl with `-k` flag for HTTPS self-signed certificates
6426 | - Machine hostname tracking integrated throughout
6427 |
6428 | #### Documentation
6429 | - `memory-store.md`: Added machine context and HTTPS configuration
6430 | - `memory-health.md`: Updated with specific health API endpoints
6431 | - `memory-search.md`: Added all search API endpoints and machine source search
6432 | - `memory-context.md`: Integrated machine tracking for session captures
6433 | - `memory-recall.md`: Updated with API endpoints and time parser limitations
6434 |
6435 | ## [4.3.2] - 2025-08-11
6436 |
6437 | ### 🎯 **Repository Organization & PyTorch Download Fix**
6438 |
6439 | #### Fixed
6440 | - **PyTorch Repeated Downloads**: Completely resolved Claude Desktop downloading PyTorch (230MB+) on every startup
6441 | - Root cause: UV package manager isolation prevented offline environment variables from taking effect
6442 | - Solution: Created `scripts/memory_offline.py` launcher that sets offline mode BEFORE any imports
6443 | - Updated Claude Desktop config to use Python directly instead of UV isolation
6444 | - Added comprehensive offline mode configuration for HuggingFace transformers
6445 |
6446 | - **Environment Variable Inheritance**: Fixed UV environment isolation issues
6447 | - Implemented direct Python execution bypass for Claude Desktop integration
6448 | - Added code-level offline setup in `src/mcp_memory_service/__init__.py` as fallback
6449 | - Ensured cached model usage without network requests
6450 |
6451 | #### Changed
6452 | - **Repository Structure**: Major cleanup and reorganization of root directory
6453 | - Moved documentation files to appropriate `/docs` subdirectories
6454 | - Consolidated guides in `docs/guides/`, technical docs in `docs/technical/`
6455 | - Moved deployment guides to `docs/deployment/`, installation to `docs/installation/`
6456 | - Removed obsolete debug scripts and development notes
6457 | - Moved service management scripts to `/scripts` directory
6458 |
6459 | - **Documentation Organization**: Improved logical hierarchy
6460 | - Claude Code compatibility → `docs/guides/claude-code-compatibility.md`
6461 | - Setup guides → `docs/installation/` and `docs/guides/`
6462 | - Technical documentation → `docs/technical/`
6463 | - Integration guides → `docs/integrations/`
6464 |
6465 | #### Technical Details
6466 | - **Offline Mode Implementation**: `scripts/memory_offline.py` sets `HF_HUB_OFFLINE=1` and `TRANSFORMERS_OFFLINE=1` before ML library imports
6467 | - **Config Optimization**: Updated Claude Desktop config templates for both Windows and general use
6468 | - **Cache Management**: Proper Windows cache path configuration for sentence-transformers and HuggingFace
6469 |
6470 | #### Impact
6471 | - ✅ **Eliminated 230MB PyTorch downloads** - Startup time reduced from ~60s to ~3s
6472 | - ✅ **Professional repository structure** - Clean root directory with logical documentation hierarchy
6473 | - ✅ **Improved maintainability** - Consolidated scripts and removed redundant files
6474 | - ✅ **Enhanced user experience** - No more frustrating download delays in Claude Desktop
6475 |
6476 | This release resolves the persistent PyTorch download issue that affected Windows users and establishes a clean, professional repository structure suitable for enterprise deployment.
6477 |
6478 | ## [4.3.1] - 2025-08-11
6479 |
6480 | ### 🔧 **Critical Windows Installation Fixes**
6481 |
6482 | #### Fixed
6483 | - **PyTorch-DirectML Compatibility**: Resolved major installation issues on Windows 11
6484 | - Fixed installer attempting to install incompatible PyTorch 2.5.1 over working 2.4.1+DirectML setup
6485 | - Added smart compatibility checking: PyTorch 2.4.x works with DirectML, 2.5.x doesn't
6486 | - Enhanced `install_pytorch_windows()` to preserve existing compatible installations
6487 | - Only installs torch-directml if PyTorch 2.4.1 exists without DirectML extensions
6488 |
6489 | - **Corrupted Virtual Environment Recovery**: Fixed "module 'torch' has no attribute 'version'" errors
6490 | - Implemented complete cleanup of corrupted `~orch` and `functorch` directories
6491 | - Added robust uninstall and reinstall process for broken PyTorch installations
6492 | - Restored proper torch.version attribute functionality
6493 |
6494 | - **Windows 11 Detection**: Fixed incorrect OS identification
6495 | - Implemented registry-based Windows 11 detection using build numbers (≥22000)
6496 | - Replaced unreliable platform detection with accurate registry lookups
6497 | - Added system info caching to prevent duplicate detection calls
6498 |
6499 | - **Installation Logging Improvements**: Enhanced installer feedback and debugging
6500 | - Created built-in DualOutput logging system with UTF-8 encoding
6501 | - Fixed character encoding issues in installation logs
6502 | - Added comprehensive logging for PyTorch compatibility decisions
6503 |
6504 | #### Changed
6505 | - **Installation Intelligence**: Installer now preserves working DirectML setups instead of force-upgrading
6506 | - **Error Prevention**: Added extensive pre-checks to prevent corrupted package installations
6507 | - **User Experience**: Clear messaging about PyTorch version compatibility and preservation decisions
6508 |
6509 | #### Technical Details
6510 | - Enhanced PyTorch version detection and compatibility matrix
6511 | - Smart preservation of PyTorch 2.4.1 + torch-directml 0.2.5.dev240914 combinations
6512 | - Automatic cleanup of corrupted package directories during installation recovery
6513 | - Registry-based Windows version detection via `SOFTWARE\Microsoft\Windows NT\CurrentVersion`
6514 |
6515 | This release resolves critical Windows installation failures that prevented successful PyTorch-DirectML setup, ensuring reliable DirectML acceleration on Windows 11 systems.
6516 |
6517 | ## [4.3.0] - 2025-08-10
6518 |
6519 | ### ⚡ **Developer Experience Improvements**
6520 |
6521 | #### Added
6522 | - **Automated uv.lock Conflict Resolution**: Eliminates manual merge conflict resolution
6523 | - Custom git merge driver automatically resolves `uv.lock` conflicts
6524 | - Auto-runs `uv sync` after conflict resolution to ensure consistency
6525 | - One-time setup script for contributors: `./scripts/setup-git-merge-drivers.sh`
6526 | - Comprehensive documentation in README.md and CLAUDE.md
6527 |
6528 | #### Technical
6529 | - Added `.gitattributes` configuration for `uv.lock` merge handling
6530 | - Created `scripts/uv-lock-merge.sh` custom merge driver script
6531 | - Added contributor setup script with automatic git configuration
6532 | - Enhanced development documentation with git setup instructions
6533 |
6534 | This release significantly improves the contributor experience by automating the resolution of the most common merge conflicts in the repository.
6535 |
6536 | ## [4.2.0] - 2025-08-10
6537 |
6538 | ### 🔧 **Improved Client Compatibility**
6539 |
6540 | #### Added
6541 | - **LM Studio Compatibility Layer**: Automatic handling of non-standard MCP notifications
6542 | - Monkey patch for `notifications/cancelled` messages that aren't in the MCP specification
6543 | - Graceful error handling prevents server crashes when LM Studio cancels operations
6544 | - Debug logging for troubleshooting compatibility issues
6545 | - Comprehensive documentation in `docs/LM_STUDIO_COMPATIBILITY.md`
6546 |
6547 | #### Technical
6548 | - Added `lm_studio_compat.py` module with compatibility patches
6549 | - Applied patches automatically during server initialization
6550 | - Enhanced error handling in MCP protocol communication
6551 |
6552 | This release significantly improves compatibility with LM Studio and other MCP clients while maintaining full backward compatibility with existing Claude Desktop integrations.
6553 |
6554 | ## [4.1.1] - 2025-08-10
6555 |
6556 | ### Fixed
6557 | - **macOS ARM64 Support**: Enhanced PyTorch installation for Apple Silicon
6558 | - Proper dependency resolution for M1/M2/M3 Mac systems
6559 | - Updated torch dependency requirements from `>=1.6.0` to `>=2.0.0` in `pyproject.toml`
6560 | - Platform-specific installation instructions in `install.py`
6561 | - Improved cross-platform dependency management
6562 |
6563 | ## [4.1.0] - 2025-08-06
6564 |
6565 | ### 🎯 **Full MCP Specification Compliance**
6566 |
6567 | #### Added
6568 | - **Enhanced Resources System**: URI-based access to memory collections
6569 | - `memory://stats` - Real-time database statistics and health metrics
6570 | - `memory://tags` - Complete list of available memory tags
6571 | - `memory://recent/{n}` - Access to N most recent memories
6572 | - `memory://tag/{tagname}` - Query memories by specific tag
6573 | - `memory://search/{query}` - Dynamic search with structured results
6574 | - Resource templates for parameterized queries
6575 | - JSON responses for all resource endpoints
6576 |
6577 | - **Guided Prompts Framework**: Interactive workflows for memory operations
6578 | - `memory_review` - Review and organize memories from specific time periods
6579 | - `memory_analysis` - Analyze patterns, themes, and tag distributions
6580 | - `knowledge_export` - Export memories in JSON, Markdown, or Text formats
6581 | - `memory_cleanup` - Identify and remove duplicate or outdated memories
6582 | - `learning_session` - Store structured learning notes with automatic categorization
6583 | - Each prompt includes proper argument schemas and validation
6584 |
6585 | - **Progress Tracking System**: Real-time notifications for long operations
6586 | - Progress notifications with percentage completion
6587 | - Operation IDs for tracking concurrent tasks
6588 | - Enhanced `delete_by_tags` with step-by-step progress
6589 | - Enhanced `dashboard_optimize_db` with operation stages
6590 | - MCP-compliant progress notification protocol
6591 |
6592 | #### Changed
6593 | - Extended `MemoryStorage` base class with helper methods for resources
6594 | - Enhanced `Memory` and `MemoryQueryResult` models with `to_dict()` methods
6595 | - Improved server initialization with progress tracking state management
6596 |
6597 | #### Technical
6598 | - Added `send_progress_notification()` method to MemoryServer
6599 | - Implemented `get_stats()`, `get_all_tags()`, `get_recent_memories()` in storage base
6600 | - Full backward compatibility maintained with existing operations
6601 |
6602 | This release brings the MCP Memory Service to full compliance with the Model Context Protocol specification, enabling richer client interactions and better user experience through structured data access and guided workflows.
6603 |
6604 | ## [4.0.1] - 2025-08-04
6605 |
6606 | ### Fixed
6607 | - **MCP Protocol Validation**: Resolved critical ID validation errors affecting integer/string ID handling
6608 | - **Embedding Model Loading**: Fixed model loading failures in offline environments
6609 | - **Semantic Search**: Restored semantic search functionality that was broken in 4.0.0
6610 | - **Version Consistency**: Fixed version mismatch between `__init__.py` and `pyproject.toml`
6611 |
6612 | ### Technical
6613 | - Enhanced flexible ID validation for MCP protocol compliance
6614 | - Improved error handling for embedding model initialization
6615 | - Corrected version bumping process for patch releases
6616 |
6617 | ## [4.0.0] - 2025-08-04
6618 |
6619 | ### 🚀 **Major Release: Production-Ready Remote MCP Memory Service**
6620 |
6621 | #### Added
6622 | - **Native MCP-over-HTTP Protocol**: Direct MCP protocol support via FastAPI without Node.js bridge
6623 | - **Remote Server Deployment**: Full production deployment capability with remote access
6624 | - **Cross-Device Memory Access**: Validated multi-device memory synchronization
6625 | - **Comprehensive Documentation**: Complete deployment guides and remote access documentation
6626 |
6627 | #### Changed
6628 | - **Architecture Evolution**: Transitioned from local experimental service to production infrastructure
6629 | - **Protocol Compliance**: Applied MCP protocol refactorings with flexible ID validation
6630 | - **Docker CI/CD**: Fixed and operationalized Docker workflows for automated deployment
6631 | - **Repository Maintenance**: Comprehensive cleanup and branch management
6632 |
6633 | #### Production Validation
6634 | - Successfully deployed server running at remote endpoints with 65+ memories
6635 | - SQLite-vec backend validated (1.7MB database, 384-dim embeddings)
6636 | - all-MiniLM-L6-v2 model loaded and operational
6637 | - Full MCP tool suite available and tested
6638 |
6639 | #### Milestones Achieved
6640 | - GitHub Issue #71 (remote access) completed
6641 | - GitHub Issue #72 (bridge deprecation) resolved
6642 | - Production deployment proven successful
6643 |
6644 | ## [4.0.0-beta.1] - 2025-08-03
6645 |
6646 | ### Added
6647 | - **Dual-Service Architecture**: Combined HTTP Dashboard + Native MCP Protocol
6648 | - **FastAPI MCP Integration**: Complete integration for native remote access
6649 | - **Direct MCP-over-HTTP**: Eliminated dependency on Node.js bridge
6650 |
6651 | ### Changed
6652 | - **Remote Access Solution**: Resolved remote memory service access (Issue #71)
6653 | - **Bridge Deprecation**: Deprecated Node.js bridge in favor of direct protocol
6654 | - **Docker Workflows**: Fixed CI/CD pipeline for automated testing
6655 |
6656 | ### Technical
6657 | - Maintained backward compatibility for existing HTTP API users
6658 | - Repository cleanup and branch management improvements
6659 | - Significant architectural evolution while preserving existing functionality
6660 |
6661 | ## [4.0.0-alpha.1] - 2025-08-03
6662 |
6663 | ### Added
6664 | - **Initial FastAPI MCP Server**: First implementation of native MCP server structure
6665 | - **MCP Protocol Endpoints**: Added core MCP protocol endpoints to FastAPI server
6666 | - **Hybrid Support**: Initial HTTP+MCP hybrid architecture support
6667 |
6668 | ### Changed
6669 | - **Server Architecture**: Began transition from pure HTTP to MCP-native implementation
6670 | - **Remote Access Configuration**: Initial configuration for remote server access
6671 | - **Protocol Implementation**: Started implementing MCP specification compliance
6672 |
6673 | ### Technical
6674 | - Validated local testing with FastAPI MCP server
6675 | - Fixed `mcp.run()` syntax issues
6676 | - Established foundation for dual-protocol support
6677 |
6678 | ## [3.3.4] - 2025-08-03
6679 |
6680 | ### Fixed
6681 | - **Multi-Client Backend Selection**: Fixed hardcoded sqlite_vec backend in multi-client configuration
6682 | - Configuration functions now properly accept and use storage_backend parameter
6683 | - Chosen backend is correctly passed through entire multi-client setup flow
6684 | - M1 Macs with MPS acceleration now correctly use ChromaDB when selected
6685 | - SQLite pragmas only applied when sqlite_vec is actually chosen
6686 |
6687 | ### Changed
6688 | - **Configuration Instructions**: Updated generic configuration to reflect chosen backend
6689 | - **Backend Flexibility**: All systems now get optimal backend configuration in multi-client mode
6690 |
6691 | ### Technical
6692 | - Resolved Issue #73 affecting M1 Mac users
6693 | - Ensures proper backend-specific configuration for all platforms
6694 | - Version bump to 3.3.4 for critical fix release
6695 |
6696 | ## [3.3.3] - 2025-08-02
6697 |
6698 | ### 🔒 **SSL Certificate & MCP Bridge Compatibility**
6699 |
6700 | #### Fixed
6701 | - **SSL Certificate Generation**: Now generates certificates with proper Subject Alternative Names (SANs) for multi-hostname/IP compatibility
6702 | - Auto-detects local machine IP address dynamically (no hardcoded IPs)
6703 | - Includes `DNS:memory.local`, `DNS:localhost`, `DNS:*.local`
6704 | - Includes `IP:127.0.0.1`, `IP:::1` (IPv6), and auto-detected local IP
6705 | - Environment variable support: `MCP_SSL_ADDITIONAL_IPS`, `MCP_SSL_ADDITIONAL_HOSTNAMES`
6706 | - **Node.js MCP Bridge Compatibility**: Resolved SSL handshake failures when connecting from Claude Code
6707 | - Added missing MCP protocol methods: `initialize`, `tools/list`, `tools/call`, `notifications/initialized`
6708 | - Enhanced error handling with exponential backoff retry logic (3 attempts, max 5s delay)
6709 | - Comprehensive request/response logging with unique request IDs
6710 | - Improved HTTPS client configuration with custom SSL agent
6711 | - Reduced timeout from 30s to 10s for faster failure detection
6712 | - Removed conflicting Host headers that caused SSL verification issues
6713 |
6714 | #### Changed
6715 | - **Certificate Security**: CN changed from `localhost` to `memory.local` for better hostname matching
6716 | - **HTTP Client**: Enhanced connection management with explicit port handling and connection close headers
6717 | - **Logging**: Added detailed SSL handshake and request flow debugging
6718 |
6719 | #### Environment Variables
6720 | - `MCP_SSL_ADDITIONAL_IPS`: Comma-separated list of additional IP addresses to include in certificate
6721 | - `MCP_SSL_ADDITIONAL_HOSTNAMES`: Comma-separated list of additional hostnames to include in certificate
6722 |
6723 | This release resolves SSL connectivity issues that prevented Claude Code from connecting to remote MCP Memory Service instances across different networks and deployment environments.
6724 |
6725 | ## [3.3.2] - 2025-08-02
6726 |
6727 | ### 📚 **Enhanced Documentation & API Key Management**
6728 |
6729 | #### Changed
6730 | - **API Key Documentation**: Comprehensive improvements to authentication guides
6731 | - Enhanced multi-client server documentation with security best practices
6732 | - Detailed API key generation and configuration instructions
6733 | - Updated service installation guide with authentication setup
6734 | - Improved CLAUDE.md with API key environment variable explanations
6735 |
6736 | #### Technical
6737 | - **Documentation Quality**: Enhanced authentication documentation across multiple guides
6738 | - **Security Guidance**: Clear instructions for production API key management
6739 | - **Cross-Reference Links**: Better navigation between related documentation sections
6740 |
6741 | This release significantly improves the user experience for setting up secure, authenticated MCP Memory Service deployments.
6742 |
6743 | ## [3.3.1] - 2025-08-01
6744 |
6745 | ### 🔧 **Memory Statistics & Health Monitoring**
6746 |
6747 | #### Added
6748 | - **Enhanced Health Endpoint**: Memory statistics integration for dashboard display
6749 | - Added memory statistics to `/health` endpoint for real-time monitoring
6750 | - Integration with dashboard UI for comprehensive system overview
6751 | - Better visibility into database health and memory usage
6752 |
6753 | #### Fixed
6754 | - **Dashboard Display**: Improved dashboard data integration and visualization support
6755 |
6756 | #### Technical
6757 | - **Web App Enhancement**: Updated FastAPI app with integrated statistics endpoints
6758 | - **Version Synchronization**: Updated package version to maintain consistency
6759 |
6760 | This release enhances monitoring capabilities and prepares the foundation for advanced dashboard features.
6761 |
6762 | ## [3.3.0] - 2025-07-31
6763 |
6764 | ### 🎨 **Modern Professional Dashboard UI**
6765 |
6766 | #### Added
6767 | - **Professional Dashboard Interface**: Complete UI overhaul for web interface
6768 | - Modern, responsive design with professional styling
6769 | - Real-time memory statistics display
6770 | - Interactive memory search and management interface
6771 | - Enhanced user experience for memory operations
6772 |
6773 | #### Changed
6774 | - **Visual Identity**: Updated project branding with professional dashboard preview
6775 | - **User Interface**: Complete redesign of web-based memory management
6776 | - **Documentation Assets**: Added dashboard screenshots and visual documentation
6777 |
6778 | #### Technical
6779 | - **Web App Modernization**: Updated FastAPI application with modern UI components
6780 | - **Asset Organization**: Proper structure for dashboard images and visual assets
6781 |
6782 | This release transforms the web interface from a basic API into a professional, user-friendly dashboard for memory management.
6783 |
6784 | ## [3.2.0] - 2025-07-30
6785 |
6786 | ### 🛠️ **SQLite-vec Diagnostic & Repair Tools**
6787 |
6788 | #### Added
6789 | - **Comprehensive Diagnostic Tools**: Advanced SQLite-vec backend analysis and repair
6790 | - Database integrity checking and validation
6791 | - Embedding consistency verification tools
6792 | - Memory preservation during repairs and migrations
6793 | - Automated repair workflows for corrupted databases
6794 |
6795 | #### Fixed
6796 | - **SQLite-vec Embedding Issues**: Resolved critical embedding problems causing zero search results
6797 | - Fixed embedding dimension mismatches
6798 | - Resolved database schema inconsistencies
6799 | - Improved embedding generation and storage reliability
6800 |
6801 | #### Technical
6802 | - **Migration Tools**: Enhanced migration utilities to preserve existing memories during backend transitions
6803 | - **Diagnostic Scripts**: Comprehensive database analysis and repair automation
6804 |
6805 | This release significantly improves SQLite-vec backend reliability and provides tools for database maintenance and recovery.
6806 |
6807 | ## [3.1.0] - 2025-07-30
6808 |
6809 | ### 🔧 **Cross-Platform Service Installation**
6810 |
6811 | #### Added
6812 | - **Universal Service Installation**: Complete cross-platform service management
6813 | - Linux systemd service installation and configuration
6814 | - macOS LaunchAgent/LaunchDaemon support
6815 | - Windows Service installation and management
6816 | - Unified service utilities across all platforms
6817 |
6818 | #### Changed
6819 | - **Installation Experience**: Streamlined service setup for all operating systems
6820 | - **Service Management**: Consistent service control across platforms
6821 | - **Documentation**: Enhanced service installation guides
6822 |
6823 | #### Technical
6824 | - **Platform-Specific Scripts**: Dedicated installation scripts for each operating system
6825 | - **Service Configuration**: Proper service definitions and startup configurations
6826 | - **Cross-Platform Utilities**: Unified service management tools
6827 |
6828 | This release enables easy deployment of MCP Memory Service as a system service on any major operating system.
6829 |
6830 | ## [3.0.0] - 2025-07-29
6831 |
6832 | ### 🚀 MAJOR RELEASE: Autonomous Multi-Client Memory Service
6833 |
6834 | This is a **major architectural evolution** transforming MCP Memory Service from a development tool into a production-ready, intelligent memory system with autonomous processing capabilities.
6835 |
6836 | ### Added
6837 | #### 🧠 **Dream-Inspired Consolidation System**
6838 | - **Autonomous Memory Processing**: Fully autonomous consolidation system inspired by human cognitive processes
6839 | - **Exponential Decay Scoring**: Memory aging with configurable retention periods (critical: 365d, reference: 180d, standard: 30d, temporary: 7d)
6840 | - **Creative Association Discovery**: Automatic discovery of semantic connections between memories (similarity range 0.3-0.7)
6841 | - **Semantic Clustering**: DBSCAN algorithm for intelligent memory grouping (minimum 5 memories per cluster)
6842 | - **Memory Compression**: Statistical summarization with 500-character limits while preserving originals
6843 | - **Controlled Forgetting**: Relevance-based memory archival system (threshold 0.1, 90-day access window)
6844 | - **Automated Scheduling**: Configurable consolidation schedules (daily 2AM, weekly Sunday 3AM, monthly 1st 4AM)
6845 | - **Zero-AI Dependencies**: Operates entirely offline using existing embeddings and mathematical algorithms
6846 |
6847 | #### 🌐 **Multi-Client Server Architecture**
6848 | - **HTTPS Server**: Production-ready FastAPI server with auto-generated SSL certificates
6849 | - **mDNS Service Discovery**: Zero-configuration automatic service discovery (`MCP Memory._mcp-memory._tcp.local.`)
6850 | - **Server-Sent Events (SSE)**: Real-time updates with 30s heartbeat intervals for all connected clients
6851 | - **Multi-Interface Support**: Service advertisement across all network interfaces (WiFi, Ethernet, Docker, etc.)
6852 | - **API Authentication**: Secure API key-based authentication system
6853 | - **Cross-Platform Discovery**: Works on Windows, macOS, and Linux with standard mDNS/Bonjour
6854 |
6855 | #### 🚀 **Production Deployment System**
6856 | - **Systemd Auto-Startup**: Complete systemd service integration for automatic startup on boot
6857 | - **Service Management**: Professional service control scripts with start/stop/restart/status/logs/health commands
6858 | - **User-Space Service**: Runs as regular user (not root) for enhanced security
6859 | - **Auto-Restart**: Automatic service recovery on failures with 10-second restart delay
6860 | - **Journal Logging**: Integrated with systemd journal for professional log management
6861 | - **Health Monitoring**: Built-in health checks and monitoring endpoints
6862 |
6863 | #### 📖 **Comprehensive Documentation**
6864 | - **Complete Setup Guide**: 100+ line comprehensive production deployment guide
6865 | - **Production Quick Start**: Streamlined production deployment instructions
6866 | - **Service Management**: Full service lifecycle documentation
6867 | - **Troubleshooting**: Detailed problem resolution guides
6868 | - **Network Configuration**: Firewall and mDNS setup instructions
6869 |
6870 | ### Enhanced
6871 | #### 🔧 **Improved Server Features**
6872 | - **Enhanced SSE Implementation**: Restored full Server-Sent Events functionality with connection statistics
6873 | - **Network Optimization**: Multi-interface service discovery and connection handling
6874 | - **Configuration Management**: Environment-based configuration with secure defaults
6875 | - **Error Handling**: Comprehensive error handling and recovery mechanisms
6876 |
6877 | #### 🛠️ **Developer Experience**
6878 | - **Debug Tools**: Service debugging and testing utilities
6879 | - **Installation Scripts**: One-command installation and configuration
6880 | - **Management Scripts**: Easy service lifecycle management
6881 | - **Archive Organization**: Clean separation of development and production files
6882 |
6883 | ### Configuration
6884 | #### 🔧 **New Environment Variables**
6885 | - `MCP_CONSOLIDATION_ENABLED`: Enable/disable autonomous consolidation (default: true)
6886 | - `MCP_MDNS_ENABLED`: Enable/disable mDNS service discovery (default: true)
6887 | - `MCP_MDNS_SERVICE_NAME`: Customizable service name for discovery (default: "MCP Memory")
6888 | - `MCP_HTTPS_ENABLED`: Enable HTTPS with auto-generated certificates (default: true)
6889 | - `MCP_HTTP_HOST`: Server bind address (default: 0.0.0.0 for multi-client)
6890 | - `MCP_HTTP_PORT`: Server port (default: 8000)
6891 | - Consolidation timing controls: `MCP_SCHEDULE_DAILY`, `MCP_SCHEDULE_WEEKLY`, `MCP_SCHEDULE_MONTHLY`
6892 |
6893 | ### Breaking Changes
6894 | - **Architecture Change**: Single-client MCP protocol → Multi-client HTTPS server architecture
6895 | - **Service Discovery**: Manual configuration → Automatic mDNS discovery
6896 | - **Deployment Model**: Development script → Production systemd service
6897 | - **Access Method**: Direct library import → HTTP API with authentication
6898 |
6899 | ### Migration
6900 | - **Client Configuration**: Update to use HTTP-MCP bridge with auto-discovery
6901 | - **Service Deployment**: Install systemd service for production use
6902 | - **Network Setup**: Configure firewall for ports 8000/tcp (HTTPS) and 5353/udp (mDNS)
6903 | - **API Access**: Use generated API key for authentication
6904 |
6905 | ### Technical Details
6906 | - **Consolidation Algorithm**: Mathematical approach using existing embeddings without external AI
6907 | - **Service Architecture**: FastAPI + uvicorn + systemd for production deployment
6908 | - **Discovery Protocol**: RFC-compliant mDNS service advertisement
6909 | - **Security**: User-space execution, API key authentication, HTTPS encryption
6910 | - **Storage**: Continues to support both ChromaDB and SQLite-vec backends
6911 |
6912 | ---
6913 |
6914 | ## [2.2.0] - 2025-07-29
6915 |
6916 | ### Added
6917 | - **Claude Code Commands Integration**: 5 conversational memory commands following CCPlugins pattern
6918 | - `/memory-store`: Store information with context and smart tagging
6919 | - `/memory-recall`: Time-based memory retrieval with natural language
6920 | - `/memory-search`: Tag and content-based semantic search
6921 | - `/memory-context`: Capture current session and project context
6922 | - `/memory-health`: Service health diagnostics and statistics
6923 | - **Optional Installation System**: Integrated command installation into main installer
6924 | - New CLI arguments: `--install-claude-commands`, `--skip-claude-commands-prompt`
6925 | - Intelligent prompting during installation when Claude Code CLI is detected
6926 | - Automatic backup of existing commands with timestamps
6927 | - **Command Management Utilities**: Standalone installation and management script
6928 | - `scripts/claude_commands_utils.py` for manual command installation
6929 | - Cross-platform support with comprehensive error handling
6930 | - Prerequisites testing and service connectivity validation
6931 | - **Context-Aware Operations**: Commands understand project and session context
6932 | - Automatic project detection from current directory and git repository
6933 | - Smart tag generation based on file types and development context
6934 | - Session analysis and summarization capabilities
6935 | - **Auto-Discovery Integration**: Commands automatically locate MCP Memory Service
6936 | - Uses existing mDNS service discovery functionality
6937 | - Graceful fallback when service is unavailable
6938 | - Backend-agnostic operation (works with both ChromaDB and SQLite-vec)
6939 |
6940 | ### Changed
6941 | - Updated main README.md with Claude Code commands feature documentation
6942 | - Enhanced `docs/guides/claude-code-integration.md` with comprehensive command usage guide
6943 | - Updated installation documentation to include new command options
6944 | - Version bump from 2.1.0 to 2.2.0 for significant feature addition
6945 |
6946 | ### Documentation
6947 | - Added detailed command descriptions and usage examples
6948 | - Created comparison guide between conversational commands and MCP server registration
6949 | - Enhanced troubleshooting documentation for both integration methods
6950 | - Added `claude_commands/README.md` with complete command reference
6951 |
6952 | ## [2.1.0] - 2025-07-XX
6953 |
6954 | ### Added
6955 | - **mDNS Service Discovery**: Zero-configuration networking with automatic service discovery
6956 | - **HTTPS Support**: SSL/TLS support with automatic self-signed certificate generation
6957 | - **Enhanced HTTP-MCP Bridge**: Auto-discovery mode with health validation and fallback
6958 | - **Zero-Config Deployment**: No manual endpoint configuration needed for local networks
6959 |
6960 | ### Changed
6961 | - Updated service discovery to use `_mcp-memory._tcp.local.` service type
6962 | - Enhanced HTTP server with SSL certificate generation capabilities
6963 | - Improved multi-client coordination with automatic discovery
6964 |
6965 | ## [2.0.0] - 2025-07-XX
6966 |
6967 | ### Added
6968 | - **Dream-Inspired Memory Consolidation**: Autonomous memory management system
6969 | - **Multi-layered Time Horizons**: Daily, weekly, monthly, quarterly, yearly consolidation
6970 | - **Creative Association Discovery**: Finding non-obvious connections between memories
6971 | - **Semantic Clustering**: Automatic organization of related memories
6972 | - **Intelligent Compression**: Preserving key information while reducing storage
6973 | - **Controlled Forgetting**: Safe archival and recovery systems
6974 | - **Performance Optimization**: Efficient processing of 10k+ memories
6975 | - **Health Monitoring**: Comprehensive error handling and alerts
6976 |
6977 | ### Changed
6978 | - Major architecture updates for consolidation system
6979 | - Enhanced storage backends with consolidation support
6980 | - Improved multi-client coordination capabilities
6981 |
6982 | ## [1.0.0] - 2025-07-XX
6983 |
6984 | ### Added
6985 | - Initial stable release
6986 | - Core memory operations (store, retrieve, search, recall)
6987 | - ChromaDB and SQLite-vec storage backends
6988 | - Cross-platform compatibility
6989 | - Claude Desktop integration
6990 | - Basic multi-client support
6991 |
6992 | ## [0.1.0] - 2025-07-XX
6993 |
6994 | ### Added
6995 | - Initial development release
6996 | - Basic memory storage and retrieval functionality
6997 | - ChromaDB integration
6998 | - MCP server implementation
```