FIDE Laws of Chess

io.arxo由 arxo.io 发布官方发布者v0.1.1更新于 Oct 24, 2026

FIDE Laws of Chess (2023) as an executable model: arbiter cases, answers with rules and judgments

发布方自己的服务:UN Charter 1945

已验证Streamable HTTP可网页运行知识与记忆开发者工具

概览

AI 生成的概览

2023 年国际象棋 FIDE 规则的 executable 模型:助手可提出裁判式问题,获得带证明与条文摘录的规则推导答案。

可以做什么
  • 检索与浏览形式化规则:语义搜索、谓词目录、规则说明与条文原文摘录
  • 向模型提问并获得带状态字段的答案,以及展开证明链的解释
  • 运行内置的虚构裁判案例并查看已保存的评估文档
  • 捕获、准备、发布与撤销冻结的答案文档,撤销需单独的密钥
  • 用确定性的 LawQL 查询形式化模型自身结构,并查看发布能力矩阵
适用场景
适合国际象棋裁判判定的教学、研究或演示,用来观察固定版本的模型如何从明确事实推导结论、以及在何处交由人工判断。不能替代正式 FIDE 规则或合格裁判。
运行要求
可使用 mcp.arxo.io 远程端点,或通过 npx 在本地运行,需 Node.js 20+,限 Linux x64 或 macOS arm64。未声明需要身份验证。可选环境变量 FIDE_CHESS_MCP_CALL_TIMEOUT 设置本地主机的单次调用超时。
安装前请注意
发布答案会生成公开文档,须妥善保存单独的撤销密钥,因为仅有公开 id 无法控制文档。该模型仅部分形式化 12 条条文,并非所有情形都能判定,其检查也不证明主题准确性。源文本为固定版本的非官方副本,并非官方出版物。

安装

在 SourceWeft 中

  1. 打开 控制台中的 FIDE Laws of Chess,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Web executable,通过 Streamable HTTP。 远程服务在工作区中配置后即可从网页运行时运行。

交给智能体安装

把这段提示词粘贴到 Claude Code、Codex、Cursor 等智能体,或 SourceWeft 对话中。智能体会读取该服务器的安装指南,先向你展示发布者、端点和登录方式,经你同意后再把它添加到你的客户端。密钥不会写进任何命令。

阅读 https://sourceweft.com/mcp/io.arxo%2Ffide-chess/install.md,并按其中说明把这个 MCP 服务器接入我的客户端。修改任何配置之前,先告诉我它的发布者、端点和登录方式,等我确认。不要把 API 密钥写进命令或我会提交的文件;问我密钥应从哪里获取。

查看智能体所依据的安装指南

其他 MCP 客户端

把它添加到你客户端的 mcpServers 配置中。

{
  "mcpServers": {
    "fide-laws-of-chess": {
      "type": "http",
      "url": "https://mcp.arxo.io/mcp/fide-chess"
    }
  }
}

README

[FIDE Laws of Chess on Arxo]

FIDE Laws of Chess on Arxo

[Smithery]

Explore a chess arbiter's decision through a pinned model, explicit facts and an inspectable answer. Ten retained fictional cases cover illegal moves, flag fall, rapid/blitz exceptions, recording and arbiter judgment.

Node.js 20+ · ESM · canon package 0.1.0 · model 0.1.1 · FIDE edition effective 1 January 2023

Start in Node.js · Cases · Evidence · Depth · Submit a case · Source repository

This is an independent open-source teaching and research demonstration. For an actual chess ruling, use the authentic FIDE Laws and the competent arbiter. Source text and model scope are pinned; the package does not claim general chess-engine capability or complete formalization.

Start in Node.js

Requirements: Node.js 20+. The example uses ES modules; keep the .mjs extension. This recipe was checked on macOS arm64 with Node.js 20.20.2 on 14 October 2026. No global CLI, Git clone or MCP client is needed for this route.

Create a fresh directory, open a terminal there, then run:

sh
npm init -ynpm install --ignore-scripts @arxo/[email protected] @arxo/[email protected]

