Classifier interface for Whyis
Project description
whyis_classifier
Installation
-
install whyis using this command
WHYIS_BRANCH=master bash < <(curl -skL https://raw.githubusercontent.com/tetherless-world/whyis/master/install.sh)
-
whyis will be installed in /apps/whyis
-
In your knowledge graph directory, add the classifier agent to the list of inferencers in your config.py file:
- Add the following import line:
import whyis_classifier.classifier_agent as cl
- Add the following line to the
inferencers
item in theConfig
dictionary constructor:"Classifier": cl.Classifier()
- Add the following import line:
-
Write your own classifier, using
whyisclassifier.WhyisClassifier
as its base class- You must provide your own identifier (an
rdflib.URIRef
) and write alabel()
method
- You must provide your own identifier (an
-
Locate your
whyis_classifier
installation, and in the fileuser_classifiers.py
, import your classifier and add it to theuser_classifiers
dictionary in the form'my_classifier_name': my_file.MyClassifier()
- To locate your
whyis_classifier
installation, runpython -c "import whyis_classifier as _; print(_.__path__[0])"
- To locate your
-
Reload your knowledge graph to run the inferencer over it
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
whyis_classifier-0.0.1.tar.gz
(5.4 kB
view hashes)
Built Distribution
Close
Hashes for whyis_classifier-0.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 93a4779ef602744a26ca740c6609f8279855770657c850abd21c5a4befb08479 |
|
MD5 | b8bf1fc29debfd71171b9e6e30a1ee60 |
|
BLAKE2b-256 | b0ee2013658995b3f53922edd603acd1a3e9390fed37a7ebdaebc9bf64a81ad2 |