ClawKit Logo
ClawKitReliability Toolkit
Back to Registry
Official Verified

Codebuddy Coding

Skill by 13770626440

skill-install — Terminal

Install via CLI (Recommended)

clawhub install openclaw/skills/skills/13770626440/codebuddy-coding
Or

CodeBuddy Coding Skill

版本: 1.0.0 创建时间: 2026-03-31 作者: OpenClaw Team


📋 Skill 概述

CodeBuddy Coding Skill 是一个通用的 AI 编程能力扩展,让任何 OpenClaw agent 都能调用 CodeBuddy CLI 的强大功能。

核心能力

  • AI 编程 - 代码生成、重构、调试、优化
  • 文件操作 - 创建、修改、删除文件
  • 命令执行 - 运行构建、测试、部署命令
  • 进度监控 - 实时报告任务进度和状态
  • 结构化输出 - JSON 格式的可解析输出

适用场景

  • Developer Agent - 编写代码、修复 Bug
  • Architect Agent - 生成项目脚手架
  • Tester Agent - 编写测试用例
  • 任何需要编程能力的 Agent - 通用编程支持

🚀 快速开始

基本用法

// 1. 加载 Skill
const codebuddy = require('./skill');

// 2. 执行编程任务
const result = await codebuddy.execute({
  task: '创建一个用户登录页面',
  context: {
    projectPath: '/path/to/project',
    techStack: 'Vue 3 + TypeScript'
  },
  options: {
    outputFormat: 'json',
    permissionMode: 'bypassPermissions'
  }
});

// 3. 获取结果
console.log(result.status);      // 'success'
console.log(result.filesModified); // ['src/views/Login.vue']
console.log(result.toolCalls);   // [{tool: 'write_to_file', ...}]

监听进度

// 订阅进度事件
codebuddy.onProgress((progress) => {
  console.log(`进度: ${progress.percentage}%`);
  console.log(`当前任务: ${progress.currentTask}`);
  console.log(`已用时间: ${progress.elapsedTime}s`);
});

🔧 配置说明

环境要求

  • CodeBuddy CLI v2.68.0+
  • Node.js v16.0.0+
  • OpenClaw coding-agent skill 框架

Skill 配置

{
  "name": "codebuddy-coding",
  "version": "1.0.0",
  "type": "coding",
  "capabilities": [
    "code-generation",
    "file-operations",
    "command-execution",
    "progress-monitoring"
  ],
  "dependencies": {
    "codebuddy-cli": ">=2.68.0"
  }
}

📚 API 文档

execute(options)

执行编程任务。

参数:

interface ExecuteOptions {
  task: string;           // 任务描述
  context?: {             // 任务上下文
    projectPath?: string; // 项目路径
    techStack?: string;   // 技术栈
    files?: string[];     // 相关文件
  };
  options?: {             // 执行选项
    outputFormat?: 'json' | 'text';  // 输出格式
    permissionMode?: 'default' | 'bypassPermissions'; // 权限模式
    timeout?: number;     // 超时时间(秒)
  };
}

返回:

interface ExecuteResult {
  status: 'success' | 'failed' | 'timeout';
  filesModified: string[];      // 修改的文件列表
  toolCalls: ToolCall[];        // 工具调用记录
  reasoning: string[];          // 推理过程
  duration: number;             // 执行时长(秒)
  error?: string;               // 错误信息
}

onProgress(callback)

订阅进度更新事件。

参数:

type ProgressCallback = (progress: {
  percentage: number;     // 完成百分比
  currentTask: string;    // 当前任务描述
  elapsedTime: number;    // 已用时间(秒)
  estimatedTime?: number; // 预计剩余时间(秒)
  filesModified: string[]; // 已修改文件
  toolCalls: number;      // 已调用工具次数
}) => void;

getStatus()

获取当前任务状态。

返回:

interface TaskStatus {
  state: 'idle' |...

Metadata

Stars4473
Views0
Updated2026-05-01
View Author Profile
AI Skill Finder

Not sure this is the right skill?

Describe what you want to build — we'll match you to the best skill from 16,000+ options.

Find the right skill
Add to Configuration

Paste this into your clawhub.json to enable this plugin.

{
  "plugins": {
    "official-13770626440-codebuddy-coding": {
      "enabled": true,
      "auto_update": true
    }
  }
}
Safety NoteClawKit audits metadata but not runtime behavior. Use with caution.