Skip to main content

Tezeta: A Package for Maximizing Context Window Utilization in Chatbots (Under Development)

:warning: Tezeta is currently under active development and is not yet functional. The features listed below are planned for future releases.

Tezeta is a Python package designed to optimize memory in chatbots and Language Model (LLM) requests using relevance-based vector embeddings. This tool aims to maximize the utilization of context windows, thereby improving chatbot performance by allowing the storage and retrieval of more relevant conversation history.

Supported Features

  • Using vector embeddings to rank chats based on relevance with OpenAI embeddings and Pinecone
  • Using ChromaDB as vector store with the default all-MiniLM-L6-v2
  • Using ChromaDB as vector store
  • Support for using Open Source Embedding Models locally (currently through all-MiniLM-L6-v2 with chromaDB)

Planned Features

  • Chunk up and rank sections of long text in a single chat or LLM request
  • Support for using the Cohere API for Embeddings

Installation

pip install tezeta

Basic Usage

First, to set the necessary environment variables in your system, you can use the following terminal commands.

For macOS/Linux:

export PINECONE_API_KEY=your_api_key
export OPENAI_API_KEY=your_api_key
export PINECONE_ENVIRONMENT=your_pinecone_environment

For Windows:

set PINECONE_API_KEY=your_api_key
set OPENAI_API_KEY=your_api_key
set PINECONE_ENVIRONMENT=your_pinecone_environment

You can use the package as follows:

import tezeta

chats = [
    {
        "role" : "user",
        "content" : "Wellness is an important part of wellbeing. How are you tackling that in your life"
    },
    {
        "role" : "user",
        "content" : "Hello there Jon, I'm a less relevant text that is trying really really hard to excluded from this test."
    },
    {
        "role" : "assistant",
        "content" : "I'm doing well, how are you?"
    }
]

tezeta.set_max_tokens(30)

print(chats)
llm_chats = tezeta.chats.fit_messages(chats)
print (llm_chats)

Documentation

Documentation will be available in the future.

License

This project is licensed under the terms of the MIT license.

Metadata

Release files for tezeta 0.0.1

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

Source distribution (sdist)

Source distribution for tezeta 0.0.1
File Size Uploaded
tezeta-0.0.1.tar.gz 5.3 kB Details

Release files / tezeta-0.0.1.tar.gz

Download URL tezeta-0.0.1.tar.gz
Size 5.3 kB
Tags Source
SHA-256 checksum
How to use checksums
19f84035cb85c786dabef45c5d05e35861a1067624adccef63ed14c3d21deb88
BLAKE2b-256 checksum
How to use checksums
e0eddab05098e887768992e4c406bdf41aeaf7067e65ad0fab734737b7c7fa62
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.4

Release history Release notifications | RSS feed

This release

0.0.1 This release

1 release file

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