maus


Namemaus JSON
Version 0.4.1 PyPI version JSON
download
home_page
SummaryPython Library that consolidates Anwendungshandbücher (AHB) and Message Implementation Guides (MIG)
upload_time2024-01-21 08:31:38
maintainer
docs_urlNone
author
requires_python>=3.8
licenseMIT
keywords ahb mig edi@energy maus
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            MIG AHB Utility Stack (MAUS) 🐭
===============================

| |Unittests status badge| |Coverage status badge| |Linting status badge| |Black status badge| |pypy status badge| |read the docs|

.. image:: https://raw.githubusercontent.com/Hochfrequenz/mig_ahb_utility_stack/main/docs/_static/maus-logo.png
   :target: https://mig-ahb-utility-stack.readthedocs.io/en/stable/api/maus.html
   :align: right
   :alt: maus logo
   :width: 150px

| This repository contains the Python package ``maus``.
| MAUS is an acronym for **M**\ IG **A**\ HB **U**\ tility **S**\ tack where MIG stands for **M**\ essage **I**\ mplementation **G**\ uide and AHB stands for **A**\ nwendungs\ **h**\ and\ **b**\ uch.
| The maus software/package allows matching single lines from the AHB with fields specified in the MIG.
| This package is necessary because EDI\@Energy does not provide any real technical and machine-readable description of the MIGs and AHBs, only PDFs.
| MAUS can also be used as a data model (``maus.model``) , without using the software or logic included in the package (MIG/AHB matching logic).

We're all hoping for the day of true digitization on which this repository will become obsolete.

What Problem Does It Solve?
---------------------------
Image you scraped the AHB PDFs into something machine-readable.
Machine-readability in this context implies, that for each field/information inside the AHB you can easily access

- segment group (e.g. "``SG4``")
- segment (e.g. "``LOC``")
- data element ID (e.g. "``3225``")
- AHB Expressions (e.g. "``Muss [123] U ([456] O [789])[904]``")

The exact data format (be it CSV, JSON, XML ...) is not important beyond an initial deserialization.

(BTW: The AHB Expression can be parsed and evaluated using the `🦅 AHBicht Library <https://github.com/Hochfrequenz/ahbicht>`__ or our AHBicht REST API which is publicly available.)

Image you also had a machine-readable version of the MIG -- spoiler: Hochfrequenz can help you with that (please contact
`@JoschaMetze <https://github.com/joschametze>`_ for a demo) -- you still weren't able to make use of your data because the MIG data and AHB data are still unrelated.
MAUS creates a connection between machine readable AHBs and machine readable MIGs.
This allows to associate certain lines from the AHB with certain fields in the MIG and is the basis for a meaningful content evaluation/validation of EDIFACT messages, or, to be more precise, validation of data structures that might be converted to EDIFACT.

Code Quality / Production Readiness
-----------------------------------

-  The code has at least a 95% unit test coverage. ✔️
-  The code is rated 10/10 in pylint and type checked with mypy (PEP 561). ✔️
-  The code is `MIT licensed <LICENSE>`__. ✔️
-  There are only `few dependencies <requirements.in>`__. ✔️

Installation
------------
For the bare maus data model and matching logic it's sufficient to install :code:`pip install maus`.
Only if the MIG you're using is based on XML (namely the Hochfrequenz XML based MIG representation), you need to install :code:`pip install maus[xml]`.
If you want to use the CLI tool, you need to install :code:`pip install maus[cli]`.

Once installed you can either use the package and its data model in your own Python code or use the mapping logic (of only the Hochfrequenz EDIFACT XML templates as of now) via CLI: :code:`maus --flat_ahb_path flat_ahb_by_kohlrahbi.ahb.json --sgh_path path_to_segment_group_hierarchy.sgh.json --template_path UTILMD5.2e.template --output_path file_to_be_created.maus.json`. The CLI tool is not only available via pip but also as standalone executable in the respective release assets.

Development
-----------

Please follow the detailed instructions in the `README of our Python
Template
Repository <https://github.com/Hochfrequenz/python_template_repository#how-to-use-this-repository-on-your-machine>`__
on how to setup your local development environment (tl;dr: tox).

Contribute
----------

You are very welcome to contribute to this template repository by
opening a pull request against the main branch.

