nshconfig


Namenshconfig JSON
Version 0.44.0 PyPI version JSON
download
home_pagehttps://github.com/nimashoghi/nshconfig
SummaryFully typed configuration management, powered by Pydantic
upload_time2025-04-25 21:34:40
maintainerNone
docs_urlNone
authorNima Shoghi
requires_python<4.0,>=3.10
licenseNone
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # nshconfig

Fully typed configuration management, powered by [Pydantic](https://github.com/pydantic/pydantic/).

**[📚 Documentation](https://nima.sh/nshconfig/) | [🔧 Installation Guide](https://nima.sh/nshconfig/installation.html)**

## Overview

`nshconfig` is a Python library that enhances Pydantic with additional features for configuration management, particularly useful for machine learning experiments and other applications requiring strongly typed configurations.

## Installation

```bash
pip install nshconfig
```

To install all optional dependencies, use:

```bash
pip install nshconfig[extra]
```

Please see the [Installation Guide](https://nima.sh/nshconfig/installation.html) for more details.

## Quick Start

```python
import nshconfig as C

class MyConfig(C.Config):
    field1: int
    field2: str
    field3: C.AllowMissing[float] = C.MISSING

config = MyConfig.draft()
config.field1 = 42
config.field2 = "hello"
final_config = config.finalize()
```

## Key Features

- Draft configs for intuitive configuration creation
- Multiple configuration formats (Python, JSON, YAML)
- Dynamic type registry for plugin systems
- Configuration code generation tools
- Built-in PyTorch Lightning integration
- MISSING constant for optional fields

For detailed examples and API reference, please visit the [documentation](https://nima.sh/nshconfig/).

## Contributing

Contributions are welcome! Please see our [Contributing Guide](https://nima.sh/nshconfig/contributing.html) for details.

## Credit

Built on top of the excellent [pydantic](https://github.com/pydantic/pydantic/) library.

## License

MIT License

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/nimashoghi/nshconfig",
    "name": "nshconfig",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4.0,>=3.10",
    "maintainer_email": null,
    "keywords": null,
    "author": "Nima Shoghi",
    "author_email": "nimashoghi@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/82/02/8cae364045bb30559f2fa5c542285d10776358d40d8b47b99b5d963f4766/nshconfig-0.44.0.tar.gz",
    "platform": null,
    "description": "# nshconfig\n\nFully typed configuration management, powered by [Pydantic](https://github.com/pydantic/pydantic/).\n\n**[\ud83d\udcda Documentation](https://nima.sh/nshconfig/) | [\ud83d\udd27 Installation Guide](https://nima.sh/nshconfig/installation.html)**\n\n## Overview\n\n`nshconfig` is a Python library that enhances Pydantic with additional features for configuration management, particularly useful for machine learning experiments and other applications requiring strongly typed configurations.\n\n## Installation\n\n```bash\npip install nshconfig\n```\n\nTo install all optional dependencies, use:\n\n```bash\npip install nshconfig[extra]\n```\n\nPlease see the [Installation Guide](https://nima.sh/nshconfig/installation.html) for more details.\n\n## Quick Start\n\n```python\nimport nshconfig as C\n\nclass MyConfig(C.Config):\n    field1: int\n    field2: str\n    field3: C.AllowMissing[float] = C.MISSING\n\nconfig = MyConfig.draft()\nconfig.field1 = 42\nconfig.field2 = \"hello\"\nfinal_config = config.finalize()\n```\n\n## Key Features\n\n- Draft configs for intuitive configuration creation\n- Multiple configuration formats (Python, JSON, YAML)\n- Dynamic type registry for plugin systems\n- Configuration code generation tools\n- Built-in PyTorch Lightning integration\n- MISSING constant for optional fields\n\nFor detailed examples and API reference, please visit the [documentation](https://nima.sh/nshconfig/).\n\n## Contributing\n\nContributions are welcome! Please see our [Contributing Guide](https://nima.sh/nshconfig/contributing.html) for details.\n\n## Credit\n\nBuilt on top of the excellent [pydantic](https://github.com/pydantic/pydantic/) library.\n\n## License\n\nMIT License\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "Fully typed configuration management, powered by Pydantic",
    "version": "0.44.0",
    "project_urls": {
        "Homepage": "https://github.com/nimashoghi/nshconfig"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f9859fd1bbd9c30b14bd7024681a6c2f013672db3a9deb75796e1aaf61928ccc",
                "md5": "cef2624e36e7a5a5e611337ec0f055c6",
                "sha256": "ff17717bb4fc39800a8b8fb2af6ef6aa8e8fa8d7769d5c7a0d2556da34386225"
            },
            "downloads": -1,
            "filename": "nshconfig-0.44.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "cef2624e36e7a5a5e611337ec0f055c6",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.10",
            "size": 41375,
            "upload_time": "2025-04-25T21:34:39",
            "upload_time_iso_8601": "2025-04-25T21:34:39.258624Z",
            "url": "https://files.pythonhosted.org/packages/f9/85/9fd1bbd9c30b14bd7024681a6c2f013672db3a9deb75796e1aaf61928ccc/nshconfig-0.44.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "82028cae364045bb30559f2fa5c542285d10776358d40d8b47b99b5d963f4766",
                "md5": "2d730d1b9c79890b4994443756ae9a0e",
                "sha256": "69d5e48076d87471211d1ec34cc49ad46d735221ef9039b3d5f9b8c09e9a1ffc"
            },
            "downloads": -1,
            "filename": "nshconfig-0.44.0.tar.gz",
            "has_sig": false,
            "md5_digest": "2d730d1b9c79890b4994443756ae9a0e",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.10",
            "size": 36201,
            "upload_time": "2025-04-25T21:34:40",
            "upload_time_iso_8601": "2025-04-25T21:34:40.792754Z",
            "url": "https://files.pythonhosted.org/packages/82/02/8cae364045bb30559f2fa5c542285d10776358d40d8b47b99b5d963f4766/nshconfig-0.44.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-04-25 21:34:40",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "nimashoghi",
    "github_project": "nshconfig",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "nshconfig"
}
        
Elapsed time: 1.89150s