AutoIT TCP direct interface with Nailgun/Java server

Closed - This job posting has been filled and work has been completed.

Job Description

I created and attached a little Autoit function that launches the Java command-line tool BaseX to perform an XPATH extraction out from an HTML file.

To avoid the 2-seconds long (on my PC) delay for Java startup every time this Java command-line tool is launched, I implemented Nailgun that is a well known little client+server tool that keeps a permanently opened Java server session in background, letting the client app Basex communicate with it via TCP.

INSTRUCTIONS to make all the above work.
1) extract the attached "test.zip" package to "c:\test\" (with subdirectories)
2) open an MS-DOS prompt and launch the Nailgun server "runNailGunSrv.bat" in the folder "c:\test\Nailgun"
3) open "c:\test\AutoIT_script_for_oDesk.au3" in SciTE and launch it with F5.
4) you'll see the resulting XPATH extraction in the botton (in the output frame, as result of the ConsoleWrite command)

Now I'ld like to further improve its speed...
and since I saw that the used Nailgun Windows client "ng.exe" implies an overhead because the AutoIT script needs to open it in an MS-DOS command-line (with a RunWait command).... and I saw that the author of Nailgun provides a "protocol" documentation page here http://www.martiansoftware.com/nailgun/protocol.html about communicating directly with the Java server session via TCP bypassing this "ng.exe" client,
I ask you to improve the speed of my AutoIT script by implementing this direct AutoIT<->TCP communication in place of "ng.exe".

Open Attachment