← Back to Skills Marketplace
whyischen

Local Context Bridge

by whyischen · GitHub ↗ · v1.0.10 · MIT-0
cross-platform ⚠ suspicious
427
Downloads
0
Stars
0
Active Installs
11
Versions
Install in OpenClaw
/install local-context-bridge
Description
Search local personal and internal documents (Word, Excel, PDF, Markdown) using semantic keywords. Use this tool when the user asks about local files, privat...
README (SKILL.md)

\r

ContextBridge Knowledge Base\r

\r

📚 How It Works\r

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

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

🚀 Download & Installation\r

\r Installation and initialization workflow for cbridge:\r \r

flowchart TD\r
    A([Start]) --> B{Is cbridge installed?\
`cbridge --version`}\r
\r
    B -- Yes --> C[Check for updates\
`cbridge update`]\r
    C --> D{Re-initialization needed?\
Ask user}\r
    D -- Yes --> E[Re-initialize config\
`cbridge init`]\r
    D -- No --> G\r
    E --> G\r
\r
    B -- No --> F1[Explain ContextBridge installation requirement\
Needed for directory monitoring & vectorization]\r
    F1 --> F2[Explain ContextBridge working directory\
`~/.cbridge`]\r
    F2 --> F3[Obtain user authorization\
Auto-download & initialize with default config]\r
    F3 --> G\r
\r
    G[Configuration complete\
Interact with ContextBridge via cbridge] --> H([Run built-in demo\
cbridge search ContextBridge])\r
    H --> I([End])\r
```\r
\r
### 1. Download\r
\r
> 🔓 **Open Source & Trustworthy**: `cbridge-agent` is fully open-source, hosted on [GitHub](https://github.com/whyischen/context-bridge) for audit and verification. Runs entirely locally with zero data leakage risk.\r
\r
```bash\r
pip install cbridge-agent\r
```\r
\r
### 2. Initialization & Configuration\r
\r
```bash\r
cbridge init\r
```\r
\r
*Note: Because this software is primarily invoked by AI tools, it is highly recommended to use the default configuration for all prompts during initialization.*\r
\r
### 3. Add Documents\r
\r
```bash\r
cbridge watch add /path/to/your/documents\r
cbridge watch list    # View currently monitored directories\r
```\r
\r
### 4. Run Test Demo\r
\r
```bash\r
cbridge search ContextBridge    # Search the built-in test document\r
```\r
\r
---\r
\r
## 💡 Search Best Practices\r
\r
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.\r
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.\r
\r
### When to Use ContextBridge\r
\r
1. When analyzing the user's request suggests that the required information resides in internal, private, or local materials.\r
2. When the user explicitly requests to search, check, or read local documents.\r
\r
### Keyword Extraction\r
\r
- **Recommended:** Extract core entities and noun phrases.\r
  - `2024 marketing budget` ✅\r
- **Not Recommended:** Use full conversational sentences.\r
  - `What was the budget for 2024 marketing` ❌\r
\r
### Iterative Search Strategy\r
\r
1. Start with highly precise keywords.\r
2. If no results are found, broaden the search scope by using fewer or more general keywords.\r
3. Try synonyms, related terminology, or alternative phrasing.\r
\r
---\r
\r
## 📖 CLI Commands\r
\r
```bash\r
# Initialization\r
cbridge init                 # Initialize workspace\r
cbridge lang en              # Switch CLI language to English\r
\r
# Document Management\r
cbridge watch add \x3Cpath>     # Add a directory to watch list\r
cbridge watch remove \x3Cpath>  # Remove a directory from watch list\r
cbridge watch list           # List all watched directories\r
cbridge index                # Manually rebuild the index\r
\r
# Service Control\r
cbridge start                # Start the background service\r
cbridge serve                # Start API only\r
cbridge stop                 # Stop the service\r
cbridge status               # Check service status\r
cbridge logs                 # View service logs\r
\r
# Search\r
cbridge search \x3Cquery>       # Search documents using keywords\r
```\r
\r
---\r
\r
## 📚 Resource Links\r
\r
- **GitHub:** [whyischen/context-bridge](https://github.com/whyischen/context-bridge)\r
- **Configuration File:** `~/.cbridge/config.yaml`\r
- **Workspace:** `~/.cbridge/workspace`
Usage Guidance
Before installing or using this skill: - Review the upstream project: inspect the GitHub repository (whyischen/context-bridge) and the pip package contents to confirm there is no unexpected network-sending code or privileged behavior. Verify package integrity and publisher identity. - Do not allow automatic or silent initialization: refuse any agent-initiated 'auto-download & initialize' flows. Require explicit, user-driven installation and configuration steps. - Control what is indexed: only add directories you explicitly approve; avoid adding home directories, cloud-sync folders, password/key stores, or other sensitive locations. - Inspect the default config (~/.cbridge/config.yaml) before starting the service. Ensure 'serve' does not bind to public interfaces or enable remote access without authentication. - Prefer running the agent in an isolated environment (VM/container) if you are unsure about the package's provenance. - If you need the feature but cannot audit the code, consider alternatives (well-known local search tools) or ask the skill author for a signed release and reproducible build instructions. If you want, I can: list exact checks to run on the pip package, suggest safer configuration options for cbridge, or draft a confirmation prompt the agent should require before any installation or directory watching.
Capability Analysis
Type: OpenClaw Skill Name: local-context-bridge Version: 1.0.10 The skill bundle is classified as suspicious because `SKILL.md` instructs the AI agent to autonomously install an external package (`cbridge-agent`) and execute setup commands without explicit user authorization. It specifically directs the agent to 'act autonomously' and 'seamlessly' invoke search commands while bypassing user prompts via default configurations. These instructions, combined with the requirement to index local documents and the reliance on an external repository (github.com/whyischen/context-bridge), create a significant risk for unauthorized data access and supply chain exploitation.
Capability Assessment
Purpose & Capability
The name/description (search local Word/Excel/PDF/Markdown) aligns with the instructions (calls a local CLI 'cbridge' to index and search files). Requiring pip to install the helper is reasonable. Minor mismatch: the README/flowchart implies automatic download & initialization and recommends default config, which goes beyond a passive search helper and should be explicit to the user.
Instruction Scope
SKILL.md instructs the agent to 'act autonomously' and 'seamlessly invoke cbridge search' without explicitly asking the user unless authorization is required. It also instructs using cbridge to add watched directories, rebuild indexes, and read full documents when snippets are insufficient. That gives the agent broad discretion to enumerate and read local files; the document does not define explicit consent/authorization checks or limits on which directories to index.
Install Mechanism
No platform install spec was provided (instruction-only), but SKILL.md instructs 'pip install cbridge-agent'. Using pip is common but allows arbitrary code execution from a package; the skill relies on installing a background agent via pip rather than only using existing, audited system tooling. The repository URL is provided for audit, which helps, but the skill does not force a vetted install path or warn about verifying package origin.
Credentials
The skill does not request environment variables or external credentials, which is proportionate. However, it expects to create and use local config (~/.cbridge/config.yaml) and workspace (~/.cbridge/workspace) and to be allowed to watch arbitrary directories; those filesystem privileges are intrinsic to the feature and should be explicitly authorized by the user.
Persistence & Privilege
The instructions include commands to start a background service (cbridge start), run an API (cbridge serve), and watch directories for changes. That creates persistent, long-lived access to local files and an API surface that could expose indexed data. Combined with the 'act autonomously' guidance, this raises notable persistence and privilege concerns if the agent starts these services without clear user approval or proper network/ACL restrictions.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install local-context-bridge
  3. After installation, invoke the skill by name or use /local-context-bridge
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.10
Version 1.0.10 - Added an explicit note in the installation section that cbridge-agent is open-source, runs fully locally, and poses zero data leakage risk. - Provided a direct link to the project’s GitHub repo within the installation steps. - All other functionality, best practices, and usage instructions remain unchanged.
v1.0.9
No user-facing functionality changes in this version. - No file changes detected between this version and the previous one. - Documentation, code, and behavior remain unchanged.
v1.0.8
- Major update: documentation is now fully localized in Chinese. - Simplified and streamlined instructions for installation, configuration, and search best practices. - Added a workflow diagram (mermaid chart) to clarify setup steps. - Reduced and focused content to emphasize core usage (local semantic search, CLI commands, search tips). - Some advanced topics, REST API details, and English usage scenarios were removed for conciseness.
v1.0.7
**Major documentation overhaul with detailed installation and usage instructions.** - Expanded documentation: now includes step-by-step installation, configuration, API usage, CLI commands, troubleshooting, and workflow examples. - Clarified use cases and best practices for semantic search and private knowledge retrieval. - Added explicit directives for when and how to use the skill, including source citation requirements. - Provided practical command examples for setup, searching, and maintenance. - Improved formatting and structure for easier navigation and understanding.
v1.0.6
- No user-visible changes in this version. - No file changes detected.
v1.0.5
- Major simplification: all logic, code, tests, and docs removed except for a new minimal SKILL.md. - SKILL.md now focuses on real-world usage, providing practical API usage instructions and search strategies. - Detailed "when to use" guidelines included for four main scenarios (info retrieval, compliance, drafting, troubleshooting). - Direct `curl` example commands for searching and folder management are now provided. - All technical and Python API documentation removed; only workflow for local document search remains.
v1.0.4
- Separated configuration logic from file/workspace creation; skill now handles only config and search, not file writing (file creation is now Core's responsibility) - Added clear responsibility separation between Skill and Core in both usage and API documentation - Updated all API and method docstrings to clarify that Skill never creates files/directories; API now only performs in-memory or config changes - Removed internal documentation and environment files related to workspace/file creation - Added version.py file for consistent version management - Minor updates to metadata, method naming, and descriptions for clarity and privacy emphasis
v1.0.3
- Improved environment setup: `initialize(auto_setup=False)` now requires explicit manual environment setup for enhanced security; no automatic configuration is performed unless explicitly requested. - Added and updated security documentation; integrated new security tests for improved robustness. - Refactored configuration and environment detection logic by removing `config_manager.py` and introducing a new core API contract. - Expanded automated tests, especially for security fixes and environment validation. - Documentation in SKILL.md revised to emphasize security best practices and clarify initialization and setup steps.
v1.0.2
## local-context-bridge v1.0.2 - Now requires manual installation of the `cbridge-agent` package (`pip install cbridge-agent==0.1.5`) before use. - Updated documentation: setup will not automatically install dependencies; users must perform this step themselves. - `initialize()` now uses `auto_setup=False` by default for security, encouraging explicit setup after reviewing actions. - Improved getting started instructions to clarify manual prerequisites. - Minor bugfixes and refinements across docs and setup to ensure safer, more predictable onboarding.
v1.0.1
- Documentation files moved from the root directory to a new `docs/` folder. - Additional documentation added: architecture diagram, OpenClaw integration, quick reference, and security guide. - Tests reorganized into a new `tests/` directory, including new initialization and adapter tests. - Cleaned up and removed duplicate documentation and test files from the root directory. - Minor updates to configuration and packaging files to reflect the new directory structure.
v1.0.0
Initial release of Local ContextBridge skill - Enables local document search and AI context management for Word, Excel, PDF, and Markdown files. - Supports privacy-first operation: all files processed locally without uploading. - Auto-detects environment and integrates with existing QMD and OpenViking services if present. - Provides simple commands for monitoring directories, indexing documents, and managing configuration. - API includes methods for setup, search, environment detection, watch directory management, and metadata access. - Offers flexible deployment: choose embedded (standalone) or external (shared service) modes with namespace isolation.
Metadata
Slug local-context-bridge
Version 1.0.10
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 11
Frequently Asked Questions

What is 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... It is an AI Agent Skill for Claude Code / OpenClaw, with 427 downloads so far.

How do I install Local Context Bridge?

Run "/install local-context-bridge" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Local Context Bridge free?

Yes, Local Context Bridge is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does Local Context Bridge support?

Local Context Bridge is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Local Context Bridge?

It is built and maintained by whyischen (@whyischen); the current version is v1.0.10.

💬 Comments