RL

royal-lobster/code-explainer

开发工具

本页由 AI 翻译,技术细节请以原文为准。 查看原文

105 stars 质量 62 趋势 4MIT

皇家龙虾/代码解释者是从[[T0]引入的特工技能候选人。

概览

皇家龙虾/代码解释者是从[[T0]引入的特工技能候选人。

概述(AI 翻译)

代码解说

✨ 互动代码攻略,配有编辑器高亮和AI语音解说。

一个编码代理技能,可以扫描你的代码库,构建攻略计划,并逐段解释代码——用专用侧边栏高亮VS Code / Cursor中的行,并用自然的本地TTS进行旁白。支持Claude Code、Codex、OpenCode、Kilo Code、Amp等多种语言。

🎬 观看演示  ·  📝 阅读


🚀 特色

  • 🪟 VS 代码侧边栏 — 专用侧边栏面板,包含步进控制、段子导航和实时解释显示
  • 🎯 代码高亮 — 自动打开文件,滚动到代码,并高亮1–8行范围,并附有每个高亮说明
  • 🔊 本地TTS — 由Kokoro-82M(#1排名开源TTS)驱动的自然语音解说,通过 mlx-audio 在 Apple Silicon 本地运行
  • 🎬 三种模式 — 通关(TTS免提)、阅读(终端文本)或播客(单音频文件)
  • 🧠 自适应深度 — 基于你熟悉程度的概述或深度解释

本页由 AI 翻译,技术细节请以原文为准。

README

以下为原文 README 节选,完整内容请查看原文。

Code Explainer

✨ Interactive code walkthroughs with editor highlighting and AI-powered voice narration.

A coding agent skill that scans your codebase, builds a walkthrough plan, and explains code segment-by-segment — highlighting lines in VS Code / Cursor with a dedicated sidebar panel and narrating with natural-sounding local TTS. Works with Claude Code, Codex, OpenCode, Kilo Code, Amp, and more.

🎬 Watch Demo  ·  📝 Read Writeup


🚀 Features

  • 🪟 VS Code Sidebar — Dedicated sidebar panel with walkthrough controls, segment navigation, and live explanation display
  • 🎯 Code Highlighting — Automatically opens files, scrolls to code, and highlights 1–8 line ranges with per-highlight explanations
  • 🔊 Local TTS — Natural-sounding voice narration powered by Kokoro-82M (#1 ranked open-source TTS), running locally on Apple Silicon via mlx-audio
  • 🎬 Three Modes — Walkthrough (hands-free with TTS), Read (text in terminal), or Podcast (single audio file)
  • 🧠 Adaptive Depth — Overview or Deep Dive explanations based on your familiarity
  • 📋 Plan-First — Scout finds files, planner builds narrative order, parallel segment agents generate highlights — outline visible immediately, segments stream in as they finish
  • 💾 Save & Share — Save walkthroughs to .walkthrough.json files, replay later or share with teammates via the repo
  • ⌨️ Keyboard Shortcuts — Full keybinding support for hands-free navigation

📦 Requirements

  • 🍎 macOS (Apple Silicon recommended for GPU-accelerated TTS)
  • 🐍 Python 3.10+
  • 📗 Node.js 18+
  • 🖥️ VS Code or Cursor with CLI enabled (code or cursor command)

🔧 Installation

Just tell your coding agent:

Install the code explainer skill from https://github.com/Royal-lobster/code-explainer

Your agent will clone the repo into the skills directory, run setup.sh, and ask you to reload your editor — all while keeping you in the loop at each step.

Skill-native agents

These agents support the skills//SKILL.md format natively. Clone directly into the skills directory:

Agent Install commands
Claude Code git clone https://github.com/Royal-lobster/code-explainer.git ~/.claude/skills/explainer
Amp git clone https://github.com/Royal-lobster/code-explainer.git ~/.config/agents/skills/explainer
OpenCode git clone https://github.com/Royal-lobster/code-explainer.git ~/.config/opencode/skills/explainer
在 GitHub 查看完整 README

推荐工具

换一个关键词,或者移除筛选条件。

安装

npx skillfish add royal-lobster/code-explainer
新手?先看 mcpskill.org 教程 →