An end-to-end platform designed to automatically detect, analyze, and resolve software incidents. By combining GitHub webhooks, AI-driven reasoning, and Docker-based sandboxed execution, the system completes the full loop from issue creation to Pull Request submission.
┌───────────────────────────────┐
│ GitHub │
│ Issues / PR / Webhooks │
└───────────────┬───────────────┘
│
│ webhook
▼
┌────────────────────────────────┐
│ Backend Orchestrator │
│ (Node.js + TypeScript) │
│--------------------------------│
│ • GitHub webhook listener │
│ • Incident creation │
│ • Redis task publisher │
│ • MongoDB storage │
│ • Dashboard REST API │
│ • Timeline updates │
└───────────────┬────────────────┘
│
│ task push
▼
┌───────────────────┐
│ Redis │
│ Task Queue │
└─────────┬─────────┘
│
│ queue pop
▼
┌────────────────────────────────┐
│ Agent Worker │
│ (Python) │
│--------------------------------│
│ • Queue listener │
│ • Repository manager │
│ • AI agent runner │
│ • Fix generator │
│ • Test runner │
│ • GitHub PR creator │
│ • Status updater │
└───────────────┬────────────────┘
│
│ git push / PR
▼
┌───────────────┐
│ GitHub │
│ Pull Request │
└───────────────┘
┌──────────────────────────────┐
│ Dashboard UI │
│ (React + TypeScript) │
│------------------------------│
│ • Incident list │
│ • Incident details │
│ • Agent timeline │
│ • Status indicators │
│ • PR link viewer │
└──────────────┬───────────────┘
│
│ REST API
▼
Backend Orchestrator
| Component | URL |
|---|---|
| Dashboard UI | swe-agent-pkhe.vercel.app |
| Backend API | swe-agent-1.onrender.com |
| Dummy App (Frontend) | swe-agent.vercel.app |
| Dummy App (Backend) | swe-agent-pn7n.onrender.com |
The core worker implements a Reason + Act (ReAct) pattern. Much like industry leaders (Devin, Cursor, OpenDevin), our agent operates in a continuous loop:
- Planning: LLM analyzes the current state and incident context.
- Tool Selection: The agent decides which tool to call (e.g.,
search_code,read_file). - Execution: The system executes the tool in the repository context.
- Observation: The results (file content, search results, or test errors) are fed back into the LLM.
- Termination: The loop breaks when tests pass, a max step count is reached, or the LLM confirms the fix.
while not task_completed:
# 1. Reason
response = llm(context + history)
# 2. Act
if response.tool == "list_files":
result = list_files(response.path)
elif response.tool == "read_file":
result = read_file(response.path)
elif response.tool == "apply_patch":
result = apply_fix(repo_path, response.patch)
# 3. Observe & Update
history.append(result)- Issue Created: A GitHub issue is labeled
assign to agent. - Webhook Trigger: Backend receives the event and creates an Incident in MongoDB.
- Queueing: A task is pushed to Redis.
- Worker Pickup: The Python worker pops the task and clones the target repo.
- Investigation: Agent analyzes the stack trace and codebase.
- Patching: A fix is generated and applied using precision string matching.
- Sandboxed Testing: The fix is verified using
pytestornpm testinside a Docker container. - PR Submission: If tests pass, a new branch is pushed and a GitHub Pull Request is created.
- Completion: The incident status is updated to
completedin the dashboard.
root
│
├── backend # Node.js + TypeScript Orchestrator
├── worker # Python Agent Worker (LLM + Tools)
├── dashboard # React + Vite Monitoring UI
├── dummy-app # Buggy E-commerce site for testing
├── docker-compose.yml
└── README.md
-
Environment Setup:
- Build a
.envinworker/withGITHUB_TOKENandGEMINI_API_KEY. - Build a
.envinbackend/withMONGO_URLandREDIS_URL.
- Build a
-
Launch with Docker:
docker-compose up --build
-
Monitor: Visit the Dashboard to watch the agent in real-time.