Skip to main content

Blexus official package

Project description

🚀 Blexus

Welcome to Blexus, an AI innovation lab committed to crafting small, specialized AI models. Our mission is to unlock the full potential of AI through task-specific models that are fast, efficient, and highly customizable—ideal for developers, businesses, and everyday use cases. READ MORE


🛠️ Installation

You can install the Blexus package using pip. Run the following command:

pip install blexus

Use Quble models

from blexus import blexus
TextGenerator = blexus.TextGenerator

# Define the chat template  IMPORTANT: fill in the fields!
chat_template = {
    "before_system": "",
    "after_system": "",
    "before_user": "",
    "after_user": "",
    "before_assistant": ""
}

# Load Quble model
text_generator_quble = TextGenerator()
text_generator_quble.loadQuble()

# Generate text using Quble model
user_input = "Hello, how are you?"
system_input = "You are a helpful assistant."
generated_texts_quble = text_generator_quble.useQuble(user_input, system_input, chat_template, max_length=100, temperature=0.7, num_return_sequences=1)
print("Quble generated texts:", generated_texts_quble)

# Eject Quble model when done
text_generator_quble.eject_model()


# Load FCP model from a Hugging Face path
huggingface_path = "huggingface/fcp-model-name"  # Replace with actual Hugging Face model path
text_generator_fcp = TextGenerator()
text_generator_fcp.loadFCP(huggingface_path)

# Generate text using FCP model
generated_texts_fcp = text_generator_fcp.useFCP(user_input, system_input, chat_template, max_length=100, temperature=0.7, num_return_sequences=1)
print("FCP generated texts:", generated_texts_fcp)

# Eject FCP model when done
text_generator_fcp.eject_model()

Working exmaple:

from blexus import blexus
TextGenerator = blexus.TextGenerator

# Define the chat template  IMPORTANT: fill in the fields!
chat_template = {
    "before_system": "SYSTEM:",
    "after_system": "<|endofsystem|>",
    "before_user": "USER:",
    "after_user": "<|endoftext|>",
    "before_assistant": "ASSISTANT:"
}

# Load Quble model
text_generator_quble = TextGenerator()
text_generator_quble.loadQuble()

# Generate text using Quble model
user_input = "hi"
system_input = "You are a helpful assistant."
generated_texts_quble = text_generator_quble.useQuble(user_input, system_input, chat_template, max_length=50, temperature=0.7, num_return_sequences=1)
print("Quble generated texts:", generated_texts_quble)

# Eject Quble model when done
text_generator_quble.eject_model()

More coming soon!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

blexus-0.0.5.tar.gz (3.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

blexus-0.0.5-py3-none-any.whl (4.1 kB view details)

Uploaded Python 3

File details

Details for the file blexus-0.0.5.tar.gz.

File metadata

  • Download URL: blexus-0.0.5.tar.gz
  • Upload date:
  • Size: 3.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.3

File hashes

Hashes for blexus-0.0.5.tar.gz
Algorithm Hash digest
SHA256 da417a3fdb24b8178ce818cb76dcf368b21f5b4851c71fb826789e00090a0454
MD5 2995b11201d99bfb7daad831be729066
BLAKE2b-256 02ba45842fc3f103c16d38b1cc8c8a2fbbfaf4e418da81cde82775a6b0a1fd8f

See more details on using hashes here.

File details

Details for the file blexus-0.0.5-py3-none-any.whl.

File metadata

  • Download URL: blexus-0.0.5-py3-none-any.whl
  • Upload date:
  • Size: 4.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.3

File hashes

Hashes for blexus-0.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 02df70943ecf3ddf853035108705dabb097b43908c81b1aa46a6e08fdb435981
MD5 83f783e187055e14e1f1bbadcf8775d9
BLAKE2b-256 02c7e02322ef3730ea746340ab9218346faff8952cfe01c9043ad972d42aa5e1

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page