Combining ML, NLP and LLMs

Toolkit · Quantitative

A measurement-design toolkit with a searchable methods catalogue, structured specifications, and a database interface.

What has been built

A methods catalogue, measurement specifications and a validator support research design. A teaching card documents musical typicality. The proposed product-description measure has no scores.

What comes next

Develop a measurement workflow and agent skill; evaluate functional differentiation using independent judgments, paraphrases and alternative comparison sets.

New wording or a new function?

The design case is novelty in product descriptions, defined as described functional differentiation: how far the functions and relationships a description states differ from those stated in a bounded set of earlier descriptions.

A rare word or a distant vector is evidence about a representation; whether a function differs has to be shown separately.

Three fictional descriptions

  • Earlier description

    Schedules appointments from a shared calendar.

    The reference.

  • Reworded

    Books meetings using a team calendar.

    Different words; the stated function is the same.

  • Focal description

    Schedules appointments and routes exceptions to a supervisor for approval.

    Adds a stated function: an approval relationship.

Written for the design: no model labelled these sentences and no score is computed. The added relationship is a stated difference only; it does not show that the product works, or that no eligible earlier description states it.

Explore this application in the catalogueProducts and functional concepts

See the proposed workflow and validation checks

The proposed sequence

This six-step workflow and its agent skill remain proposed. Extraction, representation and comparison would be checked separately.

  1. Keep the record

    Draws on acquired texts

    Each description keeps its source, entity, retrieval date and version. A posting date does not show that the retrieved wording existed on that date.

  2. Extract the stated functions

    Draws on LLMs

    LLM annotation records the actors, tasks, functions and conditions a description states, each with its supporting passage; what is not stated stays unknown. The result is a set of observations, not a verdict on novelty.

    The LLM-annotation workflow gives the pattern for such records; the two have not been connected in a run.

  3. Choose a representation

    Draws on NLP

    The same texts can be represented as weighted words, topics, embeddings, or extracted functions and relationships. Each keeps different information.

    In the catalogueLexical first use dictionaries and topicsSemantic geometric distancesConcept claim event and narrative structureMultimodal artifact comparison

  4. Fix the comparison set

    Set by the researcher

    The researcher decides which earlier descriptions are eligible: the time window, the exclusions, and how versions, repeats and self-matches are treated. A missing predecessor can make a description look new.

    In the catalogueReference universes and time

  5. Compare, keeping readings apart

    Draws on statistics, ML and LLMs

    Distance to the nearest earlier description, average distance, rarity, unusual combinations, a model’s surprise and an LLM’s judgment answer different questions; none of them alone shows a different function. A structured comparison keeps the matched functions, the remaining differences and the uncertainty with any number.

    Computational baselinesDensity rarity and outlier measuresRecombination and relational null modelsSurprise likelihood and informationTraining-corpus overlap memorization and authenticity

    LLM assessmentDirect LLM rubric scoringPairwise and ranking judgmentsRetrieval grounded prior comparisonDecomposed contribution verificationSupervised and calibrated evaluatorsEnsembles and human assisted assessment

  6. Test the reading

    Draws on human judgments

    Extraction, retrieval and comparison are each checked, against independent human judgments, deliberate changes to the texts and separate calibration and test samples, before a score supports a substantive claim.

    In the catalogueProspective validation and empirical follow upValidation uncertainty and inference

The checks it calls for

Specified for later empirical work; none has been run.

Change to the textsWhat it asksResult
Reword, keeping the meaningDoes the measure ignore a change of wording alone?Not run
Change a function or relationshipDoes it detect the difference it claims to measure?Not run
Add or omit a relevant predecessorDoes the apparent novelty depend on a missing reference?Not run
Change style, length or status cuesDoes presentation leak into the measure?Not run
Change the window, category or corpus sizeHow far does the result depend on the comparison set?Not run
Change the model or promptDo the results hold across versions?Not run
Read the AI prompt

Explore the catalogue

Explore methods, application settings and research questions before choosing a text measure. Search “functional equivalence” or open the product-description setting from the illustration.

The 110 records describe design options. All 490 application–method pairs remain unassessed and unsearched; the catalogue recommends no method.

Methods catalogueWorking design prototype

14 of 110 records

Lexical first use dictionaries and topics

Method family MF01 · Designed; applicability unassessed

Question

What do lexical and embedding-distance baselines estimate, and how sensitive are they to representation and comparator choice?

Subareas

  • dictionaries
  • first use
  • TF IDF
  • topics
  • LSA
  • document encoders
  • mean nearest and centroid distances
  • pretraining-scale n-gram overlap (cross-ref L56)

Adverse case

Synonyms, polysemy, anisotropy, hubness, normalization and converting similarity into novelty without a construct argument.

Planned output

Formula and parameter atlas separating mean, nearest, kth-neighbor and centroid measures. Contribute mechanism ancestry and dated derivation links to the shared measure genealogy; L50 owns the integrated genealogy.

Related records

Question, subareas, adverse case and planned output describe the owner lane; some lanes serve more than one method family.

Source: docs/g9-design/METHOD_FAMILIES.json, method_id=MF01 · Detail from: docs/g9-design/LANES.jsonl, lane_id=G9-L34

