Thanks for mentioning these!
I started exploring this after seeing TorchCraft on HN yesterday (https://news.ycombinator.com/item?id=16979136) and I worked on a BWAPI AI back in college myself (2009).
I took a look at ELF hoping it was a library or module I could integrate into my project to make it applicable with PyTorch, but it was its own gym complete with full game examples.
Are you aware of 'Elf' and 'TorchCraft' by Facebook (creators of Pytorch)?
From https://facebook.ai/developers/tools/elf :
"ELF provides an end-to-end solution for game research. It includes miniature real-time strategy game environments, concurrent simulation, distributed training over thousands of machines, intuitive APIs, web-based visualizations, and a reinforcement learning framework powered by PyTorch."
From https://facebook.ai/developers/tools/torchcraft :
"TorchCraft is a Brood War API (BWAPI) module that sends StarCraft data out over a ZMQ connection, allowing researchers to parse StarCraft data and interact with BWAPI from C++, Python (PyTorch-friendly), and Lua (Torch-friendly)."