skillfed

visions

Visions

visions v0.8.2 1.4M downloads/30d#3,988 on PyPI222
Permissive license BSD-4-Clause Active released

What it is and what it does

Visions is a semantic data type library that goes beyond simple type detection by building a graph of type relationships and using that structure to both identify what type your data actually is and infer what it should be. It handles common real-world messiness—integers stored as floats with trailing zeros, missing values, strings that represent numbers—and can automatically clean and cast data to the inferred type.

The package works across multiple data backends (pandas, numpy, spark, and plain Python sequences) through a dispatch-based architecture, letting you define custom semantic types for domain-specific purposes. It ships with a complete default typeset covering common use cases, and you can extend it by registering new type implementations for frameworks like Dask.

Use it for:

  • Automatically detect and correct data types in CSV or database imports where type information is lost or ambiguous.
  • Build domain-specific type systems for specialized data processing pipelines (e.g., financial, scientific, or categorical data).
  • Clean and standardize tabular data before analysis by inferring the intended type and casting accordingly.
  • Integrate type detection into data profiling or validation workflows to flag unexpected type patterns.
  • Extend type detection to custom backends (e.g., Dask) by registering new type implementations via annotations.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Visions defines and detects semantic data types across pandas, numpy, spark, and Python sequences, automatically inferring the most appropriate type even when data has been transformed or corrupted.

Yes. Visions is actively maintained, has no known vulnerabilities, installs with low friction, and solves a real problem in data processing—inferring semantic types from messy real-world data. It is particularly valuable if you work with pandas or need customizable type detection across multiple backends. The permissive BSD-4-Clause license poses no barrier to adoption.

Install

visions on PyPI

pip

pip install visions

uv

uv add visions

poetry

poetry add visions

Installing visions

Before you install

Low install friction with a pure-Python wheel and six common runtime dependencies. The package is actively maintained with a recent release and no known vulnerabilities.

License in practice

BSD-4-Clause is a permissive license; you may use, modify, and distribute this package freely in commercial or private projects with minimal restrictions.

Quickstart

pip install visions

from visions import typesets
import pandas as pd

df = pd.read_csv('data.csv')
typeset = typesets.CompleteSet()
inferred_types = typeset.infer_type(df)
cleaned_df = typeset.cast_to_inferred(df)

Requires Python 3.9 or later. Plotting type graphs requires pygraphviz to be installed separately.

Verify before relying

  • Whether the type inference accuracy holds across all supported backends (pandas, numpy, spark, Python) or varies by framework.
  • Performance characteristics when working with very large datasets or deeply nested type hierarchies.

Package facts

License BSD-4-Clause (permissive)
Python support supports the current Python release (>=3.9)
Install friction low — pure-Python wheel
Runtime dependencies 6 — numpy, pandas, attrs, networkx, multimethod, puremagic
Maintenance actively maintained — 80 days since the last release
Last repo commit
First released
Downloads 1,374,454/month — #3,988 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: visions-0.8.2-py3-none-any.whl

Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Programming Language :: Python :: 3.9

Tags

semantic data type detectionautomatic type inferencedata type classificationtabular data type detectionpandas type inferencedata cleaning and type castingcustom semantic types
data-type-inferencetabular-datamulti-backend

More Information Analysis packages