Skip to main content

The framework for language assistants

Project description

Assistants

Developing language assistants with LLMs in a low-code way.

Quick Install

Install using pip:

pip install assistants

The framework requires a database to register the assistants. The default database used is MongoAtlas. Future versions of the framework will support additional database types. Currently, there is a MongoDB collection named assistants which registers each assistant as shown below:

_id : 6556db6cf114addad09420c6
assistant_name: "test_assist"
assistant_id: "asst_52TLl1OdJW6ulmLCEsDlizz8"
file_id: "file-lZUBJ3ZnxtkTfqsuE0WYMXDI"

What are Assistants?

Assistants is a framework for developing language-based assistants using micro agents, akin to the microservices concept. Each micro agent, like a microservice, can be independently developed and deployed. The framework adheres to the Single Responsibility Principle (SRP), allowing these assistants to be combined to address complex business processes through workflows.

Capabilities of the Framework

In time, the framework will include built-in assistants for immediate deployment within OpenAI environments. It will also support the development of custom assistants.

Contribution

Contributions are welcome in any form, be it through new features or improved documentation.

Example Usage

The repository includes various examples demonstrating framework usage.

import os

from assistants.langassist.summarize_assistant import SummarizeAssistant
from dotenv import load_dotenv

load_dotenv()
OPENAI_API_KEY = os.environ.get('OPENAI_API_KEY')

if __name__ == "__main__":
    # deploy the summarization assistant
    file = "gen_ai.pdf"
    assistant_name = "summarize_assistant"
    # sc = SummarizeAssistant(file=file,
    #                         assistant_name=assistant_name)
    # sc.deploy_assistant()
    
    # Run the assistant
    sc = SummarizeAssistant(assistant_name=assistant_name)
    question = "Summarize the content in 300 words. Please ensure all points are covered"
    print(sc.run_assistant(question))

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

langassist-0.0.2.tar.gz (6.3 kB view hashes)

Uploaded Source

Built Distribution

langassist-0.0.2-py3-none-any.whl (7.0 kB view hashes)

Uploaded Python 3

Supported by

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