vitor Posted June 28 Author Posted June 28 1 hour ago, sorgel said: So, basically I'm not sure why we need to duplicate the whole workflow for every new command. Looks like we can stick with editing the original workflow. You don’t need to duplicate the whole workflow, nor should you edit the original. You should instead make another small workflow with just what you need calling this one. This is explained in the FAQ, under How can I reuse pre-made prompts?
sorgel Posted June 28 Posted June 28 4 minutes ago, vitor said: You don’t need to duplicate the whole workflow, nor should you edit the original. You should instead make another small workflow with just what you need calling this one. This is explained in the FAQ, under How can I reuse pre-made prompts? Ah, I see now, sorry, I've misunderstood the original instruction.
sorgel Posted July 2 Posted July 2 On 6/20/2024 at 12:11 PM, lone said: I made a test example where I try to scroll, and it constantly rolls down This behavior is hard-coded in the extension. I'm not sure why @Vero supposed it could be changed with Automation Tasks update. But we can change it by editing the file chatgpt in the workflow folder. There are several lines behavior: { scroll: 'end' } for different cases. I don't see the documentation for this thing. But at least changing it to behavior: { scroll: 'start' } will stop infinite scrolling. What is interesting now is how to hide the first message from the Text view. Personally, I prefer not to see the full prompt, in my case it can be really long.
vitor Posted July 2 Author Posted July 2 3 minutes ago, sorgel said: I'm not sure why @Vero supposed it could be changed with Automation Tasks update. That was in reply to a different query. 3 minutes ago, sorgel said: I don't see the documentation for this thing. https://www.alfredapp.com/help/workflows/user-interface/text/json/ You can click the (?) in any object to go to its documentation. sorgel 1
sorgel Posted July 2 Posted July 2 (edited) 5 minutes ago, vitor said: You can click the (?) in any object to go to its documentation. Thanks! Yes, I tried '?" but then i had to find a link to the json description on that page, and that's where I've failed. So `auto` could fit this task more than `start`. Edited July 2 by sorgel grammar fix
sorgel Posted July 2 Posted July 2 (edited) 51 minutes ago, sorgel said: What is interesting now is how to hide the first message from the Text view. Personally, I prefer not to see the full prompt, in my case it can be really long So the simplest and a bit dirty way to do it is to use the `replace` in this block if (streamMarker) return JSON.stringify({ rerun: 0.1, variables: { streaming_now: true }, response: '…', behaviour: { response: 'replace' }, }); While it ruins the approach where you try to use this workflow for continuous discussion, it makes workflow more usable for one-time prompts Edited July 2 by sorgel
lone Posted July 3 Posted July 3 23 hours ago, sorgel said: So the simplest and a bit dirty way to do it is to use the `replace` in this block if (streamMarker) return JSON.stringify({ rerun: 0.1, variables: { streaming_now: true }, response: '…', behaviour: { response: 'replace' }, }); While it ruins the approach where you try to use this workflow for continuous discussion, it makes workflow more usable for one-time prompts I tried all possible options, with any replace behavior it scrolls.
DonGama Posted July 6 Posted July 6 Hi, I just installed the ChatGPT / DALL-E workflow, but I am getting an error when trying to prompt ChatGPT. Error below. Prompting DALL-E works well. [21:32:15.199] ChatGPT / DALL-E[Keyword] Processing complete [21:32:15.207] ChatGPT / DALL-E[Keyword] Passing output '' to Arg and Vars [21:32:15.209] ChatGPT / DALL-E[Arg and Vars] Processing complete [21:32:15.210] ChatGPT / DALL-E[Arg and Vars] Passing output '' to Run Script [21:32:15.283] ChatGPT / DALL-E[Run Script] Processing complete [21:32:15.290] ChatGPT / DALL-E[Run Script] Passing output '' to Automation Task [21:32:15.291] ERROR: ChatGPT / DALL-E[Automation Task] Task not found 'com.alfredapp.automation.core/files-and-folders/path.exists' Workflow version: 2024.11 Alfred version: 5.5 [2257] Mac OS version: Sonoma 14.5 I will appreciate help to torubleshoot the problem.
vitor Posted July 6 Author Posted July 6 Welcome @DonGama, You have to install the Automation Tasks. I have moved your post to the correct place. Please avoid separating questions from the main workflow thread.
DonGama Posted July 6 Posted July 6 That fixed it. Thanks a lot for your help. Noted on placing observation. vitor 1
Steve28 Posted July 11 Posted July 11 I feel like I am missing something basic. I would to have text selected in, say, an email I am writing and then hit a keyboard shortcut and be able to use that in a chatgpt session. For example, select text in email program, hit hotkey, type "make this sound more formal" hit return and have alfred replace the text with the response... When I select the AskChatGPT universal action, it sends the text directly to ChatGPT, which I don't find helpful. strajk 1
Chatbot Posted July 12 Posted July 12 Hi, Great work! Is there a way that I can config openai api base in this tool?
vitor Posted July 12 Author Posted July 12 34 minutes ago, Chatbot said: Is there a way that I can config openai api base in this tool? That is covered at the top of FAQ (second post in this thread).
vitor Posted July 12 Author Posted July 12 Welcome @Steev28, I can see the sense in altering the message before sending specifically when using a Universal Action where the text you want to use may not have the proper context. I’m experimenting with it and this version does it. It won’t auto-paste the result, as that’s a bit outside the scope of the workflow but on the result you can ⌥↩ to copy it to the clipboard. This is a first draft and may change or be reverted before release.
ged12345 Posted July 14 Posted July 14 Seeing an issue in the debugger when I try and use this workflow: Code 1: /Users/robdeskoski/Library/Application Support/Alfred/Alfred.alfredpreferences/workflows/user.workflow.8DF3C6CF-EE0A-4AFC-8C1D-2E383942484A/chatgpt: execution error: Error: SyntaxError: JSON Parse error: Expected ']' (-2700) API Key seems fine, typing in as per the examples.
vitor Posted July 14 Author Posted July 14 @ged12345 When reporting issues, please include your exact installed versions of:The Workflow.Alfred.macOS.In addition to:The debugger output. Perform the failing action, click “Copy” on the top right and paste it here.Details on what you did, what happened, and what you expected to happen. A short video of the steps with the debugger open may help to find the problem faster.These requirements are listed in the FAQ (second post on the thread).
vitor Posted July 17 Author Posted July 17 Updated to 2024.12.Allow to further refine question when sending via Universal Action.Remove steps to move from cache to data.Update JSON parsing of chunks.Remove extraneous space. JJJJ 1
sosaveme Posted July 19 Posted July 19 (edited) Is it possible to integrate SOCKS proxy in the workflow? ChatGPT doesn't work in my country and I need to use VPN. But it's a shame to turn on VPN every time when I want to use the workflow. Edited July 19 by sosaveme
vitor Posted July 19 Author Posted July 19 The FAQ (second post in the thread) explains how to configure an HTTP proxy.
vitor Posted July 20 Author Posted July 20 Updated to 2024.13. Replace GPT-3.5 with GPT-4o mini. Stephen_C 1
amirk Posted August 12 Posted August 12 (edited) Hi @vitor Thank you for the great workflow! Everything is functioning well, except I can’t seem to access the Chat History feature. When I hit ⌥⏎, the previous chats aren’t appearing. Workflow: v2024.14 Alfred: 5.5 macOS: 12.7.6 The debugger output: [20:22:58.284] ChatGPT / DALL-E[Hotkey] Processing complete [20:22:58.287] ChatGPT / DALL-E[Hotkey] Passing output '' to Keyword [20:22:58.343] ChatGPT / DALL-E[Keyword] Processing complete [20:22:58.345] ChatGPT / DALL-E[Keyword] Passing output '' to Script Filter [20:22:58.349] ChatGPT / DALL-E[Script Filter] Queuing argument '(null)' [20:22:58.454] ChatGPT / DALL-E[Script Filter] Script with argv '(null)' finished [20:22:58.454] ERROR: ChatGPT / DALL-E[Script Filter] Code 1: /Users/mac/Library/Caches/com.runningwithcrayons.Alfred/Workflow Scripts/84C7C5CE-C9B2-4A1D-95A8-3DC1ADFBAB6C: execution error: Error: TypeError: dirContents(archiveDir) .filter(file => file.endsWith(".json")) .toReversed is not a function. (In 'dirContents(archiveDir) .filter(file => file.endsWith(".json")) .toReversed()', 'dirContents(archiveDir) .filter(file => file.endsWith(".json")) .toReversed' is undefined) (-2700) I’d be really grateful if you could help me figure this out! If you need any additional details, please just let me know. Edited August 12 by amirk
vitor Posted August 12 Author Posted August 12 Welcome @amirk, There’s no Hotkey in the workflow, so whatever you have has been modified. Revert it to its proper state by installing from the Alfred Gallery. There’s something funky going on for sure, since it’s not even looking for histories in the proper folder. If you want to call the workflow with something it doesn’t have, don’t modify it as you’ll lose the modifications when there is an update. Refer to “How can I reuse pre-made prompts?” in the FAQ for the proper methodology. In your case it’s even simpler: just connect a Hotkey Trigger to a Call External Trigger Output set to open continue_chat from this workflow.
amirk Posted August 13 Posted August 13 (edited) @vitor Thank you for the reply! Yes, I've modified the workflow by just adding a hotkey instead of using keyword. Now I have a separate workflow set up to initiate the process. Thanks for the advice! As you have suggested, I deleted the workflow and downloaded it from the gallery. But unfortunately the issue still remains. The debugger output: [11:56:48.089] ChatGPT / DALL-E[Keyword] Processing complete [11:56:48.090] ChatGPT / DALL-E[Keyword] Passing output '' to Script Filter [11:56:48.103] ChatGPT / DALL-E[Script Filter] Queuing argument '(null)' [11:56:48.208] ChatGPT / DALL-E[Script Filter] Script with argv '(null)' finished [11:56:48.209] ERROR: ChatGPT / DALL-E[Script Filter] Code 1: /Users/mac/Library/Caches/com.runningwithcrayons.Alfred/Workflow Scripts/28C4750C-CF7A-4B95-A7D8-9DFC7E8D28BA: execution error: Error: TypeError: dirContents(archiveDir) .filter(file => file.endsWith(".json")) .toReversed is not a function. (In 'dirContents(archiveDir) .filter(file => file.endsWith(".json")) .toReversed()', 'dirContents(archiveDir) .filter(file => file.endsWith(".json")) .toReversed' is undefined) (-2700) Edited August 13 by amirk
vitor Posted August 13 Author Posted August 13 Ah, yeah, I see the issue. It’s because you’re using an older version of macOS which doesn’t support a feature. This version should get you sorted. That link is temporary, so if you’re not going to upgrade macOS anytime soon, keep it so you can revert to it if you need.
amirk Posted August 13 Posted August 13 Awesome! It works now. Thanks so much for the support! Just one more question, can I update the workflow through the Alfred Gallery in the future or do I have to keep using this version?
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now