← 返回
数据分析 中文

OpenClaw Docs Search + Config Patterns

MANDATORY before any openclaw.json changes. Prevents config breakage via embedded anti-patterns and correct patterns. Use when configuring OpenClaw (bindings, channels, sessions, cron, heartbeat) or troubleshooting config issues.
修改 openclaw. 前必用。通过内嵌反模式与正确模式防止配置损坏。适用于配置 OpenClaw(绑定、通道、会话、定时任务、心跳)或排查配置问题。
karmanverma
数据分析 clawhub v1.1.0 1 版本 99759 Key: 无需
★ 0
Stars
📥 1,656
下载
💾 28
安装
1
版本
#latest

概述

OpenClaw Documentation Search + Config Patterns

MANDATORY before changing openclaw.json - Embedded patterns prevent silent config breakage.

Two modes:

  1. Embedded references (instant) - Common config patterns with anti-patterns
  2. Doc search (fallback) - Full OpenClaw documentation index

🚨 CRITICAL: Read AGENTS.md First

Before using this skill:

cat ~/.openclaw/skills/search-openclaw-docs/AGENTS.md

Contains:

  • Mandatory workflow for config changes
  • Decision tree (which reference to read)
  • Critical anti-patterns overview
  • When NOT to use this skill

Decision Tree

TaskAction
--------------
Adding/removing agent bindingsRead references/config-bindings.md
Enabling/disabling channelsRead references/config-channel-management.md
Session reset tuningRead references/config-session-reset.md
Heartbeat configurationRead references/config-heartbeat.md
Cron job setupRead references/config-cron.md
Config broke after patchRead references/troubleshooting-config-breaks.md
Best practices overviewRead references/best-practices-config.md
Migration (2026.2.9)Read references/migration-2026-2-9.md
Other config questionsSearch docs (see below)

Embedded References (8 files)

Config Patterns:

  • config-bindings.md - Agent routing (CRITICAL)
  • config-channel-management.md - Enable/disable channels (CRITICAL)
  • config-session-reset.md - Session lifetime policies (HIGH)
  • config-heartbeat.md - Proactive monitoring (MEDIUM)
  • config-cron.md - Scheduled tasks (MEDIUM)

Support:

  • troubleshooting-config-breaks.md - Fix broken configs (CRITICAL)
  • best-practices-config.md - Safe patterns (HIGH)
  • migration-2026-2-9.md - Version updates (MEDIUM)

Each reference contains:

  • ✅ Correct pattern
  • ❌ Common anti-patterns
  • Why it breaks
  • Examples

When to Use

ScenarioAction
------------------
Before editing openclaw.json✅ Read relevant reference first
Config changes not working✅ Read troubleshooting reference
Learning OpenClaw config✅ Read best practices reference
Personal memory/context❌ Use memory_search instead
Supabase/database work❌ Use supabase-postgres-best-practices
Next.js code patterns❌ Use next-best-practices

Doc Search (Fallback)

For topics not in references, search full docs:

# Search
node ~/.openclaw/skills/search-openclaw-docs/scripts/docs-search.js "discord requireMention"

# Check index health
node ~/.openclaw/skills/search-openclaw-docs/scripts/docs-status.js

# Rebuild (after OpenClaw update)
node ~/.openclaw/skills/search-openclaw-docs/scripts/docs-index.js rebuild

Usage Examples

# Config question
node scripts/docs-search.js "discord requireMention"

# Troubleshooting  
node scripts/docs-search.js "webhook not working"

# More results
node scripts/docs-search.js "providers" --top=5

# JSON output
node scripts/docs-search.js "heartbeat" --json

Output Format

🔍 Query: discord only respond when mentioned

🎯 Best match:
   channels/discord.md
   "Discord (Bot API)"
   Keywords: discord, requiremention
   Score: 0.70

📄 Also relevant:
   concepts/groups.md (0.66)

💡 Read with:
   cat /usr/lib/node_modules/openclaw/docs/channels/discord.md

How It Works

  • FTS5 keyword matching on titles, headers, config keys
  • Handles camelCase terms like requireMention
  • Porter stemming for flexible matching
  • No network calls - fully offline

Index Location

  • Index: ~/.openclaw/docs-index/openclaw-docs.sqlite
  • Docs: /usr/lib/node_modules/openclaw/docs/

Index is built locally from your OpenClaw version.

Troubleshooting

No results / wrong results

# 1. Check index exists
node scripts/docs-status.js

# 2. Rebuild if stale
node scripts/docs-index.js rebuild

# 3. Try exact config terms (camelCase matters)
node scripts/docs-search.js "requireMention"

# 4. Try broader terms
node scripts/docs-search.js "discord"

Integration

const { search } = require('./lib/search');
const INDEX = process.env.HOME + '/.openclaw/docs-index/openclaw-docs.sqlite';

const results = await search(INDEX, "discord webhook");
// results[0].path → full path to read

版本历史

共 1 个版本

  • v1.1.0 当前
    2026-03-28 21:22 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

data-analysis

A股量化 AkShare

mbpz
A股量化数据分析工具,基于AkShare库获取A股行情、财务数据、板块信息等。用于回答关于A股股票查询、行情数据、财务分析、选股等问题。
★ 164 📥 59,799
data-analysis

Excel / XLSX

ivangdavila
创建、检查和编辑 Microsoft Excel 工作簿及 XLSX 文件,支持可靠的公式、日期、类型、格式、重算及模板保留功能。
★ 367 📥 140,147
content-creation

MarkItDown Skill

karmanverma
OpenClaw 代理技能,用于将文档转换为 Markdown,提供 Microsoft MarkItDown 库的文档和工具,支持 PDF、Word、PowerPoint、Excel、图片(OCR)、音频(转录)、HTML、YouTube
★ 2 📥 2,684