Skip to main content

chameleon-data

An interactive CLI that replaces selected columns of a CSV / TSV / XLSX file with fake data generated by Faker. The result is saved in the same format as the input.

Installation

Published on PyPI as chameleon-data. Requires Python 3.11 or later. After installation, the chameleon and chameleon-example commands are available.

uv

# Install as a global CLI tool (recommended)
uv tool install chameleon-data

# Run once without installing
uvx --from chameleon-data chameleon -f data.csv

# Add as a dependency of another project
uv add chameleon-data

# Install into the current virtual environment
uv pip install chameleon-data

Upgrade / uninstall:

uv tool upgrade chameleon-data
uv tool uninstall chameleon-data

pip

pip install chameleon-data

# Upgrade / uninstall
pip install --upgrade chameleon-data
pip uninstall chameleon-data

To use it as a standalone CLI without touching other environments, pipx works too:

pipx install chameleon-data

From GitHub (development version)

uv tool install git+https://github.com/hidariutiwa/chameleon-data
pip install git+https://github.com/hidariutiwa/chameleon-data

To pin a specific version, use git+https://github.com/hidariutiwa/chameleon-data@<tag or commit>.

Usage

chameleon -f data.csv                 # saves to data_masked.csv
chameleon -f data.xlsx -o out.xlsx    # specify the output path
chameleon -f data.tsv -l en_US -s 42  # specify locale and seed
Option Description
-f, --filepath Input file (required). .csv / .tsv / .xlsx
-o, --output Output file. Defaults to <filename>_masked.<suffix>
-l, --language Faker locale. Defaults to ja_JP
-s, --seed Random seed. Set it to get the same result every time
-v, --version Show the version

When run, you pick the columns to mask with a checkbox prompt, then choose a replacement type for each column. Each type is shown with a sample value, and you can type to filter the list.

Group Types
— masking: every character becomes * (length is kept)
person full_name / first_name / last_name, full_name_kana / last_name_kana / first_name_kana, email, user_name, date_of_birth, age, phone_number
address full_address, zipcode, prefecture, city, street, building
business company, job, url, domain, ipv4, ipv4_private
finance / id credit_card_number, credit_card_expire, credit_card_security_code, bank_account, iban, uuid, passport_number, number, date

Types the locale does not support (e.g. kana names and building outside ja_JP) are hidden from the list.

Identical values are replaced with identical fake values, so relationships between rows are preserved. Empty cells stay empty.

Sample data

chameleon-example   # writes a sample to ./example/example.csv
chameleon -f example/example.csv

Development

Uses uv.

uv sync
uv run chameleon -f example/example.csv
uv build   # builds a wheel and sdist into dist/

Release

Pushing a v* tag triggers GitHub Actions (.github/workflows/publish.yml), which publishes to PyPI via Trusted Publishing.

uv version --bump patch   # bump the version in pyproject.toml (minor / major also work)
git commit -am "chore: release v$(uv version --short)"
git tag "v$(uv version --short)"
git push origin main --tags

License

MIT

Metadata

Release files for chameleon-data 0.3.1

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

Source distribution (sdist)

Source distribution for chameleon-data 0.3.1
File Size Uploaded Provenance
chameleon_data-0.3.1.tar.gz 8.7 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for chameleon-data 0.3.1
File Interpreter ABI Platform
chameleon_data-0.3.1-py3-none-any.whl Python 3 none any Details

Total release size: 18.5 kB

Release files / chameleon_data-0.3.1.tar.gz

Download URL chameleon_data-0.3.1.tar.gz
Size 8.7 kB
Tags Source
SHA-256 checksum
How to use checksums
ab6c6f2d4ef05d734a44849538b503b69dc23ab52f2a70f4cea2b0c0a8e88ab9
BLAKE2b-256 checksum
How to use checksums
4743faa2461c9c69da40d4fb9322af527151724bc15538ded5720cf8a95fa677
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.5 {"installer":{"name":"uv","version":"0.13.5","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 / chameleon_data-0.3.1-py3-none-any.whl

Download URL chameleon_data-0.3.1-py3-none-any.whl
Size 9.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d1eb17376d584ecc84cb9174e154385eefed3d70956b85ff367788f5f8960ac1
BLAKE2b-256 checksum
How to use checksums
ffa7b335b8e398b45514afde55e3ad34e2eae87e0245df359eab1536d3f73949
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.5 {"installer":{"name":"uv","version":"0.13.5","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}

Security for chameleon-data 0.3.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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