Superb

Meaning / Semantic identities

Semantic identities

The Semantic Identity Engine (SIE) gives stable identities to what Superb observes and proposes about meaning. It keeps four things separate that are easy to blur:

  1. an observation, meaning a usage of an expression in a passage;
  2. an interpretation, meaning a proposed sense for that usage;
  3. an accepted definition, meaning the sense itself;
  4. who has reviewed each of these, and in what capacity.

Contract version: sie-v1.

Make the request#

const found = await superb.identify({
  text: 'She deposited the check at the bank before noon.',
  target: 'bank',
});

HTTP equivalent: POST /v1/identify. The inputs and limits match resolve: up to 12,000 characters of passage and a target of up to 100 characters. Supply span when the target occurs more than once. The result is deterministic, so the same passage, span and release always return the same identities. Model inference is not part of identify; it stays behind predict_async.

Records#

Record Identity Meaning
Expression expr:en:bank The normalised form: Unicode NFC, straight apostrophes, single spaces, lower case.
Usage usage:… (32 hex) A hash of the exact passage and span. Corpus usages keep their stored identity.
Sense e.g. oewn-bank__1.14.00.. A distinction in usage. Editing a definition does not change its identity.
Interpretation interp:… (32 hex) A proposed sense for a usage under a release and model. It is always machine-proposed.
Evidence the anchor's usage identity A reviewed, released usage that supports an interpretation.
Release hash and version The accepted release, or bootstrap-reference when none exists.

An interpretation's basis says why it ranks where it does:

Under specialist-arbiter-v4, basis names the specialist that pushed hardest for this reading over its strongest rival. specialists gives every specialist's push, and share is the arbiter's share for the reading. score is the word-overlap evidence. None of these is a probability, and calibrated is always false.

Most likely, and how sure#

Superb names the most likely reading rather than declining when readings are close. selected is that reading. Under specialist-arbiter-v4, strength comes from the arbiter's share for it, with thresholds chosen on the tuning halves:

strength Share Right on natural prose (SemCor, report half) Right on dictionary examples
clear ≥ 0.757 86.1%; 35.1% of items 75.2%; 24.0% of items
likely ≥ 0.492 65.4%; 39.9% of items 50.7%; 46.8% of items
close below 40.8%; 25.0% of items 31.5%; 29.2% of items

Show a close answer as a close call. pointsTo names the runner-up. These are measured rates on two corpora, not probabilities for a given answer.

Under usual-evidence-v3, strength says how far the passage agrees instead:

syntax reports the part-of-speech cue from the word just before the target. A determiner or possessive such as "the bank" rules out a verb. "To", a modal or a subject pronoun, as in "they bank", calls for one. fits means the sense agrees with the cue. set-aside means it does not: the sense keeps its score but ranks after those that fit. When no cue applies, syntax is null.

Models#

Each release names the ranker it was built and evaluated with, as release.model, and keeps using it:

Model Ranks by Selects
lexical-anchor-v1 Overlap with the definition, examples, synonyms and hypernyms, and with reviewed anchors When score ≥ 0.08 and margin ≥ 0.025; otherwise abstains
lexical-anchor-v2 Overlap with light stemming, every WordNet link, the definitions of linked senses and reviewed anchors, then the part-of-speech cue When the passage supplies evidence and the margin is ≥ 0.02; otherwise abstains
usual-evidence-v3 The part-of-speech cue, then −ln(1 + place in the reference order) + 10 × v2's evidence Always: the most likely reading, with its strength
specialist-arbiter-v4 Six specialists weighed by a learned arbiter (below) Always: the most likely reading, with its share, strength and specialists

specialist-arbiter-v4#

Each specialist reads the passage its own way, and each has blind spots:

Specialist Reads Blind spot it covers
usual the reference's order of senses a passage that says little
partOfSpeech the word before the target verb or noun readings that can't apply
overlap words shared with the definition, links and linked definitions a definition that names the context outright
profile the passage's usage profile against the sense's (below) related words that never appear in the definition
prevalence the sense's prevalence, derived from catalogue usage usual senses that the reference's order gets wrong
placement which classes of meaning usually sit where the target sits ("went to the ___") cues from position rather than vocabulary

Meaning is derived, not looked up:

The arbiter pairs every specialist's score with signals about the situation:

It is a softmax over each item's candidates, fitted by npm run sie:train on the tuning halves only (37,358 SemCor items and 9,864 dictionary items). Frames are cross-fitted, so no item's placement signal comes from its own word's labels.

A v4 release also records usageHash, the hash of the usage assets, and resolving against different assets is refused. Without the assets, a bootstrap answer says it used usual-evidence-v3.

v1 and v2 never select a sense because it is listed first. v3 does, when the passage says nothing, and says so with basis: usual-sense and strength: usual. Open English WordNet lists senses roughly from most to least frequent, so its order is the usual-sense prior. v2 and v3 read linked senses' definitions from the dictionary's context shards. A release records contextHash, and a v3 release also records senseOrderHash. Resolving against a different context or order is refused with 503 rather than answered differently. Releases from before models were recorded use v1. Without a release, answers use v4 when the usage assets are present, and v3 otherwise.

Review states#

