@H.PWiz nah, you can play against bots, or play bots against bots (bot users are clearly marked as such). They have an API for it. It's against their terms of use to have a bot assisting you when you play as a human
@Adám two potential issues. 1 - It'd be running on my desktop at home and not on my laptop, so I'd have it installed on two devices. 2 (and this is the bigger issue) - I might be indirectly paid to work on it (my work has "team days" where instead of doing work we're meant to be social, so a few us are just writing chess bots)
@Probie 3.2 You may install each version of the software on more than one computer provided that it is used on one computer at a time.
@Probie Regarding 2: I've asked about that before. There's no problem in using Dyalog APL as a utility for your work, e.g. as a desktop calculator for your company's finances. What is restricted is using it to create money-making or paid-for software for others to use.
@Probie I just asked. As stated, you may have it installed both places, but if you leave it running at home and while you want to use it elsewhere, just apply for an additional license. :-)
@Adám is there a way to stream JSON objects from a http connection in Dyalog APL, or am I better off just writing a wrapper in another language and sending the JSON objects over stdin as they come in? (I'm not up to this yet, but by the time I am, the sun will have set where you are and I don't know who else I could ask)
@Adám lichess uses a regular http request for a bot to receive incoming actions (and sends a newline every few seconds to keep the connection alive if the bot has no incoming actions). My coworker just wrote a simple node program around his bot (in rust) and I could do the same, but it'd be pretty neat to have the whole thing in APL
@Adám it can, but then I can't launch emacs to edit (or at least I assume so - I haven't actually tried). If my bot in APL compares with my Haskell one (I expect it to be slower, but hopefully not much slower), I'll apply for a second license so I can keep it running without having to connect my laptop to my desktop, but if it's a lot slower I won't keep it running (but it'll still have been worthwhile pedagogical reasons)
@Probie What exactly do you mean by "stream"? It is easy to make a server that receives a request and sends JSON back. It is also easy to make a client that sends requests with JSON in them. Are you sure you don't need websockets?
@Adám I wish it had websockets - it's a regular http request which doesn't terminate, it just sends JSON objects whenever an event happens (and newlines every few seconds to keep the connection open)
@Adám I think lichess is put together by people who are a lot better at chess than they are at programming (streaming over HTTP/1.1 is a terrible idea, but they do it)
@Probie See, they need APL. APL is supposed to be easy so that domain experts can get their stuff done without having to worry about technical computer details.
@Probie Just to clarify: Who's the server and who's the client of you and lichess?
@Adám The only thing I'm a domain expert in is theorem proving and APL doesn't suit that (beyond SAT) too well. But after Coq (which isn't really a programming language) and Haskell (which requires learning a lot of strange, non-obvious things) APL is my favourite language right now. It's no worse than other languages for some problems and so much better for the rest.
@Probie Did the HttpCommand look like something you can use? If not, then I'll ask Brian to enter the chat here (he has a SE chat account) and help you further. He's in New York, so he'll be around later too…
@Adám I'm about to go to bed. If I can't get it working, I'll just wait until Tuesday morning (Monday afternoon your time) but I feel like you shouldn't waste too much time on me - as fun as I'm finding APL I'm unlikely to make Dyalog any money
@Adám I'm writing a chess bot and an SMT solver in Dyalog APL. They'll be less success stories and more "look how close I could get to state of the art with so few lines of code" which might be of interest
@Sherlock9 But you could always adjust the base to get as many separate "decimals" as you want.
@Sherlock9 I don;t mind you using the bot as much as you wish, but the experience of APL in an actual interactive session is just so much richer. Have you applied for a free personal license yet?
@Probie @Probie I took a quick look at Lichess' API documentation. Everything is simple HTTP GET and POST requests. One could probably use HttpCommand (in Dyalog v16.0 and later do ]load HttpCommand to load it) to interact with the chess bot. Then it's a matter of writing a client that uses HttpCommand. The client would react to the various responses from the chess bot. HttpCommand.Documentation will display the docn.