In my view, the answer to this question is “yes.” In other words, “By the Waters of Babylon” can be either a story of optimism or a story of pessimism. It really depends on the attitude of the reader.
It is at the end of the story that the reader must choose whether to see this in an optimistic or a pessimistic way. At the end of the story, John is fired with passion and energy. Twice, he says, “we make a beginning.” He ends the story saying “we must build again.” You can definitely see this as evidence that this is an optimistic story. John and his people are practically living in the Stone Age, yet John is having big dreams. He has realized that it was people, not gods, who built the ruined cities and towns. He is sure that his people can do the same if given enough time. This seems fundamentally optimistic.
However, you can also view this ending with pessimism if you are so inclined. The people who lived and died in New York City destroyed themselves. Somehow, they created weapons and fought wars that completely ruined their civilization. If you are so inclined, you can believe that it was human nature that drove them to do this. If it is human nature that caused this, is there any reason to believe that things will end better for John and his descendants? After all, even with their primitive technology, the Hill People and the Forest People try to kill one another. Is there any reason to think that they will not try to kill one another with advanced weaponry if they “progress” that far? If you are inclined to pessimism, you can believe that John and his people are going to rebuild, only to destroy themselves again because that is human nature.
So, what is your view on this question? Do you think that this is optimistic because John is going to inspire his people to build again? Or do you think that it is pessimistic because human nature means that they will inevitably destroy themselves again, just like the ancient people of New York did?