selfhost.directory

The index of self-hostable projects — ranked, categorized and served with live updates.
Own your data and stop giving it to big tech.

Patchwork logo

Self-host Patchwork

v0.0.124

CLI agent for PR reviews, bug fixes, security patches

BetaOpen SourceAGPL-3.0
Updated2 months ago
LanguagePython
Setup difficultyModerate
Stars
1 580
Install with pip

What is Patchwork?

Patchwork is an agentic AI framework for automating repetitive development tasks. It provides a CLI agent that runs patchflows — predefined or custom automations built from reusable steps and prompt templates — to handle PR reviews, vulnerability fixes, dependency upgrades, docstring generation, README creation, and issue resolution. Users bring their own LLM keys (OpenAI, Google, Groq, Hugging Face, or local models) and GitHub tokens. Patchwork installs via pip with optional dependency groups for security scanning (semgrep, depscan) and RAG (chromadb). It runs locally, in IDEs, or in CI/CD pipelines. The core is AGPL-3.0 licensed; a hosted SaaS version exists at app.patched.codes. No Docker image or server component is provided; it is a Python CLI tool.

Should you self-host Patchwork?

Patchwork scores 51/100 on selfhost.directory (how scoring works) and ranks #72 of 166 in Developer Tools. It has 1 580 GitHub stars.

There was no stable release in the past 12 months, so check the repository's recent activity before you rely on it.

Setup is moderate: expect some configuration beyond a single command. It is AGPL-3.0-licensed and written mostly in Python.

Its closest alternative on selfhost.directory is openhands (87/100, 92 068 stars). It scores higher overall, so compare the two before you pick. See Patchwork vs openhands side by side.

Features

  • Automated vulnerability fixingRequires optional 'security' dependency group
  • CI/CD pipeline integration
  • Custom patchflow creation
  • Dependency upgrade automationRequires optional 'security' dependency group
  • Docstring generation
  • Issue resolution automationRequires optional 'rag' dependency group (chromadb)
  • Local LLM Support
  • PR Review automation
  • README generation

Patchwork README

How to install Patchwork

Install Patchwork with pip

pip install 'patchwork-cli[all]' --upgrade

Optional dependency groups: security (semgrep, depscan), rag (chromadb), notifications (slack), all

How to configure Patchwork

  • client_base_urlBase URL for OpenAI-compatible LLM endpoint (e.g., Groq, Hugging Face, local llama.cpp/ollama/vllm/tgi)

    Base URL for OpenAI-compatible LLM endpoint (e.g., Groq, Hugging Face, local llama.cpp/ollama/vllm/tgi)

  • configPath to patchwork-configs directory or config.yml file

    Path to patchwork-configs directory or config.yml file

  • github_api_keyGitHub personal access token for repository operations

    GitHub personal access token for repository operations

  • google_api_keyAPI key for Google Gemini models

    API key for Google Gemini models

  • modelModel name to use for LLM calls

    Model name to use for LLM calls

  • openai_api_keyAPI key for OpenAI-compatible LLM endpoints

    API key for OpenAI-compatible LLM endpoints

  • patched_api_keyAPI key for Patched managed service (app.patched.codes)

    API key for Patched managed service (app.patched.codes)

  • prompt_template_filePath to custom prompt template file

    Path to custom prompt template file

Patchwork releases & version history

More in CLI Tools

Rate this project

Click to rate — no account needed.

0 comments

Posting as guest
Loading comments…