Skip to content
docs
Arxo ↗

A real article: source and anchor

For LLMs5 sections

Until now we worked with a fictional archive. Now — article 175 of the Social Code of the Republic of Kazakhstan, the right to disability benefit. A formalisation of this article already exists: the worked example, selected as pilot teaching material.

The first thing worth seeing in a real act is how little of it is rules proper and how much is binding to the text.

Declarations carry labels. These are not comments: a label is what the predicate will be called in the verbalised exposition a lawyer reads. A declaration without a label is verbalised by its identifier, and the lawyer signs a text that reads as code.

Arxo Law
language "law.core" version "0.2";
package tutorial.kz.social version "0.1.0";
namespace "urn:law:tutorial:kz:social";
entity Actor {
label ru-KZ official "Субъект права";
}
entity Person : Actor {
label ru-KZ official "Лицо";
}
entity DisabilityStatus {
label ru-KZ official "Группа инвалидности";
}
entity Benefit {
label ru-KZ official "Пособие";
}
const KZ: Jurisdiction = entity_ref("urn:law:jurisdiction:KZ");
const DisabilityBenefit: Benefit = entity_ref("urn:law:tutorial:kz:social#DisabilityBenefit") {
label ru-KZ official "Пособие по инвалидности";
};
relation disability_established(person: Person, status: DisabilityStatus, from: Date) kind institutional {
label ru-KZ official "инвалидность установлена";
}
relation permanently_resident(person: Person, jurisdiction: Jurisdiction, during: Interval<Date>) kind institutional {
label ru-KZ official "постоянно проживает на территории";
}
relation citizen_of(person: Person, jurisdiction: Jurisdiction) kind institutional {
label ru-KZ official "является гражданином";
}
relation foreign_citizen(person: Person) kind institutional {
label ru-KZ official "является иностранцем";
}
relation stateless_person(person: Person) kind institutional {
label ru-KZ official "является лицом без гражданства";
}
relation entitled(person: Person, benefit: Benefit) kind institutional {
label ru-KZ official "имеет право на пособие";
}

The labels read: “Subject of law”, “Person”, “Disability group”, “Benefit”, “Disability benefit”, “disability is established”, “permanently resides on the territory”, “is a citizen”, “is a foreigner”, “is a stateless person”, “is entitled to the benefit”.

KZ and DisabilityBenefit are not “domain constants” or strings: they are individuals, declared as constants. The core rejects a bare name in term position (LDC-E1330), and not from pedantry: an unresolved name would pass the whole pipeline silently, and the norm would never fire. The declaration gives the individual an entity_ref address by which the case recognises it.

Note permanently_resident: the third argument is Interval<Date>. Residence is not a fact but a fact over an interval, and the article speaks exactly so. The temptation to drop the interval (“let us assume residence now”) costs dearly: it cannot be restored later, because the case will no longer hold interval data.

Arxo Law
@source("KZ-SOCIAL-CODE-224-VII-ART-175")
rule DisabilityBenefitEntitlement strict {
label ru-KZ official "Статья 175. Право на пособие по инвалидности";
for person: Person;
for status: DisabilityStatus;
for from: Date;
when disability_established(person, status, from)
and permanently_resident(person, KZ, [from, infinity))
and (citizen_of(person, KZ) or foreign_citizen(person) or stateless_person(person));
then entitled(person, DisabilityBenefit);
}

The rule label reads: “Article 175. The right to disability benefit”.

The three branches in parentheses — citizen, foreigner, stateless person — are not the formaliser’s caution but the article’s literal composition. The disjunction is material here: removing any branch narrows the circle of entitled persons, and does so silently.

@source("KZ-SOCIAL-CODE-224-VII-ART-175") is a string. It says where the norm is derived from and lands in the proof: the explanation of the answer will show it next to the conclusion. But it guarantees nothing about the text. If the statute changes, the string stays the same.

This is easy to verify: search the repository for this anchor and you will find only the example itself and the CLIR produced from it. Not a single declared source, not one edition, not one fragment with a hash.

This is no reproach to the example. It is the boundary between two different things that are easy to confuse:

What it givesWhat it does not give
@source("…")the norm’s address in the act, landing in the proofany link to the text bytes
source / edition / fragmentpinned text, verified by a content hashby itself — nothing about applicability

The three levels from the first tutorial, now on a real act.

Arxo Law
source SOCIAL_CODE {
kind code;
jurisdiction KZ;
number "224-VII";
}
edition SOCIAL_CODE_2023_RU of SOCIAL_CODE {
language ru-KZ;
officiality official;
adopted @2023-04-20;
in_force [@2023-07-01, infinity);
materialization_status ABSTRACT_ONLY;
}

And here is the fragment — where one must be precise about what exactly is declared.

Arxo Law
fragment SOCIAL_CODE_ART175_TEACHING in SOCIAL_CODE_2023_RU {
kind article;
locator "article/175";
text ru-KZ unofficial """Учебная выдержка, не официальный текст: право на пособие по
инвалидности имеют лица с установленной инвалидностью, постоянно проживающие
на территории Республики Казахстан.
""";
content_hash "sha256:46a9b7144940cc1e85c2878749f2903a7ba915b8f72bf9ec29a72808dbc7483d";
}

The quoted fragment reads: “Teaching excerpt, not the official text: persons with established disability permanently residing on the territory of the Republic of Kazakhstan are entitled to disability benefit.”

The word unofficial carries all the weight here. The official text of article 175 is concrete bytes published by the authorised body; they cannot be written from memory, they are pinned — downloaded, placed next to the package, and presented to the compiler, as shown in the pinned-edition lesson. Several acts are pinned this way, including the Civil Code and the republican budget law.

The edition honestly declares materialization_status ABSTRACT_ONLY: there is nothing to pin as a publication. This is no formality — this field decides what the compiler requires of fragments, and how the coverage report counts the act’s textual coverage.

Meanwhile it is useful to remember the asymmetry: declaring text official is easy, while the compiler answers for it. It recomputes a fragment’s content_hash at every check: replace even one word in the text without touching the hash, and the build stops with LDC-E5201. Lying about the text content works only once.

Article 175 speaks not only of the right but of the date from which the benefit is granted — and on that date the core says “no”. The next tutorial: from the article text to the norm, and where the boundary of the expressible runs.

The exercise for this page is /tutorials/exercise-real-article-source/.

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

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