PromptRefiner 1.1.0

dotnet add package PromptRefiner --version 1.1.0
                    
NuGet\Install-Package PromptRefiner -Version 1.1.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="PromptRefiner" Version="1.1.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="PromptRefiner" Version="1.1.0" />
                    
Directory.Packages.props
<PackageReference Include="PromptRefiner" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add PromptRefiner --version 1.1.0
                    
#r "nuget: PromptRefiner, 1.1.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package PromptRefiner@1.1.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=PromptRefiner&version=1.1.0
                    
Install as a Cake Addin
#tool nuget:?package=PromptRefiner&version=1.1.0
                    
Install as a Cake Tool

Prompt Refiner

A lightweight Windows desktop application (.NET 8, WinForms) that takes a rough prompt, sends it to a large language model via the GitHub Copilot SDK, and returns a polished, comprehensive version. Supports both a graphical interface and a headless CLI.

Prompt Refiner — Main Window

Supported Platforms

Platform Status
Windows 10/11 (x64) ✅ Supported
macOS ❌ Not supported (WinForms)
Linux ❌ Not supported (WinForms)

Prerequisites

Before using Prompt Refiner, ensure you have:

  1. GitHub Copilot CLI — installed and available on PATH.

    # Install via npm
    npm install -g @anthropic-ai/sdk
    # Or via the GitHub CLI extension
    gh extension install github/gh-copilot
    
  2. Active GitHub Copilot subscription — any tier (Free, Individual, Business, Enterprise). The SDK bills against your Copilot premium request quota.

  3. Authentication — sign in once before first use:

    gh auth login
    

    The app auto-discovers credentials from (in order): COPILOT_GITHUB_TOKEN, GH_TOKEN, GITHUB_TOKEN environment variables, or the Copilot CLI's cached login.

  4. Runtime (only if building from source):

    • .NET 8.0 SDK or later.
    • The self-contained release zip requires no runtime installation.

Installation

Download the latest PromptRefiner-win-x64.zip from Releases, extract anywhere, and run PromptRefiner.exe.

No installer is needed — it's a single self-contained executable.

Verify Prerequisites

After extracting, run the built-in prerequisite checker:

PromptRefiner.exe --check-prereqs

This verifies the GitHub Copilot CLI and GitHub CLI are installed and checks for auth tokens.

Usage

GUI Mode

Double-click PromptRefiner.exe (or run it with no arguments):

  1. Type or paste a rough prompt into the input area.
  2. Select a model from the dropdown (default: claude-opus-4.6). The list is fetched live from Copilot on startup.
  3. Click Refine ➜ (or press Ctrl+Enter).
  4. A streaming output window opens showing the refined prompt in real time.
  5. Edit the result if needed, then click 📋 Copy to copy to clipboard.

CLI Mode

Run with arguments to operate headlessly — ideal for scripts and pipelines.

# Refine a prompt directly
PromptRefiner.exe -p "write a python script to sort a list"

# Read prompt from a file
PromptRefiner.exe -f prompt.txt

# Pipe from stdin
echo "help me debug my code" | PromptRefiner.exe

# Use a specific model
PromptRefiner.exe -p "design a REST API" -m gpt-4o

# Save output to a file (also prints to stdout)
PromptRefiner.exe -p "explain recursion" -o refined.txt

# List all available models
PromptRefiner.exe --list-models

# Show help
PromptRefiner.exe --help

CLI flags:

Flag Description
-p, --prompt <text> Prompt text to refine
-f, --file <path> Read prompt from a file
-m, --model <name> Model to use (default: claude-opus-4.6)
-o, --output <path> Write refined prompt to file
--list-models Print available models and exit
--check-prereqs Verify prerequisites and exit
-h, --help Show usage help

Exit codes: 0 = success, 1 = error. Status messages go to stderr; refined output goes to stdout.

Build from Source

git clone https://github.com/PranavPeshwe/prompt-refiner.git
cd prompt-refiner
dotnet build prompter2.sln

Running Tests

# Unit tests only (no network, no auth needed)
.\Run-Tests.ps1 -Filter Unit

# Startup benchmark tests
.\Run-Tests.ps1 -Filter Startup

# Integration tests (requires Copilot auth + subscription)
.\Run-Tests.ps1 -Filter Integration

# All tests
.\Run-Tests.ps1 -Filter All

# Standalone startup measurement (10 iterations with bar graph)
.\Measure-Startup.ps1 -Runs 10

Test Coverage

Category Tests Requires Auth
Unit 10 No
Integration 12 Yes
Startup Benchmark 3 No

Project Structure

├── Program.cs                 # Entry point (GUI/CLI routing)
├── MainForm.cs                # Input window (WinForms)
├── ResultForm.cs              # Streaming output window
├── ErrorDialog.cs             # Copy-able error dialog
├── PromptRefinerService.cs    # Copilot SDK wrapper
├── PromptRefiner.csproj       # Project file
├── Run-Tests.ps1              # Test runner script
├── Measure-Startup.ps1        # Startup benchmark script
├── requirements.md            # Detailed requirements document
└── tests/
    └── PromptRefiner.Tests/
        ├── UnitTests.cs
        ├── IntegrationTests.cs
        └── StartupBenchmarkTests.cs

License

Private repository — not licensed for redistribution.

Product Compatible and additional computed target framework versions.
.NET net8.0-windows7.0 is compatible.  net9.0-windows was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.1.0 206 2/28/2026