Skip to main content

MTLLM Provides Easy to use APIs for different LLM Providers to be used with Jaseci's Jaclang Programming Language.

Project description

MTLLM API library

PyPI version tests

The MTLLM Python library provides convenient access to a large number of easy to use and customizable APIs to be used in Jaseci's Jaclang by llm feature. The Library provides automatic output fixing, output type validation, different prompting techniques, and more.

Documentation

The documentation on how to use this library with Jaseci's Jaclang can be found here.

Installation

[!IMPORTANT] Though this is can be used with python projects, it is primarily intended to be used with Jaseci's Jaclang.

# install from PyPI
pip install mtllm

Usage

Refer the Documentation for detailed usage instructions.

Using Different LLMs

import:py from mtllm.llms, OpenAI;

glob llm = OpenAI();

can "Translate English to French"
translate(word: "English Word": str) -> "French Word": str by llm();

Based on your LLM of choice, make sure to set the API Key in the environment variable. For example, for OpenAI:

export OPENAI_API_KEY="your-api-key"

Using Tools

import:py from mtllm.llms, OpenAI;
import:py from mtllm.tools, wikipedia;

glob llm = OpenAI();

can "Answer History Questions"
history_qa(question: "History Question": str) -> "Detailed Answer": str by llm(tools=[wikipedia]);

Contributing

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.

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

mtllm-0.3.1.tar.gz (18.0 kB view details)

Uploaded Source

Built Distribution

mtllm-0.3.1-py3-none-any.whl (26.7 kB view details)

Uploaded Python 3

File details

Details for the file mtllm-0.3.1.tar.gz.

File metadata

  • Download URL: mtllm-0.3.1.tar.gz
  • Upload date:
  • Size: 18.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.12.4 Linux/6.5.0-1025-azure

File hashes

Hashes for mtllm-0.3.1.tar.gz
Algorithm Hash digest
SHA256 cc7ead7a24b7388d155904cabe08775fddfac786cd29e54f19efbaef00120fc3
MD5 fc25ff44af1ae5c01ea680e6a92aeeae
BLAKE2b-256 d268dcb83d49e0e2705b5cd0fdff61efe2b40201d5d563f3a19fbb38de52e94f

See more details on using hashes here.

File details

Details for the file mtllm-0.3.1-py3-none-any.whl.

File metadata

  • Download URL: mtllm-0.3.1-py3-none-any.whl
  • Upload date:
  • Size: 26.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.12.4 Linux/6.5.0-1025-azure

File hashes

Hashes for mtllm-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 9d2a6e379304d2dda4e5a2a831904b41d85a9e66469ef60718dac122e9256c78
MD5 96d727acd5c9729567a6859d85efe7dd
BLAKE2b-256 6d2927f786f31aec0521c94222d7dbf848643bea927e61c275e0495c57cf4970

See more details on using hashes here.

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