Skip to main content

Analyze and understand data stored in MongoDB from the command line

Project description

Mongo Analyser Logo

Mongo Analyser

Tests Code Coverage Code Quality PyPI Downloads Python License

Analyze and understand data stored in MongoDB from the command line


Mongo Analyser is a tool for better understanding the structure of MongoDB collections. It helps users infer the schema of a collection by analyzing a sample of documents, identifying field types, and providing insights into the data distribution, etc. It provides a text user interface (TUI) with built-in AI assistance to help users get a better understanding of their data.

Features

  • Automatically infers the schema of MongoDB collections
  • Identifies the types of fields in the collection
  • Provides insights into the distribution of data
  • Provides a user-friendly TUI with integrated AI assistance
  • Works with MongoDB Atlas and self-hosted MongoDB instances
  • Works with models from Ollama, OpenAI, and Google

Installation

pipx install mongo-analyser

Or

uv tool install mongo-analyser

Documentation

Mongo Analyser supports the following field types when inferring the schema of a MongoDB collection:

Field Type Python Equivalent MongoDB Equivalent Comments
int32 int int32
int64 int int64
double float double
str str string
bool bool bool
datetime datetime date
dict dict document Equivalent to a BSON document (which is a MongoDB object or subdocument)
empty None or [] null or array The empty type is used when a field has no value (null) or is an empty array.
array<type> list array The type of the elements in the array is inferred from the sample of documents and can be any of the supported types except for array<type>
binary<UUID> bytes binary (subtype 4) The UUID is stored as a 16-byte binary value
binary<MD5> bytes binary (subtype 5) The MD5 hash is stored as a 16-byte binary value
binary<ObjectId> bytes objectId The ObjectId is stored as a 12-byte binary value

Contributing

See CONTRIBUTING.md for details on how to make a contribution.

Logo

The leaf logo is originally from SVG Repo.

License

Mongo Analyser is licensed under the MIT License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mongo_analyser-0.2.0b1.tar.gz (59.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mongo_analyser-0.2.0b1-py3-none-any.whl (75.0 kB view details)

Uploaded Python 3

File details

Details for the file mongo_analyser-0.2.0b1.tar.gz.

File metadata

  • Download URL: mongo_analyser-0.2.0b1.tar.gz
  • Upload date:
  • Size: 59.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.3 CPython/3.12.10 Linux/6.11.0-1014-azure

File hashes

Hashes for mongo_analyser-0.2.0b1.tar.gz
Algorithm Hash digest
SHA256 2648a038f1ff12b2c60a8540d3830dfa73014d345e2f0b60211978e7f1ac5b09
MD5 6acfebcf45523a0ded43a921ee9bf67c
BLAKE2b-256 8bcbbee46094a5e3692fd3718643fa4eb403ad463059f9189a74c9e3b8d1e895

See more details on using hashes here.

File details

Details for the file mongo_analyser-0.2.0b1-py3-none-any.whl.

File metadata

  • Download URL: mongo_analyser-0.2.0b1-py3-none-any.whl
  • Upload date:
  • Size: 75.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.3 CPython/3.12.10 Linux/6.11.0-1014-azure

File hashes

Hashes for mongo_analyser-0.2.0b1-py3-none-any.whl
Algorithm Hash digest
SHA256 5e297a7086f478dc7096d63133e940181008badb09d93e9871cbe00dcb380c6d
MD5 cb888d579c49f428d2fd961230c6f0cf
BLAKE2b-256 963cbb3be1e0823f12648e0ee11ad8820f9d7960bc89aa44894482ab50b900ca

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page