OK, I am kind of excited about this, both from technical and marketing points.
You know how there is all this hoopla about Turing complete language?
For those who followed the NXTcoinsco "name change" to Tradebots, you will know I have been working on a tradebot language today, but first I thought just something simple, like >, < ==, but then I thought why not make it Turing complete?
I know you are saying that would take a long time to do, but I figured it was worth looking for a nice C interpreter.
...
So, I now have a Turing complete language for people to program their tradebots with!
In the .conf file, I look for dynamically loaded libraries to support custom languages
With the language compiler loaded into the system, you can then send it JSON string that is the program:
{'lang':'ptl','botname':'testbot','inputs':[{'exchange':'bter','base':'NXT','rel':'BTC'}],'signals':[{'name':'buy','size':4},{'name':'sell','size':8}],'picoc':'double main(int argc,char **argv){ double val = 1.234567890123456; val = *(double *)argv[0]; return(val);}'}
program output:
bot returns 13383.935580646748349 event.1 Jul_27_14 06:56:36 PM bot.(testbot) id.0 BTC NXT
The bots are called in dependency order for all price changes and once per minute. It was a bit tricky to make sure the order of calling the bots are done so all the data is ready for each bot, this is determined by order the tradebots are added to the system to create the tradebot topology.
The above is just a small test program in 'JSON' where " -> ' to deal with the stringification of strings through all the layers.
lang: ptl is just for pico tradebot language
botname: testbot is how other bots can get the output signals of this bot
inputs: is an array of external data sources (all the major exchanges and contract pairs) and I will also add some basic signal processing, like smoothing, moving averages, noise filtering, etc.
signals: these are the named outputs of this bot and the size, so the output can be more than just a single number, it could be an entire data structure
picoc: this is the Turing complete part, I was able to integrate in the picoc interpreter and verify that I can pass data in and out of the tradebot code. I even changed it so by default it outputs a double for easier connecting to other things needing floating point inputs. I will be able to give access to the picoc programs the entire dataset that my data gathering is doing. In fact, I can let it access external functions, so it would be possible to make NXT API calls from within the picoc, or bitcoind, or basically anything.
Now the reason I was able to add Turing complete language support into my tradebot language in less than a day is that I care not about synchronizing all nodes. Tradebots design is for each node to run a different set of tradebots to come up with customized trading decisions.
Now that I have the pico tradebot language and the realtime data gathering and the realtime bitmap display and the atomic exchange and a hub and spoke network, InstantDEX is very close to initial release. First I will make a auto NXT -> BTC converter that will allow payment in NXT to all places that accept BTC. With what is in place, well, that is pretty much enough to allow this.
So, NXT has Turing complete language via Tradebots (formerly NXTcoinsco) service!
People who make tradebots can let others use it and then share trading profits, but only if they are profitable. I have accelerated deploying SVM enabled tradebots as all this is coming together very nicely. With SVM creation ability, I expect people will be able to make nicely profitable tradebots.
James