Team Semantics for Interventionist Counterfactuals: Observations vs. Interventions

Team semantics is a highly general framework for logics which describe dependencies and independencies among variables. Typically, the (in)dependencies considered in this context are properties of sets of configurations or data records. We show how team semantics can be further generalized to support languages for the discussion of interventionist counterfactuals and causal dependencies, such as those that arise in manipulationist theories of causation (Pearl, Hitchcock, Woodward, among others). We show that the “causal teams” we introduce in the present paper can be used for modelling some classical counterfactual scenarios which are not captured by the usual causal models. We then analyse the basic properties of our counterfactual languages and discuss extensively the differences with respect to the Lewisian tradition.


The Goal of the Paper
We shall introduce a logical framework which can express both functional and (interventionist) counterfactual dependence. The former is an "accidental" correlation formally defined in terms of the existence of a functional correspondence between the relevant variables. The latter is a more robust correlation expressed by a family of special conditionals whose antecedent is made true by an intervention. In order to express both kinds of dependence we shall merge two existing approaches: a) team semantics, a framework developed recently for the purpose of analyzing the interaction of functional dependence with logical constructs [4,12,14,23,30,40]; and b) causal models, a popular framework which analyses causal dependencies in terms of structural equations relating appropriately chosen variables [15,17,20,32,33,38].
The main notion which emerges from the combination of the two approaches is that of a causal team (Section 2). Essentially, a causal team is a team, defined as a set of assignments over a given collection of variables, expanded with a collection of structural equations associated with some of its variables. Due to its team component, a causal team will be able to account for functional correlations, which are the basis of some of our evidential, observational reasoning; and due to its structural equations component, a causal team will be able to support counterfactual claims. We will define two operations on causal teams which will allow us to capture the difference between these two types of reasoning, each corresponding to one kind of conditional. The first operation consists of restricting a causal team to a subteam whose assignments satisfy a given formula of the language. It allows us to define a conditional, which we call selective implication, which generalizes material implication. The second operation is that of an intervention on a causal team, which leads to a new causal team whose assignments satisfy a given formula. This will be used to define (a generalization of) interventionist counterfactuals. These two operations, which are given a model-theoretic treatment, will be the main ingredients in the definition of "ϕ is true in T " where T is a causal team and ϕ is a formula of the object language. The focus of the paper is on the cases in which ϕ expresses a functional correlation or an interventionist counterfactual, possibly conditional on observations. We think that the presence of both selective and counterfactual conditional makes the underlying language more adequate than alternative formalisms (e.g. Pearl's) for expressing arguments involving causal claims where both types of reasoning are present, e.g.
On occasions where p, in fact, was not the case, q would have accompanied it, had p been the case (von Wright, [43], p. 26).
The probability Q that a subject who died under treatment would have recovered had he or she not been treated is epsilon (Pearl,[32], p. 20).
The model-theoretic analysis of interventions and interventionist counterfactuals is not new in the literature. Similar treatments, with variations in the details, may be found in e.g. [3,11,16,49]. More recent work made use of interventionist counterfactuals as an ingredient for the study of counterfactuals in natural language [8,35,36] and for the study of actual (token) causation [15,17,20]. However, the expression of the three kinds of dependencies, functional, counterfactual, and observational in one single framework is, to the best of our knowledge, unique in the literature, and it would not be possible without the additional dimension of team semantics. It allows us to investigate some of the logical rules that connect these forms of dependence and to highlight some central differences among them. One major difference appears in their behaviour with respect to interventions, that is, their "stability" or "invariance". Causal teams will be seen (Section 5) to provide a nice illustration of this difference.
As we said, one of the advantages of causal team semantics is that it supports a richer class of languages than both causal models and team semantics. A natural question is then whether causal teams bring something new also in the context of traditional (interventionist) counterfactual languages. In one sense, the answer is no: the logic of such languages coincides (modulo minor details) with that which arises over causal models (see Section 4.1 and Appendix C). On the other hand, we observe that moving from causal models to causal teams seems to be a necessary step in order to model, in an interventionist spirit, some counterfactual scenarios that arise from the literature; we consider two such examples in Section 3.
Finally, let us mention one more goal of the paper. Even though the axiomatics of both the Lewis-Stalnaker and the interventionist counterfactuals are well-enough understood, it seems to us that a thorough comparison of the two counterfactual logics is still missing. We will advance this enterprise by furthering the investigation -initiated in [3] -of which Lewisian laws fail for nested interventionist counterfactuals (Section 4.2); and clarify to what extent some non-Lewisian laws (permutation, importation and exportation) are sound for interventionist counterfactuals (Section 4.3).
A summary of some of the ideas presented in the paper appeared in conference proceedings [2], but the present paper largely extends those ideas in both scope and depth. The omitted details of some of the proofs can be found in the Arxiv draft [1].

Background
In the philosophical literature (Goodman, Stalnaker, D. Lewis, G. H. von Wright, among others) one increasingly finds evidence that robust causal relationships are conceptually related to counterfactual assumptions. However, the exact nature of this connection is still much debated. Some authors claim that this relationship is a form of reduction: for example, D. Lewis in [28] claims that causation can be defined in terms of an appropriate form of counterfactual dependence, which is in turn definable in non-causal terms. In Pearl [32] the direction of the reduction is reversed 1 : interventionist counterfactual statements are assigned a meaning in terms of basic causal assumptions, which are encoded by structural equations. This picture is made more complicated by the observation that more sophisticated notions of cause are then definable in terms of the counterfactuals (see [21,45]); and by Hitchcock's observation that a structural equation can be seen, in turn, as encoding a set of counterfactuals. The approach we follow here is closest to Pearl's treatment of structural equation models, which we now shortly review.
The definition of a structural equation model (SEM) presupposes the choice of two disjoint sets of variables: a set V of endogenous variables and a set U of exogenous variables. The latter will represent factors whose causes are not further analysed. 2 To 1 The idea that causal assumptions are parts of the semantic definition of counterfactuals also underlies some recent developments of premise semantics: see [8,26,36,42]. 2 The word "exogenous" is sometimes used in the literature with different meanings, for example to denote unobserved variables. To appreciate the difference, consider the hour displayed on a clock: it is an observable variable, but we may treat it as exogenous if we omit from the model any description of the internal mechanisms of the clock. An unobserved variable, instead, might be used to mark an hypothetical internal component of the clock that is involved in the calculation and display of the hour. We do not discuss unobserved variables in the present paper. each endogenous variable X ∈ V, an equation of the form is associated, where the variables in the set PA X ⊆ (U ∪ V) \ {X} are called the parents of X. The standard interpretation of a functional equation X := f X (PA X ) is that of a law which specifies a value of X for any possible combination of the values of PA X . The explicit specification of the function has the advantage of indicating which changes in PA X will change X and by how much, something which turned out to be useful in formulating various notions of cause [20,32,44].
To each system of equations is associated a directed graph, which summarizes the causal dependencies among variables. A (directed) graph is a pair G = (V, E), where V is called the set of vertices and E ⊆ V × V is the set of arrows. The directed graph which is associated to the given system of structural equations has as vertices the variables of the system (i.e. U ∪ V); and it contains an arrow from vertex X to vertex Y if and only if X ∈ PA Y .
We can illustrate these definitions with an example. It is originally due to Daniel Hausman [18] but here we shall present a simplified version borrowed from Woodward [45]. The example is about a salt solution which flows through pipes and mixed chambers. The concentration of salt in each chamber measured by the variables X 1 , . . . , X 4 depends on the upstream chambers to which it is connected, according to the following equations 1. X 2 = aX 1 2. X 3 = bX 1 3. X 4 = cX 2 + dX 3 .
The system of equations induces the following graph where, as we see, X 1 is the only exogenous (independent) variable, that is, a variable with no incoming arrows, and X 2 , X 3 and X 4 are endogenous (dependent) ones. Implicit in the specification of the arrows of a graph through a system of structural equations, there is also a very natural means to compute the effect of assuming the antecedent of a counterfactual conditional. This operation, called an intervention, takes now the form of a transformation of the relevant set of structural equations. There are several notions of interventions on the market, but the one which is closest in spirit to the definition that will be given in this paper is due to Pearl. According to it, an intervention consists in lifting X from the influence of the old functional mechanism X = f X (PA X ) and placing it under the influence of a new mechanism that sets the value x while keeping all other mechanisms undisturbed. ( [32], p. 70; we changed notation).
In other words, an intervention do(X = x) on a variable X is an operation which replaces the equation for X with a new equation X = x while preserving the equations associated with the other variables intact.
In our example, if we intervene on the endogenous variable X 2 and set its value to 1 (i.e., do(X 2 = 1)), the result will be the altered system of equations which induces the new graph: Typically a structural equation model is further enriched with a description of the state of the exogenous variables, which may take the form either of a full specification of their actual values (deterministic SEM), or of a probability distribution (semideterministic SEM). To give an example of the former, we might stipulate that the actual value of the exogenous variable X 1 in our example is some number m. Then, due to the acyclicity of the graph, the system of equations (1)-(3) uniquely determines values for the endogenous variables: X 2 = am, X 3 = bm and Z = cam + dbm. If we now perform the intervention do(X 2 = 1), then, X 2 depends no more on X 1 and its value becomes 1 (i.e. in Pearl's terms X 2 has been "lifted from the influence of the old mechanism X 2 = aX 1 "). After the intervention, the values of the other endogenous variables X 3 and X 4 must be recomputed using the value X 1 = m and the new value X 2 = 1, thus obtaining X 3 = bm and X 4 = c + dbm. This computation may be summarized by stating that the (interventionist) counterfactual holds in the state where X 1 takes value m. We take note of the fact that after the intervention do(X 2 = 1), the two other equations of the system, (2) and (3), have remained unaltered, a property referred to in the literature as modularity.

From Teams to Causal Teams
Team semantics was introduced by W. Hodges [23,24] in order to provide a compositional interpretation of the (game-theoretically defined) semantics of Independence-Friendly logic [19,30]. It has subsequently been used to extend first-order logic with database dependencies (e.g. Dependence logic [40], Independence logic [14], Inclusion logic [12]), and similar extensions have been proposed for propositional logics [47,48] and modal logics [41]. Generalizations of teams have been used as descriptive languages for probabilistic dependencies [10], for the expression of quantum phenomena [25], and for the modelisation of Bayesian networks [9].
The basic idea of team semantics is that notions such as dependence and independence, which express properties of relations (instead of individuals), cannot be captured by Tarskian semantics, which evaluates formulas on single assignments 3 . The appropriate unit for semantic evaluation is instead the team, i.e., a set of assignments (all sharing a common variable domain). In our context, a team can be seen as a description of the configurations that are available in a given system of variables; or, under an epistemic interpretation, as a description of our uncertainty over the actual configuration of the system.
In the most common versions of team semantics, all the values of the variables come from a unique domain of individuals associated with an underlying model. However, in order to model causal and counterfactual dependence, we shall need to relax that assumption. Instead we shall take variables to represent properties which may have all kinds of values (as specified by their range). In many applications, we will deal with propositional variables whose range is {0, 1}. By a signature σ we will mean a pair (Dom, Ran), where Dom is a nonempty finite set (whose elements will be called variables) and Ran is a function that associates to each variable X ∈ Dom a nonempty finite 4 set Ran(X) of values (the range of X). An assignment of signature σ will be a mapping s : Dom → X∈Dom Ran(X) such that s(X) ∈ Ran(X) for each X ∈ Dom. A team T of signature σ will be any set of such assignments.
Here is an example of a team T = {s 1 , s 2 }, with Dom T = {X, Y, Z} and range {0, 1} for each variable: X Y Z s 1 0 0 0 s 2 1 1 0 It is worth noting that such a special "Boolean" team (with binary range for each variable) can as well be identified with a possible-world model, in an obvious way.
The basic semantic relation is T |= ψ: the team T satisfies the formula ψ, where ψ is a formula of a formal language to be fully specified later. We are particularly interested in formulas called dependence atoms which express the existence of a functional dependency among variables. The semantics of such dependence atoms is given by expressing that Y is functionally determined by {X 1 , . . . , X n }. Thus, in our example, it holds that T |==(X; Z) but T |==(Z; X). In the special case that n = 0, we simply write =(Y) for =(; Y) and call it a constancy atom; notice that T |==(Y) if and only if Y takes the same value in all the assignments of T − .
As explained earlier, a proper treatment of causal notions requires an account of counterfactual information that is customarily encoded by structural equations. A team, by itself, encodes no counterfactual information at all; it does not tell how intervening on a variable will affect the whole system. A "causal team" will have to encode in some way the laws that link together the variables of the system. To exemplify this point, consider a system with two variables, related by the structural equation Y := X, which amounts to saying that, whenever X comes to take a specific value x, then also Y comes to take value x, as can be ascertained by applying the identity function to x. Under the assumption that the values 0,1 are in the ranges of X and Y, the following assignments are compatible with the equation: The arrow from X to Y is drawn to underline the equational dependence of Y on X. Notice that this team satisfies two functional dependencies: = (X; Y), which is specified by the appropriate structural equation, and =(Y; X), which goes in the opposite direction, but is not so specified. Dependencies of this latter kind turn out to be contingent, in the sense that they can be disrupted by some interventions. We will see a few such examples throughout the paper; see in particular Example 2.7 at the end of Section 2.4.
We now extend teams with structural equations by defining "causal teams"; later, in Section 2.4, we will define the notion of intervention on a causal team. 5 We use boldface letters, e.g. X (resp. x) to denote sets of variables (resp. sets of values).
is a graph over the set of variables. For any X ∈ Dom T , we denote as PA X the set of all variables Y ∈ Dom T such that the arrow (Y, X) is in E. We require the graph to be irreflexive, i.e. not to have arrows of the form (X, X).
which satisfies the further consistency constraint: The functional component F T induces an associated system of structural equations, say one equation The graph associated to this system of structural equations is G T . The variables in Dom T \ V will be called, as usual, exogenous.
Clause (*) ensures that the team component satisfies the functional dependencies encoded in F T . It further entails a compatibility condition between the team and the graph component: Notice also that our previous (slightly nonstandard) definition of team entails a compatibility condition between the team and the range components; writing T − (X) = {s(X) | s ∈ T − } for the set of values that X takes in the assignments of In this paper we restrict attention to causal teams T whose associated graph G T is acyclic; such causal teams will be called recursive. 6 A discussion of the developments beyond this restriction can be found in [2].

Example 2.2
We illustrate the previous definition by exhibiting a causal team which captures a "coin tossing" scenario. This is just a toy model, but we will return to the issue of coin tossing in Section 3, as it relates to some famous example discussed by Lewis. Let us say that you toss a coin, and if it comes up heads, you win; otherwise you lose. First we have to decide what variables are relevant for the description of this scenario. We choose the following: Notice first that the pair σ = (Dom, Ran), where Dom = {T, C, W} and Ran is the function associating to each of these three variables the range described above, is a signature.
We can now for example describe all possible configurations of this system by the following causal team T of signature σ: T : Each row of the table describes, in an obvious way, an assignment of T − . The arrows between variables are the edges of G T . They tell us that U and C are exogenous variables, while W is a function of both U and C. We still have to describe this function. From our narrative, it should be clear that the variables are related by one structural equation: W := 1 if and only if U = 1 and C = h; and 0 otherwise. We encode this in the causal team by stipulating that F T (W) is the function that returns 1 when U is 1 and C is h; and returns 0 otherwise.
We might instead be only interested in modelling the case in which you really toss the coin. This scenario is represented by the smaller team S : Notice that, in this smaller team, the state of the coin (C) determines whether you win or not (W), that is, the dependence atom =(C; W) is true in S . This was not the case in the larger team T .

A Basic Language and its Semantics
Before discussing interventions and counterfactuals, we need to specify what it means for a causal team to satisfy atomic formulas and their boolean combinations. Let us fix a signature σ = (Dom, Ran). Assuming X, Y ∈ Dom and y ∈ Ran(Y), the kind of language we consider, for now, contains dependence atoms of the form =(X; Y), with X, Y ∈ Dom; atomic formulas of the forms Y = y and Y = y, where Y ∈ Dom and y ∈ Ran(Y); connectives ∧ and ∨. Formulas without occurrences of dependence atoms will be called classical. We take Y = y to mean: the value of the variable Y is y. Notice that here, in order to reduce the weight of notations, we are identifying the letter Y, used as a symbol of the object language, with the variable Y ∈ Dom; and y, used as a symbol of the object language, with the object y ∈ Ran(Y) that it is meant to denote. This convention is usually followed in the literature on structural equation models, and is typically not a source of confusion. 7 We assign to these formulas semantic clauses which are standard in the literature: The disjunction ∨ will be treated as what is sometimes called "tensor" or "splitjunction"; its semantic clause requires the notion of causal subteam. 7 If needed, syntax and semantics can be kept strictly separated in a straightforward way. It suffices to specify two disjoint sets of variables (say, the set Capital of Y i s and the set S mall of y i s) and add to the definition of causal team an interpretation function I which associates to each variable in Capital a variable in Dom, and to each variable in S mall a value in Ran. Then formulas Y = y and Y = y are part of the language in case Y ∈ Capital, y ∈ S mall and I(y) ∈ Ran(I(Y)); the truth condition, say, for formula Y = y over team T will then be "for all s ∈ T − , s(I(Y)) = I(y)". Definition 2.3 Given a causal team T , a causal subteam S of T is a causal team with the same domain and the same set of endogenous variables, which satisfies the following conditions: Under the epistemic interpretation of teams, the transition from a team to a subteam reflects an increase in our knowledge of the actual state of the system, given that fewer configurations (assignments) are considered possible.
-T |= ψ ∨ χ if and only if there are two causal subteams T 1 , T 2 of T such that T − 1 ∪ T − 2 = T − , T 1 |= ψ and T 2 |= χ. 8 The tensor disjunction extends classical disjunction, in the sense that, over a causal team with singleton team component, it respect the usual Tarskian clause (T |= ψ ∨ χ if and only if T |= ψ or T |= χ).
The next two subsections are devoted to extending the basic language with two additional conditional operators. Section 2.5 will summarize the syntactical details of the resulting language.

Selective Implication
In the literature, counterfactual statements often appear embedded in a context which describes facts or observations. We have seen (Section 1.1) that von Wright ( [43]) considers examples of the form "on occasions where p, in fact, was not the case, q would have accompanied it, had p been the case". Pearl ([32]) analyses queries of the form: "the probability Q that a subject who died under treatment (X = 1, Y = 1) would have recovered (Y = 0) had he or she not been treated (X = 0) is epsilon". We will represent this statement as: where the symbol stands for counterfactual implication, while the selective implication ⊃ indicates a restriction of the range of application of the statement to the available evidence; that is, it asserts the truth of the consequent in the subteam generated by those assignments which satisfy the antecedent. 9 The probabilistic atom describes a probability which is relative to the specific team which is produced during the evaluation of the formula, i.e., the initial team restricted to assignments which satisfy X = 1 ∧ Y = 1 and further intervened upon by setting X to 0.
Given a causal team T , and a classical formula ψ (that is, a formula as in sub-Section 2.2, but without dependence atoms), we define the subteam T ψ of T by the condition: 8 Defining the union of any pair of causal teams sharing the same domain may lead to some problems, as the information encoded by the invariant functions of one team might be incompatible with the information encoded by the other. 9 The semantics of probabilistic atoms can be found in [2], while a proof of the correctness of this decomposition is available in the Arxiv preprint [1], sec. 6.3; it is part of an intended continuation of this paper.
where we abuse notation (as will be done elsewhere in the paper) by using {s} to denote the causal subteam S such that S − = {s}.
Then, we define 10 selective implication by the clause: The consequent χ can be any formula of our current logical language, including formulas which do not denote properties of single assignments. The underlying idea behind the restriction for the antecedents to be classical is that selective implication is a reasonable operator only for antecedents that are flat formulas, in the sense with which this word is used in the literature on logics of dependence. (Roughly, it means that asserting the truth of the formula over a team amounts to asserting its truth over each assignment of the team). Later on in Section 2.5 we will also allow for antecedents with occurrences of interventionist counterfactuals (which will turn out to be flat). Selective implication generalizes material implication in the sense that, over causal teams with singleton team component, it respects the usual Tarskian clause (T |= ψ ⊃ χ if and only if T |= ψ or T |= χ).

Example 2.4
For an illustration, let us look back at the teams T, S considered in Example 2.2. S was obtained by selecting the assignments in which the variable U ("whether the coin is tossed") takes value 1; therefore, S is none other than T U=1 . We have pointed out that S |==(C; W), i.e., T U=1 |==(C; W). Then, by the clause for ⊃, we may conclude that T |= U = 1 ⊃=(C; W). In other words, the information encoded in T agrees with the statement that "In case the coin is tossed, the outcome of the the tossing completely determines whether I win".

Interventions on Causal Teams
The semantic interpretation of (interventionist) counterfactual implication requires, as pointed out, the notion of intervention on a causal team. Informally, the idea is that a counterfactual X = x ψ is true in the causal team T if ψ is true in the causal team which results from an intervention do(X = x) on the team T .
We start by discussing the motivation behind this notion. Perhaps the best way to proceed is by referring first to the notion of intervention do(X = x) in which a single variable X is set to a particular value X = x in the structural equations framework. In our introductory section, we have seen that such an intervention amounts to replacing the equation X = f X (PA X ) with the new equation X = x. In the graph corresponding to the system of equations, the intervention X = x breaks all the arrows directed into X but leaves intact the arrows going out of X.
In the context of causal teams, there is one additional complication due to the fact that a causal team is a triple T = (T − , G T , F T ). An intervention, say do(X = x), is, roughly, an operation on T which affects all the three ingredients of the team, resulting in a new causal team. The modification of F T and G T goes exactly as in the case of the structural equation framework, described in Section 1.2. The new element is the specification of the way in which the team T − is affected. It will take the form of an algorithm, which ensures that the resulting team matches with the modified system of equations. Before defining it, we give an example. This is a purely numerical example, whose main purpose is to illustrate the complexities involved in the computation of the effects of an intervention. There are card(Ran(A)) × card(Ran(B)) = 2 × 3 = 6 assignments compatible with these equations; we include in our team T only the three assignments depicted below. We want to understand what new causal team is produced by the intervention do(B = 2) which fixes B to the value 2. In any case, all assignments in the new team should satisfy B = 2: T: The picture also reflects our expectation that, since A is not a descendant of B in the graph, the A-column should be unaffected by the intervention. On the other side, the variables C and D are descendants of B, and must therefore be updated using the functional component F T of the causal team.
We cannot first update the D-column, because D is determined as a function of A, B and C, which requires that we first compute the values of C := f F (B): Finally, we update the D column and we obtain the team T B=1 : Notice that the correct value for D in the first row might have been read directly from the first row of T ; computing the correct value in the second row, instead, essentially requires using the function component of the causal team. Now the team T B=2 satisfies C = 1; we conclude that the initial causal team T satisfies the counterfactual B = 2 C = 1. This example also illustrates the way in which some functional dependencies may be merely contingent: T satisfies =(B; D), but the intervention do(B = 1) destroys this dependence.
Until now we only considered an intervention over an exogenous variable; such an intervention preserves the graph component of the causal team. Consider now the intervention do(D = 0): The resulting team has a much simpler graph, given that the intervention removed all the arrows that come into to D (and, correspondingly, the function F T (D)).
The example showed how we can produce algorithmically the causal team generated by the intervention do(X = x) on the causal team T . 11 This was possible due to T being recursive, i.e., its graph component being acyclic. We will stick to this assumption throughout the paper, with the exception of Section 3.2.
More formally, an intervention do(X = x) on a recursive causal team T = 12 2. The graph G (T ) is induced by F T (X) (i.e., the incoming arrows to X are removed) 3. The team (T X=x ) − is produced in stages: we first replace each assignment s ∈ T − with s(x/X) and then compute how this replacement affects the descendants of X in G (T ) using the functions in F T . 13 The exact formulation of the algorithm in 3. requires, as the example showed, the introduction of a distance d(X, Y) between X and the other variables Y ∈ Dom T . The idea behind this notion of distance is that, if there is a path of length n from X to Y, then Y is at least at distance n from X; the details can be found in Appendix A. We only need the following crucial property of the distance (which holds in finite acyclic graphs): Here is the algorithm: -At stage 0 we produce the team T 0 by replacing each assignment s ∈ T − with s(x/X). -At stage n+1 we produce the team T n+1 by updating the variables Y such that d(X, Y) = n + 1. This happens by replacing each assignment s ∈ T n with the assignment s which is identical to s except that s assigns to every such Y a unique value ). -The procedure ends at stagê Stage n + 1 is correctly defined thanks to property (R), which guarantees that all the values of variables in PA Y have already been recomputed (if needed) in earlier stages of the algorithm.
The same algorithmic procedure can be generalised to the case of simultaneous interventions over multiple variables. We will write X = x for a generic conjunction of the form X 1 = x 1 ∧ · · · ∧ X n = x n , and we will say that such a conjunction is consistent if it does not contain two conjuncts X i = x i , X i = x i with x i = x i (and inconsistent otherwise). If X = x is a consistent conjunction, we will write do(X = x) for the intervention that fixes each variable X i to the corresponding value x i . In this case the distance d(X, Y) will have to be reformulated appropriately, as shown in the Appendix.
Given the acyclicity and finiteness of the graph G T , it is straightforward to show that this algorithm terminates (even in case T − is infinite).

Theorem 2.6 Let T be a recursive causal team. If G T is a finite acyclic graph, then T X=x is well-defined.
See Appendix B for the proof. Having defined the causal team T X=x , we are in the position to formulate the semantic clause for counterfactuals of the form X = x ψ: If the antecedent is inconsistent (i.e., it contains two conjuncts , the corresponding intervention is not defined; in this case, we postulate the counterfactual to be (trivially) true.
We may now vindicate our earlier claim that functional dependencies which are not backed up by structural equations can be disrupted by interventions.

Example 2.7
Consider again the causal team T with two boolean-valued variables X and Y, related by the structural equation Y := X (i.e. F T (Y)(x) = x for each x ∈ Ran(X)) and with assignments as in the table: As already observed, this team satisfies both the dependency = (X; Y), which is required for compatibility with the structural equation, and the dependency =(Y; X), which is not supported by the structural equations. When we intervene on the system by fixing Y to value 1, a new table is produced: This team, manifestly, does not satisfy the dependency =(Y; X) anymore. Notice also that, although we have removed the arrow in order to specify that the value of X is not anymore needed to reconstruct the value of Y, the dependency =(X; Y) still holds. This latter dependency is logically implied by the constancy of Y, =(Y), which also holds in the new table.

Logical Languages
Having defined all the main logical operators that we consider in this paper, we move now to the definition of some languages.
For a fixed signature σ = (Dom, Ran), we call counterfactual-observational language of signature σ, CO(σ), the language formed by the following rules: for Y, X ∈ Dom, y ∈ Ran(y), x ∈ Ran(X), ψ, χ formulas of CO(σ). We will often simply write CO, omitting reference to the specific signature. The semantics for this language is given by the clauses specified in the previous subsections. Notice that the clause for ψ ⊃ χ is still well defined now that occurrences of ⊃ and are allowed in the antecedent and consequent. We will refer to the sublanguage of CO(σ) without the symbol ⊃ as the language C(σ).
We will call COD(σ) the language (extending CO(σ)) which is formed by the following rules: for Y, X ∈ Dom, y ∈ Ran(y), x ∈ Ran(X), ψ, χ formulas of COD(σ), and, importantly, θ is a formula of CO(σ) (we do not allow dependence atoms in the antecedent of a selective implication).
We will be interested every now and then also in languages that contain an additional connective , called Boolean disjunction. 14 In general, given a language L, we denote by L its extension with . The semantics of this operator is given by: Like the tensor, also the Boolean disjunction behaves classically over causal teams with singleton team components. In general, though, its behaviour is nonclassical. 15 We now list three global properties of the languages introduced so far. 16 Theorem 2.8 The logic COD is downwards closed, that is: if ϕ ∈ COD , T is a recursive causal team, T is a causal subteam of T , and T |= ϕ, then also T |= ϕ.
Proof By induction on the syntactical structure of ϕ. The propositional and atomic cases are routine. For the case of dependence atoms, simply observe that, if T |== (X; Y), then there are s, s ∈ (T ) − such that s(X) = s (X) and s(Y) = s (Y). But then these two assignments are also in T − , from which T |==(X; Y) follows. Suppose T |= ψ ⊃ χ. Then by definition T ψ |= χ. Now (T ) ψ ⊆ T ψ ; therefore, by the inductive hypothesis, (T ) ψ |= χ. Thus, by the semantic clause for selective implication, T |= ψ ⊃ χ.
Suppose T |= X = x χ. Then by definition T X=x |= χ. But since the algorithm do(X = x) acts on each assignment separately, we can conclude that ( Under the epistemic interpretation of teams, closure under causal subteams expresses the fact that the properties of the system which are expressible in COD remain stable under our increase of knowledge about the actual state of the system.

Theorem 2.9
The logic COD has the empty team property, that is: for every ϕ ∈ COD , ∅ |= ϕ. Here ∅ denotes any recursive causal team with empty team component.
Proof By induction on the syntax of ϕ. The new cases are those for ⊃ and (and the case for , which is trivial).
Let ϕ be ψ ⊃ χ. Notice that ∅ ψ = ∅. By the inductive hypothesis, Let ϕ be of the form X = x χ. Any do algorithm, applied to ∅, produces a causal team with empty team component (call it ∅ ); therefore, by the inductive hypothesis, ∅ X=x = ∅ |= χ. Thus, by the semantic clause for counterfactuals we obtain ∅ |= X = x χ.
We can show that the language CO (and thus also C) satisfies a condition that is much more restrictive than downward closure: flatness. Here and in the following, we will often abuse notation and write, say, {s} for a causal team T whose support T − contains the single assignment s; the context will make clear what are the other components of this causal team. We will then write {s} X=x for the causal team T X=x , and so on.

Theorem 2.10
The logic CO over causal teams is flat, that is: for every formula ϕ of CO and every recursive causal team T , T |= ϕ iff {s} |= ϕ for every assignment s ∈ T − . Proof By induction on the complexity of ϕ. The cases related to propositional connectives are routine. We only have to check the cases of ϕ = X = x χ and ϕ = ψ ⊃ χ.
Case ) Suppose first that T |= X = x χ, with χ flat. Then, by the semantic clause for counterfactuals, T X=x |= χ. By flatness of χ, {t} |= χ for each t ∈ (T X=x ) − . Now, notice that, for all s ∈ T − , {s} X=x is a singleton causal team (see the details of the do algorithm) and its unique assignment is an element of (T X=x ) − . Therefore, by the remarks above, {s} X=x |= χ for each s ∈ T − ; so, by the semantic clause for counterfactuals, {s} |= X = x χ for every s ∈ T − . In the other direction, suppose {s} |= X = x χ for every s ∈ T − . Then for every s ∈ T − , {s} X=x |= χ. Again, any such causal team is a singleton set, say {s} X=x =: {t s }. But notice that, if t is any assignment in (T X=x ) − , then t = t s for some s ∈ T − . So we can apply the inductive hypothesis and conclude that T X=x |= χ. Therefore T |= X = x χ. Case ⊃) Suppose T |= ψ ⊃ χ, with ψ, χ flat. Then, by the semantic clause for ⊃, T ψ |= χ. By the induction hypothesis, Vice versa, suppose {s} |= ψ ⊃ χ for all s ∈ T − . Let s ∈ T − be such that {s} |= ψ. Then {s} ψ = {s}; our assumption then yields {s} |= χ. Since χ is flat, we can conclude that T ψ |= χ. So T |= ψ ⊃ χ.
We emphasise once more that, unlike in similar results for team semantics (see e.g. [40]), the truth of a flat formula in a causal team based on a singleton team uses, through structural equations, information that goes beyond that which is encoded in the single assignment of the team. A singleton causal team can be identified with a structural equation model (see Section 1.2) enriched with a description of the "actual" state for all variables in the system. From this perspective, a consequence of the flatness result is a kind of conservativity of the causal team semantics over the structural equation modelling of recursive systems. As long as one works within a sufficiently poor (i.e. flat) language, the truth of a formula in a causal team can be reduced to its truth over (a collection of) enriched structural equation models. However, as soon as non-flat language components such as dependence atoms or Boolean disjunction are introduced, structural equation models become insufficient, and causal teams are needed. Indeed, it is easy to build counterexamples to flatness using these components. The constancy atom = (X) is true over any causal team whose support is a singleton; but it is false e.g. over the team S = {{(X, 0)}, {(X, 1)}}. The disjunction X = 0 X = 1 is true over both singleton teams S X=0 and S X=1 , yet it is false in S .

Dual Negation
We can extend our language CO (resp. C) with the dual negation ¬ interpreted by the following semantic clause: 17 It is immediate to extend the proof of Theorem 2.10 to show that the language CO extended with dual negation is still a flat language (which further entails that it is also downward closed and has the empty team property).
Once we have the dual negation in the language, we can show that the selective implication ψ ⊃ χ is equivalent, like its classical relative, to ¬ψ ∨ χ. The argument, which requires 1) downward closure and 2) flatness of the antecedent, goes like this: by the semantic clause for the tensor, T |= ¬ψ ∨ χ holds if and only if there are S 1 , S 2 causal subteams of T such that S 2 |= χ and, for all The existence of such a partition of T proves that T |= ¬ψ ∨ χ.
It is easy to find examples of languages that are not downward closed, e.g., by adding a contradictory negation, the independence atoms X ⊥ Y proposed in [14], or probabilistic statements. For these kinds of logics the above synctactical definition of selective implication is in general incorrect. However, ψ ⊃ χ is usually still definable, in non-downward-closed logics, by the more complex formula ¬ψ∨(ψ∧χ) (see [13]).
The dual negation ¬ϕ of a CO formula ϕ can be expressed in the language CO itself. That is, for every CO formula ϕ, we can produce a CO formula ϕ d , called the dual of ϕ, such that for any causal team T we have: The formula ϕ d is obtained by the following syntactical transformations: Then we have: Theorem 2.11 (Duality) Let T be a causal team and ϕ ∈ CO. Then T |= ϕ d iff T |= ¬ϕ.
Proof By induction on the syntactical complexity of ϕ ∈ CO. We consider the least obvious cases. Let ϕ = ψ ⊃ χ. Then we have the following equivalences: This Theorem, together with our earlier remarks about the definability of ψ ⊃ χ by ¬ψ∨χ, entails that the selective implication is definable in the CO language by ψ d ∨χ.
In other words, we could have adopted as our basic language the smaller language C. Given the significant role that the selective implication plays in our developments 18 we prefer to stick to the CO language.
We wish to point out two more properties of the dual negation.

