Debate algorithm

From Wikiversity
Jump to navigation Jump to search
Graphic representation of a small debate tree, with sustained arguments painted green and refuted arguments painted red.

The debate algorithm (formerly DebateTree algorithm and dialectic algorithm) is a recursive algorithm for computing the status (labeled SUSTAINED or REFUTED) of any argument out of the structure of its debate tree. The algorithm captures the intuitive idea that an argument should be considered refuted when it has unrefuted objections, and sustained otherwise.

This page is aimed at merely describing the algorithm. To read about its usefulness, see the wikidebate here. To learn about the broader context of the algorithm, see the resources here.

Algorithm[edit | edit source]

Animation showing the debate algorithm as the debate tree grows. Notice how the leaves of the tree are always green.

Given a debate tree, the debate algorithm labels each argument as either SUSTAINED or REFUTED based on the following definitions:

SUSTAINED
Without sustained objections
REFUTED
With sustained objections

Considering that objections are also arguments, the algorithm will run recursively until the end of the debate tree (the leaves). Arguments at the end have no sustained objections (indeed, they have no objections at all) so they are labeled SUSTAINED, and the algorithm is then able to solve the status of all the other arguments.

Example[edit | edit source]

Below is an example of a small debate tree, with refuted arguments stroked. The structure of this debate tree is the same as the structure of the graph in this article.

  • Argument Causing unnecessary suffering on animals is morally wrong. Eating or otherwise exploiting animals is unnecessary and causes much suffering. Therefore, eating or otherwise exploiting animals is morally wrong and should be abolished.
    • Objection Non-human animals have no feelings and suffer no pain.
      • Objection Non-human animals behave very similar to us humans under circumstances that would cause us pain: they scream (or produce other loud noises), shake, contort, run, try to avoid the source of pain, etc.
      • Objection Non-human animals, especially mammals and birds, have a nervous system very similar to our own.
    • Objection Animals in the wild suffer more, as starvation and predation is a constant threat to them. For a natural equilibrium, all animal species living in the wild live at the brink of starvation, as an excess of food leads to their numbers increasing, then collapsing.
      • Objection Animals in factory farms suffer guaranteed predation at a fraction of their natural life span. They don't lack food, true, but they are systematically mutilated, exploited, denied of basic freedom of movement, electrocuted, kicked, and many, many, many other atrocities. In traditional farms, animals are denied freedom of movement and reproduction, and also suffer guaranteed predation at a fraction of their natural life span.

Pseudocode[edit | edit source]

The essence of the debate algorithm can be summed up in a simple, beautiful recursive function:

function getStatus( argument )
	let objections = getObjections( argument )
	for each objection in objections do
		if getStatus( objection ) === SUSTAINED then
			return REFUTED
	return SUSTAINED

The function calls itself recursively until it reaches the leaves of the debate tree. The leaves have no objections, so the algorithm returns SUSTAINED for each leaf and from there on solves the status for every other argument in the tree.

An alternative, boolean formulation may be:

function isSustained( argument )
	let objections = getObjections( argument )
	for each objection in objections do
		if isSustained( objection ) then
			return FALSE
	return TRUE

Loops[edit | edit source]

Consider the following exchange:

  • Argument If God existed, then evil wouldn't exist. But evil exists. Therefore, God doesn't exist.
    • Objection Your argument isn't valid because you're tainted by the Devil.
      • Objection That's an ad hominem fallacy.
        • Objection Your argument isn't valid because you're tainted by the Devil.
          • Objection That's an ad hominem fallacy.
            • Objection Your argument isn't valid because you're tainted by the Devil.
              • ...

If each argument is only a copy-paste of the previous one, then this is only a human problem. However, if each argument is a "reuse" of the previous one, then this leads to an infinite loop in the debate algorithm.

The possibility of such loops increases when extensions are incorporated, since reusing a single premise is more likely than reusing an entire argument.

Extensions[edit | edit source]

In the basic debate algorithm, the inner structure of the arguments is ignored. It's possible however to give the arguments some structure according to well known logical theories, and extend the debate algorithm into the new structure.

For example, using the terms "sound", "valid" and "true" in non-standard ways:

function isSound( argument ) {
	if not isValid( argument ) then
		return FALSE

	let premises = getPremises( argument )
	foreach premise in premises do
		if not isTrue( premise ) then
			return FALSE

	return TRUE
}

function isValid( argument ) {
	let objections = getObjections( argument )
	foreach objection in objections do
		if isSound( objection ) then
			return FALSE
	return TRUE
}

function isTrue( premise ) {
	let objections = getObjections( premise )
	foreach objection in objections do
		if isSound( objection ) then
			return FALSE
	return TRUE
}

The algorithm can be further extended to calculate the truth value of each premise out of its propositional structure in the standard ways, and perhaps even out of its first-order structure.

Implementations[edit | edit source]

Wikidebate is currently the only site that features the debate algorithm. The logo evokes a debate tree.

The first implementation of the debate algorithm was Formal Forum, a debate site that featured a propositional extension of the algorithm and encouraged premise reuse. Loops where avoided by automatically checking for them before every submission. However, the creator felt this was only a patch that would only get worse over time and with further formalization, so decided to close the forum.

Currently, the debate algorithm is available in the Wikidebate project. By clicking on the "Calculate status" button on any wikidebate (live example), the algorithm is run for every argument in the debate and arguments are colored according to their status. There's a wikidebate about the usefulness of the algorithm for the project and the wikidebate guidelines include some instructions on how to draw conclusions out of debates using methods akin to the debate algorithm. However, partly due to limitations in wiki software, every extra step in the formalization makes it harder for new users, so for now wikidebates incorporate only the most basic form of the algorithm (no extensions).

See also[edit | edit source]