GithubHelp home page GithubHelp logo

pa-0 / chatgpt-autohotkey-utility Goto Github PK

View Code? Open in Web Editor NEW

This project forked from kdalanon/chatgpt-autohotkey-utility

0.0 0.0 0.0 67 KB

An AutoHotkey script that uses ChatGPT API to process text.

License: GNU General Public License v3.0

AutoHotkey 100.00%

chatgpt-autohotkey-utility's Introduction

ChatGPT-AutoHotkey-Utility

⏬ Download here

An AutoHotkey script that uses the ChatGPT API to process selected text.

image

image

How to use

  1. Install AutoHotkey v2. Note that this script will not work on earlier versions of AutoHotkey.
  2. Copy your OpenAI API key here (you may need to create a new secret key‍)
  3. Open ChatGPT AutoHotkey Utility.ahk using your favorite text editor
  4. Paste your OpenAI API key on the API_Key variable

image

  1. Launch ChatGPT AutoHotkey Utility.ahk
  2. Highlight a text that you want to process using ChatGPT API and press the back quote key to bring up the menu

image

(Image from emacs.stackexchange.com)

Customizing menu, prompts, APIs, and hotkey

You can customize prompts and the menu order by doing the following:

Menu

Under Menus and ChatGPT prompts, add a menu by adding this code:

MenuPopup.Add("&8 - Text_To_Appear", Function_To_Execute_When_Selected)

The character next to the "and" sign (&) is the hotkey for that particular menu that, when pressed, activates it.

You can also add a line separator using this code:

MenuPopup.Add()

Prompt

You can add a prompt using this code:

Function_To_Execute_When_Selected(*) {
    ChatGPT_Prompt := "Your prompt here:"
    Status_Message := "Status message that will show while processing the request"
    API_Model := "gpt-4" ; or API_Model := "gpt-3.5-turbo"
    ProcessRequest(ChatGPT_Prompt, Status_Message, API_Model, Retry_Status)
}

APIs

You can edit the API used for each prompt by changing the API_Model under each prompt. Visit this page to explore a selection of available API models.

76IxQa4

Hotkey

You can change the activation hotkey under Hotkey. See here for the list of possible hotkeys.

image

Credits

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.