Skip to content

Featurespace/dmap

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

2 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ—ΊοΈ DMAP: A Distribution Map for Text

Python 3.12+ License: MIT

DMAP (ICLR 2026) is a mathematically grounded method that maps a text, via a language model, to a set of samples in the unit interval that jointly encode rank and probability information. This representation enables efficient, model-agnostic analysis and supports a range of applications.

DMAP works effectively with small evaluator language models such as OPT-125m that easily run on consumer hardware.

✨ Key Features

  • 🎯 Intuitive Visualization: transform text into simple, informative, representations for downstream analysis
  • πŸ”§ Easy Integration: Simple API that works with popular NLP libraries (transformers, scikit-learn, etc.)
  • πŸ“Š Rich Analytics: Built-in tools for quantitative and qualitative analysis of distribution patterns
  • 🎨 Customizable: Easily plug-in new visualisations or analysis methods
  • πŸ“– Interactive demo: Get up and running with DMAP in a few minutes

πŸš€ Quick Start

To install, simply run:

pip install git+https://github.com/Featurespace/dmap.git

Then, you may use DMAP as follows.

from dmap import DMAP

# Create and fit DMAP.
dmap = DMAP(evaluator_model='facebook/opt-125m')
text_map = dmap.fit(["The robot was dancing in the rain"])

# Visualize your DMAP samples.
dmap.plot()

For a more detailed example, we recommend cloning the repository and playing with our interactive demo.

πŸ“„ Citation

If you use DMAP in your research, please cite our paper accepted at ICLR 2026:

@article{dmap2025,
  title={DMAP: A Distribution Map for Text},
  author={Tom Kempton, Julia Rozanova, Parameswaran Kamalaruban, Maeve Madigan, Karolina Wresilo, Yoann Launay, David Sutton, and Stuart Burrell},
  year={2026},
  url={https://openreview.net/forum?id=SPElkPRurl}
}

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •