Skip to main content

OpenClaw framework knowledge graph injector - new Claw projects instantly understand the framework structure

Project description

clawphify 🦞

OpenClaw Framework Knowledge Graph Injector

GitHub Python

🍴 Fork Notice: This is a specialized fork of graphify by @safishamsi. While graphify is a general-purpose knowledge graph builder, clawphify focuses specifically on pre-built OpenClaw framework knowledge for instant project understanding. New OpenClaw projects immediately understand the framework structure—no need to RAG the entire source code.

Why clawphify?

When you start a new project based on OpenClaw:

Without clawphify:

  1. AI reads OpenClaw source files to understand structure
  2. Consumes thousands of tokens
  3. May miss architectural patterns

With clawphify:

  1. Pre-built knowledge graph loaded instantly
  2. Zero token cost for framework understanding
  3. Structured, accurate framework knowledge

Quick Start

# Install
pip install clawphify

# Show built-in OpenClaw knowledge
clawphify info

# Initialize your project with framework graph
clawphify init

# Query the framework
clawphify query "how does channel routing work?"

What You Get

Pre-built Framework Knowledge

Core System:

  • Gateway architecture and session management
  • Pi agent and multi-agent routing
  • Channel ecosystem (20+ channels)
  • Web Control UI

Source Structure:

src/agents     → Agent system, tools, sandbox
src/gateway    → Gateway core, routing
src/channels   → Channel implementations  
src/cli        → CLI commands
src/plugin-sdk → Plugin development SDK
src/security   → Tokens, allowlists
src/tasks      → Task management

CLI Commands:

  • openclaw onboard --install-daemon
  • openclaw dashboard
  • openclaw agent
  • openclaw nodes

Channels:

  • Built-in: Discord, Telegram, WhatsApp, Signal, Slack, iMessage, WebChat
  • Plugin: Matrix, Zalo, Nostr, Twitch, IRC, Mattermost, Feishu

Knowledge Communities

The framework is pre-clustered into 8 communities:

  1. Core System - gateway, agent, config
  2. Channel Ecosystem - all channel integrations
  3. Agent System - runtime, routing, skills
  4. CLI & Interface - commands, TUI, web UI
  5. Plugin System - SDK, extensions
  6. Infrastructure - utils, security, sessions
  7. Media Processing - images, audio, docs
  8. Documentation - all docs hubs

Usage Patterns

New OpenClaw Project

# In your new project directory
clawphify init

# Now ask framework questions:
# "What files should I modify to add a channel?"
# "How does authentication work?"
# "Where is the session config?"

OpenClaw Development

If you're modifying OpenClaw itself, use graphify directly:

graphify . --update

This builds a project-specific graph including your changes.

Installation

pip install clawphify

# Install skill for your AI assistant
clawphify install                    # Claude Code
clawphify install --platform claw    # OpenClaw
clawphify install --platform codex   # Codex

Commands

Command Description
clawphify info Show built-in OpenClaw framework info
clawphify init Copy built-in graph to clawphify-out/
clawphify query "Q" Query the framework graph
clawphify install Install skill for AI assistant
clawphify claude install Configure for Claude Code
clawphify claw install Configure for OpenClaw

Example Queries

# Architecture questions
clawphify query "how does gateway manage sessions?"
clawphify query "what is the relationship between channels and plugins?"

# Implementation guidance
clawphify query "where should I add authentication logic?"
clawphify query "how do I create a new channel?"

# Configuration help
clawphify query "what are the key config settings?"
clawphify query "how do I configure WhatsApp channel?"

Integration with graphify

clawphify uses graphify's graph format. You can use graphify tools:

# Merge with project-specific knowledge
graphify . --update --graph clawphify-out/openclaw_graph.json

# Use graphify's query on clawphify graph
graphify query "channels" --graph clawphify-out/openclaw_graph.json

How It Works

  1. Built-in Graph: Contains OpenClaw v3.22.0 framework structure
  2. JSON Format: Compatible with graphify's graph.json format
  3. Node Types: system, module, feature, command, config, docs
  4. Edges: EXTRACTED (from source) and INFERRED (relationships)
  5. Communities: Pre-clustered using Leiden algorithm

Graph Contents

  • 50+ nodes: Core components, modules, features, docs
  • 30+ edges: Relationships and dependencies
  • 8 communities: Logical groupings
  • Quick reference: Getting started, key directories, config essentials

Requirements

  • Python 3.10+
  • networkx
  • tree-sitter

License

MIT - Same as OpenClaw and graphify

Credits

  • Built on graphify by @safishamsi
  • OpenClaw framework by the OpenClaw team
  • Graph extraction from OpenClaw v3.22.0

For new Claw: Know thy framework instantly. 🦞

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

clawphify-0.1.0.tar.gz (80.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

clawphify-0.1.0-py3-none-any.whl (86.4 kB view details)

Uploaded Python 3

File details

Details for the file clawphify-0.1.0.tar.gz.

File metadata

  • Download URL: clawphify-0.1.0.tar.gz
  • Upload date:
  • Size: 80.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.12

File hashes

Hashes for clawphify-0.1.0.tar.gz
Algorithm Hash digest
SHA256 440ed88b65a0458df1b9a763f7ee0d7b377a8383e506d3eaa50966ea4e35a74b
MD5 561d592d4ad345d09813792de251387e
BLAKE2b-256 a14df09c386f5ec9faf21f43b06a302430e793458d4a5a42bae05f1ef6df1692

See more details on using hashes here.

File details

Details for the file clawphify-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: clawphify-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 86.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.12

File hashes

Hashes for clawphify-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7e630e0dc7651c7fc489723c1291f09aefc9901731b2bbac902ada24dbfa0195
MD5 47fa898c291ae753fc63336358096539
BLAKE2b-256 912f2f3e9b0ecd19c8619aed2333e3d37de866dd959d00707c524a954b7a3de6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page