If the situation is truly as bad as you've described then you need to make some hard choices. You can continue to act like you're the apex predator and world super power or you can cede Earth to the apes and go in hiding in some remote area.
If you continue to act like a world super power you will eventually die a violent death at the hands of these apes. After all you will need to successfully counter all of their attempts, whereas they only need to get lucky once. Due to their great capacity for innovation and superior numbers the odds are greatly in their favor over time.
If you go in hiding the apes will either civilize themselves to the point where it is possible to peacefully coexist or kill each other off without your help. This is the pathway taken by several other species in my world ranging from Bigfoot, to the Loch Ness monster, or even the powerful Megalodon. During your self-imposed exile these apes will no doubt develop more and more efficient ways to kill each other. As they increase their population density and become more militarily advanced they will either develop more and more advanced diplomatic skills in order to ensure their survival or they'll kill each other off. Regardless you will be in a better position to negotiate a peaceful resolution.
As an aside it should be noted that once their military might reaches a point where it can overwhelm you easily your safety is greatly increased. This is especially true if you learn to communicate with the apes. Their ability to dominate you will make them feel more at ease with your existence. In this way you use their strength of arms to bolster your survivability.