Theorem 2.12 (Complementarity) Let T be a causal team, ϕ ∈ CO, and S
Proof By induction on the syntactical complexity of ϕ ∈ CO. We consider the least obvious cases.
The proof is a simple induction on the syntax. The dual negation ¬ must be contrasted with the (team-theoretical) contradictory negation: -T |=∼ϕ ⇐⇒ T |= ϕ Languages with contradictory negation are neither flat nor downward closed, and they also lack the empty team property. Contradictory negation usually increases considerably the expressive power of a language, but we shall not be concerned with it in the present paper.

Causal Teams as a Modeling Tool
In the present section we will show, by exhibiting two case studies, that causal team semantics allows for richer modelling possibilities than its special case, structural 18 Especially for extensions to probabilistic reasoning, as sketched in [2]. equation modelling. In particular, we point out that some counterfactual scenarios considered in the literature on Lewis-Stalnaker counterfactuals essentially require causal teams (with more than one assignment) if we want to treat the conditionals as interventionist counterfactuals.
The first example is a simple coin-tossing scenario considered by Lewis in connection with a controversy about two Stalnakerian principles: In the second subsection we show how to model a counterexample to the Lewis-Stalnaker interpretation of counterfactuals that was proposed by McGee. It turns out that the counterfactuals involved in the example are correctly evaluated in a nonrecursive causal team, whose structural equations plausibly do not have a causal interpretation. In this example, although the "actual world" seems to be captured by a deterministic SEM (i.e. by a causal team with exactly one assignment), the process of evaluation of counterfactuals inevitably produces causal teams with more than one assignment.

