MCP Catalogs
首页

ontomics

by EtienneChollet·31·综合分 44

ontomics 通过 MCP 从代码库中提取领域知识,减少 20% 的令牌消耗和 10% 的搜索时间,使概念和命名约定可查询。

developer-toolsai-llmknowledge-graph
6
Forks
0
活跃 Issue
1 个月前
最近提交
2 天前
收录于

概述

ontomics 是一个基于 Rust 的 MCP 服务器,通过将相关符号聚类为概念、检测命名约定、解析缩略词和按行为相似性对函数进行分组,来构建代码库的语义索引。它完全本地运行,无需 API 密钥,使用 tree-sitter 解析源文件,并使用嵌入模型对概念和逻辑进行聚类。该服务器提供工具用于查询概念、追踪词汇变化、查找功能相似的代码,并将领域知识作为可移植工件导出。

试试问 AI

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

:通过基于概念的查询而非文件搜索将代码理解速度提高 20 倍
:通过检查命名约定与既定模式来保持代码一致性
:发现不同命名函数之间的实现相似性
:导出领域知识,以在新的代码库中建立既定约定
:ontomics 如何减少 20 倍的令牌消耗?
:ontomics 支持哪些编程语言?
:数据是否会被发送到外部服务器?

什么时候选它

当您处理大型代码库,需要快速理解领域概念、命名约定和行为关系,且希望避免过度的令牌消耗时,请选择 ontomics。

什么时候不要选它

如果您需要实时协作功能,或者您的项目使用了 ontomics 不支持的语言(目前仅支持 Python、TypeScript、JavaScript 和 Rust),请不要选择 ontomics。

此 server 暴露的工具

从 README 抽取出 12 个工具
  • query_concept

    Find all variants, related concepts, and occurrences of a term

  • locate_concept

    Find the key signatures, classes, and files for a concept

  • describe_symbol

    Get the signature, docstring, and relationships for a function or class

  • trace_concept

    Trace how a concept flows through the codebase via call chains

  • find_similar_logic

    Find functions with behaviorally similar implementations

  • describe_logic

    Get the behavioral description and logic cluster membership for a function

  • compact_context

    Assemble tiered context for a symbol, optimized for LLM consumption

  • describe_file

    Overview of a file's entities, concepts, and relationships

  • concept_map

    Show which modules contain which domain concepts

  • list_concepts

    List the top domain concepts by frequency

  • check_naming

    Check an identifier against project conventions

  • export_domain_pack

    Export domain knowledge as portable YAML

可对比工具

semantic-search-mcpcodebase-mcpsemantic-code-search

安装

使用您喜欢的方式安装 ontomics:

**npm (macOS/Linux):**

npm install -g @ontomics/ontomics

**macOS (Homebrew):**

brew install EtienneChollet/tap/ontomics

**与 Claude Desktop 注册:** 添加到您的 claude_desktop_config.json

{
  "mcpServers": {
    "ontomics": {
      "command": "ontomics"
    }
  }
}

**与团队共享** — 在您的代码库根目录中放置一个 .mcp.json

{
  "mcpServers": {
    "ontomics": {
      "command": "npx",
      "args": ["-y", "@ontomics/ontomics", "--repo", "."]
    }
  }
}

FAQ

ontomics 如何减少 20 倍的令牌消耗?
ontomics 构建了一个领域概念的语义索引,使 LLM 能够通过单个工具调用找到概念信息,而不是在多个文件中搜索并进行大量工具调用。
ontomics 支持哪些编程语言?
当前支持 Python、TypeScript、JavaScript 和 Rust,通过文件扩展名自动检测。
数据是否会被发送到外部服务器?
不会,ontomics 在本地机器上处理所有内容,不需要 API 密钥。索引存储在 <repo>/.ontomics/index.db 本地。

ontomics 对比

GitHub →

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