There are three main passages where Descartes enunciates his
first principle:

(a) . . . I noticed that while I was
trying . . . to think everything false, it was necessary that I,
who was thinking this, was something. And observing that this
truth I am thinking, therefore I exist was so
firm and sure that all the most extravagant suppositions of the
sceptics were incapable of shaking it, I decided that I could
accept it without scruple as the first principle of the
philosophy I was seeking. [Discourse IV, para. 1; CSM,
I, p. 127.]

(b) But [on the most radical sceptical
hypothesis] there is a deceiver of supreme power and cunning who
is deliberately and constantly deceiving me. In that case I too
undoubtedly exist, if he is deceiving me; and let him deceive me
as much as he can, he will never bring it about that I am nothing
so long as I think that I am something. So after considering
everything very thoroughly, I must finally conclude that this
proposition, I am, I exist, is necessarily true whenever
it is put forward by me or conceived in my mind. [Meditations
II, para. 3; CSM, II, p. 17.]

(c) . . . we cannot for all that [we
might doubt] suppose that we, who are having such thoughts, are
nothing. For it is a contradiction to suppose that what thinks
does not, at the very time when it is thinking, exist.
Accordingly, this piece of knowledge - I am thinking, therefore I
exist  is the first and most certain of all to occur to
anyone who philosophizes in an orderly way. [Principles I,
section 7; CSM, I, pp. 194-5.]

(B) Interpretations and Issues

(1) Intuition or deduction?

The famous proposition Cogito ergo sum does not
occur in the Meditations passage, suggesting that it is
not, at least, a straightforward inference. Descartes himself
denies that it is a syllogism (with a suppressed premiss):

When someone says I am thinking,
therefore I am, or I exist, he does not deduce
existence from thought by means of a syllogism, but
recognizes it as something self-evident by a simple
intuition of the mind. This is clear from the fact that
if he were deducing it by means of a syllogism, he would
have to have had previous knowledge of the major premiss
Everything which thinks is, or exists; yet in
fact he learns it from experiencing in his own case that
it is impossible that he should think without existing.
It is in the nature of our mind to construct general
propositions on the basis of our knowledge of particular
ones. [2nd Replies, 3rd point; CSM, II, p. 100.]

Yet there is clearly some argument involved, I
exist being some kind of conclusion, arrived at as a
result of Descartes sceptical considerations. By
intuition here, Descartes doesnt just mean a
recognition of something as true, but a
recognition of something as certain; so that we can
say that what is being intuited is the certainty of
ones own existence, on the basis of the sceptical
argumentation.

(2) Implicit knowledge

The passage from the 2nd Replies also raises a problem about
the role of general principles. Elsewhere, Descartes states:

Before this inference, I am
thinking, therefore I exist, the major
whatever thinks exists can be known; for it
is in reality prior to my inference, and my inference
depends on it. This is why the author says in the Principles
[CSM, I, pp. 195f.] that the major premiss comes
first, namely because implicitly it is always presupposed
and prior. But it does not follow that I am always
expressly and explicitly aware of its priority, or that I
know it before my inference. This is because I am
attending only to what I experience inside myself 
for example, I am thinking, therefore I
exist. I do not pay attention in the same way to
the general notion whatever thinks exists. As
I have explained before, we do not separate out these
general propositions from the particular instances;
rather, it is in the particular instances that we think
of them. This, then, is the sense in which the words
cited here should be taken. [Conversation with Burman;
CSM, III, p. 333.]

Descartes is not denying that, in some sense, we
know the general principle; what he wants to argue is
that it is not our knowledge of this that makes us certain of our
own existence. However, there does seem to be a tension between
this view and the implications of Descartes initial
sceptical considerations, where it seems to be suggested that
such general propositions can indeed be doubted. Such a view also
seems in conflict with the transparency doctrine noted below.

(3) What kind of thinking?

Thinking, according to Descartes, covers any kind
of mental activity, so would any kind of thought do as a premiss
for the Cogito? There are passages that seem to suggest
this, a view that emerges naturally out of his so-called
doctrine of the perfect transparency of the mind,
thoughts being whatever we are aware of as happening
within us (see Principles, I, 9). But this seems to make
the emergence of the Cogito conclusion out of the
sceptical considerations problematic, it being the specific
process of doubting that makes us certain of our
own existence. There may thus again be a certain tension between
proving the truth of the Cogito conclusion, and
demonstrating its certainty.

(4) Inference or
performance?

Hintikka has argued that there are two lines of thought
involved in the Cogito. The first amounts to an inference
that I exist from the premisses that if I am right in thinking
something, I must exist, and that if I am wrong in thinking
something, I must still nevertheless exist (to be wrong). But, he
writes:

This neat argument is a petitio
principii, however, as you may perhaps see by
comparing it with the following similar argument: Homer
was either a Greek or a barbarian. If he was a Greek, he
must have existed; for how could one be a Greek without
existing? But if he was a barbarian, he likewise must
have existed. Hence he must have existed in any case.
[Hintikka, 1962, in Doney, pp. 114-5.]

However, it is open to us to simply deny the initial premiss
of this argument (if there was no Homer, the premiss is neither
true nor false); and to the general charge of petitio
principii, Descartes might respond that he is making explicit
our knowledge of our own existence, so that we can be certain
of it.

On Hintikkas second interpretation, the Cogito is
construed as a performance, the very act of thinking that
I exist (or wondering whether I exist) demonstrating its truth.
It is the existential self-verifiability of I
exist that provides the required indubitability when I
follow the Cogito line of thought (cf. ibid., pp. 121-2).
However, it is hard to reconcile this interpretation with
Descartes texts. In particular, it is not the thought that
I exist that is pivotal in his reasoning, and the relationship to
his sceptical considerations is rendered unclear.

(5) What am I?

If Cogito ergo sum is some kind of argument, then
Cogito is its premiss. But what exactly does this
involve? It has often been argued that all Descartes is entitled
to is the premiss there is some thinking going on.
Lichtenberg, for example, wrote: We should say it thinks,
just as we say it lightens. To say cogito is
already to say too much as soon as we translate it I think.
To assume, to postulate the I is a practical
requirement. [Aphorisms, tr. R.J. Hollingdale,
Penguin, 1990, p. 168.] To conclude I am, then, might
seem of little content; yet Descartes wants to move from
Cogito ergo sum immediately to Sum res
cogitans, which arguably provides a significant addition to
Sum. Here the move is supported by appeal to the
principle nihili nulla sunt attributa (nothing
can be predicated of nothing; cf. e.g. Principles,
I, 11), resting on the Aristotelian doctrine of substance and
attribute. If there is a thought, then there must be a thinker
having it. But what is it to be a thinker?