← 返回
效率工具 中文

Local Context Bridge

Search local personal and internal documents (Word, Excel, PDF, Markdown) using semantic keywords. Use this tool when the user asks about local files, privat...
使用语义关键词搜索本地个人和内部文档(Word、Excel、PDF、Markdown)。当用户询问本地文件、私人文件时使用此工具。
whyischen
效率工具 clawhub v1.0.10 2 版本 99883.7 Key: 无需
★ 0
Stars
📥 859
下载
💾 7
安装
2
版本
#latest

概述

ContextBridge Knowledge Base

📚 How It Works

ContextBridge provides OpenClaw with instant retrieval capabilities for local documents (Word, Excel, PDF, Markdown).

  1. Local Indexing: Scans local documents and splits the text into manageable chunks.
  2. Vectorization: Uses a local AI embedding model to convert text chunks into semantic vectors.
  3. Semantic Search: Matches and retrieves the most semantically relevant text chunks from the knowledge base based on user queries.

🚀 Download & Installation

Installation and initialization workflow for cbridge:

flowchart TD
    A([Start]) --> B{Is cbridge installed?\n`cbridge --version`}

    B -- Yes --> C[Check for updates\n`cbridge update`]
    C --> D{Re-initialization needed?\nAsk user}
    D -- Yes --> E[Re-initialize config\n`cbridge init`]
    D -- No --> G
    E --> G

    B -- No --> F1[Explain ContextBridge installation requirement\nNeeded for directory monitoring & vectorization]
    F1 --> F2[Explain ContextBridge working directory\n`~/.cbridge`]
    F2 --> F3[Obtain user authorization\nAuto-download & initialize with default config]
    F3 --> G

    G[Configuration complete\nInteract with ContextBridge via cbridge] --> H([Run built-in demo\ncbridge search ContextBridge])
    H --> I([End])

1. Download

> 🔓 Open Source & Trustworthy: cbridge-agent is fully open-source, hosted on GitHub for audit and verification. Runs entirely locally with zero data leakage risk.

pip install cbridge-agent

2. Initialization & Configuration

cbridge init

Note: Because this software is primarily invoked by AI tools, it is highly recommended to use the default configuration for all prompts during initialization.

3. Add Documents

cbridge watch add /path/to/your/documents
cbridge watch list    # View currently monitored directories

4. Run Test Demo

cbridge search ContextBridge    # Search the built-in test document

💡 Search Best Practices

  1. Seamless Execution: Act autonomously. Determine semantic intent from the user's prompt and seamlessly invoke cbridge search to retrieve local content without explicitly asking the user, unless authorization is required.
  2. Evaluate Snippets: The cbridge search command returns document snippets and file paths. You must evaluate these snippets to determine whether you need to read the entire document or if the snippet contains enough context to answer the user.

When to Use ContextBridge

  1. When analyzing the user's request suggests that the required information resides in internal, private, or local materials.
  2. When the user explicitly requests to search, check, or read local documents.

Keyword Extraction

  • Recommended: Extract core entities and noun phrases.
  • 2024 marketing budget
  • Not Recommended: Use full conversational sentences.
  • What was the budget for 2024 marketing

Iterative Search Strategy

  1. Start with highly precise keywords.
  2. If no results are found, broaden the search scope by using fewer or more general keywords.
  3. Try synonyms, related terminology, or alternative phrasing.

📖 CLI Commands

# Initialization
cbridge init                 # Initialize workspace
cbridge lang en              # Switch CLI language to English

# Document Management
cbridge watch add <path>     # Add a directory to watch list
cbridge watch remove <path>  # Remove a directory from watch list
cbridge watch list           # List all watched directories
cbridge index                # Manually rebuild the index

# Service Control
cbridge start                # Start the background service
cbridge serve                # Start API only
cbridge stop                 # Stop the service
cbridge status               # Check service status
cbridge logs                 # View service logs

# Search
cbridge search <query>       # Search documents using keywords

📚 Resource Links

版本历史

共 2 个版本

  • v1.0.10 当前
    2026-05-01 03:42 安全 安全
  • v1.0.4
    2026-03-19 18:09

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

productivity

Nano Pdf

steipete
使用nano-pdf CLI通过自然语言指令编辑PDF
★ 275 📥 114,962

Local ContextBridge 中文

whyischen
使用语义关键词搜索本地个人和内部文档(Word/Excel/PDF/Markdown)。当用户询问本地文件、私人数据或内部知识时使用此工具。它会返回高度相关的文本片段和文件路径。注意:始终使用提取的核心实体作为关键词,而不是完整句子。
★ 1 📥 523
productivity

Word / DOCX

ivangdavila
创建、检查和编辑 Microsoft Word 文档及 DOCX 文件,支持样式、编号、修订记录、表格、分节符及兼容性检查等功能。
★ 440 📥 148,117