MCP - Titan Memory Server

by jasonkneen

Integrations

  • Collaboration between GitHub users @jasonkneen and @ExpressionsBot

  • Uses TensorFlow.js for efficient tensor operations in the neural memory model with operations wrapped in tf.tidy() for proper memory management

  • Implements a type-safe implementation with TypeScript including type-safe MCP tool definitions

Titan 内存服务器

具有增强型 Titan 内存模型的模型上下文协议 (MCP) 服务器实现。

概述

该项目实现了大型语言模型 (LLM) 的记忆模型,旨在增强生成式 AI 系统的记忆能力。它使用 TensorFlow.js 构建,并以 MCP 服务器的形式实现,因此可以轻松与任何兼容 MCP 的客户端集成。

特征

目前已实施:

  • 多头注意力机制
  • 分层内存结构
  • 内存状态持久性
  • 与模型上下文协议 (MCP) 集成
  • 记忆重放增强学习效果
  • LLM Cache 集成
  • 动态内存分配
  • 长期记忆存储
  • 高级内存压缩
  • 持久任务特定记忆
  • 基于动量的内存更新
  • 可配置内存集成变体(MAC/MAG)

用法

服务器通过模型上下文协议(MCP)公开了几种工具:

  • init_model :使用自定义配置初始化内存模型
  • forward :执行模型的前向传递
  • train_step :执行单个训练步骤
  • train_sequence :在向量序列上进行训练
  • save_model :保存当前模型权重
  • load_model :从保存的文件中加载模型权重
  • get_status :获取模型的当前状态
  • store_memory_state :使用键存储当前内存状态
  • retrieve_memory_state :检索存储的内存状态
  • compress_memory :压缩当前内存状态以节省空间
  • memory_replay :执行记忆重放训练以增强学习

安装

npm install

运行服务器

npm run build npm start

这将在端口 3000 上启动 MCP 服务器。

发展

npm run watch

测试

npm test

高级功能

记忆重播

记忆重放机制存储过去的输入输出对,并定期对其进行重新训练以强化学习。这有助于防止灾难性遗忘,并提高模型的整体性能。

动态内存分配

该模型可以根据输入的复杂性和意外程度(预测误差)动态调整内存分配。这使得它能够为复杂模式分配更多资源,并压缩更简单的模式。

长期记忆存储

系统会维护一个持久的长期记忆,该记忆在会话期间有效。该记忆存储在磁盘上,并在服务器启动时加载,从而确保学习的连续性。

内存压缩

先进的压缩技术可在保留重要信息的同时减少内存占用。这对于在资源受限的环境中部署尤其有用。

LLM 缓存集成

系统维护经常访问的内存状态的缓存,从而提高重复查询的性能并减少计算开销。

引文

如果您在研究中使用此实现,请引用:

@misc{titanmemory2023, author = {Titan Memory Team}, title = {Titan Memory: Enhanced Memory Framework for Language Models}, year = {2023}, publisher = {GitHub}, url = {https://github.com/titan-memory/titan-cognitive-memory-framework} }

执照

麻省理工学院

-
security - not tested
F
license - not found
-
quality - not tested

remote-capable server

The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.

通过记忆增强模型实现神经记忆序列学习,以改善代码理解和生成,具有状态管理、新颖性检测和模型持久性。

  1. 概述
    1. 特征
      1. 用法
        1. 安装
          1. 运行服务器
            1. 发展
              1. 测试
                1. 高级功能
                  1. 记忆重播
                  2. 动态内存分配
                  3. 长期记忆存储
                  4. 内存压缩
                  5. LLM 缓存集成
                2. 引文
                  1. 执照

                    Related MCP Servers

                    • -
                      security
                      A
                      license
                      -
                      quality
                      Provides deep source code analysis for Unreal Engine codebases, allowing AI assistants to understand C++ class structures, search code, and analyze subsystems.
                      Last updated -
                      71
                      TypeScript
                      MIT License
                    • A
                      security
                      A
                      license
                      A
                      quality
                      Enhances Claude AI with persistent memory storage for Infrastructure-as-Code components, supporting version tracking and relationship mapping for Terraform and Ansible resources.
                      Last updated -
                      23
                      4
                      Python
                      MIT License
                    • -
                      security
                      A
                      license
                      -
                      quality
                      This advanced memory server facilitates neural memory-based sequence learning and prediction, enhancing code generation and understanding through state maintenance and manifold optimization as inspired by Google Research's framework.
                      Last updated -
                      34
                      40
                      TypeScript
                      MIT License
                      • Apple
                      • Linux
                    • -
                      security
                      F
                      license
                      -
                      quality
                      Provides a project memory bank and RAG context provider for enhanced code understanding and management through vector embeddings, integrated with RooCode and Cline.
                      Last updated -
                      9
                      Python
                      • Apple

                    View all related MCP servers

                    ID: iasz64qj43