TL;DR version
There is a conditioned and compounded, dependently originated self-doer, which is a discernible endeavouring and initiating being, that is generating the volitions to perform action. But there is no standalone independent eternal entity that is acting as the driver or charioteer.
An example is the autopilot of a self-flying airplane. It's a self-flying airplane, not a Self flying airplane. Several computers together with software, sensors and actuators in the plane work together to calculate, decide, and instruct how the plane flies. There is no human pilot (who is independent of the airplane) who is flying the self-flying plane. The autopilot is very much an integral and inseparable part of the airplane, just like its landing gear, engines and wings.
Similarly, there is no independent Self or Atman working like a "human pilot" performing action. Rather, there is a dependently originated self-doer working like the autopilot which is calculating, deciding and performing the actions. The self-doer is very much an integral and inseparable part of the five aggregates.
If one thinks that nobody is doing anything, this will result in an unwholesome attitude of not doing anything or not taking responsibility, which in turn results in unskillful actions, which in turn results in deepening suffering. For more info on this, please refer to the commentaries by Nizamis and Piya Tan below on fatalism.
Furthermore, to think there is no self at all, is an annihilationist view, which is a false view, just like the eternalist view.
Long version
The Attakari Sutta (AN 6.38) answers this:
Then a certain brahman approached the Blessed One; having approached
the Blessed One, he exchanged friendly greetings. After pleasant
conversation had passed between them, he sat to one side. Having sat
to one side, the brahman spoke to the Blessed One thus:
“Venerable Gotama, I am one of such a doctrine, of such a view: ‘There
is no self-doer, there is no other-doer.’” (Note1)
“I have not, brahman, seen or heard such a doctrine, such a view. How,
indeed, could one — moving forward by himself, moving back by himself (Note2)
— say: ‘There is no self-doer, there is no other-doer’? What do you
think, brahmin, is there an element or principle of initiating or
beginning an action?”
“Just so, Venerable Sir.”
“When there is an element of initiating, are initiating beings clearly
discerned?”
“Just so, Venerable Sir.”
“So, brahmin, when there is the element of initiating, initiating
beings are clearly discerned; of such beings, this is the self-doer,
this, the other-doer.
“What do you think, brahmin, is there an element of exertion ... is
there an element of effort ... is there an element of steadfastness
... is there an element of persistence ... is there an element of
endeavoring?”
“Just so, Venerable Sir.”
“When there is an element of endeavoring, are endeavoring beings
clearly discerned?”
“Just so, Venerable Sir.”
“So, brahmin, when there is the element of endeavoring, endeavoring
beings are clearly discerned; of such beings, this is the self-doer,
this, the other-doer. I have not, brahmin, seen or heard such a
doctrine, such a view as yours. How, indeed, could one — moving
forward by himself, moving back by himself — say ‘There is no
self-doer, there is no other-doer’?”
“Superb, Venerable Gotama! Superb, Venerable Gotama! Venerable Gotama
has made the Dhamma clear in many ways, as though he were turning
upright what had been turned upside down, revealing what had been
concealed, showing the way to one who was lost, or holding up a lamp
in the dark: ‘Those who have eyes see forms!’ Just so, the Venerable
Gotama has illuminated the Dhamma in various ways. I go to Venerable
Gotama as refuge, and to the Dhamma, and to the assembly of monks.
From this day, for as long as I am endowed with breath, let Venerable
Gotama remember me as a lay follower who has gone to him for refuge.”
Commentary by Nizamis:
Note1: “Natthi attakāro, natthi parakāro.” Some people might have expected the Buddha to have approved highly of this naïve negative
doctrine. The fact that he very succinctly and effectively refutes it
is extremely instructive and of great significance for gaining a
better understanding of the depth, subtlety, and holism of the
Buddha’s actual teaching. Although the Buddha taught that there is no
permanent, eternal, immutable, independently-existing core “self”
(attā), he also taught that there is “action” or “doing”, and that it
is therefore meaningful to speak of one who intends, initiates,
sustains and completes actions and deeds, and who is therefore an
ethically responsible and culpable being. It should be quite clear
from its usage in this sutta, and from the argument of this sutta,
that kāra in atta-kāra must be an agent noun, “doer, maker”: this is
strongly entailed, for example, by the Buddha’s statement:
“ārabbhavanto sattā paññāyanti, ayaṃ sattānaṃ attakāro ayaṃ parakāro”,
“initiating beings are clearly discerned: of (such) beings, this is
the self-doer, this, the other-doer” (AN iii.338). (This is perhaps
even clearer than the term hāra in bhāra-hāra meaning “bearer”
(“burden-bearer”) in SN 22.22 (Bhāra Sutta: The Burden; PTS SN
iii.25). SN 22.22, which describes the “bearer” of the “burden” of the
“five clung-to aggregates” (pañc-upādāna-kkhandhā) as the “person”
(puggala), is arguably very closely related to AN 6.38 in meaning and
implications. See SN 22.22 and also SN 12.61, note 1.) Atta-kāra could
mean that one motivates oneself, or that one acts upon oneself;
para-kāra could refer to the atta-kāra as seen from a third-person
perspective, or to one who acts upon another being or thing. In each
one of these cases, there is necessarily an all-important moment of
initiation of action. As for the
form of the term atta-kārī, which occurs in the title of this sutta,
compare the expression: “yathā-vādī tathā-kārī”, “one who speaks thus,
one who does thus”; or, in other words, “he does as he says”, “he
practises what he preaches” (compare, for example, PTS DN iii.135, AN
ii.24, Sn 359).
Note2: Sayaṃ abhikkamanto: “moving forward by oneself”; sayaṃ paṭikkamanto: “moving backward by oneself”. Sayaṃ means “self; by
oneself”. The example seems to suggest the action of someone who
intentionally takes a step forward, and then intentionally takes a
step back again. This example leads directly to the next statement,
and thus emphasises the idea of initiating an action:
when someone takes a step forward or backward, the origin and impetus
of this action must, so to speak, come from “somewhere” or
“something”. In other words, it really is an intentionally initiated
action (kiriya, kriyā), and not merely the arbitrary mechanical
“effect” of some prior mechanical “cause” in a deterministic chain of
mechanical push-and-pull. The sense, here, can be better understood if
one also consults AN 2.33 (Aññataro Brāhmaṇo: A Certain Brahmin; PTS
AN i.62), where the Buddha describes himself thus: “I am one who
asserts that which ought to be done... and one who asserts that which
ought not to be done.” (“Kiriyavādī cāhaṃ... akiriyavādī cā'ti.”)
There, it is made very clear that doing and non-doing are morally
significant and morally effective. Similarly, in several other suttas,
such as in MN 95 (Caṅkī Sutta; PTS MN ii.164), the Buddha is described
thus: “The venerable recluse Gotama is truly one who asserts the
doctrine of kamma, one who asserts the doctrine of what ought to be
done. . .” (“Samaṇo khalu bho gotamo kammavādī kiriyavādī. . .” (MN
ii.167).) Again, in MN 71 (Tevijjavacchagotta Sutta; PTS MN i.481),
the Buddha humorously recounts that in the last ninety-one aeons, no
ājivaka, or “fatalist” who denies the power of volitional acts, has
ever gone to heaven, except one, who happened to follow the doctrine
of kamma and of morally effective deeds (“sopāsi kammavādī
kiriyavādī”, MN i.483).
Part of Piya Tan's commentary on the Attakari Sutta:
2 Causality and agency
2.1 The Attakari Sutta is a short discourse on causality and agency, and is a clear statement on the efficacy of personal effort. Here,
causality refers to a karmic action we (or anyone) have initiated, and
such an action has karmic consequences. This is only one “link” in a
complex karmic network of multiple causes and conditions. For, all
actions work in concert with other actions, producing a network of
results. This is called conditionality.
2.2 Agency, on the other hand, refers to how an action or set of actions we do affects others. For example, we hear a Dharma talk
(action), and inspired by it, we go on to meditate (result). The
Dharma speaker is an “agent,” so to speak, to our being motivated to
meditate. A better Buddhist explanation is that the agency here is the
teaching (not the person) of the Dharma teacher who motivated us. In
short, it is possible to move others to goodness. It is for this
reason that the Buddha teaches us the Dharma: we can be moved to act
in a way that would transform us into awakened beings.5
2.3 The efficacy of action view (kamma,vāda) is that our present condition is partly the result of our deeds in previous lives. Those
who reject this view, that is, the non-efficacy of action
(akiriyā,vāda), believe that all deeds, past, present or future, have
no effect on the condition of beings. “Thus, in its extreme forms the
[akiriyā,vādi] would say that there is actually no causal connection
between what a living being does and what he is or becomes, in this or
in another life” (Gomez 1975:81 f).
2.4 The teaching on the efficacy of action is mentioned in greater detail in the Sonadanda Sutta (D
4.6), where the Buddha declare himself to be “one who teaches karma, who teaches (the efficacy of) action” (kamma,vādi kiriyā,vādi) (D
4.6/1:115). Similarly, in the Anna,titthiya Sutta (S 12.24), Sāriputta declares to the wanderers that the Buddha teaches the efficacy of
action (S 12.14/2:33 ff). A threefold classification of non-action
(akiriya) in the Titth’āyatana Sutta (A 3.61): our present condition
is all due to our past actions; that it is the result of a god’s
creation; or, that it is by sheer chance (A 3.61.1-4).6
2.5 Strictly speaking, the Atta,kārī Sutta is not about free will, but rather about fatalism. Philosophically, free will can only operate in
a deterministic situation. If we do A, then it always follow that B
will occur. If the situation is indeterministic, we will have no way
of knowing how our actions will result. Fatalism, on the other hand,
is an ethical view that choice is meaningless.
2.6 Makkhali Gosāla’s niyati,vāda is fatalism, which the Buddha rejects because Gosāla claims that purification happens without cause
or condition within the individual (D 2).7 Furthermore, like the
brahmin in the Atta,kārī Sutta, he claims that there is neither human
agency (atta,kāra), nor effort (viriya), nor human exertion
(purisa,parakkama) (id).8 Here, we are dealing with the ethics of what
we can or cannot do.
2.7 As scholars of philosophy, like Asaf Federman, have noted, “The Buddhist rejection of this view is not a rejection of deterministic
theory of causality but a rejection of fatalism.” (2010:13).9 It
should be noted that the Atta,kārī Sutta is not discussing philosophy,
but rejecting the view (especially that of Gosāla and of the brahmin
in this Sutta) purporting or suggesting that we are all fated, so that
no effort possible for spiritual purification and liberation. The
Buddha teaches the contrary: we can help ourselves. Indeed, if we do
not, no one can help us (Dh 160, 380).