VIEW THIS AS

Auto mode follows the Route Engine until you choose a viewpoint.

YOU ARE HERE

ROUTE CHECK

CONNECTED TO

WHAT NEXT

Use the canonical route for this room, or HELP if you are unsure.

Edge Technology for Vocabulary | The Scoped Rule Compiler: Can AI Combine True Premises Without Changing Their Subject, Context or Meaning?

Three secondary students review open books and notes together in a classroom.

Edge Technology for Vocabulary needs to preserve the subject and scope of every premise in a chain of reasoning. The Scoped Rule Compiler combines reviewed positive conditions only within a declared entity, context and version. A true fact about one project cannot fill a missing condition about another.

This original eduKate demonstration was locally executed on sixteen synthetic cases. It extends the earlier condition and evidence-join mechanisms into bounded rule closure, not general English reasoning, a deployed system or an independently validated educational intervention.

  • Keep every premise attached to its subject and context.
  • Use reviewed implications, not guessed associations.
  • Preserve explicit false, unknown and missing evidence.
  • Hold conflicting derivations.
  • Reproduce actual local tests.

Contents

1. The hidden meaning of together

A fictional classroom rule says a particular student’s work is reviewable if it is written and checked. A second rule says that reviewable and labelled work is ready for review. If AI combines one student’s writing, another student’s check and a third student’s label, it may produce a formally attractive but invalid conclusion. The individual premises may be accurate; the binding between them is wrong. The centre-level lesson is to keep who, what, where and when attached to an explanation. The edge-level mechanism is a rule evaluator that never merges differently scoped records to satisfy a conjunction.

The earlier Evidence Join Guard concerns compatible records of one observation. This extension asks how reviewed implications can produce further supported statements without escaping their shared context. A conclusion about readiness for review is deliberately not a decision that a student has passed or received approval.

Back to contents

2. Established logic and the local compiler

The Soufflé Datalog documentation explains rule bodies and heads using Horn clauses and grounded variables. Positive rules can derive additional facts from matching premises. The local prototype is much narrower: every predicate is attached to one entity, one scope and one version; rules are applied only within that selected context. It is not a Datalog implementation and provides no general variable substitution, joins, negation-as-failure, existential creation or natural-language parser.

The algorithm repeatedly adds supported heads until no new head can be added. Because the set of rule heads is finite and the loop only adds previously absent heads, the bounded model terminates even in cycles. Explicit false and unknown observations are not promoted to true. A positive derivation conflicting with an explicit negative produces a hold for the entire selected context, a conservative local policy rather than a universal logical requirement.

Back to contents

3. The meaning contract

FieldRole
entityOne reviewed referent throughout the inference.
scopeThe specified fictional project.
versionThe exact definition and rule release.
predicateA reviewed property identifier.
valueTrue, false or explicit unknown.
body and headNonempty conjunction of required positive predicates and its stated consequence.
{
  "query": {
    "entity": "p1",
    "scope": "fictional-project",
    "version": "1",
    "predicate": "ready-for-review"
  },
  "facts": [
    {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "written",
      "value": true
    },
    {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "checked",
      "value": true
    },
    {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "labelled",
      "value": true
    }
  ],
  "rules": [
    {
      "id": "R1",
      "scope": "fictional-project",
      "version": "1",
      "body": [
        "written",
        "checked"
      ],
      "head": "reviewable"
    },
    {
      "id": "R2",
      "scope": "fictional-project",
      "version": "1",
      "body": [
        "reviewable",
        "labelled"
      ],
      "head": "ready-for-review"
    }
  ]
}

A source reviewer must establish the meaning and applicability of these identifiers. A matching string is not proof that two real records describe the same entity. The function treats input records as declared fixtures. It does not authenticate the source, determine permission or prove the rule itself is valid.

Back to contents

4. Five Fencing moves for the classroom

Start with the relevant work. Add the first property: written. Add the required check for that same work. Establish the declared intermediate condition of reviewability. Then add the relevant label and inspect the final consequence. Try a fresh example in which the check belongs to a different project. The learner should identify the missing connection before seeing the engine’s hold. Do not require a student to learn Datalog to practise this distinction. The method connects familiar language to an inspectable reasoning structure.

Back to contents

5. Executable scoped closure