Lewis's Coin Tossing
In his critique of the conditional excluded middle and consequent distribution principles, Lewis [29] considered a simple coin-tossing scenario. Let the Boolean variable X stand for the event "whether the coin is tossed" and Y stand for the outcome of the tossing (h = heads, t = tails). Lewis finds problematic the following instance of (D): Stalnaker defended the validity of (D) and ensured it by requiring the antisymmetry of the similarity relation: if there are two possible worlds v and w such that v is as close to r as w is, v r w, and w is as close to r as v is, w r v, then v is identical to w. Lewis, on the other hand, thinks it is true that if the coin had been flipped it would have come up either head or tails but he denies both disjuncts. Consequently he rejects the antisymmetry of the model and the principles (D) and (CEM) that come with it. We want to argue that Lewis's example is not a counterexample to (D) when interpreted on structural equations models, nor on our framework. In the former case, this happens simply because there seems to be no way to describe Lewis' example by means of a deterministic structural equation model. Instead, Lewis's example can be naturally modelled by the following team T : where the first assignment corresponds to the case in which the outcome of the flipping of the coin is head, and the second to the case in which it is tails. The team has no structural equations.
Here the fact that the team has more than one assignment makes a difference. Although on singleton causal teams T we have T |= ϕ ∨ ψ if and only if T |= ϕ or T |= ψ, this does not hold for teams with at least two assignments. In this case we have both as T can be partitioned into two singleton causal teams, each making true one of the disjuncts. On the other side, both disjuncts are false, i.e.
and T |= (X = 1 Y = t) exactly as Lewis wants. We thus managed to preserve both the validity of (D) and block Lewis's counterexample thanks to the generalization of disjunction as a tensor interpreted on arbitrary causal teams.
Let us mention in passing that, as far as CO formulas are concerned, also the related principle (CEM) and the (unconditional) law of the excluded middle (LEM) hold for our counterfactuals, for reasons that will be clarified in Section 4. We do not consider these principles in relation to formulas with dependence atoms or occurrences of , since we have not defined a dual negation for such formulas. 19 We might instead consider extending the languages with the contradictory negation -T |=∼ϕ ⇐⇒ T |= ϕ and contemplate principles such as (D ∼ ), (CEM ∼ ) and (LEM ∼ ) where ∼ takes the place of the dual negation ¬. However, (LEM ∼ ) (and consequently (D ∼ ) and (CEM ∼ )) already fails for constancy atoms: =(X)∨ ∼=(X) is falsified on any causal team T , since no causal subteam of T -not even the empty one -satisfies ∼=(X). Similarly, X = 1 ∨ ∼X = 1 fails on a team where X takes the constant value 1: (LEM ∼ ) fails even when applied to atomic CO formulas.

