AD SPACE AVAILABLE · BRAND PARTNERS WELCOME

How to Use Pieces to Generate Commit Messages and Pull Request Descriptions from Recent Changes

Morgan E. McVickar · 365Finds Editorial
Indexed 88,650 Wiki articles

Put 365 Wiki to work with your AI

Copy the prompt below, paste it into the AI you already use, then ask your question.

Download full Skill

Try it with the prompt first. If you use 365 Wiki often, install the full 365Wiki Skill so you do not have to paste it again. No regular AI? Gemini or Microsoft Copilot on the web will work.

365Wiki Skill

Most AI commit generators suffer from tunnel vision. They ingest a raw git diff, notice that three lines changed in an authentication middleware, and hallucinate a generic message like fix: update auth logic. They do not know that you spent the preceding forty minutes reading an OAuth2 token revocation spec in your browser, testing invalid refresh tokens in your terminal, and reverting an earlier refactor.

Pieces approaches this problem differently. Instead of relying solely on isolated text diffs, Pieces connects your code changes to your broader development activity through its Workstream Pattern Engine and Live Context. At 365Finds, we look for tools that eliminate cognitive friction without introducing sloppy automation. Pieces provides two distinct mechanisms to handle version control documentation: a direct terminal workflow via the Pieces CLI (pieces commit) for fast atomic commits, and a context-aware Copilot workflow that synthesizes multi-hour workstreams into detailed Pull Request descriptions.

Here is how to set up, operate, and evaluate both workflows.


The Two Paths: CLI Automation vs. Workstream Synthesis

DimensionPieces CLI (pieces commit)Pieces Copilot (Live Context / Workstream)
Primary Use CaseRapid atomic git commit messagesComprehensive Pull Request summaries and release notes
Input SourceStaged git diff (git add)Temporal workstream data; open IDE files; browser research; terminal logs
InterfaceTerminal / shellPieces Desktop; VS Code / JetBrains extensions; MCP clients
Model HostingLocal on-device models or cloud LLMsLocal on-device (Mistral, Llama, Phi) or cloud (Claude 3.5 Sonnet, GPT-4o)
Human VerificationPrompt approval before commit (unless -p passed)Conversational review and markdown editing

Method 1: Generating Commit Messages via Pieces CLI

When you are deep in a development flow, writing Conventional Commits for every small increment breaks focus. The Pieces CLI hooks directly into your Git staging environment to draft and apply commit messages automatically.

Step 1: Ensure Prerequisites Are Running

Pieces CLI relies on Pieces OS, the local core engine that handles background processing and model inference.

  1. Download and install Pieces OS from the official portal. Keep it running in the background.
  2. Install the Pieces CLI:
    • macOS (Homebrew): brew install pieces-cli
    • Windows / Linux (pip): pip install pieces-cli
  3. Verify your setup:
    pieces version
    
    Ensure both the CLI and Pieces OS show active versions.

Step 2: Stage Your Changes

Pieces analyzes your staged index, not unstaged working tree edits. Navigate to your repository and stage only the logical unit of work you want to commit:

git add src/auth/token_validator.py src/tests/test_token_validator.py

Step 3: Run the Commit Command

Execute the dedicated commit command:

pieces commit

Pieces CLI inspects the staged diff, selects your configured model (running locally through Pieces OS or in the cloud), and presents a generated commit message adhering to standard conventions (such as feat:, fix:, or refactor:).

You will see the generated message displayed in your terminal. You can accept it to complete the commit, edit it, or abort.

[!WARNING] Pieces CLI supports a -p / --push flag (pieces commit -p) that commits and immediately pushes to your remote branch. 365Finds strongly advises against using automatic push flags with AI-generated messages. Commit history is permanent; always review the generated summary line and scope before pushing to shared branches.


Method 2: Generating Deep PR Descriptions Using Live Context

Pull requests demand far more context than individual commits. A reviewer needs to understand the problem motivation, architecture decisions, altered logic, and exact testing steps. This is where Pieces stands out from generic diff bots.

Pieces Copilot leverages the Workstream Pattern Engine (WPE). By monitoring your active applications (your IDE, terminal sessions, browser documentation tabs), it retains temporal grounding: it knows what you did and why you did it over the past several hours.

Step 1: Configure Live Context in Pieces OS

  1. Open the Pieces Desktop application or your Pieces IDE extension (VS Code, JetBrains, or Visual Studio).
  2. Ensure Live Context / Workstream Activity is active in Pieces OS settings.
  3. On macOS, verify that system permissions for screen and accessibility indexing are enabled in System Settings > Privacy & Security; Pieces OS uses these permissions locally to correlate active window contexts.

Step 2: Set the Context Boundary in Pieces Copilot

Open the Pieces Copilot panel within your IDE or Desktop client:

  1. In the context selector, select your active repository or working folder.
  2. Set the temporal window for Live Context. If you spent the afternoon building a feature branch, anchor the context to Today or Past 4 Hours.
  3. Select your model backend:
    • For sensitive, proprietary, or air-gapped codebases, select an on-device model (e.g., Llama 3 or Mistral running offline via Pieces OS).
    • For complex multi-file architectural overviews where literary quality and structured formatting matter, select Claude 3.5 Sonnet or GPT-4o.

Step 3: Run the PR Generation Prompt

Paste a structured directive into Pieces Copilot:

Act as the lead author of this pull request. Review my recent workstream context, modified files, and terminal runs on this branch. 

Generate a comprehensive Pull Request description in GitHub-flavored Markdown using the following structure:
1. ## Overview & Problem Statement (Explain the problem solved and the original trigger)
2. ## Key Changes (Bullet points grouped by component or file, explaining 'why' not just 'what')
3. ## Architectural & Breaking Decisions (Any altered contracts, API changes, or schema updates)
4. ## Verification & Testing (Commands run in terminal, unit tests added, and edge cases verified)

Because Pieces tracks your recent browser lookups and shell commands, the generated description will often reference the exact documentation you consulted and the tests you executed—details that never appear inside a git patch file.


Alternative: Integrating Pieces Memory into Cursor or GitHub Copilot via MCP

If you already use GitHub Copilot in VS Code or an AI-native editor like Cursor, you do not have to switch chat interfaces. Pieces provides a Model Context Protocol (MCP) server.

By registering the Pieces MCP endpoint in your editor configuration:


What 365Finds Values—and What We Question

At 365Finds, we test developer tooling against everyday friction. Here is our assessment of Pieces for version control summaries:

What Convinced Us

Where Friction Remains

Pieces eliminates the chore of writing commit messages and PR overviews, provided you choose the right interface for the task: use pieces commit in the terminal for short increments, and engage Pieces Copilot with Live Context when your reviewers deserve the complete story.


References