Save this as example.mjs, then run node example.mjs:

js
import { open } from '@arxo/law';import { loadModel } from '@arxo/canon-fide-chess/chess';import { game, white, getCaseInput } from '@arxo/canon-fide-chess/examples/arbiter';
const model = await loadModel();const chess = await open(model.spec, {  offline: true,  local: { packages: { [model.spec]: model.package } },});
const input = getCaseInput('SecondIllegal');const loss = await chess.truth('game_lost_by', [game, white], input);const draw = await chess.truth('game_drawn', [game], input);console.log(loss.evaluationStatus, loss.truthStatus); // COMPUTED, TRUE_ONLYconsole.log(draw.evaluationStatus, draw.truthStatus); // COMPUTED, NEITHER

The two output lines are loss, then draw:

text
COMPUTED TRUE_ONLYCOMPUTED NEITHER

COMPUTED means the query was evaluated. TRUE_ONLY means it has positive support and no negative support. NEITHER means neither polarity is supported; it does not establish that the proposition is false.

Now replace only getCaseInput('SecondIllegal') with getCaseInput('SecondIllegalNoMate') and run node example.mjs again:

text
REQUIRES_JUDGMENT NEITHERCOMPUTED TRUE_ONLY

The second line now establishes a draw. This case supplies the fact that the opponent cannot checkmate by any legal series. The separate loss query still requests an arbiter's assessment because other reachable loss grounds remain unresolved. Read both status fields; REQUIRES_JUDGMENT identifies an assessment the model does not decide on its own.

To try another retained episode, choose a name from the case table. To propose your own episode, open an issue with the case facts, legal date, query, package/runtime versions, output and the FIDE clause or model rule you think should give a different answer. Use a fictional or anonymized case.

The SDK executes the rules through @arxo/[email protected]. Installation alone does not register this distribution in the SDK's automatic canon resolver: keep the explicit local.packages handoff above. The loader implements no chess decisions or formulas.

[Model and episode to answer and proof]

Use as an MCP server

The separate native MCP wrapper runs the same pinned model over stdio:

sh
npx -y @arxo/[email protected]

Node.js 20+, Linux x64 or macOS arm64. Client configuration, HTTP endpoint, inputs and limitations · OCI recipe · npm recipe · Accepted delivery. This MCP delivery is separate from the Node.js route above.

Choose a case

getCaseInput(name)EpisodeChecked question and result
TouchIntentUnknownA movable own piece; intentional touch not adjudicatedmust_move_first_touched_piece: REQUIRES_JUDGMENT / NEITHER
FirstIllegalOne completed illegal moveLoss: REQUIRES_JUDGMENT / NEITHER; draw: COMPUTED / NEITHER
SecondIllegalTwo illegal moves under the model's specified closureLoss: COMPUTED / TRUE_ONLY
SecondIllegalNoMateTwo illegal moves; inability to checkmate establishedDraw: COMPUTED / TRUE_ONLY
FlagFallFlag observed, time control not completed, mate possibleLoss: COMPUTED / TRUE_ONLY
FlagFallNoMateThe same flag; inability to checkmate establishedDraw: COMPUTED / TRUE_ONLY
RapidFirstIllegalRapid 15+10; first illegal moveOpponent receives 60 seconds; 120-second query is NEITHER
BlitzFirstIllegalCompetitiveBlitz 3+2 under competitive rules B.2Opponent receives 120 seconds; 60-second query is NEITHER
ShortOfTimeRecordingStandard chess, no increment, 240 seconds leftmust_record_moves: COMPUTED / FALSE_ONLY
DeviceWarningElectronic device evident; arbiter gave a warningLoss and differing-penalty queries: COMPUTED / TRUE_ONLY

All 18 original case/query expectations are retained and checked. The fixture export provides caseNames, game, white, black, king, CaseName and getCaseInput(name). Each call returns an independent copy; an unknown name throws RangeError.

[Loss and the explicit inability-to-mate exception]

Facts and arbiter judgments

