improved readme and comments, TODO: more unit tests, mainly for spawning agents