McGee's Counterfactuals
Our second example involves a system of equations whose graph is cyclic, i.e., a nonrecursive system. As hinted already in [2], there is a natural way of extending the notion of intervention to cover also the case of non-recursive causal teams. The idea is as follows. Suppose we want to compute the intervention do(X = x) on a causal team T with exogenous variables U. Let W = U ∪ X and U = U \ X (so that W is the disjoint union of U and X). An intervention do(X = x) is supposed to produce a new causal team of exogenous variables W. The most natural way to obtain it seems to be to include in the intervened team all the assignments s that are "solutions" to the associated system of equations and which respect the constraint that s(U X) = u x for some tuple u of U -values occurring in T . This somewhat abstract definition is illustrated in the example below.
McGee's paper [31] is mostly well-known for its counterexample to modus ponens for indicative conditionals. However, McGee also discusses the counterfactuals a) If Reagan hadn't won the election, and a Republican had won, it would have been Anderson. We take note that the graph is cyclic, given the path It can be checked that the only assignment of the team, call it s, is consistent with the equations. The cyclicity of the graph introduces some complications in defining interventions on T which might not output a unique assignment for each given assignment in T . Indeed, this is the case in our example. An intervention Rea = 0 leads to a new causal team T Rea=0 with  20 This confirms the equivalence of (a) and (b), as desired. So, it looks as if McGee's example can be modelled by means of interventionist counterfactuals, provided we are ready to allow for the causal teams with multiple assignments that may arise after an intervention on a nonrecursive causal model.
It is worth pointing out that after the intervention do(Rea = 0), it is still unsettled, as expected, whether Anderson won the election or not, as witnessed by What is settled, however, after that intervention, is the fact that "whether Anderson is the winner or not" is completely determined by "whether the winner is Republican or not". This is, indeed, the case, as witnessed by the fact that T Rea=0 |==(Rep; And).

Counterfactual Logic
In this section we ask two questions. First, what logical principles govern the behaviour of interventionist counterfactuals as interpreted on causal teams? Second, how do these principles differ from those that govern that behaviour according to the Lewis-Stalnaker interpretation?
We shall write ψ |= χ to mean that χ holds on any recursive causal team on which ψ holds. We write ψ ≡ χ to express that both ψ |= χ and χ |= ψ hold. By |= χ we mean that χ holds on all recursive causal teams. We will write |= σ , ≡ σ for the analogous notions relativized to a fixed signature σ.
In the following, for better readability, we will often write ¬ψ for the dualization ψ d (defined in Section 2.6).

