claudeers.
// Automation & Workflows

cc-to-grok-bridge

Bridge Claude Code → Grok Build: shared rules/skills, hook adapter hard-gates, optional memory mirror

// Automation & Workflows[ cli ][ api ][ web ][ claude ]#claude#ai-agents#claude-code#developer-tools#grok#hooks#llm#xai#automationMIT$open-sourceupdated about 1 month ago
Actively maintained
95/100
last commit 25 days ago
last release none
releases 0
open issues 0
// star history

Install with your AI

Paste into Claude Code, Cursor, or any agent — it reads the repo and wires the tool into your project.

Install and set up cc-to-grok-bridge (git-clone project) into my current project.
Found on https://claudeers.com/cc-to-grok-bridge
Repo: https://github.com/yyu0310/cc-to-grok-bridge
Homepage/docs: —
Detected install method: git-clone → git clone https://github.com/yyu0310/cc-to-grok-bridge
Category: automation. Platforms: cli, api, web.
Read the repo's README for exact setup and env vars, then install it and wire it into my project.

Claudeers Health Verdict:
active; community-verified: false. Confirm the source before running anything.
// or clone
git clone https://github.com/yyu0310/cc-to-grok-bridge

// compatibility

Platformscli, api, web
Operating systems
AI compatibilityclaude
LicenseMIT
Pricingopen-source
LanguagePython

cc-to-grok-bridge

English | 繁體中文 | 简体中文

Bridge Claude CodeGrok Build: reuse rules / skills, run the same hook hard-gates via an adapter, optional memory mirror. Grok-only assets never enter Claude’s context.

What this is

LayerWhat the bridge does
System PromptPoint Grok at the same workspace CLAUDE.md (compat load)
skillReuse ~/.claude/commands slash skills (including symlinks)
HooksCall your existing Claude Code security scripts through a thin adapter that translates allow/deny for Grok (see below)
MemoryCC → Grok pull + rules pointer + three-zone isolation; optional constrained push
PluginsDoes not auto-port CC enabledPlugins; always-on only — see docs/06_plugins.md
MCPAI-assisted install by server type (never auto-copy secrets; see AGENTS.md)

Research helper: ccgrok.sh

A small wrapper that drives grok -p as a disciplined research tool. It prepends a model-agnostic research-method prefix (research-prefix.md) and runs from a clean temp directory, so a pure research query is not polluted by project rules.

scripts/ccgrok.sh "your question"

The prefix forces sourced, dated answers with facts separated from speculation, and (measured on the same query) makes Grok flag stale or downgraded facts instead of stating them with false confidence. The same research-prefix.md works with any headless AI CLI (grok -p, agy -p, claude -p).

The read-only flags (--disallowed-tools "run_terminal_cmd,write,search_replace") keep the run unable to touch local files even under auto-approve.

Compatibility matrix

DomainCompatibilityWhat worksGaps
System PromptHighSame workspace CLAUDE.md (Grok compat auto-load)
skillHighSame ~/.claude/commands set (symlinks OK)Minor frontmatter / trigger differences
MemoryHighmemory_sync + rules pointer + three-zone layout; optional pushNot the same as CC MEMORY.md index load; product search optional
HooksMediumAdapter + your CC hard-block scriptsPayload/deny translation; no full CC ask UI
MCPMediumReinstall by type (HTTP key, OAuth, stdio); Notion/Google in docsclaude.ai cloud connectors not portable; secrets never auto-copied
PluginsLowA: install when Grok packaging exists; B: rules always-on (see note)CC settings do not auto-port; different marketplaces

In practice: moving a Claude Code setup onto Grok Build is usually much smoother than the Antigravity / Gemini bridge path (real hard-blocks + simpler memory). Always-on plugins still need a deliberate path.

Plugins note (Low = not drop-in, but documented fixes exist):
CC auto-enabled plugins ≠ Grok per-session injection. A: grok plugin install only when upstream has Grok packaging (SessionStart always-on). B: otherwise put always-on text in .grok/rules/ (auto-load, no slash). See docs/06_plugins.md.
Outlook: if most common plugins ship on the Grok marketplace with real Grok packaging, compatibility can rise to medium–high (still not auto-porting CC settings, but path A becomes normal and B is the exception).

Memory detail: bridge day-use does not require [memory] enabled=true first — the rules pointer loads with the project. Product memory improves search if you want it.

MCP detail: ask an AI coding agent to follow AGENTS.md (Notion, Google, OAuth). You approve the browser; you should not be asked to paste long terminal homework.

What the hook adapter does (plain language)

Claude Code hooks are shell scripts (e.g. block reading .env). Grok also runs hooks, but the contracts differ:

  1. JSON field names on stdin differ (payload shape)
  2. How “block this tool call” is reported differs (deny protocol)