getCaseInput preserves the CLI's canonical assertions, constants, context and options. The loader supplies neither absent facts nor adjudications. The model's explicitly declared closures are part of its rules; they are not a general assumption that a missing fact is false.

For touch-move, use the two declared arguments — player and piece:

js
import { open } from '@arxo/law';import { loadModel } from '@arxo/canon-fide-chess/chess';import { white, king, getCaseInput } from '@arxo/canon-fide-chess/examples/arbiter';
const model = await loadModel();const chess = await open(model.spec, {  offline: true, local: { packages: { [model.spec]: model.package } },});const answer = await chess.truth(  'must_move_first_touched_piece', [white, king], getCaseInput('TouchIntentUnknown'),);const document = JSON.parse(new TextDecoder().decode(answer.document));console.log(answer.evaluationStatus, answer.truthStatus); // REQUIRES_JUDGMENT, NEITHERconsole.log(document.results[0].judgmentRequests);

A positive, explicitly adjudicated intentional-touch assertion establishes this model's obligation; that path is checked separately. The original missing-judgment fixture stays unchanged.

Missing empirical facts, negative facts and contradictory support retain NEITHER, FALSE_ONLY and BOTH. For the checked empirical conflict, SDK 0.4.3 returns COMPUTED / BOTH: the query was computed and both polarities are supported. Read both fields; do not collapse them to a Boolean. Exact Decimal inputs, such as recorded points, are strings ('0.75').

Complete canonical input for SecondIllegal
json
{  "legalTime": "2023-06-01",  "assertions": [    {      "contentHash": "sha256:696ba690ec316ad1654c94c94886b3d6e9764573460a0ed89f76280496c904fa",      "evidence": [],      "id": "urn:law:examples:chess:arbiter#player",      "kind": "assertion",      "literal": {        "args": [          {            "id": "urn:example:chess:game",            "kind": "entity_ref"          },          {            "id": "urn:example:chess:white",            "kind": "entity_ref"          }        ],        "kind": "literal",        "polarity": "positive",        "predicate": "urn:fide:laws:clir:chess#player_of"      },      "origin": "case_input",      "package": "urn:law:examples:chess:arbiter"    },    {      "contentHash": "sha256:9f7706ed8482cd04f869afdd849b90eea3c2e42ca246bf932c8a20f77a1fcc15",      "evidence": [],      "id": "urn:law:examples:chess:arbiter#complete-mate-facts",      "kind": "assertion",      "literal": {        "args": [          {            "id": "urn:example:chess:white",            "kind": "entity_ref"          }        ],        "kind": "literal",        "polarity": "positive",        "predicate": "urn:fide:laws:clir:chess#checked_player"      },      "origin": "case_input",      "package": "urn:law:examples:chess:arbiter"    },    {      "contentHash": "sha256:cd688c83624c70688f10ead443e5c46c32ad7d3310696caf6dad9b80be7c1cb0",      "evidence": [],      "id": "urn:law:examples:chess:arbiter#illegal-count",      "kind": "assertion",      "literal": {        "args": [          {            "id": "urn:example:chess:white",            "kind": "entity_ref"          },          {            "kind": "value",            "type": {              "name": "urn:law:std#Integer"            },            "value": 2          }        ],        "kind": "literal",        "polarity": "positive",        "predicate": "urn:fide:laws:clir:chess#completed_illegal_move_count"      },      "origin": "case_input",      "package": "urn:law:examples:chess:arbiter"    }  ],  "context": {    "decisionTime": "2026-09-08T12:00:00Z",    "knowledgeTime": "2026-09-08T12:00:00Z",    "legalTime": "2023-06-01",    "timezone": "UTC"  },  "options": {}}

This input was captured by released CLI 0.2.3 from the retained .lawcase; the fixture generator does not reproduce chess semantics. Fixture bytes · Capture provenance.

Inspect the evidence

Preserve answer.document as the canonical bytes returned by Arxo. With the same runtime version, pinned model and dependencies, repeated executions of identical complete inputs (query, facts, judgments, temporal context and options) reproduce those bytes and their hashes. answer.proof.nodes identifies the applied rules and their premises.

