The execute JavaScript methods in Selenium support passing arguments to the script. Selenium2Library does not support passing arguments, though (yet).
The way the arguments are passed is through injecting a variable into the scope of the script named arguments.
Because there may be arguments, Selenium adds a pointer to the callback function to the end of the array.
Since S2L does not support passing arguments, arguments[arguments.length - 1] = arguments[0].
Assigning that pointer to a variable called callback just makes the script more readable.
The script could be as simple as this, though not useful:
Execute Async Javascript arguments[arguments.length - 1]()
The second example does not have a callback because the script is hypothetical - its just to show you that you can have the script stored in a file rather than as an argument to the keyword.
The Python documentation for Selenium is pretty sparse. You should check out the Javadoc for
executeAsyncScript.