
MS TextWorld: open-source engine that both generates and simulates text games - dyukqu
https://www.microsoft.com/en-us/research/project/textworld/
======
Maimedpuppet
They won a text adventure AI competition as well [1][2] and is now running
their own with $2000 reward at stake [3]. Getting an agent to solve unseen RPG
games like zork or modern games like Zelda and Witcher would be awesome and
seriously impressive, but I don't think anybody is even close to that right
now.

[1] [https://arxiv.org/abs/1902.04259](https://arxiv.org/abs/1902.04259)

[2]
[https://github.com/Microsoft/nail_agent](https://github.com/Microsoft/nail_agent)

[3] [http://aka.ms/textworld-challenge](http://aka.ms/textworld-challenge)

~~~
chongli
I would be genuinely surprised if anyone can build an agent that can solve
Zelda for the NES without any foreknowledge of the game. So much of that game
is bound up in the human cultural tropes associated with the monomyth. To
finish the game you need to have at least a basic working knowledge of what it
means to be a hero. There is no obvious, short-term indicator of progress the
way there is in Mario (increase the x position to win).

The process of obtaining just a single piece of the Triforce (the primary
indicator of progress) is so complicated that you'll essentially never see it
happen with random button-pressing. So any agent attempting to play and win
Zelda is going to need to develop its own model of the game world and try to
understand things that way. I don't see how that is supposed to happen though,
without any context.

~~~
taftster
Zelda was simply a means for Nintendo to sell Nintendo Magazine subscriptions.
They had to have made a killing on subscriptions, and they were absolutely
required for solving games like Zelda. For example, you have to place a bomb
in this one obscure location without any in-game clues as to said location. Or
burn a tree.

Here's the connection to your post. I think a human and a computer have about
the same chance of solving Zelda. At least a computer could be programmed to
drop bombs in every rock wall in the game. For a human, that would be too
brain-numbing hard.

~~~
feanaro
You definitely do not need external hints to solve Zelda games. I've finished
many Zelda titles without ever getting any hints. I've even finished A Link to
the Past in German by using a dictionary to translate dialogue. Before that, I
had not known a word of German.

~~~
korla
He is talking specifically about Legend of Zelda, or Zelda for short, the
first game in the series.
[https://en.wikipedia.org/wiki/The_Legend_of_Zelda_(video_gam...](https://en.wikipedia.org/wiki/The_Legend_of_Zelda_\(video_game\))

~~~
feanaro
Fair enough. The tree burning should had given me the hint.

That said, I did finish the original LOZ without hints too.

------
cwyers
> TextWorld requires Python 3 and only supports Linux and macOS systems at the
> moment.

Truly, this is a new Microsoft.

~~~
4thaccount
Yes and No. I think they understand the very real limitations of Windows and
how developers and power users hate it.

Let's compare and contrast the two. Linux has a usable shell that has GCC,
Bash, Awk, dozens of specific commands that can be piped together, Perl,
Python, TCL...etc all built-in and easily composable. Windows has well...CMD
which is horrible, Batch files, VBScript (deprecated), VBA, and Powershell (a
mess). If you install Visual Studio Tools you can get a C++ compiler and .NET
languages like C# and VB.NET. Linux might have its faults, but the design is
coherant and you can get stuff done. With Windows your only options are use a
GUI or write at least a 1/2 page of code for something that is a oneliner in
Linux. Powershell is a sometimes great (mostly meh) attempt to right this, but
the everything is an object design is just simply more complex than the Unix
philosophy of strings, pipes, and interoperable pieces. It seems like the
Windows approach is to recognize the failing, while keeping in mind that a lot
of desktop software uses Windows. So give developers Linux via WSL and people
can still run their other Windows only software without Wine.

~~~
debaserab2
Or maybe this came out of an MS R&D arm that had free reign on design and it’s
not some overall signal that MS has admitted defeat to Linux on the shell.

I have a hard time believing this couldn’t have just as easily been windows
based with the exact same amount of effort. Windows has fantastic developer
tooling that I think you’re downplaying quite a bit.

> Powershell is a sometimes great (mostly meh)

Powershell has a different philosophy for sure - but I have seen sys admins do
some pretty powerful things with it, and quickly. What can a Linux shell do
that power shell can’t (that isn’t specific to Linux platform needs)?

~~~
4thaccount
Quite a bit in my opinion. Of course if both are Turing complete the answer is
nothing, but efficiency in development time and speed should be a factor.

To give an example, suppose you have a directory with 20 .CSV files that are
all 200 MB. This is extremely common for me and the files are much larger for
many developers. Say you want to extract certain data matching a string and
then sort the whole thing into a new file. In Linux this is really simple with
a oneliner and it also runs really fast. Powershell has a oneliner capability,
but it is quite frankly abysmally slow. The Linux solution takes about 5
seconds and the Powershell takes 15 minutes. Now there is a way to speed up
the powershell code. Running it in parallel helps, but the true performance
aid comes in calling some C# within the script and now it is definitely not a
oneliner. That is the overall issue. The Unix philosophy is simple to execute,
understand, and fast to run. The Windows is complex to understand and often
slow. Powershell is great in some instances. The language is certainly better
than Bash, but if I have to constantly use C# with it...you might as well just
use C#.

~~~
tracker1
for anything more complex, I often just defer to a node/js script... mostly
out of more comfort, but also because it runs everywhere I want it to (linux,
windows, mac), usually with minimal effort.

~~~
4thaccount
There's obviously nothing inherantly wrong with that and it's great that you
can run it anywhere. However, isn't it a shame you have to resort to that?
Shouldn't there be a way to easily specify to the computer what you want
without having to go so far outside the OS? Obviously this isn't Star Trek
where you can ask the computer to do something and it knows exactly what you
want. At some level of complexity you will have to start writing real code and
at that point I agree it doesn't matter a whole lot whether you're using
Python, Bash, C#, NodeJS, or Haskell. However, if you're doing something
really simple like loop over some files that match a string in a directory,
parse the files, and make a report, that should be easy. If your first thought
is "let me go open Visual Studio"...then your OS has failed in my opinion.

~~~
tracker1
Fair enough... tbh, if Git for Windows, registered `.sh` and `.bash` file
extensions to execute via that version of Bash, I'd be content with that... as
it is, I have re/used a little bash even in windows at work (everyone has git
for windows) and have certain things installed via script+chocolatey. Second
pass/configuration, etc, calls a bash script in windows... The first part I
also have a bash script for mac, and the second script is shared.

That said, JS/Node is often my goto... I also do a fair amount of `npm i -g
UTIL` mainly out of convenience between platforms. There isn't a really
universal scripting system I can completely rely on where at least one of the
three aren't oddities.

I do use bash pretty much everywhere, and that's what I _use_ ... it's just
when I'm writing a script for reuse, I'm more inclined to use NodeJS.

~~~
4thaccount
Gotcha. Thanks for the additional thoughts!

------
wuschel
What is the difference between _TextWorld_ and a design system for interactive
fiction games like _Inform_ [1]?

It seems to be that the former has natural language processing/semantics
integrated, while the latter relies on a rather old school approach to text-
based games. Or am I mistaken?

[1] [http://inform7.com/](http://inform7.com/)

~~~
marccote19
Hi, I'm with the TextWorld team.

TextWorld actually uses Inform7. The framework first builds a game object
(e.g. objects, locations, quests) according to some settings. Then, it
converts it into Inform7 code before being compiled into a playable game. See
[https://imgur.com/oOcy5kk](https://imgur.com/oOcy5kk)

~~~
malloryerik
How could you run a TextWorld game in a web browser? Use a Glulx file
interpreter like Quixe?

[https://eblong.com/zarf/glulx/quixe/](https://eblong.com/zarf/glulx/quixe/)

~~~
yorwba
The "try it" example on the TextWorld page uses Parchment:
[https://github.com/curiousdannii/parchment](https://github.com/curiousdannii/parchment)

------
macca321
There are interesting parallels between problem solving textworld agents and
smart hypermedia client agents.

------
rainydaybook
Why not show a simple map of the room you're in, at least? It's a fairly
simple change, but would make the orientation in space and remembering of
location and few previous locations much more intuitive.

~~~
taodav
TextWorld environments have a render function that renders an SVG of the room
and your inventory
([https://github.com/Microsoft/TextWorld#extras](https://github.com/Microsoft/TextWorld#extras))

~~~
marccote19
Also, those games are intended for Reinforcement Learning agents, not Humans.

------
zyngaro
Amazing! Yesterday while taking a walk I thought exactly about that ! A text
based game and a text game engine.

------
ucaetano
Is this Microsoft's response to Google's Stadia?

~~~
tellarin
Microsoft's approach would likely be xCloud.
[https://www.theverge.com/2019/3/13/18263405/microsoft-
xcloud...](https://www.theverge.com/2019/3/13/18263405/microsoft-xcloud-game-
streaming-demo-video)