The current SDK's answer.sources and proof-node source-anchor arrays are empty for these queries. Source links below are an explicit static join of executed producer IDs with anchors in the hash-checked model; they are not additional citations emitted by the evaluator. The pinned publication is the FIDE Handbook, Laws 2023.

This complete example saves the loss answer and prints its model anchor links:

js
import { writeFile } from 'node:fs/promises';import { open } from '@arxo/law';import { loadModel } from '@arxo/canon-fide-chess/chess';import { game, white, getCaseInput } from '@arxo/canon-fide-chess/examples/arbiter';
const model = await loadModel();const chess = await open(model.spec, {  offline: true, local: { packages: { [model.spec]: model.package } },});const answer = await chess.truth('game_lost_by', [game, white], getCaseInput('SecondIllegal'));await writeFile('answer.json', answer.document);const nodes = new Map(model.package.ir.nodes.map(node => [node.id, node]));const sourceLinks = answer.proof.nodes.filter(node => node.rule).map(node => ({  rule: node.rule,  anchors: (nodes.get(node.rule)?.anchors ?? []).map(id => ({    id, locator: nodes.get(id)?.locator,  })),}));console.log(answer.hashes, sourceLinks); // includes SecondIllegalMoveLoses → article/7
What the model knows: native touch-move producer tree

[Native touch-move producer tree]

Produced by chess.unfold('must_move_first_touched_piece', { depth: 2, lang: 'en', quote: 0 }), with no selected case. Complete native tree and text. Recursion depth is separate from formalization depth.

Model and loader API

ImportExact model specExports
@arxo/canon-fide-chess[email protected]models, loadModel(exactSpec), error classes
@arxo/canon-fide-chess/chess[email protected]spec, loadModel()
@arxo/canon-fide-chess/examples/arbiterRetained case inputsIdentifiers, case names and independent input copies

loadModel returns { spec, package, descriptor, pin, questionCatalog }. Root imports read only the catalog and metadata. A load verifies original bytes before parsing the selected world and its catalog, then returns an independent model object. The descriptor remains separate: package.meta.contentHash is the linked world hash; packageContentHash is the original package hash. There are no model imports in this release.

Unknown or versionless specs fail with ModelNotFoundError.code === 'MODEL_NOT_FOUND'. Missing, corrupt or inconsistent model assets fail with ModelIntegrityError.code === 'MODEL_INTEGRITY'. There is no network fallback. TypeScript declarations cover exact specs, relation names, qualified relation names and fixture names; argument arity and value kinds are validated by the SDK at runtime.

Formalization depth

ModelPinned editionMeasured unit / denominatorEXECUTABLEOther measured levelsStatus
[email protected]Effective 1 January 2023en_article / 12 articles12INTERPRETED: 0, ANCHORED: 0, SOURCE_ONLY: 0, NONE: 0partial

The existing boundaries.depth measure reads own package nodes, excluding imports, and the original article-division declaration. All 12 articles have deriving rules; this coarse measure does not establish complete formalization of every clause. 28 anchor references remain unresolved by this article measure and are recorded in the report.

The preface and Appendices A–D are outside this denominator. A and B have executable rules used by the rapid/blitz cases; C's notation and D's organizational material are not executed by this demonstration. Guidelines are outside the retained Laws publication. These areas remain unmeasured by the article report.

Per-unit report records the denominator, edition, source/package/world hashes, original measurement implementation hashes and adapter hash. EXECUTABLE, source presence, completeness, declared scenarios and successful runs are separate claims. The model exposes institutional predicates and a procedure; it declares no deontic norms or full obligation-lifecycle positions.

Scope and verification

The package evaluates presented episodes. Most board/history conditions remain explicit protocol facts. Its limited observed-position slice handles complete known four-piece K/Q/R frames and a specific inability-to-mate case; other positions remain outside that slice. It does not establish general position reachability, parse PGN or construct a tournament pairing. Rating, title, tie-break and Swiss-pairing models are separate packages and are not bundled.

Model 0.1.1 corrects four preparation defects while preserving the original expected outcomes: scoped procedure predicates in the fixtures, and an exact Decimal intermediate before half-point rounding. The selected package passes 103 source scenarios, including six new numeric boundaries, through build, replay and rebuild. The installed demonstration checks all 18 retained questions, loader failures/isolation, explicit and absent judgment, missing/negative/conflicting facts, score boundaries, canonical repeatability, README examples and strict TypeScript.

Checks are addressed to this distribution. Full corpus: not_checked; releaseVerified: false. Delivery checks do not establish subject accuracy or completeness.

Source pins and reproduction

Source pin fixes original model/descriptor/world/catalog bytes and case inputs to an immutable public source revision. Source origin separately records the corpus origins and addressed fixes. English source text is a pinned visible-text extraction (PINNED_UNOFFICIAL_COPY), not a claimed official PDF publication. FIDE attribution and publisher terms are retained in NOTICE; Apache-2.0 covers Arxo-authored code and does not replace those terms.

To rebuild the wrapper from the pinned inputs in the repository:

sh
git clone https://github.com/arxohq/arxo-fide-chess.gitcd arxo-fide-chess/npmnpm ci --ignore-scriptsnpm run build -- --canon ..npm testnpm run test:typesnpm run candidate -- --out /absolute/new-candidate-directory

The candidate script prepares one local tarball and the existing arxo.npm-candidate/1 manifest; it does not publish. Delivery uses the established CI in arxo-io/law. Publishing and verification recipe · Delivery record.

来源:README.md,提交 d4b14bf

工具

16

law_passport

Release passport

Passport of an exact release: purpose, interface, boundaries, checks and performance. The reports section holds the history of measurements, failures included. Entries are paged by JSON Pointer; next continues the answer.

输入参数name必填limitoffsetversion必填sectionscontentHash必填

law_answer_capabilities

Lens capabilities

A machine-readable matrix of the Lens producers that are actually installed, of replay/projection checks, profiles, limits and the contract tests that confirm them. declared_only means a schema with no executable witness.

无需输入参数。

law_capture_answer

Capture a result for a Lens

Run a registered producer and obtain producerControl/0.2 for a later verifiable preparation of a Lens. The producer is chosen only from the shipped registry.

输入参数request必填producer必填

law_prepare_answer

Prepare a public write-up

At the explicit request of the user, repeat between 1 and 12 earlier law_ask or law_process_run calls, compare their replayControl strictly, and prepare a non-public frozen document for 24 hours. The client never supplies the machine answer: the server obtains it only by executing afresh. A divergence in any input, in the law, in a resource, in the server code, in the engine library or in the result rejects the document as a whole.

输入参数languagequestion必填assistantcalculationsproducerRunsdocumentVersion

law_publish_answer

Publish a write-up

Publish a prepared document. Repeating it with the same preparationId idempotently returns the same URL and the same separate revocation secret.

输入参数preparationId必填

law_revoke_answer

Revoke a write-up

Revoke a published document using its separate secret. The public id alone grants no control; revocation closes the HTML page, the API and the download.

输入参数publicId必填revokeSecret必填

law_packages

Catalogue of law

