I have developed a chess engine in Python with negamax, alpha beta and piece square table. I want to "compile" my code into a UCI compatible one so I can load it to Arena GUI, but I have no idea at all how to do that and every time I search for information I found it very confusing and counterintuitive. Could someone give me a light, a direction please, cause I don't know how to even begin ...

Note: I use Python chess module in my code and the moves are returned in UCI format since I use the return move.uci() method, but I don't understand if this is enough or how to load my code to Arena GUI, I have just few experience developing.

  • 5
    Did you read the uci protocol?
    – ferdy
    Commented Aug 14, 2022 at 12:35
  • 5
    Put simply, your engine needs to write certain information to standard output, which the GUI will read, and you need to read certain information the GUI will send via standard input. What this "certain information" is is specified in the UCI protocol Ferdy linked.
    – Chris
    Commented Aug 14, 2022 at 16:05
  • 4
    Probably a look at Sunfish uci.py file would be of help.
    – emdio
    Commented Aug 14, 2022 at 19:36
  • I believe the tricky part is that the engine must always listen for input even when thinking.
    – qwr
    Commented Aug 22, 2022 at 3:45

1 Answer 1


I once posted a simple code example on Stack Overflow. This may help. There they also mention the python-chess package, but that does not support the full set of UCI commands.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.