---
title: "wordgraph-tamp-norm — Mova code model"
description: "Mova code model of wordgraph/tamp/src/norm.rs: components with their labels, obernants and the model text."
url: "https://groupants.elamur.ai/free/en/mova/wordgraph/tamp/src/norm.rs.groupant/"
---
Elamur: [Mova](https://md.mova.elamur.ai/free/en/) · [Dictionary](https://md.dictionary.elamur.ai/free/en/) · [Research](https://md.research.elamur.ai/free/en/) · **Groupants**

This page as HTML: <https://groupants.elamur.ai/free/en/mova/wordgraph/tamp/src/norm.rs.groupant/>

# wordgraph-tamp-norm

The groupant beside wordgraph/tamp/src/norm.rs in the Mova repository: what the code computes, what it never does, how to go back from its outputs, its invariants, cost and checks.

## Facts

- **kind:** groupant
- **status:** partial source bound model
- **source:** [`wordgraph/tamp/src/norm.rs`](https://github.com/ElamurAI/mova-free/blob/main/wordgraph/tamp/src/norm.rs)
- **repository folder:** [`wordgraph/tamp/src/norm.rs.groupant`](https://github.com/ElamurAI/mova-free/tree/main/wordgraph/tamp/src/norm.rs.groupant)

> **Implementation material.** A Mova code model describes this code at one source revision: partial models, finite checks and their stated scope. It is not a reviewed general exposition, and its labels are shown as written, never raised.

## Components

| component | label | where |
|---|---|---|
| **Approximant** | partial | [Approximant](#approximant) |
| **Ast** | partial | `syntax.json` |
| **Composition** | partial | [Composition](#composition) |
| **Cost** | partial | [Cost](#cost) |
| **Descriptant** | present | [Descriptant](#descriptant) |
| **Invariant** | partial | [Invariant](#invariant) |
| **Tests** | executed bounded checks | [Tests](#tests) |

## Obernants

The typed relations around the forward model: the behaviour complement (what the code never does), the reverse reconstruction (every input compatible with an output) and specialised views.

| relation | type | label | where |
|---|---|---|---|
| Behavior complement | behavior complement | partial source derived model | [Behavior complement](#behavior-complement) |
| Reverse reconstruction | reverse reconstruction | partial source derived model | [Reverse reconstruction](#reverse-reconstruction) |

## Model text


### Descriptant

Statements normalized to lemma ids (the `en` dictionary numbers the word graph uses; `OOV_TAG | fnv` otherwise),
content UPOS only, numbers one id, light verbs out; order-sensitive shingles (ordered pairs at distance one or two);
Jaccard; seeded shuffles; the order test (`order_holds`: own score − best of 8 shuffles ≥ 0.2).

### Approximant

sequence(s) = [map(id(l)) | k ∈ covered(s), upos_k ∈ CONTENT, l ∉ LIGHT]; shingles(q) = sort∪{h(q_i,q_{i+1}),
h(q_i,q_{i+2})}; J(A,B) = |A∩B|/|A∪B| by merge; shuffled(q, seed) = Fisher–Yates with splitmix.

### Invariant

Pure functions; shingles sorted and unique; J ∈ [0,1], J(A,A)=1; a reversed sequence shares no shingle; a shuffle is
a permutation fixed by its seed.

### Cost

O(n log n) per sequence; J O(|A|+|B|); order test 8 shuffles × the scored measure.

### Composition

Used by `corpus`, `cluster`, `anchor`, `build`, `synonym` (lemma ids).

### Tests

`shingles_are_ordered_and_jaccard_is_bounded` (reversal shares nothing: the red side), `shuffle_is_seeded_and_a_permutation`,
`numbers_are_one_id_and_light_words_go`.

### Behavior complement

No stemming beyond the parser's lemma, no word senses, no multiword expressions, no weighting of shingles.

### Reverse reconstruction

From a shingle set one recovers neither the words (hashes) nor their order beyond pair evidence; from a sequence, the
content lemmas in order but not function words or numbers' values.

## Provenance

- **source SHA-256:** `e9f786a83133c9b2…`
- **repository commit:** `9c26aadad2d4`