.. |Unittests status badge| image:: https://github.com/Hochfrequenz/mig_ahb_utility_stack/workflows/Unittests/badge.svg
.. |Coverage status badge| image:: https://github.com/Hochfrequenz/mig_ahb_utility_stack/workflows/Coverage/badge.svg
.. |Linting status badge| image:: https://github.com/Hochfrequenz/mig_ahb_utility_stack/workflows/Linting/badge.svg
.. |Black status badge| image:: https://github.com/Hochfrequenz/mig_ahb_utility_stack/workflows/Black/badge.svg
.. |pypy status badge| image:: https://img.shields.io/pypi/v/maus
.. |read the docs| image:: https://readthedocs.org/projects/mig-ahb-utility-stack/badge/?version=latest&style=flat

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "maus",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": "",
    "keywords": "AHB,MIG,edi@energy,maus",
    "author": "",
    "author_email": "Hochfrequenz Unternehmensberatung GmbH <info@hochfrequenz.de>",
    "download_url": "https://files.pythonhosted.org/packages/ea/f2/02166f66ae10f04cd740cbfb251a0a28ce65dc2cacc1980cddaa4c4ebcb1/maus-0.4.1.tar.gz",
    "platform": null,
    "description": "MIG AHB Utility Stack (MAUS) \ud83d\udc2d\n===============================\n\n| |Unittests status badge| |Coverage status badge| |Linting status badge| |Black status badge| |pypy status badge| |read the docs|\n\n.. image:: https://raw.githubusercontent.com/Hochfrequenz/mig_ahb_utility_stack/main/docs/_static/maus-logo.png\n   :target: https://mig-ahb-utility-stack.readthedocs.io/en/stable/api/maus.html\n   :align: right\n   :alt: maus logo\n   :width: 150px\n\n| This repository contains the Python package ``maus``.\n| MAUS is an acronym for **M**\\ IG **A**\\ HB **U**\\ tility **S**\\ tack where MIG stands for **M**\\ essage **I**\\ mplementation **G**\\ uide and AHB stands for **A**\\ nwendungs\\ **h**\\ and\\ **b**\\ uch.\n| The maus software/package allows matching single lines from the AHB with fields specified in the MIG.\n| This package is necessary because EDI\\@Energy does not provide any real technical and machine-readable description of the MIGs and AHBs, only PDFs.\n| MAUS can also be used as a data model (``maus.model``) , without using the software or logic included in the package (MIG/AHB matching logic).\n\nWe're all hoping for the day of true digitization on which this repository will become obsolete.\n\nWhat Problem Does It Solve?\n---------------------------\nImage you scraped the AHB PDFs into something machine-readable.\nMachine-readability in this context implies, that for each field/information inside the AHB you can easily access\n\n- segment group (e.g. \"``SG4``\")\n- segment (e.g. \"``LOC``\")\n- data element ID (e.g. \"``3225``\")\n- AHB Expressions (e.g. \"``Muss [123] U ([456] O [789])[904]``\")\n\nThe exact data format (be it CSV, JSON, XML ...) is not important beyond an initial deserialization.\n\n(BTW: The AHB Expression can be parsed and evaluated using the `\ud83e\udd85 AHBicht Library <https://github.com/Hochfrequenz/ahbicht>`__ or our AHBicht REST API which is publicly available.)\n\nImage you also had a machine-readable version of the MIG -- spoiler: Hochfrequenz can help you with that (please contact\n`@JoschaMetze <https://github.com/joschametze>`_ for a demo) -- you still weren't able to make use of your data because the MIG data and AHB data are still unrelated.\nMAUS creates a connection between machine readable AHBs and machine readable MIGs.\nThis allows to associate certain lines from the AHB with certain fields in the MIG and is the basis for a meaningful content evaluation/validation of EDIFACT messages, or, to be more precise, validation of data structures that might be converted to EDIFACT.\n\nCode Quality / Production Readiness\n-----------------------------------\n\n-  The code has at least a 95% unit test coverage. \u2714\ufe0f\n-  The code is rated 10/10 in pylint and type checked with mypy (PEP 561). \u2714\ufe0f\n-  The code is `MIT licensed <LICENSE>`__. \u2714\ufe0f\n-  There are only `few dependencies <requirements.in>`__. \u2714\ufe0f\n\nInstallation\n------------\nFor the bare maus data model and matching logic it's sufficient to install :code:`pip install maus`.\nOnly if the MIG you're using is based on XML (namely the Hochfrequenz XML based MIG representation), you need to install :code:`pip install maus[xml]`.\nIf you want to use the CLI tool, you need to install :code:`pip install maus[cli]`.\n\nOnce installed you can either use the package and its data model in your own Python code or use the mapping logic (of only the Hochfrequenz EDIFACT XML templates as of now) via CLI: :code:`maus --flat_ahb_path flat_ahb_by_kohlrahbi.ahb.json --sgh_path path_to_segment_group_hierarchy.sgh.json --template_path UTILMD5.2e.template --output_path file_to_be_created.maus.json`. The CLI tool is not only available via pip but also as standalone executable in the respective release assets.\n\nDevelopment\n-----------\n\nPlease follow the detailed instructions in the `README of our Python\nTemplate\nRepository <https://github.com/Hochfrequenz/python_template_repository#how-to-use-this-repository-on-your-machine>`__\non how to setup your local development environment (tl;dr: tox).\n\nContribute\n----------\n\nYou are very welcome to contribute to this template repository by\nopening a pull request against the main branch.\n\n.. |Unittests status badge| image:: https://github.com/Hochfrequenz/mig_ahb_utility_stack/workflows/Unittests/badge.svg\n.. |Coverage status badge| image:: https://github.com/Hochfrequenz/mig_ahb_utility_stack/workflows/Coverage/badge.svg\n.. |Linting status badge| image:: https://github.com/Hochfrequenz/mig_ahb_utility_stack/workflows/Linting/badge.svg\n.. |Black status badge| image:: https://github.com/Hochfrequenz/mig_ahb_utility_stack/workflows/Black/badge.svg\n.. |pypy status badge| image:: https://img.shields.io/pypi/v/maus\n.. |read the docs| image:: https://readthedocs.org/projects/mig-ahb-utility-stack/badge/?version=latest&style=flat\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Python Library that consolidates Anwendungshandb\u00fccher (AHB) and Message Implementation Guides (MIG)",
    "version": "0.4.1",
    "project_urls": {
        "Changelog": "https://github.com/Hochfrequenz/mig_ahb_utility_stack/releases",
        "Documentation": "https://maus.readthedocs.io/en/latest/",
        "Homepage": "https://github.com/Hochfrequenz/mig_ahb_utility_stack"
    },
    "split_keywords": [
        "ahb",
        "mig",
        "edi@energy",
        "maus"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "2a9724ea010e2e8d3e2e4f63d83ee5b09277640c4d1f5fda537d3829dac25d2b",
                "md5": "05151cd55bf929bc42def838d6f521f8",
                "sha256": "122f0891971147eb6574d0399494f4ec7a62255cf5095a483d5756508177d76c"
            },
            "downloads": -1,
            "filename": "maus-0.4.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "05151cd55bf929bc42def838d6f521f8",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 53890,
            "upload_time": "2024-01-21T08:31:36",
            "upload_time_iso_8601": "2024-01-21T08:31:36.358824Z",
            "url": "https://files.pythonhosted.org/packages/2a/97/24ea010e2e8d3e2e4f63d83ee5b09277640c4d1f5fda537d3829dac25d2b/maus-0.4.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "eaf202166f66ae10f04cd740cbfb251a0a28ce65dc2cacc1980cddaa4c4ebcb1",
                "md5": "2ed5f34a1edd12a44aeb33f11a24211b",
                "sha256": "1d59659e936b80cf9cf9f770b93bb54efe8f295820a83d5e7627f9f958284c28"
            },
            "downloads": -1,
            "filename": "maus-0.4.1.tar.gz",
            "has_sig": false,
            "md5_digest": "2ed5f34a1edd12a44aeb33f11a24211b",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 88699,
            "upload_time": "2024-01-21T08:31:38",
            "upload_time_iso_8601": "2024-01-21T08:31:38.823940Z",
            "url": "https://files.pythonhosted.org/packages/ea/f2/02166f66ae10f04cd740cbfb251a0a28ce65dc2cacc1980cddaa4c4ebcb1/maus-0.4.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-01-21 08:31:38",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "Hochfrequenz",
    "github_project": "mig_ahb_utility_stack",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "requirements": [],
    "tox": true,
    "lcname": "maus"
}
        
Elapsed time: 0.16813s