インストール
PRX-MemoryはRustワークスペースとして配布されています。主要な成果物はprx-memory-mcpクレートのprx-memorydデーモンバイナリです。
推奨
ソースからビルドすることで最新機能が使用でき、LanceDBなどのオプションバックエンドを有効にできます。
前提条件
| 要件 | 最小 | 備考 |
|---|---|---|
| Rust | stable toolchain | rustupでインストール |
| オペレーティングシステム | Linux、macOS、Windows (WSL2) | Rustがサポートする任意のプラットフォーム |
| Git | 2.30+ | リポジトリをクローンするため |
| ディスク容量 | 100 MB | バイナリ + 依存関係 |
| RAM | 256 MB | 大規模メモリデータベースにはより多く推奨 |
方法1:ソースからビルド(推奨)
リポジトリをクローンしてリリースモードでビルドします:
bash
git clone https://github.com/openprx/prx-memory.git
cd prx-memory
cargo build --release -p prx-memory-mcp --bin prx-memorydバイナリはtarget/release/prx-memorydにあります。PATHにコピーします:
bash
sudo cp target/release/prx-memoryd /usr/local/bin/prx-memorydビルドオプション
| フィーチャーフラグ | デフォルト | 説明 |
|---|---|---|
lancedb-backend | 無効 | LanceDBベクトルストレージバックエンド |
LanceDBサポートでビルドするには:
bash
cargo build --release -p prx-memory-mcp --bin prx-memoryd --features lancedb-backendビルド依存関係
Debian/Ubuntuでは以下が必要な場合があります:
bash
sudo apt install -y build-essential pkg-config libssl-devmacOSではXcode Command Line Toolsが必要です:
bash
xcode-select --install方法2:Cargoインストール
Rustがインストールされている場合は直接インストールできます:
bash
cargo install prx-memory-mcpこれはソースからコンパイルし、prx-memorydバイナリを~/.cargo/bin/に配置します。
方法3:ライブラリとして使用
PRX-Memoryクレートを自分のRustプロジェクトの依存関係として使用するには、Cargo.tomlに追加します:
toml
[dependencies]
prx-memory-core = "0.1"
prx-memory-embed = "0.1"
prx-memory-rerank = "0.1"
prx-memory-storage = "0.1"インストールの確認
ビルド後、バイナリが動作することを確認します:
bash
prx-memoryd --help基本的なstdioセッションをテストします:
bash
PRX_MEMORYD_TRANSPORT=stdio \
PRX_MEMORY_DB=./data/memory-db.json \
prx-memorydHTTPセッションをテストします:
bash
PRX_MEMORYD_TRANSPORT=http \
PRX_MEMORY_HTTP_ADDR=127.0.0.1:8787 \
PRX_MEMORY_DB=./data/memory-db.json \
prx-memorydヘルスエンドポイントを確認します:
bash
curl -sS http://127.0.0.1:8787/health開発セットアップ
開発とテストには標準のRustワークフローを使用します:
bash
# Format
cargo fmt --all
# Lint
cargo clippy --all-targets --all-features -- -D warnings
# Test
cargo test --all-targets --all-features
# Check (fast feedback)
cargo check --all-targets --all-featuresアンインストール
bash
# Remove the binary
sudo rm /usr/local/bin/prx-memoryd
# Or if installed via Cargo
cargo uninstall prx-memory-mcp
# Remove data files
rm -rf ./data/memory-db.json