Liking cljdoc? Tell your friends :D

org.replikativ.foerster.attribution

Attribution and repair search over declared counterfactual mechanisms. A baseline and an outcome score are part of the question. Contributions are allocations of that score, not probabilities that a node is a cause.

Attribution and repair search over declared counterfactual mechanisms.
A baseline and an outcome score are part of the question. Contributions
are allocations of that score, not probabilities that a node is a cause.
raw docstring

actual-causeclj/s

(actual-cause evaluate
              effect?
              candidate
              domains
              &
              [{:keys [witnesses max-evaluations max-nodes]
                :or {max-evaluations 65536 max-nodes 12}}])

Modified Halpern-Pearl actual causality in a FINITE deterministic SCM. evaluate maps interventions {node value} to all endogenous values under ONE fixed exogenous realization. effect? is true on the factual result. candidate is the set of actual events under test. domains gives the alternative values allowed at candidate nodes. Witness nodes may be held at their factual values; by default every other endogenous node is eligible.

Exhaustive AC2 witness search plus AC3 subset minimality. A bias toward small sets is not substituted for the minimality check. Returns :actual-cause, :not-cause, :not-minimal, or :unresolved when :max-evaluations is exhausted. :witnesses restricts the allowed context; :max-nodes (default 12) limits combinatorics. This is not a discovery algorithm or a posterior probability.

Modified Halpern-Pearl actual causality in a FINITE deterministic SCM.
`evaluate` maps interventions {node value} to all endogenous values under
ONE fixed exogenous realization. `effect?` is true on the factual result.
`candidate` is the set of actual events under test. `domains` gives the
alternative values allowed at candidate nodes. Witness nodes may be held
at their factual values; by default every other endogenous node is eligible.

Exhaustive AC2 witness search plus AC3 subset minimality. A bias toward
small sets is not substituted for the minimality check. Returns :actual-cause,
:not-cause, :not-minimal, or :unresolved when :max-evaluations is exhausted.
:witnesses restricts the allowed context; :max-nodes (default 12) limits
combinatorics. This is not a discovery algorithm or a posterior probability.
sourceraw docstring

attribute-changeclj/s

(attribute-change old new value & [opts])

Attribute a change between two mechanism maps. value evaluates a mixed mechanism map, e.g. the mean outcome of a simulator. The coalition uses new mechanisms for its nodes and old mechanisms elsewhere. Both maps must have identical keys. Uses shapley's exact/sampling options. Fitting mechanisms and choosing a distribution discrepancy remain explicit.

Attribute a change between two mechanism maps. `value` evaluates a mixed
mechanism map, e.g. the mean outcome of a simulator. The coalition uses
new mechanisms for its nodes and old mechanisms elsewhere. Both maps
must have identical keys. Uses `shapley`'s exact/sampling options.
Fitting mechanisms and choosing a distribution discrepancy remain explicit.
sourceraw docstring

attribute-noiseclj/s

(attribute-noise model
                 abduction
                 baselines
                 {:keys [nodes score max-nodes] :or {max-nodes 10}})

Exact noise-coalition attribution for ONE abducted incident. baselines is a nonempty vector of noise maps from a declared normal reference population. Selected nodes retain factual noise; the others receive baseline noise. Other sites keep the incident's noise. score maps a predicted result to a number. Resolves a Shapley report, averaged over the supplied baseline bank, with the incident's :weight retained. Requires complete replay coupling; at most :max-nodes (default 10).

Exact noise-coalition attribution for ONE abducted incident.
`baselines` is a nonempty vector of noise maps from a declared normal
reference population. Selected `nodes` retain factual noise; the others
receive baseline noise. Other sites keep the incident's noise. `score`
maps a predicted result to a number. Resolves a Shapley report, averaged
over the supplied baseline bank, with the incident's :weight retained.
Requires complete replay coupling; at most :max-nodes (default 10).
sourceraw docstring

repairsclj/s

(repairs model abductions candidates success? & [{:keys [cost]}])

Evaluate finite named candidate interventions against an abducted posterior. candidates maps name -> interventions, success? judges a predicted result. Resolves reports sorted by decreasing success probability, optionally including :cost from a function of candidate name. Candidates can include joint repairs; this is enumeration, not a claim of minimality or a Halpern-Pearl actual-causality decision.

Evaluate finite named candidate interventions against an abducted
posterior. `candidates` maps name -> interventions, `success?` judges a
predicted result. Resolves reports sorted by decreasing success
probability, optionally including :cost from a function of candidate name.
Candidates can include joint repairs; this is enumeration, not a claim
of minimality or a Halpern-Pearl actual-causality decision.
sourceraw docstring

shapleyclj/s

(shapley nodes value)
(shapley nodes
         value
         {:keys [method permutations seed max-evaluations]
          :or {method :exact permutations 128 max-evaluations 65536}})

Allocate value of a coalition (set of nodes). Exact or sampled permutation Shapley values. Memoizes coalition evaluations and enforces :max-evaluations (default 65536). :seed makes sampling reproducible. A budget failure is an exception, never a completed attribution.

Allocate `value` of a coalition (set of nodes). Exact or sampled
permutation Shapley values. Memoizes coalition evaluations and enforces
:max-evaluations (default 65536). :seed makes sampling reproducible.
A budget failure is an exception, never a completed attribution.
sourceraw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
←Move to previous article
→Move to next article
Ctrl+/Jump to the search field
× close