The catalogue of formalised law: instruments, predicates with signatures, the boundaries of coverage. This is where the NAMES of predicates come from — they must never be guessed. But do NOT start from the catalogue when looking for the right instrument: the overview is large, and the title of an instrument rarely matches the words of a question ("Newton's laws of motion" contains no word "physics"). A question in your own words goes to law_search first, which returns addresses; the catalogue is for the exact signature of what you found. With no arguments — the overview: one line per instrument (key, title, legal order, counters of rules, facts, signatures, norms, constants); a whole instrument — package="kz-gpk"; a search over the signatures, labels and constants of every instrument — query="substring". All three modes are PAGED: limit and offset, with the remainder named in the text (`showing a–b of N; k more`) and in structuredContent (total, truncated, next — a ready-made continuation call). The unit of a page is named by pageUnit: the overview and query page over INSTRUMENTS (20 and 20 by default), package=… pages over the SIGNATURES of one instrument (20 by default, 300 at most) — large codes carry thousands. package=… together with catalog=… pages a separate list of the instrument: "questions" — the CATALOGUE OF QUESTIONS: which enquiries are provided for (a question in words, a form, a predicate or norms) and what the instrument does NOT answer, with the type of reason; a card is a template of an enquiry, not an answer, and not every instrument has one; "norms" — the NORMS of the instrument, "constants" — the CONSTANTS (names of declarations). "task-guides" — TASK GUIDES: the order of applying a canon to a document — what to gather, which cards to ask and how to read the answers; a guide answers nothing. catalog="task-guides" is allowed without package too — every guide of the profile; guide=… — the detail of one guide; the walkthrough — MCP Prompts under th

输入参数guidelimitqueryoffsetcatalogpackage

law_ask

Ask the law

Put a question to formalised law. When the answer is "not established" it carries whyNot — the engine's why_not report: the candidate rules and the state of every conjunct (satisfied / not satisfied / undetermined); the missing facts are visible there and need not be guessed. BEFORE THE FIRST call obtain the predicate names through law_search (a question in your own words → addresses) or law_packages (the signatures of a known instrument) — an invented name will be rejected. If the tool returned an error or "not established", THAT IS THE ANSWER: pass it to the user and do not substitute general knowledge about the law of some other country. But "I found no suitable instrument" is NOT an answer until law_search has been asked: silence of the catalogue is a property of searching by title, not a conclusion about the corpus. kind='truth' — whether a fact is established; kind='collect' — enumerate the records; kind='deadline' — compute a time limit on the official calendar; kind='positions' — which DUTIES arose from the facts and what their statuses are; kind='why_not' — the why_not report on the same goal, whatever the status of the answer. The answer carries the rules applied, the warnings and the provenance with hashes; truth/collect also carry a signature block for presentation. The server does not guess: where a norm is not formalised, the answer is "not established" or an error.

输入参数argscalcdayskindunitafterfactsproofcutoffcontextfocusedpackage另有 10 个

law_screen

Population screening

Build a necessary condition — a superset — for the preliminary selection of rows from an external source. This is NOT a legal answer and NOT SQL: the result is a typed tree and a manifest of the extensions up to TRUE. Every row that passes must then be computed in full by the engine, with a proof graph, on the same snapshot of the data. The binding is passed as a pinnable object; sourceSchemaContentHash is the actual hash of the source schema and is compared loudly with the pin. Case facts that carry provenance (origin, document, quote, extractor) are supplied to law_ask, not here. The confidence figure is read by the package EvidencePolicy, not by this tool and not by the engine.

输入参数goal必填binding必填package必填legalTimesourceSchemaContentHash必填

law_rules

Rules of inference

The rules of formalised law put into words: exactly how a predicate is derived (premises, source articles). Call this BEFORE supplying facts to law_ask — the rules say which facts are needed instead of leaving them to be guessed. For large instruments package=… returns a table of contents; the full text comes from predicate=…. The listing by package is paged: limit (20 by default, 500 at most) and offset; the remainder is named in the text (`showing a–b of N; k more`) and in structuredContent (total, truncated, next — a ready-made continuation call).

输入参数langlimitoffsetpackagecontractpredicateinputLimitinputOffset

law_explain

Unfold the proof

Unfold the proof of a law_ask answer into a chain "rule ← premises → conclusion". The compact input: question (the original law_ask arguments, truth/collect), resultHash and codeHash from the provenance of the answer. The server repeats the computation and compares the hashes; if anything changed it refuses explicitly. Alternatively pass the evaluation from law_ask(proof=true). answerResource=fullAnswer.uri explains a stored compact snapshot without recomputing and without the client loading pages; by default only the proofRef chain. nodeId selects one node and all of its premises (up to 24 KB, otherwise an explicit refusal). proofHash refers to the whole graph; scope marks the part selected.

