Skip to content

4 lexicon deterministic linguistic evidence

TransCompilator edited this page Nov 26, 2026 · 1 revision

4 Lexicon: Deterministic Linguistic Evidence

Source: https://deepwiki.com/PonvasanthPon/TransCompilator/4-lexicon-deterministic-linguistic-evidence

Lexicon: Deterministic Linguistic Evidence

Relevant source files

The following files were used as context for generating this wiki page:

The tc-lexicon crate provides a deterministic, zero-machine-learning lexical infrastructure for TransCompilator (tc_r1). Its primary responsibility is to bridge raw natural language verbs, prepositions, and function words into precise computational semantics without heuristics, runtime network calls, or stochastic models. By grounding all lexical mappings in verifiable linguistic corpora—specifically Open English WordNet 2025 and CU Boulder VerbNet 3.4—the system ensures 100% compilation reproducibility and complete provenance auditing.

For a high-level view, the lexicon connects raw English tokens to structured semantic concepts via statically generated lookup tables and deterministic helper routines defined in crates/tc-lexicon/src/lib.rs:1-17.

Title: "Lexicon Architecture and Provenance Flow"

graph TD
    subgraph "Natural Language Space"
        WN["Open English WordNet 2025"]
        VN["CU Boulder VerbNet 3.4"]
        CC["Closed-Class Function Words"]
    end

    subgraph "Harvesting Space"
        HW["goldmines/tools/harvest_wordnet_r1.py"]
        HV["goldmines/tools/harvest_verbnet_r1.py"]
    end

    subgraph "Code Entity Space"
        GE["crates/tc-lexicon/src/generated/wordnet_concepts.rs"]
        GF["crates/tc-lexicon/src/generated/verbnet_frames.rs"]
        CL["crates/tc-lexicon/src/closed_class.rs"]
        LIB["crates/tc-lexicon/src/lib.rs"]
    end

    WN --> HW
    VN --> HV
    HW --> GE
    HV --> GF
    CC --> CL
    GE --> LIB
    GF --> LIB
    CL --> LIB
Loading

Sources: goldmines/PROVENANCE.md:1-122, crates/tc-lexicon/src/lib.rs:1-17


4.1. Lexicon API and Generated Tables

The public API of tc-lexicon exposes core structural types representing parts of speech, computational concepts, verb predicates, and thematic preposition roles. Statically generated tables compiled directly into the binary contain hundreds of WordNet-derived lemma mappings and thousands of VerbNet syntactic frames.

For details on the specific enum variants, table structures, classification algorithms (classify_verb), closed-class datasets (279 function words), and deterministic lemmatization rules, see Lexicon API and Generated Tables.

Title: "Lexicon Type Hierarchies and Code Entities"

graph TD
    subgraph "Natural Language Space"
        VERB["English Verb Lemmas & Prepositions"]
    end

    subgraph "Code Entity Space"
        LIB["crates/tc-lexicon/src/lib.rs"]
        POS["Pos (Verb, Noun, Adj, Adv)"]
        SC["SemanticConcept (Add, Sub, Assign, Loop...)"]
        VP["VerbPredicate (TransferAdd, Assign, Emit...)"]
        PR["PrepRole (Source, Destination, Theme...)"]
        WE["WordNetEntry & WORDNET_ENTRIES"]
        VF["VerbNetFrame & VERBNET_FRAMES"]
    end

    VERB --> LIB
    LIB --> POS
    LIB --> SC
    LIB --> VP
    LIB --> PR
    LIB --> WE
    LIB --> VF
Loading

Sources: crates/tc-lexicon/src/lib.rs:18-232


4.2. Goldmine Harvesters and Provenance

No raw corpus files or unstructured language datasets are compiled into the tc_r1 binary or tracked in the core source tree. Instead, deterministic Python harvesting scripts process version-controlled upstream releases in a read-only local sandbox (goldmines/), emitting clean, sorted Rust source files under crates/tc-lexicon/src/generated/.

For details on the Open English WordNet 2025 multi-source BFS hypernym traversal, CU Boulder VerbNet 3.4 parsing, reproducibility scripts, and automated audit checks, see Goldmine Harvesters and Provenance.

Title: "Corpus Ingestion to Generated Code Flow"

graph TD
    subgraph "Natural Language Space"
        XML["english-wordnet-2025.xml.gz"]
        VNDIR["verbnet3.4/ XML Classes"]
    end

    subgraph "Code Entity Space"
        HW["goldmines/tools/harvest_wordnet_r1.py"]
        HV["goldmines/tools/harvest_verbnet_r1.py"]
        GENW["crates/tc-lexicon/src/generated/wordnet_concepts.rs"]
        GENV["crates/tc-lexicon/src/generated/verbnet_frames.rs"]
        GENM["crates/tc-lexicon/src/generated/morphology.rs"]
    end

    XML --> HW
    VNDIR --> HV
    HW --> GENW
    HW --> GENM
    HV --> GENV
Loading

Sources: goldmines/PROVENANCE.md:1-122, goldmines/tools/harvest_wordnet_r1.py:1-153


Clone this wiki locally