Skip to main content

Framework-agnostic Python utilities: text, time, iterables, structured logging, telemetry primitives, and more.

Project description

neutronium

Framework-agnostic Python utilities, extracted from Gaussian's internal infrastructure. No Django, no web framework, no cloud SDK in the base install — everything third-party is an optional extra.

pip install neutronium              # base: zero dependencies
pip install neutronium[text]        # inflection-backed pluralize/singularize
pip install neutronium[xpath]       # lxml-backed HTML/XPath helpers

What's inside

Module What it gives you
neutronium.utils.text Text normalization, slugs, tokenization, pluralize/singularize
neutronium.utils.time Timezone-aware datetime helpers
neutronium.utils.iterable Chunking, grouping, flattening, dict utilities
neutronium.utils.template_context Pure template-variable extraction and context building
neutronium.utils.json_patch RFC-6901 JSON pointer / merge-patch primitives
neutronium.utils.hash blake2b content hashing helpers
neutronium.utils.schema JSON-schema → default-dict
neutronium.utils.xpath lxml HTML parsing + link extraction ([xpath])
neutronium.utils.url URL parse / canonicalize / normalize / domain extraction ([url])
neutronium.requester Resilient HTTP fetcher with retries/paywall/no-index detection ([requests])
neutronium.utils.file Pickle / text / JSONC file helpers
neutronium.utils.performance Simple multi-level timer
neutronium.utils.email Canonical email normalization
neutronium.utils.{aws,ssm,s3} EC2/ECS instance metadata, SSM parameter fetch, S3 upload/download ([aws])
neutronium.utils.{print,params,profiling,memory,url_credentials} Assorted small utilities
neutronium.threads.thread_simple Minimal threading helpers
neutronium.telemetry Request-context vars, RequestFacts, pluggable sinks
neutronium.logging JSON / dev-console log formatters and context filters

Optional extras

text, time, aws, url, requests, memory, memory-extended, xpath, otel, profiling — install only what you use.

  • awsboto3, requests, ec2-metadata (for neutronium.utils.aws / ssm / s3)
  • urltldextract (only for get_url_domain; the rest of neutronium.utils.url is pure stdlib)
  • memorypsutil (for print_memory_usage); memory-extendedpympler, objgraph (for the heap/objgraph tools — opt in only if you use them)

Development

uv run --all-extras pytest   # installs all optional extras + the dev group

License

MIT © Gaussian Holdings, LLC

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

neutronium-0.2.1.tar.gz (53.5 kB view details)

Uploaded Source

Built Distribution

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

neutronium-0.2.1-py3-none-any.whl (52.5 kB view details)

Uploaded Python 3

File details

Details for the file neutronium-0.2.1.tar.gz.

File metadata

  • Download URL: neutronium-0.2.1.tar.gz
  • Upload date:
  • Size: 53.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for neutronium-0.2.1.tar.gz
Algorithm Hash digest
SHA256 238dd3f065cfaa688e6ad2b4b68d82d4e9c30100c6a8ecf8c864b1bab87aaabe
MD5 1eef3f6f7937eebdc9e48207bf23ffff
BLAKE2b-256 c9f1cc2d8dd48f93b651d80427cfdee646764a3f3d04e1930628b008fba488f3

See more details on using hashes here.

Provenance

The following attestation bundles were made for neutronium-0.2.1.tar.gz:

Publisher: publish.yml on gaussian/neutronium

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file neutronium-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: neutronium-0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 52.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for neutronium-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 6f29377b5fbd13b5d6ae192a5cc95efd15957474eb611bdd3aa510bcbcc2611b
MD5 27ab82c951d3d453dd1af02d1fe3d4e0
BLAKE2b-256 a1b56795dd0802eb3cc0b4aeec12de6f2752274901cd0abc6461bb91347a9f9e

See more details on using hashes here.

Provenance

The following attestation bundles were made for neutronium-0.2.1-py3-none-any.whl:

Publisher: publish.yml on gaussian/neutronium

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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