← 返回
未分类 Key 中文

Memory Semantic Search

Semantic search over workspace markdown files using embedding API + SQLite vector store. Use when: (1) searching workspace notes/memory by meaning rather tha...
使用嵌入 API + SQLite 向量库对工作区 Markdown 文件进行语义搜索。适用场景:(1) 按意义而非精确词汇搜索工作区笔记/记忆。
toller892
未分类 clawhub v1.0.0 1 版本 100000 Key: 需要
★ 0
Stars
📥 340
下载
💾 0
安装
1
版本
#latest

概述

Memory Semantic Search

Standalone semantic search over workspace .md files. Uses an OpenAI-compatible embedding API and SQLite for vector storage. No external dependencies beyond Python 3 stdlib + the embedding API.

Setup

Set these environment variables (or pass as CLI args):

export EMBEDDING_API_KEY="sk-xxx"
export EMBEDDING_API_BASE="https://api.openai.com/v1"   # any OpenAI-compatible endpoint
export EMBEDDING_MODEL="text-embedding-3-small"          # optional, this is the default

Usage

Index workspace

python3 scripts/index.py /path/to/workspace

Options:

  • --force — full reindex (clear existing data)
  • --db PATH — custom SQLite path (default: memory_search.sqlite in skill dir)
  • --api-base, --api-key, --model — override env vars

Incremental: only new/changed chunks are embedded. Deleted files are cleaned up automatically.

Search

python3 scripts/search.py "your query here"

Options:

  • --top-k N — number of results (default: 5)
  • --min-score F — minimum cosine similarity threshold (default: 0.3)
  • --json — output as JSON
  • --db, --api-base, --api-key, --model — same as index

Typical agent workflow

  1. Run index.py on the workspace (once, or after file changes)
  2. Run search.py "query" to find relevant snippets
  3. Use read tool to load full context from the returned file paths and line numbers

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-05-07 18:11 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

API Health Monitor

toller892
解析最近的OpenClaw会话日志,提取LLM API错误并返回结构化健康报告。
★ 0 📥 404
developer-tools

GitHub AI Trends

toller892
生成 GitHub AI 趋势项目的文本排行榜,按日、周、月抓取 AI/ML/LLM 高星仓库并渲染。用于查询 AI 项目趋势、GitHub 趋势、AI 排行榜或热门 AI 仓库。
★ 12 📥 7,497

Capability Evolver

toller892
AI智能体自我进化引擎,通过分析运行时历史识别改进点,实现协议约束的进化。
★ 0 📥 1,262