Axiomatization of CO
We present a complete deductive system for CO(σ) languages (over recursive causal teams of signature σ) which is largely adapted from the system presented by Halpern [16], combined with some ideas from [3]. The axioms of Halpern's system which involve material implication could be rendered in our system using selective implication. We preferred to convert them into inference rules; in this way, the system we obtain is still sound for downward closed languages which extend CO (such as CO , COD, COD ). 21 Another basic difference is that Halpern's treatment of exogenous and endogenous variables differs from ours in at least two respects: it allows interventions on endogenous variables only; and it encodes the exogenous/endogenous distinction in the signature. We see no philosophical reasons nor technical advantages in keeping this distinction.
Writing down one cumbersome axiom ("Recursivity") will be easier by introducing an abbreviation (as in [16]) for "X affects Y": 22 where the (tensor) disjunction ranges over all sets of variables Z ⊆ Dom \ {X, Y}, all tuples z ∈ Ran(Z), all x = x ∈ Ran(X), y = y ∈ Ran(Y). 23 Our inference system AX CO (σ) is then described by the following list, which includes four axiom schemes and twelve inference rules. We write σ for derivability in AX CO (σ). When a rule is marked with an asterisk, we mean that also its inverse should be included in the system.
-All CO instances of classical tautologies.
-Composition 1: 21 Of course, in these larger languages some rules (Modus ponens, Definition of ⊃ and Extraction of ¬; see the axiomatization below) will be applicable only when the involved formula ψ is in CO -and thus it has a dual negation. For non-downward-closed languages, the Definition of ⊃ rule must be corrected as follows: ψ⊃χ ¬ψ∨(ψ∧χ) * . 22 This causal notion is also referred to, in the literature, as "X is causally relevant to Y"; see e.g. [22]. 23 Here z ∈ Ran(Z) abbreviates z 1 ∈ Ran(Z 1 ) and... and z n ∈ Ran(Z n ).
-Extraction of ∧: -Extraction of ∨: -Extraction of ¬: -Extraction of : -Exportation: -Recursivity k : These are all schemes, parametrized over the variables and values allowed by the given signature σ, and over k; ψ and χ range over CO formulas. We include the limit cases in which some set of variables is empty (thus, if a counterfactual X = x Y = y occurs in an axiom or rule, if X = ∅ this formula will be replaced by Y = y). We show the completeness of this system for |= σ (over recursive causal teams) in Appendix C.
Most of the schemes correspond straightforwardly to those considered by Halpern in [16]. The Extraction of ¬, ∧, ∨ rules were also noticed by Halpern in [16], but were not part of his axiom systems; yet they are needed for our completeness proof, since our language is a bit more complex than Halpern's. 24 Extraction of and Exportation are needed because, unlike Halpern, we allow for nested counterfactuals; in particular, Extraction of is a more compact presentation of an axiom discovered by Briggs [3]. A-triviality expresses the vacuous truth of counterfactuals with inconsistent antecedents; we have not found earlier mention of this axiom in the literature. C-Substitution and A-Substitution have been used in some axiomatiations of Lewisian counterfactuals, and they seem to be used implicitly in the literature on interventionist counterfactuals while proving completeness results, but as far as we know, in the latter context they are explicitly isolated here for the first time. We point out that A-Substitution could be replaced by three more elementary invertible rules: -A-Associativity: The completeness proof for this modified system is a bit more difficult (in particular, for what regards the proof of lemma C.10 in the Appendix).
The case of languages COD(σ), CO (σ) and COD (σ) is much more delicate. One problem which arises in this context is the nonclassical behaviour of the tensor disjunction ∨ with respect to non-flat disjuncts: for example, the law of idempotency, ψ ∨ ψ ≡ ψ, may fail. It is to be hoped that complete natural deduction systems for these languages can be produced in the style of those obtained for propositional dependence logic [47], but this remains a task for future work.

Invalid Principles
We will give counterexamples to the validity of some well known logical principles (cp. [29], sec. 1.8): strengthening the antecedent The non-validity of the first three principles is a common feature of both similarity based (Lewis-Stalnaker) and interventionist interpretations of counterfactuals. It is generally agreed that these principles, which are valid for strict implication, are not desirable for the counterfactual conditional. By contrast the last four principles hold for similarity-based counterfactuals but fail for interventionist counterfactuals (the counterexamples require nesting of counterfactuals, i.e. occurrences of in the consequent of a counterfactual). This is the case with our languages CO and COD (and their extensions) as well as with those considered in [3]. The four principles do hold for unnested interventionist counterfactuals, as long as only recursive causal teams are considered. 25 25 See [16] and [49] for unnested counterexamples in the nonrecursive case.
We now give counterexamples to the first three principles. A counterexample to the validity of the strengthening of the antecedent is quite straightforward. Consider the causal team T X Y Z 0 1 0 with one equation, Z := X ∧ Y. It may be checked that T |= X = 1 Z = 1 but T X = 1 ∧ Y = 0 Z = 1; in fact we have T |= X = 1 ∧ Y = 0 Z = 0 illustrating how additional information can flip the truth-value of the consequent.
For contraposition, notice that our languages allow only quite limited instances, as antecedents can only take the form X = x. This formula is the dual negation of X∈X X = x. Therefore, the most general instance of the law of contraposition in CO is: with structural equation X := Y. Clearly, it satisfies X = 1 Y = 1 but not its contrapositive Y = 1 X = 1. A counterexample to the principle of transitivity is more involved. To that effect, we consider the team T X 1 X 2 X 3 X 4 0 0 0 1 with 3 equations (all variables are Boolean): It is straightforward to check that T |= X 2 = 1 X 3 = 1, T |= X 1 = 1 X 2 = 1 but T |= X 1 = 1 X 3 = 1. We now give counterexamples to the last four principles in our list. As pointed out, they are valid on the similarity semantics, valid (in the recursive case) also for unnested interventionist counterfactuals, but fail in general. The fact that these principles hold for unnested counterfactuals in the recursive case derives from an analysis of their axiomatizations on causal models (see [11] and [16]). The difference between the nested and the unnested case was first called into attention in [3] with a counterexample to the modus ponens principle for interventionist counterfactuals. Let us give a general argument which identifies the source of the difference between the behaviour of nested counterfactuals on similarity semantics and on structural equation based models. Consider a possible world model whose "worlds" are causal teams of a fixed signature; we also require that, if T is in the model, also T X=x is, for each consistent X = x. Then we may extract from our semantic clause for a worldselection function: f (X = x, T ) = T X=x if X = x is a consistent antecedent, and some fixed causal team with empty team component, otherwise; the truth of a counterfactual X = x ψ can then be written as a Stalnakerian condition: T |= X = x ψ if and only f (X = x, T ) |= ψ. Interventionist counterfactuals should then satisfy the Stalnakerian axiom system VCS, plus perhaps some additional axioms. How can we then explain that some Stalnakerian logical principles are falsified by (nested) interventionist counterfactuals? The answer is that a world-selection function (call it g) is required by Stalnaker to satisfy two constraints both of which are easily falsified for our function f . 26 As expected in light of our explanations, also our counterexample to Modus Tollens involves nested counterfactuals. Consider the causal teams This example also illustrates our earlier remark that the candidate "selection function" f does not satisfy Stalnaker's requirements. Indeed, even though Y = 1 holds in T , T and f (Y = 1, T ) = T Y=1 are distinct causal teams, as they differ in the function and graph components: strong centering fails.
In [29], Lewis considered some variants of transitivity that do hold for his conditionals, such as the weak transitivity principle stated above. In the context of causal models or causal teams, weak transitivity has a special instance of particular interest: This inference expresses one half of the axiom of Composition that was introduced by Galles&Pearl ( [11]); more on this in Appendix C. Its "converse" is also valid 26 We will illustrate this point in our counterexample to Modus Tollens. These observations are inspired by [49], where J. Zhang uses set-selection functions g(X = x, s) := s X=x to explain the failure of Lewisian laws for unnested counterfactuals over nonrecursive causal models. The functions suggested by him, indeed, fail to satisfy one of the Lewisian constraints for set-selection functions (S4; see [49] for the list). However, we cannot fully agree with Zhang's analysis: as he himself observes, his set-selection functions do satisfy all of Lewis's constraints over recursive causal models; it should then be impossible to produce counterexamples to Lewisian laws on recursive models, as done in [3] and in the rest of this section. The problem with Zhang's approach seems to be that it takes worlds to be assignments (without any functional or equational component), while the unit of semantic evaluation is the pair (s, F ) (s assignment, F functional/equational component). Therefore, the nonvacuous truth of a conditional is expressed by the clause (s, F ) |= X = x ψ iff "(t, F ) |= ψ for all t ∈ g(X = x, s)", which is not Lewis's truth condition "t |= ψ for all t ∈ g(X = x, s)". It seems thus to be impossible to draw any conclusion using a function g which returns sets of assignments; one might try to use, instead, a function, similar to our f , which returns set of pairs (s, F ). Such a function -as our f -can easily be seen to falsify Lewis's requirements S1 and S4 on recursive causal models, and also S3 on nonrecursive ones. over recursive causal models and teams. It is none other than the Composition 1 rule already considered in the axiom system of Section 4.1: The analogy between weak transitivity and composition suggests that we consider an inverse to the former: -Inverse weak transitivity: ϕ ψ, ϕ χ |= (ϕ ∧ ψ) χ.
It turns out that this principle is valid according to the Lewis-Stalnaker semantics; it can also be seen as a way of repairing the "strengthening the antecedent" principle. To see the validity of this rule, observe that the premises state that the closest ϕworlds satisfy ψ and χ. The former assertion (together with Lewis' nesting principle) tells us that the set of the closest ϕ-worlds and the set of the closest ϕ ∧ ψ-worlds coincide. Therefore, the closest ϕ ∧ ψ-worlds satisfy χ. 27 We may now wonder if weak transitivity and its converse hold in general for languages evaluated on causal teams. The most general form that weak transitivity can take for the kind of languages we have considered in this paper is: (where for simplicity we may assume that the antecedents of counterfactuals are consistent). If ψ contains no counterfactuals, this principle is valid over causal teams T , for the general reasons mentioned above. We can also give a more informative direct argument: first, from the second premise we get T X=x∧Y=y |= ψ. The consistency of X = x ∧ Y = y allows us to rewrite the latter condition as (T X=x ) Y=y |= ψ. 28 The first premise tells us that T X=x |= Y = y; therefore, the intervention do(Y = y) will not modify the team component of T X=x ; thus T X=x and (T X=x ) Y=y satisfy the same formulas without occurrences of , in particular they both satisfy ψ. This also shows the validity of the Inverse for ψ without occurrences of . We would like to draw attention to the fact that this argument is purely model-theoretical, and so it proves the validity of the rule for unnested counterfactuals of any language that features our version of the interventionist counterfactuals (in particular, for CO, COD, CO , COD ). Instead, we can easily build counterexamples to weak transitivity involving formulas ψ which allow occurrences of . Consider the following team T Our counterexamples to Modus Ponens and conjunction conditionalization (simpler than Briggs's "execution line" example, [3]) use the following causal teams, with Boolean ranges and functions f Y (X) := X and f Z (X, Y) := X ∧ Y: It is then immediate to see that: Now 1., 2., and 4. provide a counterexample to Modus Ponens. Like the other two earlier counterexamples, this one involves nested counterfactuals. We notice in passing that the pair of formulas 2., 3. confirms the unsurprising fact that and ⊃ have different truth conditions. For a counterexample to conjunction conditionalization, observe that from 1. and 5. we get T |= Y = 0 ∧ (X = 1 Z = 1). On the other hand, the corresponding counterfactual does not hold, as shown by 6.
As in the case of (inverse) weak transitivity and Modus Tollens, it can be shown by direct model-theoretical arguments that Modus Ponens and conjunction conditionalization hold for non-nested counterfactuals in any of the languages considered in the paper.

Permutation and Exportation/Importation of Antecedents
The following laws of permutation, exportation and importation of antecedents are known to fail quite generally for Stalnaker's [39] and Lewis's [29] counterfactuals (see [37], chap. 8); their validity for natural language counterfactuals is controversial. These principles can be shown to hold for our counterfactuals (under some restrictions). There is a direct link between these three rules and the different ways of producing a complex intervention. Under appropriate assumptions, an intervention can be decomposed into a sequence of two interventions over smaller sets of variables; this justifies exportation and importation. The possibility of swapping the order of the two smaller interventions justifies permutation. The following theorem specifies the conditions under which these transformations do not modify the effect of an intervention.