Files

The downloadable data match the measurement appendix.

The measure card

A measure card specifies the construct, inputs, comparison set, scoring and validation. Fields distinguish reported values, explicit unknowns and proposed choices. The validator checks structure and refuses a teaching card as a submission.

The teaching card

The one card filled in documents the measure of musical typicality in Askin and Mauskapf (2017): each song is compared with the songs that charted in the 52 weeks before its debut, weighted by genre similarity. It is unreviewed teaching material. Typicality is measured from sonic features, so the card shows the format, not a text measure.

Inspect the card fields

44 fields in nine sections: 17 reported, 24 unknown, 3 proposed.

  1. Identity

    5 fields

    • Citation: Reported
    • Manifestation: Reported
    • Publication status: Unknown
    • Corrections retractions: Unknown
    • Access and inspection: Reported
  2. Construct

    5 fields

    • Intended construct: Reported
    • Level and unit: Reported
    • Text role: Reported
    • Domain and language: Unknown
    • Relative to whom: Reported
  3. Inputs

    5 fields

    • Text or features: Reported
    • Preprocessing: Reported
    • Representation: Reported
    • Model version training cutoff: Unknown
    • Prompt and decoding: Unknown
  4. Scoring

    8 fields

    • Formula or pseudocode: Reported
    • Comparator universe: Reported
    • Time window: Reported
    • Restriction and weighting: Reported
    • Null model and support: Unknown
    • Aggregation: Reported
    • Direction and normalization: Reported
    • Missingness: Unknown
  5. Study design

    5 fields

    • Population and sample: Unknown
    • Unit denominator: Unknown
    • Raters rubric blinding: Unknown
    • Clustering and dependence: Unknown
    • Splits and leakage: Unknown
  6. Validation

    4 fields

    • Target: Unknown
    • Design and population: Unknown
    • Estimates and uncertainty: Unknown
    • Transport and invariance: Unknown
  7. Rival explanations

    3 fields

    • Confounds: Unknown
    • Adverse evidence: Unknown
    • Author limitations: Unknown
  8. Reproducibility

    5 fields

    • Code: Unknown
    • Data: Unknown
    • Model: Unknown
    • License and rights: Unknown
    • Execution status: Proposed
  9. Interpretation

    4 fields

    • Supported scope: Reported
    • Our inference: Proposed
    • Unresolved details: Unknown
    • Reuse and correction lineage: Proposed

Unknown fields stay empty until their source support is established.

Read the scoring fields and validator example

The scoring section as recorded

FieldStatusRecorded valueWhere in the source
Formula or pseudocodeReportedCompute song-pair cosine similarities; multiply by genre similarity; average weighted entries.Author manuscript, printed pp. 18–20 (PDF pp. 18–20); Typicality subsection.
Comparator universeReportedCharting songs in the preceding 52 weeks before focal debut.Author manuscript, printed pp. 18–20 (PDF pp. 18–20); Typicality subsection.
Time windowReported52 weeks.Author manuscript, printed pp. 18–20 (PDF pp. 18–20); Typicality subsection.
Restriction and weightingReportedGenre similarity weights; same-genre weight one.Author manuscript, printed pp. 18–20 (PDF pp. 18–20); Typicality subsection.
Null model and supportUnknownLeft empty. Not inspected for this teaching example.
AggregationReportedAverage weighted pair similarities.Author manuscript, printed pp. 18–20 (PDF pp. 18–20); Typicality subsection.
Direction and normalizationReportedGreater similarity means greater typicality.Author manuscript, printed pp. 18–20 (PDF pp. 18–20); Typicality subsection.
MissingnessUnknownLeft empty. Not inspected for this teaching example.

What the validator does

Try the two Python commands in the appendix README.

InputResult
The teaching card, checked for structureAccepted
The teaching card, offered as a submissionRefused: teaching material cannot be submitted
A copy with a value in a field marked unknownRefused

The validator checks structure only. It cannot tell whether the cited page supports the value recorded.

Use and limits

Limits

  • The product-description specification is unpopulated; no text has been scored or estimate validated.
  • The musical-typicality card is unreviewed teaching material about a non-text measure. Structural checks do not establish source support or construct validity.
  • The measurement workflow and agent skill remain proposed, including evaluation with independent judgments, paraphrases and alternative comparison sets. A reference-text cutoff does not remove later knowledge from a model.

In the repository

Run the validator, open the offline catalogue, inspect the design tables, or adapt the measure-card schema. The README gives commands and expected results.

Open measurement appendix

Sources and credit

Measure documented by the teaching card: Askin and Mauskapf (2017), “What Makes Popular Culture Popular? Product Features and Optimal Differentiation in Music”, American Sociological Review 82(5): 910–944. The card holds the project’s own notes on the measure, with page locators; it reproduces no text from the paper.

The catalogue data and the project’s teaching-card notes are licensed under CC BY 4.0. The cited third-party works retain their own terms.

Collection provider: Product Hunt.

Method sources: Grimmer and Stewart (2013), on validating automated text methods for each research problem; Reimers and Gurevych (2019), on sentence embeddings for similarity, whose results do not validate this construct.