← Back to Skills Marketplace
jpengcheng523-netizen

Agent Code Debugger

by jpengcheng523-netizen · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ⚠ suspicious
141
Downloads
0
Stars
0
Active Installs
1
Versions
Install in OpenClaw
/install agent-code-debugger
Description
Provides debugging assistance for AI-generated code with pattern detection, common issue identification, and fix suggestions across multiple programming lang...
README (SKILL.md)

Agent Code Debugger

Debugging assistance for AI-generated code with multi-language support.

When to Use

  • Debugging AI-generated code
  • Analyzing code for common AI generation issues
  • Getting Visual Studio debugging guidance
  • Detecting security vulnerabilities in generated code
  • Quick fixes for common code issues

Usage

const debugger = require('./skills/agent-code-debugger');

// Analyze code for issues
const analysis = debugger.analyze(code, { language: 'csharp' });
console.log(analysis.summary);

// Get fix suggestions
const fixes = debugger.suggestFixes(analysis.issues);

// Get Visual Studio guidance
const guidance = debugger.getVisualStudioGuidance('csharp');

// Generate debug configuration
const config = debugger.generateDebugConfig('csharp');

// Quick fix common issues
const fixed = debugger.quickFix(code, 'console_writeline_leftover');

API

analyze(code, options?)

Analyze code for issues.

const analysis = analyze(csharpCode, { language: 'csharp' });
// {
//   language: 'csharp',
//   totalIssues: 5,
//   criticalCount: 0,
//   highCount: 2,
//   mediumCount: 2,
//   lowCount: 1,
//   issues: [...],
//   summary: 'Found 5 issue(s): 2 high, 2 medium, 1 low'
// }

suggestFixes(issues, options?)

Generate fix suggestions for issues.

const fixes = suggestFixes(analysis.issues, { language: 'csharp' });
// [{ type: 'async_void', fixSuggestion: '...', ... }]

getVisualStudioGuidance(language?)

Get Visual Studio debugging guidance.

const guidance = getVisualStudioGuidance('csharp');
// {
//   breakpoints: '...',
//   watchWindow: '...',
//   tips: [...]
// }

generateDebugConfig(language, options?)

Generate debug configuration for VS Code / Visual Studio.

const config = generateDebugConfig('csharp');
// { visualStudio: {...}, vscode: {...} }

detectAIPatterns(code)

Detect common AI-generated code characteristics.

const patterns = detectAIPatterns(code);
// [{ type: 'todo_comments', description: '...', suggestion: '...' }]

quickFix(code, issueType)

Apply quick fix for common issues.

const fixed = quickFix(code, 'console_writeline_leftover');
// { original: '...', fixed: '...', applied: true }

generateReport(analysis)

Generate a markdown debugging report.

const report = generateReport(analysis);
// '# Code Analysis Report\
...'

Supported Languages

  • C# / .NET Core - Full support with Visual Studio guidance
  • TypeScript - Type safety and async patterns
  • JavaScript - Promise and async/await patterns
  • Python - Exception handling and best practices
  • Java - Exception handling and threading

Common Issues Detected

C# / .NET Core

Issue Severity Description
async_void High async void should only be used for event handlers
task_result_blocking High .Result blocks thread, potential deadlock
task_wait_blocking High .Wait() blocks thread
empty_catch High Empty catch swallows exceptions
console_writeline_leftover Low Debug Console.WriteLine left in code
thread_sleep_blocking Medium Thread.Sleep blocks thread

JavaScript / TypeScript

Issue Severity Description
promise_without_catch High Promise chain without .catch()
async_without_try_catch Medium Async function without error handling
console_log_leftover Low Debug console.log left in code
explicit_any_type Medium Explicit use of any type (TS)
ts_ignore_comment High @ts-ignore suppresses errors (TS)

Python

Issue Severity Description
bare_except High Bare except catches all exceptions
wildcard_import Medium Wildcard import pollutes namespace
print_statement_leftover Low Debug print left in code

Visual Studio Debugging Tips

Breakpoints

  • F9 - Toggle breakpoint
  • F5 - Start debugging
  • F10 - Step over
  • F11 - Step into
  • Shift+F11 - Step out

Debug Windows

  • Watch - Monitor variables
  • Immediate - Evaluate expressions
  • Call Stack - Trace execution
  • Locals - View local variables
  • Autos - View relevant variables

Advanced Features

  • Conditional breakpoints - Right-click breakpoint > Conditions
  • Hit count - Break after N hits
  • Exception settings - Break on specific exceptions
  • Edit and Continue - Modify code while debugging

Example: Debugging AI-Generated C# Code

const debugger = require('./skills/agent-code-debugger');