Theorem 4.1 Let T be a causal team with G T finite acyclic, X, Y sets of variables,
x ∈ Ran T (X), and y ∈ Ran T (Y). Suppose X = x ∧ Y = y is consistent. Suppose also that, if X i = Y j ∈ X ∩ Y, then x i = y j . Then T X=x∧Y=y = (T X=x ) Y=y .
In words, the decomposition of an intervention works correctly for disjoint sets X, Y of variables, or more generally when do(X = x) and do(Y = y) act in the same way on the common variables X ∩ Y.
The proof is straightforward but tedious and will not be given here (it can be found in [1]). From it we obtain as a corollary the validity of the interventionist versions of importation/exportation of antecedents under the above restrictions, over recursive teams. We notice that when the conditions in the statement of the theorem are fulfilled, we also get (T X=x ) Y=y = T X=x∧Y=y and (T Y=y ) X=x = T Y=y∧X=x . Since the order of variables is irrelevant in the definition of the do algorithm, it follows that T X=x∧Y=y = T Y=y∧X=x . Thus (T X=x ) Y=y = (T Y=y ) X=x , which shows that the rule (PERM) : is valid (under the above restrictions) over recursive causal teams. In order to have a full characterization of the range of validity of the three rules, we still have to see what happens if some of the involved antecedents are inconsistent. When either X = x or Y = y is inconsistent, (IMP) and (EXP) hold for trivial reasons. But when X = x and Y = y are both consistent, while X = x ∧ Y = y is not, then it is easy to build counterexamples to the two principles. In such cases, applying in sequence the interventions do(X = x) and do(Y = y) will produce the intervention do(X = x ∧ Y = y), where X = X \ Y and x = x \ y; i.e., the second intervention overrides the first on the set of variables in common. This fact justifies the more general rule Extraction of that was included in the axioms for CO (Section 4.1).

Conditionals and Dependencies
In this section we consider the interactions of counterfactuals with other special operators, such as the selective implication, the Boolean disjunction and the dependence atoms. We also investigate what kinds of causal dependencies can be expressed in our languages.

Selective vs Counterfactual Implication
In this section we focus on the logical properties of selective implication and its interaction with counterfactual implication. Given that selective implication is a generalization of material implication to team semantics, it is natural to ask to what extent properties of the latter generalise to the former. We consider several cases, which show how the generalization is conditioned on some of the properties of causal teams that we investigated earlier. The following inference rules θ ⊃ χ are sound when the antecedents of the selective implication are CO formulas; the leftmost rule also requires downward closure of the consequent χ, and the rule in the middle requires the empty team property. The rightmost rule is invertible.
Selective implication also obeys a semantic version of the Deduction Theorem, relative to CO antecedents. 30 To see this, assume that any team that satisfies a CO formula θ also satisfies χ, and consider, for an arbitrary causal team T , the subteam T θ . By flatness, T θ |= θ, and by our assumption, T θ |= χ. Hence T |= θ ⊃ χ. Thus all the valid inference rules that are stated in the paper can be internalized in the object language as selective implications, provided the antecedents are CO formulas.
It is standard, after Lewis's seminal book [29], to inquire about the relationships between the counterfactual ψ χ and the material implication ψ → χ. It is known that in the Stalnaker-Lewis approach, [29,39] the former implies the latter; the converse is also known to hold, provided the antecedent ψ is true. The proof of these facts requires strong centering.
It is natural to ask whether similar principles hold for our interventionist counterfactual and selective implication. Given our analysis of these notions on causal teams, the first question may be rephrased as whether an intervention may be replaced with an observation. Within this perspective, it is also natural to consider other similar questions, e.g., whether the two conditionals respect the same inference rules, whether the order of consecutive applications of the two operations may be reversed (commutativity), etc.
The answer to these questions turns out to be negative, as expected. This has to do, essentially, with the discrepancy between evidential reasoning (observations), encoded by T ψ , and counterfactual reasoning (interventions), encoded by T ψ . The former produces a causal subteam of T which, by definition, uses the same structural equations and graph components as T . By contrast, the latter may alter the equations component and the graph component of T , which may further affect the truth-conditions of some counterfactual statements even when ψ is true in T .
The fact that the uniform replacement of an intervention by an observation may affect the truth-value of the relevant formula was shown while discussing our counterexample to modus ponens in Section 4.2. With the next example, we show that also the logical status of a formula may be affected by such a replacement. 31 More exactly, there are non-valid formulas which become valid (on teams with appropriate variable domain) once every occurrence of is replaced by ⊃. Consider the formula Y = 1 ⊃ (X = 1 Y = 1). It is false in every causal team whose structural equation component is Y := X + 1, such as the causal team T shown in the picture: On the other hand, it follows from the semantic clause for selective implication that the formula Y = 1 ⊃ (X = 1 ⊃ Y = 1) is valid. For a different kind of counterexample, consider the formula X = 1 (X = 2 X = 1): it is contradictory, i.e. false in every causal team (of nonempty team component) with the appropriate domain of variables (notice that the second intervention rewrites the value assigned to X by the first intervention; given that assignments are functions, the claim follows right away). But X = 1 ⊃ (X = 2 ⊃ X = 1) is trivially true in any causal team T , given that ((T X=1 ) X=2 ) − is empty.
Finally, we show the non-commutativity of interventions with observations, that is, we show that the equivalence between θ (χ ⊃ ψ) and χ ⊃ (θ ψ) fails on causal teams in both directions. All the teams in our counterexamples have one structural equation, Y := X + Z; it is not really important to specify the ranges of variables. The teams T : ). For the opposite direction consider the teams (with the same graph and equation as before): S : X Z Y 2 1 3 31 We thank Tapani Hyttinen for raising this issue.
. We remark that the noncommutativity of with ⊃ is a phenomenon that lies somehow hidden in the literature on causation, and is dealt with by means of a multiplicity of ad hoc notations ("do expressions", "counterfactual expressions", etc.) which only cover some specific logico-probabilistic forms. 32

Dependence Atoms
As we already pointed out, the inferences rules described in Section 4 extend to languages that admit dependence atoms (and/or Boolean disjunctions). In this subsection, we briefly describe some rules that are specific to the extended languages COD, CO , COD , and that illustrate some of the interactions between dependence atoms (functional dependencies), on one side, and selective implications, counterfactuals and causal dependencies, on the other. These issues will be clearer in the light of the following observations (which derive from [6]): 1) a constancy atom =(Y) is equivalent (relative to a fixed finite signature σ = (Dom, Ran)) to the Boolean disjunction Y∈Ran(Y) Y = y; more generally, for every causal team T of signature σ, T |==(X; Y) can be shown to be equivalent to the metalanguage assertion that, for all causal subteams S of T , i.e., if a subteam decides the value of X, then it also decides the value of Y. In the languages considered in this paper, though, we do not have the kind of conditionals that would allow us to internalize the above logical implication. 33 However, a moment of thought shows that we still can define =(X; Y) in CO (σ) or COD (σ) as This tells us two things: first, that the expressive power of CO is at least as great as that of COD; and secondly, that the following is a sound invertible rule in COD (σ): (as before, the asterisk marks the invertibility of the rule). The rule tells us that if for every tuple of values for X there is a corresponding value that Y takes (or the tuple X does not occur in the team), then we can infer that Y is functionally dependent on X. Its inverse says that, if we assume that Y is functionally dependent on the set X, then any evidence that X takes certain specific values implies that Y takes a constant value. We conjecture that this pair of rules summarizes all the interactions between dependence atoms and ⊃ in COD (σ). The rule (and its inverse) can also be converted into a sound, invertible rule for COD(σ): Notice that the inverse of this rule, unlike the rule for COD (σ), does not completely remove dependence atoms from the consequent of ⊃; and in general, we see no reasonable rule for removing constancy atoms from the consequents of ⊃ without making use of . This might suggest that the expressive resources of COD are weaker than those of CO ; however, the literature on propositional dependence logics warns us against quick conclusions. 34 An analogous (but not invertible!) rule connects counterfactual and functional dependence: or, in the style of COD(σ): Instead, the "inverse" inference from =(X; Y) to X = x =(Y) is unsound. The statement =(X; Y) tells us that for any value x of X there is associated exactly one value y for Y; but we cannot infer that for every value x there is a value y such that if X had taken the value x then Y would have been y.
This inference pattern can, expectedly, be falsified in many ways. We have already seen one such example in Section 2.4 (ex. 2.7); in that case, a functional dependency =(Y; X) could be broken by an intervention -thereby falsifying the statement Y = 0 =(X) -because it was a contingent dependency, going in the opposite direction as the dependence induced by the structural equations. The following example shows a different possibility. Consider the causal team T : with associated structural equation Y := X ∨ Z. For trivial reasons, T |== (X; Y). However, the intervention do(X = 0) produces the causal team T X=0 T X=0 : and T X=0 |==(X; Y). In this example, an intervention on X can make it so that Y is not anymore functionally determined by X, even though here X is an argument of the function which produces Y -a parent of Y. Notice that the assignment had the effect of shrinking the set of values available for X in the team, while enlarging the set of values available for Y, and ultimately breaking the relation of functional dependence. 35 We also remark that causal teams with at least two assignments are needed to produce these kinds of counterexamples (as long as we only consider recursive causal teams).
Although we cannot infer X = x = (Y) from = (X; Y), the following much weaker rule is sound:

Notions of Cause
In this subsection we show that many of the notions of cause that are considered in the philosophical literature that is inspired by structural equation modeling translate smoothly into the more general framework of causal team semantics. We consider the taxonomy of causal notions that was introduced by Hitchcock in [21], but we stick to the terminology used by Woodward [45]. This classification includes three notions of type causation (direct, total, and contributing cause) and one of token causation (actual cause).
First we consider at length the notion of direct cause (and some of its interactions with functional dependencies). Woodward expresses it thus: A necessary and sufficient condition for X to be a direct cause of Y with respect to some variable set V is that there be a possible intervention on X that will change Y (or the probability distribution of Y) when all other variables in V besides X and Y are held fixed at some value by interventions. ( [45], p. 55) Woodward is ambiguous here as to what "changing Y" may mean. The remarks that follow the above quote, though, make it clear that what is really meant is that there are two possible interventions (of the kind described in the quote) which force Y to take two distinct values.
The assertion DC σ (X; Y) that X is a direct cause of Y (relative to the variables in the domain of σ) can then be expressed in the language C(σ) (and its extensions) as follows: x =x ,y =y ,z 35 Other examples can be devised in which just one of either of these two factors suffices to break a functional dependency.
where Z = Dom \ {X, Y} and x, x , y, y , z vary within the ranges of the corresponding variables. It would seem more natural to express this condition as a Boolean disjunction; the following results prove the adequacy of the definition in terms of tensor disjunction, and something more: that its truth in a causal team is determined by the functional component alone. The main point which makes this definition work in accordance with the usual behaviour of direct cause is the fact that, if X is really a direct cause of Y, then the specific interventions involved in the definition always produce singleton teams. For brevity, in the proofs we write A x,y,z for (Z = z ∧ X = x) Y = y. Since some ambiguity may arise when we discuss multiple teams, we write here PA T X for the parents of X in the causal team T . Proof Suppose X / ∈ PA T Y or X is a dummy argument of F T (Y): then, by the definition of F T (Y) and of intervention, for every x, x , y, z we have that T |= A x,y,z entails T |= A x ,y,z ; so T |= A x ,y ,z . This contradicts the initial assumption that T |= DC σ (X, Y).

