Micro AI Tool

AI Prompt Refiner

This project turns rough prompts into cleaner, stronger prompt variants using the OpenAI Responses API. It is intentionally lightweight and does not require a database.

What It Does

Setup

  1. Open functions/config.local.php.
  2. Add your OpenAI API key to openai_api_key.
  3. Keep or change the default model in openai_model. The project starts with gpt-5-mini.
  4. Optional: add adsense_client and adsense_sidebar_slot to activate the right sidebar ad area.
  5. Optional: instead of the local config file, you can provide OPENAI_API_KEY from the server environment.
  6. Load /AiPromptRefiner/ in your browser through MAMP.

How To Use

  1. Paste your original prompt into the main textarea.
  2. Choose the refinement mode that matches your goal.
  3. Optionally add tone, use case, goal, and extra context.
  4. Click Refine Prompt.
  5. Review the generated output in the popup modal.
  6. Copy the version you want, or reopen it with the View Refined Output button.

Folder Structure

Security Notes

Troubleshooting