function infer(q,facts,rules){
 const s=x=>typeof x==="string"&&x.length>0,ctx=["entity","scope","version"];
 if(!q||!ctx.every(k=>s(q[k]))||!s(q.predicate)||!Array.isArray(facts)||facts.length>200||!Array.isArray(rules)||rules.length>80)return {status:"HOLD_INPUT"};
 if(!facts.every(f=>f&&ctx.every(k=>s(f[k]))&&s(f.predicate)&&[true,false,null].includes(f.value)))return {status:"HOLD_FACT"};
 if(!rules.every(r=>r&&s(r.id)&&s(r.scope)&&s(r.version)&&s(r.head)&&Array.isArray(r.body)&&r.body.length>0&&r.body.length<=12&&r.body.every(s)&&new Set(r.body).size===r.body.length)||new Set(rules.map(r=>r.id)).size!==rules.length)return {status:"HOLD_RULE"};
 const yes=new Set(),no=new Set(),trace=[];
 for(const f of facts.filter(x=>ctx.every(k=>x[k]===q[k]))){if(f.value===true)yes.add(f.predicate);if(f.value===false)no.add(f.predicate)}
 const active=rules.filter(r=>r.scope===q.scope&&r.version===q.version);
 let changed=true;
 while(changed){changed=false;for(const r of active){if(!yes.has(r.head)&&r.body.every(x=>yes.has(x))){yes.add(r.head);trace.push(r.id);changed=true;}}}
 if([...yes].some(x=>no.has(x)))return {status:"HOLD_CONFLICT",trace};
 return {status:yes.has(q.predicate)?"SUPPORTED":no.has(q.predicate)?"EXPLICITLY_FALSE":"NOT_ESTABLISHED",trace};
}

SUPPORTED means the query is derived or explicitly present within the supplied context. EXPLICITLY_FALSE means its negative is explicitly recorded, with no positive conflict. NOT_ESTABLISHED does not mean false. HOLD_CONFLICT indicates that a declared positive and negative collide. The trace lists rules that first added a head; it is not a complete proof graph or a count of independent evidence. A subsequent release gate needs its own source and authority checks.

Back to contents

6. Sixteen actual synthetic tests

The function ran locally on sixteen author-defined fixtures. 16 of 16 verdict strings matched expectations, including two rule orders, wrong-subject premises, mismatched releases and an unseeded cycle. No real student or institutional data were used.

