From 697a1adce1e463079e640b55d6386cf82d7bd6bc Mon Sep 17 00:00:00 2001 From: Malik Talha Date: Sun, 22 Oct 2023 21:06:23 +0500 Subject: Add Snips Inference Module Add slightly modified version of the original Snips NLU library. This module adds support for Python upto version 3.10. Bug-AGL: SPEC-4856 Signed-off-by: Malik Talha Change-Id: I6d7e9eb181e6ff4aed9b6291027877ccb9f0d846 --- snips_inference_agl/cli/versions.py | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 snips_inference_agl/cli/versions.py (limited to 'snips_inference_agl/cli/versions.py') diff --git a/snips_inference_agl/cli/versions.py b/snips_inference_agl/cli/versions.py new file mode 100644 index 0000000..d7922ef --- /dev/null +++ b/snips_inference_agl/cli/versions.py @@ -0,0 +1,19 @@ +from __future__ import print_function + + +def add_version_parser(subparsers, formatter_class): + from snips_inference_agl.__about__ import __version__ + subparser = subparsers.add_parser( + "version", formatter_class=formatter_class, + help="Print the package version") + subparser.set_defaults(func=lambda _: print(__version__)) + return subparser + + +def add_model_version_parser(subparsers, formatter_class): + from snips_inference_agl.__about__ import __model_version__ + subparser = subparsers.add_parser( + "model-version", formatter_class=formatter_class, + help="Print the model version") + subparser.set_defaults(func=lambda _: print(__model_version__)) + return subparser -- cgit 1.2.3-korg