- Joined
- Jan 12, 2016
- Messages
- 342
- Reaction score
- 1,030
- Points
- 468
- Age
- 38
- Gender
- Male
As probably everyone has heard of AHK for PC users and it's positive effect on mTurk tasks, there has been a glaring information hole for anything useful for Mac turkers as far as scripts and macros programs. But there is a hope for those users who solely use mac, prefer to use only mac or are just turned off by the idea of having to dual boot their machine with Windows just to be able to use AHK while turking.
The solution, Keyboard Maestro. This is a macros program that is available for free download (trial version with full functionality) from the site linked in the previous sentence (duh). In case you're completely new to this and have no idea what "macros" is(are?) here is my laziest definition ripped from Wikipedia.com
"A macro (short for "macroinstruction", from Greek μακρο- 'long') in computer science is a rule or pattern that specifies how a certain input sequence (often a sequence of characters) should be mapped to a replacement output sequence (also often a sequence of characters) according to a defined procedure."
Source: https://en.wikipedia.org/wiki/Macro_(computer_science)
Okay, so what does this mean? To put it simply, it's a way to automate repetitive tasks on your computer. For better reference I'll illustrate an example from the actual program.
This is one of my favorite Macro(instructions) that works on a number of different types of HITs on mTurk. This one is from a specific Kevin Dodds scripts I made on Keyboard Maestro...
So what this macro allows me to do is when I found the phone number in another search window that I want, all I have to do is left-click on the phone number with the "alt" modifier key pressed then the macro will triple click wherever I clicked, copy, move back to the HIT window, tab down to the correct text field and paste the number. This saves about 4-6 seconds per HIT.... so what? So this is just one macro that I have for this HIT, and with each one saving a couple seconds, I can effectively knock off 20-30 seconds from these HITs....
So there is an example and little definition of Keyboard Maestro and Macros and how Mac users can take advantage of it on mTurk.
Here are some helpful links and highlights from the official KM documentation:
The Document
On Triggers and Hotkeys (or any other way you wish to initiate a macro)
Macro Actions
Example Macro Actions
The Keyboard Maestro Forum is also a great resource and place to ask more in depth questions.
A few more tips
Application Specific Macro
Here's something that has become incredibly useful to me and saved a lot of headaches...
When creating a Macro group for a certain HIT you can specify it to only be active in a certain application. For example, I do HITs in Chrome almost exclusively while I use FF to run panda's/Scraper and I use Opera browser for email/forums etc.
So, it can be a huge pain in the ass when you have a Macro assigned to a Hotkey like the letter "f" for example. I don't want to have to turn off the macro every time that I want to type something in the forum or whatever, but if I don't then I may type "f" and set off some crazy Macro that completely fucks up my flow.
Solution:
When creating a new Macro you are presented with this screen (I named this "New Macro")
Now click "Available in all applications" then "Available in the following applications" (note the other ways to specify as well)
Then select whatever app you want the Macro to work in (you can choose multiple apps if you want)
This feature is always available, not just when you are creating a new Macro.
I highly recommend using it
Execute Javascript
This is one brand new (to me) but omg I'm lovin' it, I can't believe it took me this long to discover this feature.
Within any macros you can add the "Execute Javascript" action. There are a couple different options for this and a multitude of ways to specify and achieve exactly what you want... so for simplicities sake I'll show the first one I made.
I wanted a way to grab a url address and copy it to clipboard without having to use a multitude of keyboard shortcuts to achieve it. Utilizing javascript works excellent in this instance.
First I set up a new macro with a trigger (I chose to use a hot key, but that's up to you) then search "Execute". The list of options should now look something like this...
Right. So now, I would prefer to encapsulate this javascript in an "If Then Else" . For the function I'm going to use this doesn't need to be done necessarily, but since I am using a js function this is something that could come in handy later when I want to make updates on it or further specify the parameters.
Next I'm going to select the "Execute a Javascript in Google Chrome" (note: the other options, safari and automation). I throw that in my "if" box and get this (note: I also de-selected the else option, because I have nothing else to execute at this time)
Alright, I'm gonna kind of jump ahead here and assume that if you're messing with this you know at least some javascript... next I throw in my function of choice, which for this one I want to grab the url of a window I use for searches... then I adjusted some parameters and check "Save to System Clipboard", and now I got this bad-boy
I've briefly tested this in Chrome only so far, but it works great. It's way faster than my other method (I'll illustrate below), more accurate, requires less CPU and works in messenger windows. This was the way I was achieving the same affect (which does not work in messenger windows).
( my use of "Escape" is to stop the current page from loading to increase speed of function)
So that's a quick run down, and as far as I've taken this feature so far. But now I'm very excited to see how else I can apply it! Could be used to open links, select radio buttons etc. etc.
Please feel free to comment, ask questions or share this thread as you wish!!!!
The solution, Keyboard Maestro. This is a macros program that is available for free download (trial version with full functionality) from the site linked in the previous sentence (duh). In case you're completely new to this and have no idea what "macros" is(are?) here is my laziest definition ripped from Wikipedia.com
"A macro (short for "macroinstruction", from Greek μακρο- 'long') in computer science is a rule or pattern that specifies how a certain input sequence (often a sequence of characters) should be mapped to a replacement output sequence (also often a sequence of characters) according to a defined procedure."
Source: https://en.wikipedia.org/wiki/Macro_(computer_science)
Okay, so what does this mean? To put it simply, it's a way to automate repetitive tasks on your computer. For better reference I'll illustrate an example from the actual program.
This is one of my favorite Macro(instructions) that works on a number of different types of HITs on mTurk. This one is from a specific Kevin Dodds scripts I made on Keyboard Maestro...

So what this macro allows me to do is when I found the phone number in another search window that I want, all I have to do is left-click on the phone number with the "alt" modifier key pressed then the macro will triple click wherever I clicked, copy, move back to the HIT window, tab down to the correct text field and paste the number. This saves about 4-6 seconds per HIT.... so what? So this is just one macro that I have for this HIT, and with each one saving a couple seconds, I can effectively knock off 20-30 seconds from these HITs....
So there is an example and little definition of Keyboard Maestro and Macros and how Mac users can take advantage of it on mTurk.
Here are some helpful links and highlights from the official KM documentation:
The Document
On Triggers and Hotkeys (or any other way you wish to initiate a macro)
Macro Actions
Example Macro Actions
The Keyboard Maestro Forum is also a great resource and place to ask more in depth questions.
A few more tips
Application Specific Macro
Here's something that has become incredibly useful to me and saved a lot of headaches...
When creating a Macro group for a certain HIT you can specify it to only be active in a certain application. For example, I do HITs in Chrome almost exclusively while I use FF to run panda's/Scraper and I use Opera browser for email/forums etc.
So, it can be a huge pain in the ass when you have a Macro assigned to a Hotkey like the letter "f" for example. I don't want to have to turn off the macro every time that I want to type something in the forum or whatever, but if I don't then I may type "f" and set off some crazy Macro that completely fucks up my flow.
Solution:
When creating a new Macro you are presented with this screen (I named this "New Macro")

Now click "Available in all applications" then "Available in the following applications" (note the other ways to specify as well)

Then select whatever app you want the Macro to work in (you can choose multiple apps if you want)

This feature is always available, not just when you are creating a new Macro.
I highly recommend using it
Execute Javascript
This is one brand new (to me) but omg I'm lovin' it, I can't believe it took me this long to discover this feature.
Within any macros you can add the "Execute Javascript" action. There are a couple different options for this and a multitude of ways to specify and achieve exactly what you want... so for simplicities sake I'll show the first one I made.
I wanted a way to grab a url address and copy it to clipboard without having to use a multitude of keyboard shortcuts to achieve it. Utilizing javascript works excellent in this instance.
First I set up a new macro with a trigger (I chose to use a hot key, but that's up to you) then search "Execute". The list of options should now look something like this...

Right. So now, I would prefer to encapsulate this javascript in an "If Then Else" . For the function I'm going to use this doesn't need to be done necessarily, but since I am using a js function this is something that could come in handy later when I want to make updates on it or further specify the parameters.
Next I'm going to select the "Execute a Javascript in Google Chrome" (note: the other options, safari and automation). I throw that in my "if" box and get this (note: I also de-selected the else option, because I have nothing else to execute at this time)

Alright, I'm gonna kind of jump ahead here and assume that if you're messing with this you know at least some javascript... next I throw in my function of choice, which for this one I want to grab the url of a window I use for searches... then I adjusted some parameters and check "Save to System Clipboard", and now I got this bad-boy

I've briefly tested this in Chrome only so far, but it works great. It's way faster than my other method (I'll illustrate below), more accurate, requires less CPU and works in messenger windows. This was the way I was achieving the same affect (which does not work in messenger windows).

( my use of "Escape" is to stop the current page from loading to increase speed of function)
So that's a quick run down, and as far as I've taken this feature so far. But now I'm very excited to see how else I can apply it! Could be used to open links, select radio buttons etc. etc.
Please feel free to comment, ask questions or share this thread as you wish!!!!
Last edited: