Skip to main content

Janex

Janex-Python is a library which can be used to create Natural Language Processing-based programs and other forms of Artificial Intelligence.

It is part of the Janex eco-system which is designed for developers to use in their own projects for free, licensed under the Free Lily License.

As of update 0.0.80, the entire infrastructure of how this code works has been modified intensely.

How to use

First, install Janex using pip.

python3 -m pip install Janex

Next, import it into your code

from Janex import *

Intent classifier

To use the pre-built intent classifier included with the package, you need to create an instance of it and then set the intents, vectors and dimensions.

from janex.intentclassifier import *

Classifier = IntentClassifier()

Classifier.set_intentsfp("intents.json")
Classifier.set_vectorsfp("vectors.json")
Classifier.set_dimensions(300)

Classifier.train_vectors()

You can then determine the class of which a certain variable belongs in using the Classifier.claffy() function.

Input = input("You: ")

classification = Classifier.classify(Input)

response = random.choice(classification["responses"])

print(response)

Data experimentation with vectors

If you would like to tokenize, stem or otherwise preprocess data, the Janex library comes with some pre-made tools.

To tokenize:

from Janex.word_manipulation import *

string = "Hello. My name is Brendon."

tokens = tokenize(string)

print(tokens)

To vectorize:

from Janex.vectortoolkit import *

input_string = "Hello, my name is Sheila."

vectors = string_vectorize(input_string)

vectors = reshape_array_dimensions(vectors, 300) # To reshape the vector array

secondstring = "Hello, my name is Robert."

second_vectors = string_vectorize(secondstring)

second_vectors = reshape_array_dimensions(second_vectors, 300)

similarity = calculate_cosine_similarity(vectors, second_vectors)

print(similarity)

Metadata

Release files for Janex 0.0.80

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for Janex 0.0.80
File Size Uploaded Provenance Actions
Janex-0.0.80.tar.gz 5.4 kB Without provenance Details for Janex-0.0.80.tar.gz

Release files / Janex-0.0.80.tar.gz

Download URL Janex-0.0.80.tar.gz
Size 5.4 kB
Tags Source
SHA-256 checksum
How to use checksums
39b9e9937c711f4d1a7690d2ce84335ed70380eb57ec314b317707e3d4b20234
BLAKE2b-256 checksum
How to use checksums
ab2f249dde29ce9d47d2d24b8bbd6c4ba157fd90a2a72d99991e22e5dfac656f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.2

Security for Janex 0.0.80

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.0.80 This release

1 release file No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page