code-audit

Audit R or Python research scripts with a two-phase read-only workflow.

148|30|Updated Mar 26, 2026
One-click install
npx skills add https://github.com/aspi6246/Claude-Code-Skills-for-Academics --skill code-audit-aspi6246
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: code-audit
Source: https://github.com/aspi6246/Claude-Code-Skills-for-Academics/tree/main/code-audit
Command: npx skills add https://github.com/aspi6246/Claude-Code-Skills-for-Academics --skill code-audit-aspi6246

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

It prevents wrong conclusions from buggy or unsafe research pipelines by enforcing a structured, read-only review before any execution—especially when the code touches licensed or sensitive datasets.

Core Features & Use Cases

  • Two-phase audit workflow: Phase 1 is strictly static (no execution), and Phase 2 runs only after explicit user approval.
  • Evidence-focused quality checks: Covers data integrity, econometric validity (clustering, fixed effects, DiD/IV pitfalls), reproducibility, and code quality.
  • Severity-based, actionable output: Ends with ordered recommendations that reference specific lines, helping you fix issues systematically.

Quick Start

Ask the AI to audit your R or Python research script in read-only mode first, then tell it to run only after you approve Phase 2.

Frequently Asked Questions about code-audit

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I audit research code safely before running scripts on licensed datasets?

You can audit research code safely by running a strictly read-only static analysis on your R or Python scripts before any execution. This two-phase workflow prevents data corruption by requiring explicit user approval before running code that touches licensed datasets.

What econometric issues does a static code audit check for in causal inference pipelines?

A static code audit checks causal inference pipelines for econometric validity issues like clustering errors, fixed effects misconfigurations, and difference-in-differences or instrumental variable pitfalls. It also verifies data integrity and reproducibility to ensure your results are reliable.

Can I review R and Python panel data scripts without executing the code?

Yes, you can review R and Python panel data scripts without executing the code. The first phase of the audit workflow performs a strictly static analysis to identify bugs and data integrity issues in read-only mode before any commands are run.

How do I get actionable recommendations from an empirical finance code review?

You get actionable recommendations from an empirical finance code review by generating a severity-based output. The audit provides ordered recommendations that reference specific code lines, helping you systematically fix data integrity and econometric validity issues.

Does the two-phase code audit workflow support scripts handling WRDS or CRSP data?

Yes, the two-phase code audit workflow supports scripts handling WRDS, CRSP, WellDatabase, and PLIDA data. It is specifically designed to validate empirical research pipelines that process licensed or sensitive panel datasets safely.

When should I use a read-only code audit instead of running my empirical script directly?

You should use a read-only code audit when your empirical script handles licensed or sensitive datasets. Running a static analysis first prevents wrong conclusions from buggy or unsafe research pipelines by enforcing a structured validation check before execution.