Skip to main content

Simple Langchain model based on Ollama using Langchain model manager for Quackamollie Telegram chat bot

Project description

Name:

Quackamollie Model Langchain Simple

Package name:

quackamollie-model-langchain-simple

Description:

Simple Langchain model based on Ollama using Langchain model manager for Quackamollie Telegram chat bot

Version:
0.1
Main page:

https://gitlab.com/forge_of_absurd_ducks/quackamollie/lib/models/langchain/quackamollie_model_langchain_simple

PyPI package:

https://pypi.org/project/quackamollie-model-langchain-simple/

Docker Image:

registry.gitlab.com/forge_of_absurd_ducks/quackamollie/lib/models/langchain/quackamollie_model_langchain_simple:0.1

Documentation:

https://simple-langchain-model-forge-of-absurd-ducks-qua-dc7b8b58725b30.gitlab.io

Build Status:
Master:

Master pipeline status Master coverage status

Dev:

Dev pipeline status Dev coverage status


Project description

Quackamollie is a Telegram chat bot developed in Python using the library aiogram to serve LLM models running locally using Ollama.

This package is a simple Langchain model compatible with the Langchain model manager of the Quackamollie project. It contains:

  • a model SimpleLangchainQuackamollieModel class implementing abstract functions of MetaLangchainQuackamollieModel

Learn more about Quackamollie on the project main page.

Requirements

Virtual environment

  • Setup a virtual environment in python 3.10

make venv
# or
python3 -m venv venv
  • Activate the environment

source venv/bin/activate
  • If you want to deactivate the environment

deactivate

Tests

Tests requirements

  • Install test requirements

make devtools
# or
pip install tox

Run pytest

  • Run the tests

tox

Run lint

  • Run the lintage

tox -e lint

Documentation

  • To auto-generate the documentation configuration

tox -e gendocs
  • To generate the documentation in Html

tox -e docs
  • An automatically generated version of this project documentation can be found here

    • N.B.: This automatically generated documentation of the Quackamollie core project is still laking a lot of improvements. Sorry for the inconvenience.

Install

  • Install the application from sources

make install
# or
pip install .
  • Or install it from distribution

pip install dist/quackamollie-model-langchain-simple-0.1.tar.gz
  • Or install it from wheel

pip install dist/quackamollie-model-langchain-simple-0.1.whl
  • Or install it from PyPi repository

pip install quackamollie-model-langchain-simple  # latest
# or
pip install "quackamollie-model-langchain-simple==0.1"

Docker

  • To build the application docker

docker build --network=host -t quackamollie_model_langchain_simple:0.1 .
  • The official Docker image of this project is available at: registry.gitlab.com/forge_of_absurd_ducks/quackamollie/lib/models/langchain/quackamollie_model_langchain_simple

  • You can pull the image of the current release:

docker pull registry.gitlab.com/forge_of_absurd_ducks/quackamollie/lib/models/langchain/quackamollie_model_langchain_simple:latest  # or dev
# or
docker pull registry.gitlab.com/forge_of_absurd_ducks/quackamollie/lib/models/langchain/quackamollie_model_langchain_simple:0.1

Running the model

quackamollie-model-langchain-simple package is automatically discovered, through entrypoints, by the Langchain model manager through the command tool line named quackamollie. Therefore, once installed, you should automatically see this model in Telegram /settings command.

You should pull an Ollama model for this Langchain model by simply using the ollama command tool line:

ollama pull llama3

For details on how to run the Quackamollie project, please refer to the Quackamollie’s project main page.

Authors

Contributing

If you want to report a bug or ask for a new feature of quackamollie-model-langchain-simple, please open an issue in the Gitlab ticket management section of this project. Please, first ensure that your issue is not redundant with already open issues.

If you want to contribute code to this project, please open first an issue and then a merge request with commit names referencing this issues. Note that only fast-forward merge requests are accepted.

For more details on the general contributing mindset of this project, please refer to CONTRIBUTING.md.

Credits

Section in writing, sorry for the inconvenience.

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

quackamollie_model_langchain_simple-0.1.tar.gz (19.3 kB view details)

Uploaded Source

Built Distribution

File details

Details for the file quackamollie_model_langchain_simple-0.1.tar.gz.

File metadata

File hashes

Hashes for quackamollie_model_langchain_simple-0.1.tar.gz
Algorithm Hash digest
SHA256 958c545f8dd1364e155d5b7dc2cdd653f84873b9720de4ec59f2586690954e87
MD5 7f2952bb01562dbbaba4278b89492600
BLAKE2b-256 3e2806ea58fc30a56b0ee4cdff473f301bd8e90eb01a1c7ceba43af342fb2cb8

See more details on using hashes here.

File details

Details for the file quackamollie_model_langchain_simple-0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for quackamollie_model_langchain_simple-0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 01c086f0e10c108978d85d01c8f6ca1b0439edb958f51aa52e7af3b04d22170a
MD5 b60775d4eaa71713e8b87228c7a6c1af
BLAKE2b-256 b0cac85a88e272d06005b62034f328916ec65240aa4aef3cf0a5024d275e9c74

See more details on using hashes here.

Supported by

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