Skip to content
docs
Arxo ↗

Immunity locks the effect

For LLMs6 sections

I want to protect a status from change while keeping the fact of the attempt.

Incorrect form
protected_effect sign(p);

Immunity must match the legal effect valid(p), not the action sign(p). When they match and there is no priority, a conflict arises and the effect does not materialize.

Arxo Law
language "law.core" version "0.2";
package recipes.a.r07 version "0.1.0";
namespace "urn:recipe:a-positions:07";
entity Person;
relation registered(p: Person);
relation done(p: Person);
relation sign(p: Person);
relation competent(p: Person);
relation valid(p: Person);
rule Grant strict { for p: Person; when registered(p);
then power Permit { holder p; exercise sign(p); valid_when competent(p); effect create(valid(p)); };
}
relation protected(p: Person);
rule Protect strict { for p: Person; when registered(p) and protected(p);
then immunity Shield { holder p; against p; protected_effect valid(p); window [@2026-09-01, @2026-09-10]; };
}
Facts and snapshotQuestionAnswer
unresolved pair; 2026-09-05truth(valid(entity_ref("urn:recipe:a-positions:07:p")))truth_status == NEITHER; / UNRESOLVED_NORMATIVE_CONFLICT
the attempt is kept; 2026-09-05truth(sign(entity_ref("urn:recipe:a-positions:07:p")))truth_status == TRUE_ONLY; / COMPUTED
no immunity; 2026-09-05truth(valid(entity_ref("urn:recipe:a-positions:07:p")))truth_status == TRUE_ONLY; / COMPUTED
unresolved pair blocks effect
Arxo Law
test "unresolved pair blocks effect" {
given {
context {
legal_time @2026-09-05;
decision_time @2026-09-05T09:00:00+05:00;
knowledge_time @2026-09-30T09:00:00+05:00;
timezone "Asia/Almaty";
}
assert registered(entity_ref("urn:recipe:a-positions:07:p")); assert competent(entity_ref("urn:recipe:a-positions:07:p")); assert sign(entity_ref("urn:recipe:a-positions:07:p")); assert protected(entity_ref("urn:recipe:a-positions:07:p"));
}
evaluate truth(valid(entity_ref("urn:recipe:a-positions:07:p")));
expect truth_status == NEITHER;
expect evaluation_status == UNRESOLVED_NORMATIVE_CONFLICT;
}
attempt fact survives
Arxo Law
test "attempt fact survives" {
given {
context {
legal_time @2026-09-05;
decision_time @2026-09-05T09:00:00+05:00;
knowledge_time @2026-09-30T09:00:00+05:00;
timezone "Asia/Almaty";
}
assert registered(entity_ref("urn:recipe:a-positions:07:p")); assert competent(entity_ref("urn:recipe:a-positions:07:p")); assert sign(entity_ref("urn:recipe:a-positions:07:p")); assert protected(entity_ref("urn:recipe:a-positions:07:p"));
}
evaluate truth(sign(entity_ref("urn:recipe:a-positions:07:p")));
expect truth_status == TRUE_ONLY;
expect evaluation_status == COMPUTED;
}
no immunity lets effect through
Arxo Law
test "no immunity lets effect through" {
given {
context {
legal_time @2026-09-05;
decision_time @2026-09-05T09:00:00+05:00;
knowledge_time @2026-09-30T09:00:00+05:00;
timezone "Asia/Almaty";
}
assert registered(entity_ref("urn:recipe:a-positions:07:p")); assert competent(entity_ref("urn:recipe:a-positions:07:p")); assert sign(entity_ref("urn:recipe:a-positions:07:p"));
}
evaluate truth(valid(entity_ref("urn:recipe:a-positions:07:p")));
expect truth_status == TRUE_ONLY;
expect evaluation_status == COMPUTED;
}

The incorrect-form variant is executed as a separate package: protected_effect valid(p) is replaced with protected_effect sign(p); a mismatching immunity does not lock valid.

mismatched immunity leaves effect valid
Arxo Law
test "mismatched immunity leaves effect valid" {
given {
context {
legal_time @2026-09-05;
decision_time @2026-09-05T09:00:00+05:00;
knowledge_time @2026-09-30T09:00:00+05:00;
timezone "Asia/Almaty";
}
assert registered(entity_ref("urn:recipe:a-positions:07:p")); assert competent(entity_ref("urn:recipe:a-positions:07:p")); assert sign(entity_ref("urn:recipe:a-positions:07:p")); assert protected(entity_ref("urn:recipe:a-positions:07:p"));
}
evaluate truth(valid(entity_ref("urn:recipe:a-positions:07:p")));
expect truth_status == TRUE_ONLY;
expect evaluation_status == COMPUTED;
}
Python
>>> import runpy
>>> check = runpy.run_path("docs/recipes/a-positions/resources/check.py")
>>> check["check_variant"](https://github.com/arxohq/law/blob/master/docs/recipes/a-positions/7)
'А7: контрфактуал подтверждён; lawc = lawref'

Mutation: protected_effect valid(p); → “; rejection LDC-E1305. Additional counterfactuals are shown as separate scenes.

The physical attempt is kept. Priority and the Power/Immunity resolution profile are covered by Power against immunity; immunity is not the same as a prohibition of the action.

Documentation for Arxo. Writings — blog.arxo.io.

Anonymous visit counts on stats.arxo.io, no cookies.