diff options
author | Matthias Baumgartner <dev@igsor.net> | 2022-12-15 16:42:07 +0100 |
---|---|---|
committer | Matthias Baumgartner <dev@igsor.net> | 2022-12-15 16:42:07 +0100 |
commit | 3dc3e9a9b0fc8c9727f91359814866d3deae6e79 (patch) | |
tree | a563234d0327a4aaae488e082e0396b0ee5fe1f8 | |
parent | 559e643bb1fa39feefd2eb73847ad9420daf1deb (diff) | |
download | bsie-3dc3e9a9b0fc8c9727f91359814866d3deae6e79.tar.gz bsie-3dc3e9a9b0fc8c9727f91359814866d3deae6e79.tar.bz2 bsie-3dc3e9a9b0fc8c9727f91359814866d3deae6e79.zip |
minor fixes and comments
-rw-r--r-- | .pylintrc | 2 | ||||
-rw-r--r-- | bsie/__init__.py | 5 | ||||
-rw-r--r-- | bsie/base/extractor.py | 9 | ||||
-rw-r--r-- | bsie/utils/namespaces.py | 1 |
4 files changed, 11 insertions, 6 deletions
@@ -148,7 +148,7 @@ logging-format-style=old [MISCELLANEOUS] # List of note tags to take in consideration, separated by a comma. -notes=FIXME,TODO,NOTE +notes=FIXME,TODO diff --git a/bsie/__init__.py b/bsie/__init__.py index 2b874bd..96e6953 100644 --- a/bsie/__init__.py +++ b/bsie/__init__.py @@ -9,9 +9,8 @@ import collections import typing # constants -version_info = collections.namedtuple('version_info', - ('major', 'minor', 'micro')) \ - (0, 0, 1) +T_VERSION_INFO = collections.namedtuple('T_VERSION_INFO', ('major', 'minor', 'micro')) +version_info = T_VERSION_INFO(0, 0, 1) # exports __all__: typing.Sequence[str] = [] diff --git a/bsie/base/extractor.py b/bsie/base/extractor.py index 75b7173..bfa403c 100644 --- a/bsie/base/extractor.py +++ b/bsie/base/extractor.py @@ -20,7 +20,7 @@ __all__: typing.Sequence[str] = ( # constants # essential definitions typically used in extractor schemas. -# NOTE: The definition here is only for convenience; Each Extractor must implement its use, if so desired. +# NOTE: This preamble is only for convenience; Each Extractor must implement its use, if so desired. SCHEMA_PREAMBLE = ''' # common external prefixes prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> @@ -45,7 +45,12 @@ SCHEMA_PREAMBLE = ''' ## code ## class Extractor(abc.ABC): - """Produce (node, predicate, value)-triples from some content.""" + """Produce (subject, predicate, value)-triples from some content. + The Extractor produces princpal predicates that provide information + about the content itself (i.e., triples that include the subject), + and may also generate triples with auxiliary predicates if the + extracted value is a node itself. + """ # what type of content is expected (i.e. reader subclass). CONTENT_READER: typing.Optional[str] = None diff --git a/bsie/utils/namespaces.py b/bsie/utils/namespaces.py index 2fcb2dc..d6e1c72 100644 --- a/bsie/utils/namespaces.py +++ b/bsie/utils/namespaces.py @@ -21,6 +21,7 @@ __all__: typing.Sequence[str] = ( 'bse', 'bsfs', 'bsm', + 'xsd', ) ## EOF ## |