![]() The key combo is specified as command E - see Specifying key combinations below. Snippets can be used for all types of PopClip extension, except Shell Script extensions. key combo - the main action, which is to press a key combination. Usually you can just copy one of the examples and edit it. Here I have put copy which makes PopClip copy the selection to the clipboard, where TextExpander will find it. prompt_new_command Īfter you are done, run npm run dev to push the update locally to your Raycast. The before field specifies an action PopClip should perform before the main action. You could then read this prompt from the preferences in the new_command.ts file: const prompt = getPreferenceValues ( ). For example, if you want to add a new command called New Command (the corresponding file is new_command.ts), add the following entry to the commands array: , Declare your new command in the package.json file. It's safe to kill the npm run dev process and close the terminal window.ĭepending on the desired behavior of the new command, duplicate the execute.ts or rewrite.ts files. This set of commands should install the extension to Raycast. First, you will need to install the extension from source: cd ~/Developer # or wherever you want to store the extension git clone For example, you can add more commands or change the default model. If you are comfortable with modifying the source code, you can also add more commands to your liking. You will need to provide your OpenAI API key.Ĭustomize your prompts and keyboard shortcuts in the settings. Follow the wizard to finish the setup.Search for ChatGPT Quick Actions using the "Store" command in Raycast.Additionally, I have included some additional features, such as a token counter and a cost estimator. You don't have to remember all these shortcuts, as Raycast also conveniently provide these options in the UI. If the default gpt-3.5-turbo is not powerful enough for you, you may use cmd + shift + R to regenerate the result with gpt-4. If you are not happy with the output, you can regenerate the results with cmd + R. The output from ChatGPT will stream to the Raycast UI, which allows you to copy the output to your clipboard using the keyboard shortcut enter or paste it directly into your foreground application using cmd + enter. Here is the Summarize shortcut working in the wild: Sorry, your browser doesn't support embedded videos. For Summarize, Refine, and Rewrite, you may customize the prompt in the Extension settings. You can assign a dedicated keyboard shortcut to each of these commands. Rewrite: Rewrite the the selected text using an academic tone.Refine: Refine the writing of the selected text.Summarize: summarize and explain the selected text for you.Execute: Similar to preview, but directly pastes the result into your foreground application.Preview: use your selected text (e.g., "Write me an email about blah blah") as the input, then stream the output to the Raycast UI.Several commands available in the Raycast Extension. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |