Skip to main content

chatter: a Python library for applying information theory and AI/ML models to animal communication

The study of animal communication often involves categorizing units into types (e.g. syllables in songbirds, or notes in humpback whales). While this approach is useful in many cases, it necessarily flattens the complexity and nuance present in real communication systems. chatter is a new Python library for analyzing animal communication in continuous latent space using information theory and modern machine learning techniques. It is taxonomically agnostic, and has been tested with the vocalizations of birds, bats, whales, and primates. By leveraging a variety of different architectures, including variational autoencoders and vision transformers, chatter represents vocal sequences as trajectories in high-dimensional latent space, bypassing the need for manual or automatic categorization of units. The library provides an end-to-end workflow—from preprocessing and segmentation to model training and feature extraction—that enables researchers to quantify features like:

  • Complexity: path length of sequences in latent space per unit time.
  • Predictability: predictability of a transition in latent space.
  • Similarity: cosine similarity between units or sequences in latent space.
  • Novelty: inverse of predicted density of units or sequences in latent space.

Below is a basic diagram of the chatter workflow, showing the progression from spectrograms to latent features to visualizations in 2D space.

workflow

Additionally, chatter makes it easy to explore the latent space of a species' vocalizations, either statically or with an interactive plot like the one below (of syllables in Cassin's vireo song).

embeddings

This project is heavily inspired by the work of folks like Nilo Merino Recalde and Tim Sainburg. Here is a list of related projects:

Please cite chatter as:

@article{youngblood_chatter_2025,
   author = {Youngblood, Mason},
   title = {chatter: a Python library for applying information theory and AI/ML models to animal communication},
   date = {2025},
   journal = {arXiv},
   doi = {10.48550/arXiv.2512.17935},
   url = {https://doi.org/10.48550/arXiv.2512.17935}
}

Installing chatter

chatter should always be installed inside a new virtual environment. To create an environment using conda you can run:

conda create -n chatter python==3.13.3
conda activate chatter
conda install libsndfile

Then, you can activate the environment and install from GitHub using pip or uv:

pip install chatter-pkg
uv pip install chatter-pkg

Note that chatter uses torch as its machine learning backend, and was developed to use GPU acceleration on Apple Silicon. If you run into issues with compatibility, please look into the torch documentation before opening an issue on GitHub.

Metadata

Release files for chatter-pkg 0.1.6

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for chatter-pkg 0.1.6
File Size Uploaded
chatter_pkg-0.1.6.tar.gz 55.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for chatter-pkg 0.1.6
File Interpreter ABI Platform
chatter_pkg-0.1.6-py3-none-any.whl Python 3 none any Details

Total release size: 111.1 kB

Release files / chatter_pkg-0.1.6.tar.gz

Download URL chatter_pkg-0.1.6.tar.gz
Size 55.8 kB
Tags Source
SHA-256 checksum
How to use checksums
9e7b3d3be25b98bc7af4c015d4ea4d83abed02c8c29082f60335f06c793ee13c
BLAKE2b-256 checksum
How to use checksums
996d692495f804a39d8aacc9c07f7051b177151fc648f8ee3b166b4e66fbd1f6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.9.18 {"installer":{"name":"uv","version":"0.9.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / chatter_pkg-0.1.6-py3-none-any.whl

Download URL chatter_pkg-0.1.6-py3-none-any.whl
Size 55.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5b996a7e8b5cafc1cab368555454725ea116372e8e15010c5723b44fb6fff983
BLAKE2b-256 checksum
How to use checksums
d9339138aaeaed228a8c8e7422b3a8d2aef06a6e534f38ccccb4586b6e6a7cb2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.9.18 {"installer":{"name":"uv","version":"0.9.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release history Release notifications | RSS feed

This release

0.1.6 This release

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page