IDExpectedObservedPurpose
S01SUPPORTEDSUPPORTEDComplete same-context chain.
S02SUPPORTEDSUPPORTEDRule order cannot erase closure.
S03NOT_ESTABLISHEDNOT_ESTABLISHEDOther person’s fact cannot complete conjunction.
S04NOT_ESTABLISHEDNOT_ESTABLISHEDDifferent project.
S05NOT_ESTABLISHEDNOT_ESTABLISHEDDifferent version.
S06NOT_ESTABLISHEDNOT_ESTABLISHEDUnknown is not true or false.
S07HOLD_CONFLICTHOLD_CONFLICTDerived support conflicts with explicit negative.
S08EXPLICITLY_FALSEEXPLICITLY_FALSEAn explicit negative is retained.
S09NOT_ESTABLISHEDNOT_ESTABLISHEDCycle without evidence cannot bootstrap truth.
S10SUPPORTEDSUPPORTEDA seeded cycle terminates.
S11NOT_ESTABLISHEDNOT_ESTABLISHEDRule release mismatch.
S12HOLD_RULEHOLD_RULEDuplicate rule ID.
S13HOLD_RULEHOLD_RULENo unsupported unconditional implication.
S14SUPPORTEDSUPPORTEDUnrelated subject conflict does not change query context.
S15HOLD_FACTHOLD_FACTString true is not Boolean true.
S16HOLD_INPUTHOLD_INPUTUnresolved entity cannot be inferred.
const tests = [
  {
    "id": "S01",
    "query": {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "ready-for-review"
    },
    "facts": [
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "written",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "checked",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "labelled",
        "value": true
      }
    ],
    "rules": [
      {
        "id": "R1",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "written",
          "checked"
        ],
        "head": "reviewable"
      },
      {
        "id": "R2",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "reviewable",
          "labelled"
        ],
        "head": "ready-for-review"
      }
    ],
    "want": "SUPPORTED"
  },
  {
    "id": "S02",
    "query": {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "ready-for-review"
    },
    "facts": [
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "written",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "checked",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "labelled",
        "value": true
      }
    ],
    "rules": [
      {
        "id": "R2",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "reviewable",
          "labelled"
        ],
        "head": "ready-for-review"
      },
      {
        "id": "R1",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "written",
          "checked"
        ],
        "head": "reviewable"
      }
    ],
    "want": "SUPPORTED"
  },
  {
    "id": "S03",
    "query": {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "ready-for-review"
    },
    "facts": [
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "written",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "checked",
        "value": true
      },
      {
        "entity": "p2",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "labelled",
        "value": true
      }
    ],
    "rules": [
      {
        "id": "R1",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "written",
          "checked"
        ],
        "head": "reviewable"
      },
      {
        "id": "R2",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "reviewable",
          "labelled"
        ],
        "head": "ready-for-review"
      }
    ],
    "want": "NOT_ESTABLISHED"
  },
  {
    "id": "S04",
    "query": {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "ready-for-review"
    },
    "facts": [
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "written",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "checked",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "other",
        "version": "1",
        "predicate": "labelled",
        "value": true
      }
    ],
    "rules": [
      {
        "id": "R1",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "written",
          "checked"
        ],
        "head": "reviewable"
      },
      {
        "id": "R2",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "reviewable",
          "labelled"
        ],
        "head": "ready-for-review"
      }
    ],
    "want": "NOT_ESTABLISHED"
  },
  {
    "id": "S05",
    "query": {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "ready-for-review"
    },
    "facts": [
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "written",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "checked",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "2",
        "predicate": "labelled",
        "value": true
      }
    ],
    "rules": [
      {
        "id": "R1",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "written",
          "checked"
        ],
        "head": "reviewable"
      },
      {
        "id": "R2",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "reviewable",
          "labelled"
        ],
        "head": "ready-for-review"
      }
    ],
    "want": "NOT_ESTABLISHED"
  },
  {
    "id": "S06",
    "query": {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "ready-for-review"
    },
    "facts": [
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "written",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "checked",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "labelled",
        "value": null
      }
    ],
    "rules": [
      {
        "id": "R1",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "written",
          "checked"
        ],
        "head": "reviewable"
      },
      {
        "id": "R2",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "reviewable",
          "labelled"
        ],
        "head": "ready-for-review"
      }
    ],
    "want": "NOT_ESTABLISHED"
  },
  {
    "id": "S07",
    "query": {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "ready-for-review"
    },
    "facts": [
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "written",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "checked",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "labelled",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "ready-for-review",
        "value": false
      }
    ],
    "rules": [
      {
        "id": "R1",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "written",
          "checked"
        ],
        "head": "reviewable"
      },
      {
        "id": "R2",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "reviewable",
          "labelled"
        ],
        "head": "ready-for-review"
      }
    ],
    "want": "HOLD_CONFLICT"
  },
  {
    "id": "S08",
    "query": {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "ready-for-review"
    },
    "facts": [
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "ready-for-review",
        "value": false
      }
    ],
    "rules": [],
    "want": "EXPLICITLY_FALSE"
  },
  {
    "id": "S09",
    "query": {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "ready-for-review"
    },
    "facts": [],
    "rules": [
      {
        "id": "C1",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "ready-for-review"
        ],
        "head": "reviewable"
      },
      {
        "id": "C2",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "reviewable"
        ],
        "head": "ready-for-review"
      }
    ],
    "want": "NOT_ESTABLISHED"
  },
  {
    "id": "S10",
    "query": {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "ready-for-review"
    },
    "facts": [
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "reviewable",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "labelled",
        "value": true
      }
    ],
    "rules": [
      {
        "id": "R2",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "reviewable",
          "labelled"
        ],
        "head": "ready-for-review"
      },
      {
        "id": "C1",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "ready-for-review"
        ],
        "head": "reviewable"
      }
    ],
    "want": "SUPPORTED"
  },
  {
    "id": "S11",
    "query": {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "ready-for-review"
    },
    "facts": [
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "written",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "checked",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "labelled",
        "value": true
      }
    ],
    "rules": [
      {
        "id": "R1",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "written",
          "checked"
        ],
        "head": "reviewable"
      },
      {
        "id": "R2",
        "scope": "fictional-project",
        "version": "2",
        "body": [
          "reviewable",
          "labelled"
        ],
        "head": "ready-for-review"
      }
    ],
    "want": "NOT_ESTABLISHED"
  },
  {
    "id": "S12",
    "query": {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "ready-for-review"
    },
    "facts": [
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "written",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "checked",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "labelled",
        "value": true
      }
    ],
    "rules": [
      {
        "id": "R1",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "written",
          "checked"
        ],
        "head": "reviewable"
      },
      {
        "id": "R1",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "written",
          "checked"
        ],
        "head": "reviewable"
      }
    ],
    "want": "HOLD_RULE"
  },
  {
    "id": "S13",
    "query": {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "ready-for-review"
    },
    "facts": [
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "written",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "checked",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "labelled",
        "value": true
      }
    ],
    "rules": [
      {
        "id": "empty",
        "scope": "fictional-project",
        "version": "1",
        "body": [],
        "head": "ready-for-review"
      }
    ],
    "want": "HOLD_RULE"
  },
  {
    "id": "S14",
    "query": {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "ready-for-review"
    },
    "facts": [
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "written",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "checked",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "labelled",
        "value": true
      },
      {
        "entity": "p2",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "written",
        "value": false
      }
    ],
    "rules": [
      {
        "id": "R1",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "written",
          "checked"
        ],
        "head": "reviewable"
      },
      {
        "id": "R2",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "reviewable",
          "labelled"
        ],
        "head": "ready-for-review"
      }
    ],
    "want": "SUPPORTED"
  },
  {
    "id": "S15",
    "query": {
      "entity": "p1",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "ready-for-review"
    },
    "facts": [
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "written",
        "value": "true"
      }
    ],
    "rules": [
      {
        "id": "R1",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "written",
          "checked"
        ],
        "head": "reviewable"
      }
    ],
    "want": "HOLD_FACT"
  },
  {
    "id": "S16",
    "query": {
      "entity": "",
      "scope": "fictional-project",
      "version": "1",
      "predicate": "ready-for-review"
    },
    "facts": [
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "written",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "checked",
        "value": true
      },
      {
        "entity": "p1",
        "scope": "fictional-project",
        "version": "1",
        "predicate": "labelled",
        "value": true
      }
    ],
    "rules": [
      {
        "id": "R1",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "written",
          "checked"
        ],
        "head": "reviewable"
      },
      {
        "id": "R2",
        "scope": "fictional-project",
        "version": "1",
        "body": [
          "reviewable",
          "labelled"
        ],
        "head": "ready-for-review"
      }
    ],
    "want": "HOLD_INPUT"
  }
];
for (const x of tests) console.log(x.id,infer(x.query,x.facts,x.rules),x.want);