So you cannot point Grok straight at CC scripts. A thin adapter (scripts/hook_adapter.py) sits in the middle: Grok calls it; it calls your existing ~/.claude/hooks/*.sh.

TermMeaning
Thin adapterFormat translation only — does not reimplement the security policy
Wraps CC scriptsInvokes the same scripts; bodies stay on the CC side
Payload normalizeMap Grok field names to what CC scripts expect (e.g. target_filefile_path)
Deny translateCC often uses exit 2 + stderr; adapter emits Grok’s {"decision":"deny", …}

Why this design:

  • Single source of truth — blocklists stay in CC hooks
  • Hard block on Grok — not “model please remember”; the tool call is actually denied
  • No forking CC scripts — no need to edit ~/.claude/hooks/*.sh just for Grok

Requirements

  • macOS or Linux with Python 3.10+
  • Claude Code already set up (hooks under ~/.claude/hooks/, skills under ~/.claude/commands/)
  • Grok Build CLI / TUI
  • No API key required for the bridge scripts themselves

Quick start

git clone https://github.com/<YOUR_USERNAME>/cc-to-grok-bridge.git
cd cc-to-grok-bridge

# From your real workspace root (the folder that has CLAUDE.md / .grok/)
export CC_GROK_WORKSPACE=~/path/to/your-workspace

python3 scripts/install_bridge.py
python3 scripts/memory_sync.py --workspace "$CC_GROK_WORKSPACE"
python3 scripts/bridge_doctor.py --workspace "$CC_GROK_WORKSPACE"   # expect fails=0

Then open Grok from that workspace and restart the session so hooks reload.

Layout

PathRole
scripts/hook_adapter.pyNormalize Grok payload → CC hook stdin; translate deny
scripts/install_bridge.pyInstall adapter + Grok hooks JSON; disable double-fire
scripts/memory_sync.pyCC → Grok memory pull
scripts/memory_push.pyOptional constrained push: general/ → CC
scripts/bridge_doctor.pyRead-only health check + hard-block smoke
scripts/hook_acceptance.pyAdapter-layer acceptance tests
architecture.mdDesign invariants (source of truth for “why”)
docs/Gap matrix, day-to-day SOP, memory, MCP, plugins, harness table

Security

  • Scripts never copy MCP env / tokens / OAuth secrets.
  • Sensitive-read hard block is verified via adapter + your CC block_sensitive_read hook (e.g. .clasprc*, .env).
  • Grok-only rules live under <workspace>/.grok/rules/ and must not be written into Claude’s system files by this bridge.

Limitations

  1. MCP: secrets never auto-copied; claude.ai cloud connectors not portable — reinstall via docs/03_mcp.md / AGENTS.md
  2. Global Grok ~/.grok/memory/MEMORY.md (/remember) ≠ CC project memory; sync uses a project subfolder
  3. After install, restart the Grok session from the workspace root

License

MIT — see LICENSE.

// faq

What is cc-to-grok-bridge?

Bridge Claude Code → Grok Build: shared rules/skills, hook adapter hard-gates, optional memory mirror. It is open-source on GitHub.

Is cc-to-grok-bridge free to use?

cc-to-grok-bridge is open-source under the MIT license, so it is free to use.

What category does cc-to-grok-bridge belong to?

cc-to-grok-bridge is listed under automation in the Claudeers registry of Claude-compatible tools.

2 views
10 stars
unclaimed
updated about 1 month ago

// embed badge

cc-to-grok-bridge on Claudeers
[![Claudeers](https://claudeers.com/api/badge/cc-to-grok-bridge.svg)](https://claudeers.com/cc-to-grok-bridge)

// retro hit counter

cc-to-grok-bridge hit counter
[![Hits](https://claudeers.com/api/counter/cc-to-grok-bridge.svg)](https://claudeers.com/cc-to-grok-bridge)

// reviews

// guestbook

0/500

// related in Automation & Workflows

🔓

The agent that grows with you

// automationNousResearch/Python230,654MIT[ claude ]
🔓

The API to search, scrape, and interact with the web at scale. 🔥

// automationfirecrawl/TypeScript167,815AGPL-3.0[ claude ]
🔓

🌐 Make websites accessible for AI agents. Automate tasks online with ease.

// automationbrowser-use/Python110,149MIT[ claude ]
🔓

An open-source long-horizon SuperAgent harness that researches, codes, and creates. With the help of sandboxes, memories, tools, skill, subagents and message…

// automationbytedance/Python80,016MIT[ claude ]
→ see how cc-to-grok-bridge connects across the ecosystem