MCP Catalogs
首页

context-harness

by parallax-labs·36·综合分 44

本地优先的上下文摄入与检索框架,使用 SQLite、嵌入技术和 MCP 服务器,为 Cursor 和 Claude 等 AI 工具提供服务。

developer-toolsfile-systemai-llmproductivity
4
Forks
1
活跃 Issue
3 个月前
最近提交
2 天前
收录于

概述

Context Harness 是一个全面设计的本地优先上下文摄入与检索框架。它支持多种数据源,包括文件系统、Git 仓库、S3 存储桶和自定义 Lua 脚本。系统在本地 SQLite 中存储数据,并可选择使用嵌入技术进行语义搜索。它通过 CLI 工具和 MCP 兼容的 HTTP 服务器提供服务,使 Cursor 和 Claude 等 AI 工具能够访问您的上下文。架构支持关键字、语义和混合检索模式,并提供多种嵌入选项,包括本地 fastembed、Ollama 和 OpenAI。

试试问 AI

装完之后,这里有 3 个你可以让 AI 做的事:

:从本地文档和代码仓库构建个人知识库
:通过 MCP 集成使 AI 助手访问公司文档
:创建可搜索的 Git 仓库档案,支持自动同步

什么时候选它

当您需要支持多种数据源并具备混合搜索功能的本地优先上下文摄取系统时,选择 Context Harness。

什么时候不要选它

如果您需要基于云的上下文存储、实时协作功能,或者更喜欢完全托管的服务而非自托管解决方案,请避免使用此工具。

此 server 暴露的工具

从 README 抽取出 8 个工具
  • searchsearch("query string")

    Search indexed documents using keyword, semantic, or hybrid mode

  • getget("document id")

    Retrieve a specific document by its ID

  • sourcessources()

    List available connectors and their status

  • embedembed({action: "pending" | "rebuild"})

    Backfill missing embeddings or regenerate all embeddings

  • exportexport()

    Export index as JSON for static site search

  • agents_listagents_list()

    List all registered agents

  • agent_promptagent_prompt({name: "agent_name", prompt: "query"})

    Resolve an agent prompt with specific agent

  • listlist()

    List all registered tools

可对比工具

semantic-searchvector-searchobsidian-mcpfile-system-mcp

安装

安装

**预构建二进制文件**(推荐):

# macOS (Apple Silicon)
curl -L https://github.com/parallax-labs/context-harness/releases/latest/download/ctx-macos-aarch64.tar.gz | tar xz
sudo mv ctx /usr/local/bin/

# Linux (x86_64)
curl -L https://github.com/parallax-labs/context-harness/releases/latest/download/ctx-linux-x86_64.tar.gz | tar xz
sudo mv ctx /usr/local/bin/

**Claude Desktop MCP 配置:

添加到 claude_desktop_config.json

{
  "mcpServers": {
    "context-harness": {
      "url": "http://127.0.0.1:7331/mcp"
    }
  }
}

**启动 MCP 服务器:

ctx serve mcp

Hacker News 讨论

开发者社区最近的相关讨论。

context-harness 对比

GitHub →

最后更新于 · 由 README + GitHub 公开数据自动生成。