The local suite compares statuses, not the complete trace or real-world extraction accuracy. Independent tests should verify derivation traces, wrong aliases, inconsistent authority and larger rule graphs. Reordering the input is only one narrow invariance check.

Back to contents

7. VocabularyOS and the centre-to-edge path

The source-span witness connects a premise to a source. Reference binding identifies the work. The argument-frame guard protects roles. This compiler evaluates positive scoped implications. The status transition and composed handover gates remain separate. The system should be able to explain an unresolved result and return it to the responsible reviewer. No inference status automatically changes a real student’s work or gives an AI permission to act.

Ladder areaExample
L0–L4Attend, identify, name, explain and recall the relevant condition.
L5–L8Encode, relate, combine and distinguish the scope of premises.
L9–L11Transfer, interpret and formalise a fresh reasoning problem.
L12–L15Trace changes, critique a derivation, govern a rule register and test a needed distinction.

The L0–L15 ladder is an original teaching framework, not an official or validated assessment scale. Choose the relevant operation. A software verdict cannot demonstrate the learner’s independent understanding.

Back to contents

8. Four-week laboratory

WeekActivityEvidence
1Review fictional conjunctions and implication directions.Source-grounded rules and entity labels.
2Reproduce tests and commission independent counterexamples.Wrong releases, correct holds and trace checks.
3Test a separate extraction stage and compare a simpler unscoped baseline.Scope errors and teacher correction effort.
4Use new authorised classroom tasks without the earlier answer.Independent transfer and time, separate from software results.

Research involving children requires appropriate school permission, consent or assent and privacy safeguards. The prototype was not deployed. No human experiment or educational treatment effect is claimed.

Back to contents

9. References and connected research

Back to contents