Edge Technology for Vocabulary needs a correction mechanism that preserves what was already right. If a learner or AI changes some registered members may collect if the room is available into all members will collect, repairing the mistake should not accidentally replace the correct action, source or proposal status. A transactional semantic repair patch specifies what changes, what must remain unchanged and which source supports the correction.
This original eduKate demonstrator extends the existing semantic redline and versioned vocabulary work into executable repair preparation. It ran twelve synthetic tests. It is not a deployed editing service, a fully implemented database transaction, independently validated software or evidence of student learning gains.
- Correct reviewed fields without overwriting unrelated meanings.
- Require the expected old value and record revision.
- Prepare the full patch or hold without partial changes.
- Keep preparation, commitment and verification separate.
- Inspect reproducible test outputs and learning-transfer boundaries.
Contents
- 1. Repair is a different operation from rewriting
- 2. Established technology and the local design
- 3. Fence the correction, not the entire answer
- 4. Local repair contract
- 5. Executable JavaScript demonstrator
- 6. Executed synthetic regression checks
- 7. Integrating repair with the learning and AI runtime
- 8. Vocabulary ladder: the correction as an observable operation
- 9. Four-week validation and teaching laboratory
- 10. References and connected research
1. Repair is a different operation from rewriting
A student has correctly recorded that a club is considering a kit collection but has changed some registered members may collect if the room is available into all members will collect. The right repair is not to regenerate an entirely different paragraph. Preserve the action and proposal status, restore the group, modality and condition, and verify that no unrelated detail changes. This is an extension of the semantic redline workbench: redlining locates a discrepancy; a transactional patch specifies a bounded repair and its preconditions.
The centre of vocabulary instruction teaches these differences in complete sentences. The edge must carry the difference through a computer operation. A correction received after another teacher has updated the record may no longer apply. A repair that changes one field and fails on the next can leave an incoherent description. The system must distinguish a proposed correction from a committed correction, and neither should be confused with evidence that a learner has understood it.
2. Established technology and the local design
The JSON Patch specification (RFC 6902) describes operations including testing a value and replacing it, and specifies failure handling. Its use with HTTP PATCH has atomic application semantics. HTTP Semantics (RFC 9110), section 13.1.1 defines If-Match preconditions for preventing unintended overwrites. These are existing engineering mechanisms. The local eduKate function is inspired by them, not a conformant JSON Patch or HTTP implementation.
Its input is a flat structured semantic record, an expected revision, a list of explicit old and new values and a reviewed reference. The code prepares a new record without mutating the input. In production, a database transaction or conditional write must check the revision again at commit time; this demonstration does not implement storage, concurrency, authentication or authorisation. A review flag in an input fixture is not evidence of actual review or permission.
3. Fence the correction, not the entire answer
| Original field | Candidate | Reviewed reference |
|---|---|---|
| group | all | some registered members |
| modality | will | may |
| condition | null / unresolved | room available |
| outcome | collect kit | collect kit |
| status | proposed | proposed |
Begin with what the learner already got right: kit collection is the subject. Add the group distinction, then the modal distinction, then the condition. The three changes are connected; the final statement should not be released as corrected until all relevant defects have been inspected. A teacher can discuss one distinction at a time even if the data repair is prepared as one batch. The Fencing Method controls instructional complexity, whereas the transaction controls consistency of the stored representation. These are different jobs. The student should later paraphrase a fresh notice without copying the corrected record.
4. Local repair contract
{
"record": {
"id": "notice-01",
"rev": 4,
"source": "notice-v1",
"fields": {
"group": "all",
"modality": "will",
"condition": null,
"outcome": "collect kit",
"status": "proposed"
}
},
"request": {
"id": "notice-01",
"baseRev": 4,
"source": "notice-v1",
"changes": [
{
"field": "group",
"old": "all",
"next": "some registered members"
},
{
"field": "modality",
"old": "will",
"next": "may"
},
{
"field": "condition",
"old": null,
"next": "room available"
}
]
},
"reference": {
"id": "notice-v1",
"reviewed": true,
"fields": {
"group": "some registered members",
"modality": "may",
"condition": "room available",
"outcome": "collect kit",
"status": "proposed"
}
}
}
The reference is a synthetic reviewed-value fixture. A real system must inspect the original source and link the record to the exact reviewed release. The function only accepts five allow-listed fields, scalar strings or null, a nonempty change list and a safe integer revision. It rejects duplicate edits, stale revisions, mismatched old values and replacements not present in the reference. A valid patch can still omit an additional necessary correction; PREPARED does not mean that every field is verified. Use a separate whole-record review and release gate.
5. Executable JavaScript demonstrator
function repair(record,request,reference){
const allowed=["group","modality","condition","outcome","status"];
const scalar=x=>x===null||typeof x==="string";
if(!record||!request||!reference||typeof record.id!=="string"||!Number.isSafeInteger(record.rev)||record.rev<0||record.rev===Number.MAX_SAFE_INTEGER||!record.fields||!reference.fields||!Array.isArray(request.changes)||!request.changes.length)return {status:"HOLD_INPUT"};
if(record.id!==request.id||record.rev!==request.baseRev)return {status:"HOLD_STALE"};
if(reference.reviewed!==true||reference.id!==record.source||request.source!==reference.id)return {status:"HOLD_REFERENCE"};
const seen=new Set(),next={...record.fields};
for(const c of request.changes){
if(!c||!allowed.includes(c.field)||seen.has(c.field)||!scalar(c.old)||!scalar(c.next))return {status:"HOLD_PATCH"};
seen.add(c.field);
if(!Object.hasOwn(record.fields,c.field)||record.fields[c.field]!==c.old)return {status:"HOLD_PRECONDITION"};
if(!Object.hasOwn(reference.fields,c.field)||reference.fields[c.field]!==c.next)return {status:"HOLD_UNSUPPORTED"};
next[c.field]=c.next;
}
return {status:"PREPARED",record:{...record,rev:record.rev+1,fields:next},changed:[...seen]};
}
The original object is not modified. A successful call returns a prepared copy with the revision increased by one and a list of changed fields. A hold returns a reason without a replacement record. The clone is shallow because the demo assumes flat scalar semantic fields; do not extend this to arbitrary nested documents without a tested deep-copy and validation contract. The result is not a committed write or permission to publish.
6. Executed synthetic regression checks
This function was run locally on 2 December 2026. 12 of 12 authored cases matched the expected status, preserved the input under JSON serialization, and, for prepared outputs, matched the expected changed fields and revision. This is an author-run regression suite, not an independent benchmark.
| ID | Expected | Observed | Check |
|---|---|---|---|
| P01 | PREPARED | PREPARED | All three reviewed corrections prepared together. |
| P02 | HOLD_STALE | HOLD_STALE | Old revision cannot overwrite newer work. |
| P03 | HOLD_PRECONDITION | HOLD_PRECONDITION | Expected old value differs. |
| P04 | HOLD_UNSUPPORTED | HOLD_UNSUPPORTED | Replacement not supported by reference. |
| P05 | HOLD_REFERENCE | HOLD_REFERENCE | Unreviewed reference cannot prepare a repair. |
| P06 | HOLD_REFERENCE | HOLD_REFERENCE | Different source release. |
| P07 | HOLD_UNSUPPORTED | HOLD_UNSUPPORTED | Later failure cannot partially apply first change. |
| P08 | HOLD_PATCH | HOLD_PATCH | Duplicate target rejected. |
| P09 | HOLD_PATCH | HOLD_PATCH | Identity fields cannot be edited by this operator. |
| P10 | HOLD_INPUT | HOLD_INPUT | Empty patch is not a repair. |
| P11 | PREPARED | PREPARED | Null is not silently treated as missing. |
| P12 | HOLD_PRECONDITION | HOLD_PRECONDITION | Missing/undefined differs from explicit null. |
const fixtures = [
{
"id": "P01",
"record": {
"id": "notice-01",
"rev": 4,
"source": "notice-v1",
"fields": {
"group": "all",
"modality": "will",
"condition": null,
"outcome": "collect kit",
"status": "proposed"
}
},
"request": {
"id": "notice-01",
"baseRev": 4,
"source": "notice-v1",
"changes": [
{
"field": "group",
"old": "all",
"next": "some registered members"
},
{
"field": "modality",
"old": "will",
"next": "may"
},
{
"field": "condition",
"old": null,
"next": "room available"
}
]
},
"reference": {
"id": "notice-v1",
"reviewed": true,
"fields": {
"group": "some registered members",
"modality": "may",
"condition": "room available",
"outcome": "collect kit",
"status": "proposed"
}
},
"expected": "PREPARED"
},
{
"id": "P02",
"record": {
"id": "notice-01",
"rev": 4,
"source": "notice-v1",
"fields": {
"group": "all",
"modality": "will",
"condition": null,
"outcome": "collect kit",
"status": "proposed"
}
},
"request": {
"id": "notice-01",
"baseRev": 3,
"source": "notice-v1",
"changes": [
{
"field": "group",
"old": "all",
"next": "some registered members"
},
{
"field": "modality",
"old": "will",
"next": "may"
},
{
"field": "condition",
"old": null,
"next": "room available"
}
]
},
"reference": {
"id": "notice-v1",
"reviewed": true,
"fields": {
"group": "some registered members",
"modality": "may",
"condition": "room available",
"outcome": "collect kit",
"status": "proposed"
}
},
"expected": "HOLD_STALE"
},
{
"id": "P03",
"record": {
"id": "notice-01",
"rev": 4,
"source": "notice-v1",
"fields": {
"group": "all",
"modality": "will",
"condition": null,
"outcome": "collect kit",
"status": "proposed"
}
},
"request": {
"id": "notice-01",
"baseRev": 4,
"source": "notice-v1",
"changes": [
{
"field": "group",
"old": "some",
"next": "some registered members"
}
]
},
"reference": {
"id": "notice-v1",
"reviewed": true,
"fields": {
"group": "some registered members",
"modality": "may",
"condition": "room available",
"outcome": "collect kit",
"status": "proposed"
}
},
"expected": "HOLD_PRECONDITION"
},
{
"id": "P04",
"record": {
"id": "notice-01",
"rev": 4,
"source": "notice-v1",
"fields": {
"group": "all",
"modality": "will",
"condition": null,
"outcome": "collect kit",
"status": "proposed"
}
},
"request": {
"id": "notice-01",
"baseRev": 4,
"source": "notice-v1",
"changes": [
{
"field": "group",
"old": "all",
"next": "everyone"
}
]
},
"reference": {
"id": "notice-v1",
"reviewed": true,
"fields": {
"group": "some registered members",
"modality": "may",
"condition": "room available",
"outcome": "collect kit",
"status": "proposed"
}
},
"expected": "HOLD_UNSUPPORTED"
},
{
"id": "P05",
"record": {
"id": "notice-01",
"rev": 4,
"source": "notice-v1",
"fields": {
"group": "all",
"modality": "will",
"condition": null,
"outcome": "collect kit",
"status": "proposed"
}
},
"request": {
"id": "notice-01",
"baseRev": 4,
"source": "notice-v1",
"changes": [
{
"field": "group",
"old": "all",
"next": "some registered members"
},
{
"field": "modality",
"old": "will",
"next": "may"
},
{
"field": "condition",
"old": null,
"next": "room available"
}
]
},
"reference": {
"id": "notice-v1",
"reviewed": false,
"fields": {
"group": "some registered members",
"modality": "may",
"condition": "room available",
"outcome": "collect kit",
"status": "proposed"
}
},
"expected": "HOLD_REFERENCE"
},
{
"id": "P06",
"record": {
"id": "notice-01",
"rev": 4,
"source": "notice-v1",
"fields": {
"group": "all",
"modality": "will",
"condition": null,
"outcome": "collect kit",
"status": "proposed"
}
},
"request": {
"id": "notice-01",
"baseRev": 4,
"source": "other",
"changes": [
{
"field": "group",
"old": "all",
"next": "some registered members"
},
{
"field": "modality",
"old": "will",
"next": "may"
},
{
"field": "condition",
"old": null,
"next": "room available"
}
]
},
"reference": {
"id": "notice-v1",
"reviewed": true,
"fields": {
"group": "some registered members",
"modality": "may",
"condition": "room available",
"outcome": "collect kit",
"status": "proposed"
}
},
"expected": "HOLD_REFERENCE"
},
{
"id": "P07",
"record": {
"id": "notice-01",
"rev": 4,
"source": "notice-v1",
"fields": {
"group": "all",
"modality": "will",
"condition": null,
"outcome": "collect kit",
"status": "proposed"
}
},
"request": {
"id": "notice-01",
"baseRev": 4,
"source": "notice-v1",
"changes": [
{
"field": "group",
"old": "all",
"next": "some registered members"
},
{
"field": "status",
"old": "proposed",
"next": "approved"
}
]
},
"reference": {
"id": "notice-v1",
"reviewed": true,
"fields": {
"group": "some registered members",
"modality": "may",
"condition": "room available",
"outcome": "collect kit",
"status": "proposed"
}
},
"expected": "HOLD_UNSUPPORTED"
},
{
"id": "P08",
"record": {
"id": "notice-01",
"rev": 4,
"source": "notice-v1",
"fields": {
"group": "all",
"modality": "will",
"condition": null,
"outcome": "collect kit",
"status": "proposed"
}
},
"request": {
"id": "notice-01",
"baseRev": 4,
"source": "notice-v1",
"changes": [
{
"field": "group",
"old": "all",
"next": "some registered members"
},
{
"field": "group",
"old": "all",
"next": "some registered members"
}
]
},
"reference": {
"id": "notice-v1",
"reviewed": true,
"fields": {
"group": "some registered members",
"modality": "may",
"condition": "room available",
"outcome": "collect kit",
"status": "proposed"
}
},
"expected": "HOLD_PATCH"
},
{
"id": "P09",
"record": {
"id": "notice-01",
"rev": 4,
"source": "notice-v1",
"fields": {
"group": "all",
"modality": "will",
"condition": null,
"outcome": "collect kit",
"status": "proposed"
}
},
"request": {
"id": "notice-01",
"baseRev": 4,
"source": "notice-v1",
"changes": [
{
"field": "source",
"old": "notice-v1",
"next": "other"
}
]
},
"reference": {
"id": "notice-v1",
"reviewed": true,
"fields": {
"group": "some registered members",
"modality": "may",
"condition": "room available",
"outcome": "collect kit",
"status": "proposed"
}
},
"expected": "HOLD_PATCH"
},
{
"id": "P10",
"record": {
"id": "notice-01",
"rev": 4,
"source": "notice-v1",
"fields": {
"group": "all",
"modality": "will",
"condition": null,
"outcome": "collect kit",
"status": "proposed"
}
},
"request": {
"id": "notice-01",
"baseRev": 4,
"source": "notice-v1",
"changes": []
},
"reference": {
"id": "notice-v1",
"reviewed": true,
"fields": {
"group": "some registered members",
"modality": "may",
"condition": "room available",
"outcome": "collect kit",
"status": "proposed"
}
},
"expected": "HOLD_INPUT"
},
{
"id": "P11",
"record": {
"id": "notice-01",
"rev": 4,
"source": "notice-v1",
"fields": {
"group": "all",
"modality": "will",
"condition": null,
"outcome": "collect kit",
"status": "proposed"
}
},
"request": {
"id": "notice-01",
"baseRev": 4,
"source": "notice-v1",
"changes": [
{
"field": "condition",
"old": null,
"next": "room available"
}
]
},
"reference": {
"id": "notice-v1",
"reviewed": true,
"fields": {
"group": "some registered members",
"modality": "may",
"condition": "room available",
"outcome": "collect kit",
"status": "proposed"
}
},
"expected": "PREPARED"
},
{
"id": "P12",
"record": {
"id": "notice-01",
"rev": 4,
"source": "notice-v1",
"fields": {
"group": "all",
"modality": "will",
"outcome": "collect kit",
"status": "proposed"
}
},
"request": {
"id": "notice-01",
"baseRev": 4,
"source": "notice-v1",
"changes": [
{
"field": "condition",
"old": null,
"next": "room available"
}
]
},
"reference": {
"id": "notice-v1",
"reviewed": true,
"fields": {
"group": "some registered members",
"modality": "may",
"condition": "room available",
"outcome": "collect kit",
"status": "proposed"
}
},
"expected": "HOLD_PRECONDITION"
}
];
for (const x of fixtures) console.log(x.id, repair(x.record,x.request,x.reference).status, x.expected);
The JSON fixture serializes the undefined condition in P12 by omitting that property; the reproduced case still tests the missing-field precondition. The published snippet can reproduce the status outputs in a compatible JavaScript runtime. The function was not deployed to the website. The suite does not independently verify arbitrary inputs, the truth of the reference or actual database atomicity.
7. Integrating repair with the learning and AI runtime
A proposed pipeline first identifies a mismatch against a reviewed source, then prepares a patch against the specific version of the record, shows the affected fields and receives the applicable human approval. A commit component should enforce real access control and revision checks inside the transaction. The release gate verifies the revised whole record and affected dependencies. The return component preserves the earlier correction reason and checks a fresh learning task. Re-running a technical test can establish that a field changed; it cannot establish that the learner acquired the concept.
Keep private learner observations separate from public definitions and respect retention and deletion requirements. A correction must not publish a student’s work or change everyone else’s dictionary merely because a single user edits a sentence. The record scope, owner and review authority must be explicit. The local function contains no real user data, network operations or authorisation mechanism.
8. Vocabulary ladder: the correction as an observable operation
| Rung | Demonstration |
|---|---|
| L0 | Attend to source |
| L1 | Identify wrong scope |
| L2 | Name the distinction |
| L3 | Explain the near-miss |
| L4 | Recall the meaning later |
| L5 | Read/write the corrected form |
| L6 | Relate source and candidate |
| L7 | Combine accurate qualifiers |
| L8 | Disambiguate intended status |
| L9 | Transfer to a fresh notice |
| L10 | Interpret consequences of the change |
| L11 | Use specified formal definitions |
| L12 | Trace revisions |
| L13 | Critique unsupported replacement |
| L14 | Govern a reviewed correction record |
| L15 | Propose a testable new distinction |
This is the proposed eduKate teaching ladder, not an official grade or diagnosis. Use the operations relevant to the task. A parent can simply ask which part is wrong, what the source actually says and which accurate facts should be kept.
9. Four-week validation and teaching laboratory
| Week | Activity | Evidence |
|---|---|---|
| 1 | Review synthetic source and candidate pairs; identify only supported repairs. | Reviewed field-level evidence. |
| 2 | Reproduce the twelve cases and add independent stale, conflict and missing-field cases. | Status, actual outputs, input preservation. |
| 3 | Design transactional persistence and separate permission tests before deployment. | Commit preconditions, rollback and dependency inspection. |
| 4 | Use an authorised fresh paraphrasing task and inspect delayed transfer. | Separate software behaviour from learner understanding. |
For technical evaluation compare a full-text regeneration baseline with the bounded repair policy: inspect unsupported additions, preserved correct fields, missed errors, false holds, time and human review effort. Independently reviewed cases should be held out from development. For a human study use appropriate consent, school permissions and privacy safeguards. No human experiment or production deployment was performed here.
10. References and connected research
- RFC 6902: JSON Patch
- RFC 9110: HTTP Semantics
- Semantic Redline Workbench
- Versioned Meaning and Provenance
- Composed Handover Gate
- Complete L0–L15 ladder
- Fencing Method
The standards are established; the local patch contract and executed fixtures are original. The next research step is independent verification of the repair and commit boundaries, not a claim that the prototype is a finished product.