const aiGeneratedCode = `
public async void ProcessData() {
    var result = GetDataAsync().Result;
    Console.WriteLine($"Debug: {result}");
    try {
        // Process result
    } catch {
        // Handle error
    }
}
`;

// Analyze
const analysis = debugger.analyze(aiGeneratedCode, { language: 'csharp' });
console.log(analysis.summary);
// Found 4 issue(s): 3 high, 1 low

// Get fixes
const fixes = debugger.suggestFixes(analysis.issues);
for (const fix of fixes) {
  console.log(`Line ${fix.line}: ${fix.type}`);
  console.log(`Fix: ${fix.fixSuggestion}`);
}

// Quick fix
const cleaned = debugger.quickFix(aiGeneratedCode, 'console_writeline_leftover');

// Get VS guidance
const guidance = debugger.getVisualStudioGuidance('csharp');
console.log('Tips:', guidance.tips);

Example: Generating Debug Configuration

const debugger = require('./skills/agent-code-debugger');

// For C# / .NET Core
const csharpConfig = debugger.generateDebugConfig('csharp');
console.log(JSON.stringify(csharpConfig.vscode, null, 2));

// For TypeScript
const tsConfig = debugger.generateDebugConfig('typescript');
console.log(JSON.stringify(tsConfig.vscode, null, 2));

Notes

  • Pattern detection based on common AI-generated code issues
  • Security vulnerability scanning included
  • Multi-language support with language-specific patterns
  • Visual Studio and VS Code integration guidance
  • Quick fixes available for common cleanup tasks
  • Reports generated in markdown format
Usage Guidance
This skill appears to be what it claims: a local pattern-based code analyzer and fixer. Before installing, review index.js yourself to ensure no hidden network calls or eval/child_process execution were added (the provided source appears to only use regex matching). Because it will analyze code you provide, avoid sending sensitive secrets inside code strings you analyze. If you plan to run this in a high-security environment, run it in a sandbox or node environment with restricted network/file permissions and verify the module's exports and behavior on a few benign examples first.
Capability Analysis
Type: OpenClaw Skill Name: agent-code-debugger Version: 1.0.0 The 'agent-code-debugger' skill is a static analysis tool designed to identify common coding errors and security vulnerabilities in AI-generated code across multiple languages. The implementation in index.js uses regular expressions to detect patterns like 'eval()', SQL injection risks, and language-specific anti-patterns (e.g., 'async void' in C#) without executing the analyzed code or performing any network/file system operations. No evidence of malicious intent, data exfiltration, or prompt injection was found.
Capability Assessment
Purpose & Capability
The name/description describe a code-debugging assistant and the included SKILL.md plus index.js implement regex-based analysis, fix suggestion, and IDE guidance for the stated languages. Required resources (none) match the described functionality.
Instruction Scope
SKILL.md instructs the agent to call local API functions (analyze, suggestFixes, quickFix, etc.) on code strings. It does not direct the agent to read arbitrary system files, access environment variables, or send data to external endpoints.
Install Mechanism
No install specification is present (instruction-only/packaged code). The repository contains a local index.js and package.json; there are no downloads, extracted archives, or external install steps that would pull remote code at install time.
Credentials
The skill declares no required environment variables, credentials, or config paths. The implementation operates on code strings and pattern matching and does not read process.env or request secrets.
Persistence & Privilege
The skill is not forced-always (always:false) and does not request persistent system-wide privileges. There are no signs it modifies other skills or global agent configuration.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install agent-code-debugger
  3. After installation, invoke the skill by name or use /agent-code-debugger
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.0
Initial release of agent-code-debugger — a multi-language code debugging assistant: - Detects and analyzes common AI-generated code issues in C#, .NET Core, TypeScript, JavaScript, Python, and Java. - Provides language-specific issue detection, severities, and guided fixes. - Offers Visual Studio debugging guidance and quick reference tips. - Supports quick fixes, AI pattern detection, and markdown report generation. - Generates debug configurations for Visual Studio and VS Code. - Includes security vulnerability scanning as part of the analysis.
Metadata
Slug agent-code-debugger
Version 1.0.0
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 1
Frequently Asked Questions

What is Agent Code Debugger?

Provides debugging assistance for AI-generated code with pattern detection, common issue identification, and fix suggestions across multiple programming lang... It is an AI Agent Skill for Claude Code / OpenClaw, with 141 downloads so far.

How do I install Agent Code Debugger?

Run "/install agent-code-debugger" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Agent Code Debugger free?

Yes, Agent Code Debugger is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does Agent Code Debugger support?

Agent Code Debugger is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Agent Code Debugger?

It is built and maintained by jpengcheng523-netizen (@jpengcheng523-netizen); the current version is v1.0.0.

💬 Comments