Inspiration

Debugging is one of the most time-consuming parts of software development. Developers often spend hours reproducing bugs, tracing failures, investigating root causes, and testing possible fixes. AI can suggest code changes quickly, but a suggested fix is not necessarily a correct fix.

We built RepoDoctor to bridge this gap: an AI-assisted debugging agent that focuses not only on proposing a solution, but also on testing and verifying it before claiming success.

What it does

RepoDoctor is an AI-powered debugging assistant designed to investigate software test failures and help developers find reliable fixes.

  • Reproduces failing tests to establish a baseline.
  • Inspects repository files and test output to investigate potential root causes.
  • Generates minimal code patches for review.
  • Requires human approval before proceeding with a proposed change.
  • Applies approved patches and reruns tests to verify the result.
  • Provides a web interface and API for managing debugging sessions and tracking progress.
  • Uses a Docker-based sandbox to isolate repository code execution.
  • Includes safeguards for local API binding and ZIP archive path conflicts.

RepoDoctor aims to make AI-assisted debugging more transparent, controlled, and test-driven.

How we built it

We built RepoDoctor using Python for the core debugging workflow, FastAPI and Uvicorn for the backend API, React and Vite for the web interface, and SQLite for local persistence.

The debugging workflow uses an orchestrated sequence of steps and controlled tools to inspect code, execute tests, prepare patches, manage approval, and verify outcomes. The AI integration supports Amazon Bedrock through the Strands Agents SDK, while demo and test engines allow development and testing without requiring a live AI request.

Docker provides a sandbox for executing repository commands and tests. Pytest is used to validate application behavior, including API settings, ZIP upload handling, and other project components.

Challenges we ran into

One of our main challenges was ensuring that an AI-generated patch would not automatically be treated as a successful fix. We designed the workflow around explicit human approval and test-based verification.

Other challenges included handling unreliable or incomplete test output, maintaining predictable debugging states, safely extracting uploaded ZIP archives, preventing conflicting file paths, and ensuring that the local API is not accidentally exposed on a network without authentication.

We also needed to test the project without depending on live AI services for every development cycle.

Accomplishments that we're proud of

  • Built an end-to-end debugging workflow that connects failure investigation, patch proposals, human approval, and test verification.
  • Added a Docker-based sandbox for repository test execution.
  • Implemented API safeguards that reject non-loopback bind addresses through the standard module entry point.
  • Improved ZIP extraction by validating destination paths and rejecting duplicate or conflicting paths.
  • Achieved 687 passing tests with 2 skipped in the recorded full test-suite run.
  • Verified the latest targeted test runs: 38 ZIP upload tests passed and 11 API settings tests passed.
  • Published the latest changes to GitHub in commit 63fee82.

These results demonstrate progress toward a safer and more reliable AI-assisted debugging workflow.

What we learned

We learned that building a useful AI engineering tool requires more than connecting a language model to a codebase. Reliable tools need controlled execution, clear state transitions, human oversight, defensive input handling, and independent verification.

We also learned the importance of automated regression tests, reproducible development workflows, and honest reporting: a patch should only be described as verified when the relevant checks actually support that conclusion.

What's next for RepoDoctor

Our next goals are to:

  • Improve debugging accuracy and root-cause analysis.
  • Expand support for additional programming languages and test frameworks.
  • Improve handling of complex fixes involving multiple files.
  • Add optional GitHub issue and pull-request integration.
  • Improve session history, debugging reports, and developer experience.
  • Strengthen sandbox isolation and resource controls.
  • Expand end-to-end testing, including opt-in integration tests with real AI services.

Our long-term vision is to make RepoDoctor a trustworthy debugging partner that helps developers move from a failing test to a reviewed, evidence-backed fix with less manual effort.

Share this project:

Updates

Submission history