1) There are thoughts,
2) There is something that is thinking these thoughts,
3) That something which thinks may be identified as "I",
4) Therefore I exist.
Steps 2 and 3 are hidden assumptions. There may not be such a thing as the thinker and even if the thinker did exist, we do not know that it is the same as what we refer to as the "I". Both David Hume and Krishnamurti regard the thinker as an unnecessary construct. Eastern philosophy takes pains to remind us that, "You are not your mind".
We could state Descartes' assumptions as, "I think that something thinks and I think that I am that thing."