From e348d4434c2d723c3f4dbb6418d2c793990d48a4 Mon Sep 17 00:00:00 2001 From: ines Date: Thu, 16 Mar 2017 17:13:40 +0100 Subject: [PATCH] Add spacy.info(model_name) to show model meta Allows "previewing" model before loading and making sure it's linked correctly. --- spacy/__init__.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/spacy/__init__.py b/spacy/__init__.py index 52ebf0635..ca5a39f05 100644 --- a/spacy/__init__.py +++ b/spacy/__init__.py @@ -41,3 +41,8 @@ def load(name, **overrides): overrides['meta'] = meta overrides['path'] = Path(data_path / name) return cls(**overrides) + + +def info(name): + meta = parse_package_meta(util.get_data_path(), name) + print(json.dumps(meta, indent=2))