Lemma 5.2 Let T, S be recursive causal teams of signature σ such that
In words, causal teams which have the same signature and the same associated equations also encode the same relationships of direct cause.
Proof Suppose T |= DC σ (X, Y); then, by Lemma 5.1, X ∈ PA T Y and is not a dummy argument of F T (Y) = F S (Y). Therefore, X ∈ PA S Y by the compatibility condition (*) from the definition of causal team.
T |= DC σ (X, Y) entails, by the clause for ∨, that there is a causal subteam of T , call it T , such that T |= A x,y,z ∧ A x ,y ,z for some x = x , y = y , z. Since G T = G T , X ∈ PA T Y entails X ∈ PA T Y . Since X ∈ PA T Y and X ∈ PA S Y , we have that T Z=z∧X=x and S Z=z∧X=x are the same causal team with singleton team component; the same holds for T Z=z∧X=x and S Z=z∧X=x . Therefore, from T |= A x,y,z ∧ A x ,y ,z we can infer S |= A x,y,z ∧ A x ,y ,z . Since the causal subteam of S with empty team component satisfies each of the other disjuncts of DC σ (X, Y), we can conclude that S |= DC σ (X, Y).
There are x, x ∈ Ran(X), y, y ∈ Ran(Y), z ∈ Ran(Z) such that x = x , y = y and T |= [ There are x, x ∈ Ran(X), y, y ∈ Ran(Y), z ∈ Ran(Z) such that x = x , y = y and, for every causal team S of signature σ and functional component F T , S |= Proof 2. follows from 3. as a special case. We show that 1. entails 3. Suppose 1. holds, i.e. T |= DC σ (X, Y). Let S be a causal team of signature σ and functional component F T . From Lemma 5.2, we get S |= DC σ (X, Y). By the clause for ∨, there is a causal subteam S of S and x = x , y = y , z such that S |= A x,y,z ∧ A x ,y ,z . Furthermore, by downward closure we have S |= DC σ (X, Y), and thus from Lemma 5.1 we get that X ∈ PA S Y , from which it immediately follows that S Z=z∧X=x and S Z=z∧X=x have singleton team components. Clearly, if S * is any causal subteam of S with singleton team component, applying the same two interventions to S * produces exactly the same pair of causal teams as is obtained by intervening on S . Therefore, S * |= A x,y,z ∧ A x ,y ,z . By flatness, we get S |= A x,y,z ∧ A x ,y ,z . So 3. holds.
The entailment from 2. to 1. immediately follows from the clause for ∨ and the fact that causal teams with empty team component satisfy all CO formulas.
We want to show that the notion of direct cause has some kind of logical interaction with dependence atoms. It is to be expected that, if we know that X is the set of all direct causes of Y, then we can infer that X functionally determines Y. We write All-DC σ (X; Y) for the statement that X is the set of all direct causes of Y. 36 That is, Here ∼ is contradictory negation (this requires an enrichment of COD). Now it can be shown that the rule is a valid inference rule in the language COD enriched with ∼.
The notion of total cause may seem more difficult to express in our languages; part of the difficulty lies in an even greater ambiguity with which it is expressed in the philosophical literature. In Woodward's words: X is a total cause of Y if and only if there is a possible intervention on X that will change Y or the probability distribution of Y. ([45], p. 51) One way to interpret this statements is that, for some assignment of values to the variables in the system, some intervention on X will change the value of Y. Now, it is straightforward to prove that this statement is equivalent to the assertion that after fixing the nondescendants of X in some appropriate way, there are two interventions on X which produce two distinct values for Y. In this formulation, "X is a total cause of Y" (relative to a signature σ) can be expressed by a CO formula which has the same form as DC σ (X, Y), except that Z is now the set of nondescendants of X. The appropriateness of this definition over causal teams is due to the fact that, when there is a chain of direct causes from X to Y, the interventions mentioned in the definition produce singleton teams. We omit a detailed discussion of this point, but we illustrate it with an example. Consider the causal team T : with equations Z := X and Y := Z XOR W. Here no intervention on X alone can produce a team where Y has a constant value, as the tables show: However, if we fix W (the only nondescendant of X) e.g. to 0, then further interventions on X permit to settle the value of Y (in two distinct ways): Thus X is a total cause of Y.
The third and perhaps most important notion of type causation is called by Woodward contributing cause. We say that "X is a contributing cause of Y" ( [45], p. 59) if there is a chain of direct causes from X to Y, and, while holding fixed in an appropriate way the variables that are not on this path, one can make two distinct interventions on X which produce two distinct values of Y. It should be clear, at this point, that this notion can be written in CO in a similar fashion to direct cause and total cause (adding an external tensor disjunction over paths of direct causes from X to Y, and taking Z to be the set of variables not occurring on the path). 37 Our framework seems to be less adequate for dealing with token causation, i.e., with the causes of a specific event. A typical question of this kind might take the form: It happened that Y = y. Is the fact that X = x a cause of it?
What is usually intended here is that X = x and Y = y are true in the actual world. Furthermore, most of the notions of actual cause on the market (e.g., Woodward [45], Halpern and Pearl [17]) rely crucially on the notion of "intervention that fixes a variable to its actual value". These kinds of devices are lacking in our version of causal teams. And the presence of teams introduces complications of its own, especially in the case of nonrecursive systems: if the system of equations has multiple solutions, it is not always possible to recompute deterministically what the new "actual world" will be after an intervention. For this reason, we think that the modelling of token causation should proceed differently on causal team semantics, replacing talk of actuality by talk of observations, as in the scenario: We see that X = x and Y = y. It is entailed by/compatible with our observations that X = x is a cause Y = y.
To model such a scenario we propose a notion of cause that we may call discernible cause, derived from the simplest definition of actual causation from [45]. We are aware that such a definition is in need of various refinements in order to treat correctly e.g. cases of overdetermination. We say that X = x is a discernible cause of Y = y if holds, where P varies over sets of variables which form a directed path of direct causes from X to Y. The most external implication, (X = x ∧ Y = y) ⊃ . . . can be read: "in case we observed X = x and Y = y". The formula inside square parentheses can be rewritten as a conjunction of formulas of the form Z = z ⊃ (Z = z ψ); this is our surrogate for "intervening on the actual value of Z". What such a formula says is that, if the actual value of Z were z, then fixing Z to z would yield ψ.
The proposed notion of discernible cause explicitly incorporates epistemic aspects. The comments above should illustrate that one possible reading of our selective implication ⊃ is as an epistemic subjunctive conditional.

Conclusions and Future Developments
We have seen that, even though team semantics, by itself, is insufficient to support interventionist counterfactuals and causal dependencies, it can be extended to overcome this limitation. The resulting causal team semantics enriches each team with components that encode structural equations, and induces a notion of intervention on a team (a procedure that rewrites parts of the team when one of the variables in its domain is acted upon).
This notion of intervention was the main ingredient in our semantic clause for interventionist counterfactuals. We studied the logical principles that govern these counterfactuals by comparison with, on one side, Lewis-Stalnaker counterfactuals, and interventionist counterfactuals over causal models, on the other. In particular,we made some advances in the comparison of nested interventionist counterfactuals vs. the Lewisian ones, as it was initiated in [3]; we found more Lewisian principles that can be falsified in the interventionist frameworks, for example weak transitivity and Modus tollens.
We also used our interventionist counterfactuals to define various notions of cause in Woodward's style. The team component of causal teams led to interesting generalizations of some of the basic propositional connectives (e.g. tensor, selective implication). It also made it possible to express functional dependencies in the language. Many other operators and notions of dependence have been considered in the literature on team semantics, and it might be worthwhile to consider their interactions with counterfactuals in the context of future work.
We hope that the paper has shown that causal teams already bring something new when they are applied to "classical" languages, such as the language CO. The novelty does not lie in the resulting logic (which, save for minor details, is the same as for causal models); it consists, instead, in the possibility of modelling more scenarios, as illustrated by the examples in Section 3. The examples also show that, in nonrecursive systems, it is necessary to consider causal teams with multiple assignments in order to compute interventions over causal models.
In a continuation of this paper we will show how these ingredients can be made to work together with probabilities in the framework of causal multiteams, supporting languages that are compatible with the framework of semi-deterministic SEMs. The operators ⊃ and , which have played a mild role so far, will be seen to be crucial. In particular, we will see that the selective implication can be used to decompose statements of conditional probabilities into more basic statements, and allows expressing forms of conditioning (mixed with interventions) that are more general, as far as we know, than those considered in the literature on structural equation models.
Concerning the deterministic case considered in this paper, future work will have to settle the issue of axiomatizability of the languages containing nonclassical operators, such as functional dependence and the "Boolean disjunction" . The literature on propositional dependence logic (in particular [34,47]) suggests that complete deduction system should be possible to achieve. Towards an adaptation of the results of [47], it might be necessary to find exact characterizations of the expressive power of our formal languages. Finally, the case of nonrecursive causal teams, only sketched here, will need to be more systematically studied, both from a semantic and a proof-theoretic point of view.
vertices V are thought of as variables. The general intuition is that, after an intervention on X, other variables should be updated; and variables at distance n + 1 can only be updated after the variables at distance ≤ n have been updated.
We define the distance between two variables X and Y to be the maximum length of a directed path from X to Y: if any such paths exists; or −1 otherwise.
Clearly, if the graph is finite and acyclic, d G (X, Y) ∈ N ∪ {−1} for any pair X, Y. We omit the subscript G when the graph is clear from the context. Notice that in an acyclic graph d G (X, Y) = d G (Y, X) whenever X and Y are distinct variables.
The algorithm described in Section 2 uses this notion of distance in order to define interventions of the form do(X = x). However, as we saw, we needed to define the more general notion of intervention of the form do(X = x). This can be achieved by defining a notion of distance between a set of variables X and a variable Y; we denote it by d G (X, Y). There are two ideas involved in this generalization. The first is that we should not count the directed paths that are disrupted by the intervention itself (an intervention do(X = x) removes all arrows coming into variables of X); for this purpose, we need to consider the reduced graph G −X = (V, E −X ), the graph obtained by removing all arrows going into some vertex of X (i.e., an edge ( The second idea is that we should take the maximum of the individual distances between each variable X of X and Y (relative to the reduced graph). Thus we obtain d G (X, Y) = sup{ length(P) | P dir. path of G −X going from some X ∈ Xto Y }.
Let X = x be a consistent conjunction (i.e. it does not contain pairs of formulas X = x, X = x with x = x ). An algorithm for do(X = x) is then obtained by modifying the algorithm for do(X = x) as follows: -Stage 0 is replaced with: produce the team T 0 by replacing each assignment s ∈ T − with s(x/X).
We do not define the algorithm for inconsistent conjunctions.
Using Theorem 4.1, it can be proved (see [1]) that the intervention do(X = x) (for consistent X = x) could be equivalently defined as the sequential application of individual interventions do(X = x), for each conjunct X = x in X = x, applied in any order.
Suppose that, for X ⊆ Dom T , Y ∈ Dom T , d(X, Y) > card(G T ). Then there is a path P in G −X T from some X ∈ X to Y such that length(P) > card(G T ). Then there is a node which is crossed at least twice by P; so G −X T contains a cycle. Therefore, the larger graph G T contains a cycle, and we have a contradiction. Thus, sup{d(X, Z) | Z ∈ Dom T } ≤ card(G T ); this means that the "for" cycle in the algorithm goes through a finite number of iterations over the variable n.
Finally, notice that, for each n, the number of variables Z such that d(X, Z) = n is finite (due to finiteness of G T ), as is the number of assignments t in the team that is undergoing modification (due to the finiteness of T − ). Therefore, the algorithm terminates after a finite number of steps.
If instead T − is infinite, (T X=x ) − is produced by an infinitary algorithm which, in each iteration of the "for" cycle, performs simultaneously the substitution t → t( f Z 1 (s(PA Z 1 ))/Z 1 , . . . , f Z k n+1 (s(PA Z k n+1 ))/Z k n+1 ) for all the assignments t in the current team. By the arguments above, such an "algorithm" terminates and yields a welldefined causal team.
literature [3,11,16]. Next we show how to extend this result to all recursive causal teams.
We point out that the following principles are also sound for recursive causal teams (as can be proved by the two previous lemmas): -Composition 2: . -Reversibility: Composition 2 is a "converse" to Composition 1. It was implicitly part of the axiom system of Galles and Pearl [11], but [16] showed that it is unnecessary for a completeness proof.
What we now show is that (for each signature σ) the system AX CO (σ) is complete for |= σ . The strategy will be to show that every consistent set of formulas has a model; we mostly follow the method used in [3]. There is some vagueness in the literature as to what notion of (proof-theoretic) consistency is involved here; the notion we will use is given in the definition below. But first a notational convention. Given a set Γ of CO(σ) formulas, write Γ σ for its closure under deduction in AX CO (σ). CO(σ) formulas is σ-consistent if Γ σ does not contain any pair of formulas of the form ψ, ¬ψ.

Definition C.3 A set Γ of
Γ is maximally σ-consistent if it is σ-consistent and every Γ ⊃ Γ is not σ-consistent.
In the following we shall simply write "consistent" for σ-consistent, since the relevant signature will be clear from the context. We note that, since AX CO (σ) contains all instances of classical tautologies and modus ponens, one can prove the syntactical deduction theorem as usual.
Using this result, one can prove as usual a version of Lindenbaum's lemma.
Lemma C. 6 Let Γ be a consistent set of CO(σ) formulas. Then there is a maximally consistent set Δ of CO(σ) formulas such that Γ ⊆ Δ.
In the next lemma we prove that a maximally consistent set of CO(σ) formulas "uniquely determines" the outcome of interventions.

2.
For every x ∈ Ran(X) there is exactly one y ∈ Ran(Y) such that .
Proof Let us prove 2. Let x ∈ Ran(X). First we show that Δ can contain a formula of the form for at most one value y ∈ Ran(Y). Indeed, let y be a distinct value in Ran(Y); observe that Δ is closed under σ , and thereby under applications of the Uniqueness rule; so, since , we obtain that . But notice that this formula is (by definition of the dualization). So, by the consistency of Δ, . We then have to show that there is at least one y ∈ Ran(Y) such that . For suppose this is not the case; then by maximality of Δ, corollary C.7 and the definition of dual negation, for each y ∈ Ran(Y); thus . But this formula is just ; and by the Definiteness axiom. Since Δ is consistent, we have reached a contradiction.
The proof of 1. is analogous, using instances of Uniqueness and Definiteness with empty antecedents.
We will need two substitution lemmas to guarantee that rules need not be applied to the outermost connectives of a formula. The first is for formulas that occur in positive contexts. We write ϕ[θ] for a formula if we want to highlight that it has an (occurrence of) a subformula θ. If θ is yet another formula, ϕ[θ ] will denote the formula which results by substituting the occurrence θ with θ in ϕ. The second substitution lemma guarantees substitution of equivalents in the antecedents of counterfactuals occurring in the context of a complex formula. Proof The proof is analogous to that of lemma C.9, using A-substitution instead of C-substitution.
The next lemma shows how to build an appropriate "model" for any maximally consistent set of CO(σ) formulas.

Lemma C.11
Let σ = (Dom, Ran) be a signature, and Δ be a maximally consistent set of CO(σ) formulas. Then there is a recursive causal team T of signature σ such that T − is a singleton, and T |= Δ.
Proof 1) Defining T . Suppose first that card(Dom) ≥ 2. For each variable V ∈ Dom, let W V be the list of variables in Dom \ {V}, arranged in some order. To each V ∈ Dom we associate a function g V : Ran(W V ) → Ran(V) as follows: We must verify that this function is correctly defined; but this immediately follows from lemma C.8. Now define PA V as the set of nonredundant arguments of g V ; that is, the smallest subset Z ⊆ W V such that, for every fixed tuple z ∈ Ran(Z), g V (z, ·) is a constant function. Define the graph G T := (Dom, E), where (X, Y) ∈ E iff X ∈ PA Y . By the definition of g Y , we have that Y / ∈ PA Y ; so, G T is irreflexive. Let End(T ) be the set of variables V ∈ Dom such that PA V = ∅. For each V ∈ End(T ), define f V : Ran(PA V ) → Ran(V) as g V deprived of the redundant parameters (i.e., for all pa ∈ Ran(PA V ), f V (pa) := g V (pa, u) for any u ∈ Ran(W V \ PA V )). Let F T := {(V, f V ) | V ∈ End(T )}.
By lemma C.8 again, we have that, for each V ∈ Dom, Δ contains exactly one formula of the form "V = v", for some v ∈ Ran(V). Let s be the unique assignment of signature σ such that, for each V ∈ Dom, s(V) = v iff "V = v" ∈ Δ. Define T − := {s}. Now T is defined as the triple (T − , G T , F T ). In order to show that T is a causal team (of endogenous variables End(T )), we need to prove that T − and F T are compatible, i.e. they respect the clause (*) of definition 2.1. Let V ∈ End(T ); let v = s(V) and w = s(W V ). Now by definition of s we have that "V = v" ∈ Δ and "W V = w" ∈ Δ. Let pa be the restriction of w to PA V . Then by Composition 1 (for assumptions with empty antecedents) and the fact that Δ is closed under derivations, we have . But then, by definition of g V , we have g V (w) = v, from which f V (pa) = v, as desired. 38 In case card(Dom) = 1, we let G T and F T be empty, and define s and T as above.
2) T is recursive. First we show that, if X ∈ PA Y , then "X Y" ∈ Δ. Write Z for Dom \ {X, Y}. Assume X ∈ PA Y . By the construction of PA Y , this means that there is a z ∈ Ran(Z) and there are distinct x, x ∈ Ran(X) and distinct y, y ∈ Ran(Y) such that y = g Y (z, x) = g Y (z, x ) = y . By the construction of g Y , we have and from which, applying classical logic, Exportation, the inverse of Extraction of ∧ and the closure of Δ under σ , we obtain and applying classical logic and closure under σ again, we obtain "X Y" ∈ Δ.
Now, for the sake of contradiction, suppose that for some X 1 , . . . , X n ∈ Dom we have X i ∈ PA X i+1 (i = 1, . . . , n − 1) and X n ∈ PA X 1 . As shown above, then, we have "X i X i+1 " ∈ Δ and "X n X 1 " ∈ Δ. Since Δ is closed under 38 We thank Kaibo Xie (personal communication) for this argument.
3) T |= Δ. We have to show that, for each ψ ∈ Δ, T |= ψ. First we show that, for every ψ ∈ Δ, there is a ψ ∈ Δ such that ψ σ ψ and furthermore the following conditions hold: a) All counterfactuals occurring in ψ have atoms of the form V = v as consequents. b) ψ has no occurrences of ⊃. c) Antecedents of counterfactuals in ψ contain at most one occurrence of each variable. d) The variables in the antecedents of counterfactuals in ψ occur in a fixed alphabetical order.
We show how to derive the desired ψ from ψ; the inverse derivation proceeds analogously, using the inverses of the rules (the inverse of -Extraction is Exportation). First of all we remove all occurrences of ⊃ by using the rule Definition of ⊃ together with lemma C.9. This has to be done inductively, starting from the most external occurrences of ⊃ (so that the occurrence of ⊃ satisfies the assumptions of lemma C.9, i.e. it is not in an antecedent of ⊃). In this way we obtain a formula satisfying b). Next we apply the extraction rules (plus lemma C.9) until a) is ensured. Then we use lemma C.10, together with A-Triviality, classical tautologies and lemma C.4, to ensure c) and d). ψ ∈ Δ since ψ is, and Δ is closed under σ .
The base cases are those for formulas of the form Y = y, Y = y and : -Case ψ = Y = y. If ψ ∈ Δ, then, by consistency, "Y = y" / ∈ Δ. Then, by definition of s, s(Y) = y. Since s is the only assignment in T − , T |= Y = y.
If Y ∈ X, then ψ is obviously valid on causal teams; so T |= ψ . If instead Y / ∈ X, we proceed with a further induction on the number n = card(W Y \ X).
-If n = 0, notice that X = W V as sequences, thanks to c) and d). Then T |= ψ by the definition of g Y together with the semantic clause for (or by the definition of s, in case X = ∅). -Case n > 0. In case X = ∅, from the assumption that "Y = y" ∈ Δ we get s(Y) = y by definition of s. Since T = {s}, then, T |= Y = y. Suppose instead X = ∅. Now, there is at least one variable Z ∈ Dom \ (X ∪ {Y}). By lemma C.8 there is a unique z ∈ Ran(Z) such that . Since furthermore ψ ∈ Δ and Δ is closed under the Composition 1 rule, we conclude that . Since the antecedent of this counterfactual operates on a larger number of variables than the antecedent of ψ , we can apply the inductive hypothesis and conclude . Applying Composition 1 with the premises in opposite order, and again the inductive hypothesis, we obtain . Since recursive causal teams satisfy the Reversibility rule we conclude that .