输入参数nodeIdcodeHashquestionevaluationresultHashanswerResource

law_inspect

Evaluation inspector

Evaluation inspector over a SAVED evaluation document: summary — the origin card, resultHash and snapshot verification, listings of results, positions and issues; slice — the closure of proof nodes for a query, rule, position or node with addresses, both sides of BOTH, defeats, values, names resolved against the snapshot; diff — what changed between two documents on the context, result and justification levels; locate — the declaration by StableId. Nothing is evaluated or recomputed: the source is evaluation from law_ask(proof=true) or an answerResource. Missing data is a limit state (limits), never a negation.

输入参数pageindexbundleselectagainstcontextsourcessnapshotoperation必填evaluationanswerResource

law_case_ask

Case package: ask

The ask operation: run a registered case of a case package over its pinned dependencies and return the answer: by default a projection of the evaluation document without the proof graph, on responseMode full or proof: true the canonical document with a proof and a manifest. The question is JSON per query.schema.json (query), an evaluate string (evaluate + queryId), a saved queryId without query, or card + args. A refusal to prepare is an error with an LDC-* code, never an empty answer.

输入参数argscardcaseproofquerypackage必填queryIdevaluateresponseMode

law_sources

Official text

Sources: by default short excerpts (view=summary), 5 texts per page, with the address of the full text in fragments[].full. Either package or fragment is required (a StableId from law_search/law_rules). view=full returns exact parts of the text: textRange sets a range of Unicode characters, fragments[].next is the continuation with a contentHash. The hash refers to the WHOLE source, not to the excerpt or the part. textOffset/textLimit require fragment; a continuation requires contentHash. Lists are paged with offset/limit; the answer budget may shrink a page.

输入参数viewlimitoffsetstatuspackagefragmentlanguagetextLimittextOffsetcontentHash

law_query

LawQL query

A deterministic LawQL query over the CLIR of a formalization: a question about the model of the act itself, not about a case. Relations (14): anchors, edges, fields, imports, interpretations, labels, links, literals, nodes, norms, positions, rules, variables, windows. Full field lists: `law query --schema`. Functions (9): anchor/1, labels/1..2, short/1, contains/2, overlaps/2, starts_with/2, ends_with/2, position/2, derivation/2. exists/not exists over a bound variable; equality and membership only, no arithmetic and no ordering comparisons. Scope: corpus by package.name (for example kz.corpus.labour_code, not a file name) or a glob; without corpus, the whole profile slice; a scope outside the profile is empty (CORPUS_EMPTY). Examples: `from r in rules where r.head_predicate == "urn:…#eligible" select r.id as producer, r.strength as strength, anchor(r.id) as anchors` — who produces; `from l in literals where l.predicate == "urn:…#eligible" select l.node as reader, l.context as context` — who reads; `query eligible over "pkg" { for x: Person; where applicant(x); select eligible(x); }` — inference by the core. This is orchestration over the CLIR and the core; no new legal semantics is implemented here. Instead of text, a question from the catalog with arguments: anchors-of, imports-of, links-of, producers, readers, type-step (see `law query --list` for the set) (predicate/node/type parameters are URNs, pkg is a package.name or a glob). A structural answer is a queryPage: resultHash of the full queryResult, snapshot (hash of the scope package list), rowCount, rows by rowLimit (20, at most 5000) and rowOffset, next with the snapshot for continuation; full: true returns the full queryResult when the scope is one package. Every row carries provenance (CLIR nodes); an empty answer carries the explain funnel (emptyAt names the clause); errors carry LDC-Qxxxx codes with hints; a source product too wide is refused before execution (QUERY_TOO_BROAD), a continuation on another

输入参数casefulllimitquerycorpusenginequestionrowLimitsnapshotargumentsrowOffset

版本历史

2
  1. v0.1.1最新Oct 15, 2026
  2. v0.1.0Oct 14, 2026

评分

已满足适用检查项的 100%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通必需25 分
  • 已声明认证方式必需10 分
  • 已列出工具必需15 分
  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分

其他 Arxo 集成