State Means
unreviewed Nobody at Superb has reviewed it, for example a sense imported from Open English WordNet.
machine-proposed Computed by a deterministic or model process. Every interpretation starts here.
owner-reviewed Reviewed or accepted by the project owner, including editorial definitions.
contributor-judged Decided by contributor judgments under a published rule.
independently-reviewed Reviewed by someone independent of the work, with the review recorded as such.
review-state-unrecorded Reviewed before review states were recorded. It keeps its reviewer but claims no kind.

A review state is recorded only when the reviewer states it. It is never inferred from who happened to review. Release manifests count the review states of their anchors, evaluation labels and contrasts. A release can therefore say plainly how much of it is owner-reviewed, contributor-judged, independently reviewed or unrecorded.

Handle all outcomes#

Result What to show
selected is present The proposed sense, labelled as machine-proposed, with its strength, evidence and release
strength is contested A close call: the selected reading, and the reading the wording leans toward (pointsTo)
abstention is NO_SUPPORTED_SENSE Only under v1 and v2 releases: the candidates, and a request for more context
abstention is AMBIGUOUS_TARGET Ask which occurrence; usage is null until a span is given
status is not_found The expression is not in the inventory yet; keep it as unlisted, not wrong

Keep the release with anything you store. A bootstrap-reference answer rests on the reference inventory only and has no release hash.

How usage becomes evidence#

The SIE improves as reviewed usage accumulates:

  1. Reading. A reading app calls identify. An answer is the most likely reading, a machine-proposed interpretation, with a strength.
  2. Question. When the answer is a close call (contested), or a model-assisted reading stays ambiguous, the app can offer a contrast question about the same word: nextTask({target}). It shows two attributed passages from the cleared catalogue and asks whether they use the word the same way. The reader's own text is never sent and never becomes a question.
  3. Judgment. A signed-in reader's answer is stored as a contribution judgment (GET /v1/me), sent with the app's Authorization: Session header. Answers are pooled, and a contrast resolves only under the published rule, which makes it contributor-judged. Without an account, questions are practice and are not recorded.
  4. Release. Resolved contrasts, and anchors labelled by review, go into the next release after its evaluation gate. Its manifest counts what the release rests on, by review state.
  5. Evidence. Under that release, identify cites the anchors as reviewed-anchors evidence with their recorded review states, the next time the word is read.

A contribution record counts answers. Neither agreement among contributors nor model agreement establishes what a word means.

Evaluation#

npm run sie:evaluate compares the SIE's deterministic rankers with three ordinary baselines:

There are two sets, and words are split into two halves by hash for both. The v2 and v3 changes and weights were chosen on the tuning halves; the tables report the other halves, whose words had no part in tuning.

SemCor, report half: 37,537 items across 5,532 words, set ec8887b7839d.

Method Answers Accuracy Precision
Chance – 25.8% –
First sense 100% 58.5% 58.5%
Gloss retrieval 100% 49.6% 49.6%
TF-IDF vectors 100% 49.8% 49.8%
SIE lexical-anchor-v1 20.8% 7.6% 36.5%
SIE lexical-anchor-v2 42.3% 17.1% 40.3%
SIE usual-evidence-v3 100% 59.7% 59.7%
SIE specialist-arbiter-v4 100% 66.5% 66.5%

Dictionary examples, report half: 10,104 items across 5,421 words, set d9aff1912cbf.

Method Answers Accuracy Precision
Chance – 31.5% –
First sense 100% 39.2% 39.2%
Gloss retrieval 100% 42.0% 42.0%
TF-IDF vectors 100% 42.2% 42.2%
SIE lexical-anchor-v1 18.9% 8.7% 45.9%
SIE lexical-anchor-v2 26.5% 13.4% 50.5%
SIE usual-evidence-v3 100% 43.7% 43.7%
SIE specialist-arbiter-v4 100% 51.0% 51.0%

On natural prose, word overlap alone does worse than taking the first sense. v2's evidence is right only 40% of the time when it answers, because long sentences share words with the wrong senses by chance. v3 is only 1.2 points above first sense there. No single specialist beats the usual sense on natural prose, but the arbiter does: v4 gains 8 points over first sense on SemCor and 7.3 over v3 on dictionary examples. Each specialist is right where the others are blind. The strength rates above come from these report halves. The arbiter was fitted mostly on natural prose; an earlier fit with fewer SemCor items reached 56.7% on dictionary examples and 65.1% on SemCor.

How the rankers are judged#

Accuracy is measured only against people's annotations: SemCor's sense tags and the dictionary's own examples, with report halves the models never trained on. Example sentences in this document and in the tests are illustrations of behaviour, not gold. Tests check the contract (determinism, shares, strengths, identities), never which reading a sentence "really" has.

Many sentences don't settle a meaning. In "She went to the bank", the riverbank, the institution and its building are all live; only the surrounding text could decide. The engine should say so: v4 gives it as a close call and names the runner-up, rather than forcing one reading. A reading counts as settled only when the benchmarks show the signals behind it are reliable, as for clear answers, which are right 86% of the time on SemCor.

Placement frames learned from natural usage show real regularities, for example "went to the ___" favours physical things such as buildings (log-lift +1.72 for artifacts). Applied alone, frames lowered accuracy (67.3% down to 58.9% as their weight rose). As one specialist among six they add about 2 points. The next gains should come from connections learned per word and sense from labelled natural usage: catalogue anchors from the labelling tool, contributor judgments and SemCor. That will be a separately named model, measured the same way.

Rerun the comparison on both sets, --half=report by default and --half=tuning while developing, whenever the ranker, inventory or anchors change, and report it with the release.