Refactor the Autobahn client script.