Skip to main content
Yanked

This release has been yanked by its maintainers, and will be ignored by installers, except when explicitly specified.
Consider using release 0.8.8 instead.
Reason given by maintainers: bug with latest feature. hotfix applied in 0.7.12

lanarky-logo

Lanarky

stars Documentation Code Coverage License: MIT Twitter

PyPI version PyPI stats Supported Python Versions

Lanarky is an open-source framework to deploy LLM applications in production. It is built on top of FastAPI and comes with batteries included.

Table of Contents

🚀 Features

  • 🌐 multi-mode token streaming
  • 💬 simple gradio chatbot UI for fast prototyping
  • 🔗 supports LangChain applications
  • 🗄️ multiple LLM caching strategies

See Roadmap for upcoming features.

❓ Why?

There are great low-code/no-code solutions in the open source to deploy your LLM projects. However, most of them are opinionated in terms of cloud or deployment code. This project aims to provide users with a cloud-agnostic and deployment-agnostic solution which can be easily integrated into existing backend infrastructures.

💾 Installation

The library is available on PyPI and can be installed via pip.

pip install lanarky

You can find the full documentation at https://lanarky.readthedocs.io/en/latest/.

🔥 Build your first Langchain app

from dotenv import load_dotenv
from fastapi import FastAPI
from langchain import ConversationChain
from langchain.chat_models import ChatOpenAI

from lanarky import LangchainRouter

load_dotenv()
app = FastAPI()

langchain_router = LangchainRouter(
    langchain_url="/chat",
    langchain_object=ConversationChain(
        llm=ChatOpenAI(temperature=0), verbose=True
    ),
    streaming_mode=0
  )
app.include_router(langchain_router)

See examples/ for list of available demo examples.

Create a .env file using .env.sample and add your OpenAI API key to it before running the examples.

demo

📍 Roadmap

🤩 Stargazers

Leave a ⭐ if you find this project useful.

Star History Chart

🤝 Contributing

Code check Publish

Contributions are more than welcome! If you have an idea for a new feature or want to help improve lanarky, please create an issue or submit a pull request on GitHub.

See CONTRIBUTING.md for more information.

Contributors

⚖️ License

The library is released under the MIT License.

✨ Want to build LLM applications with us?

Are you interested in building LLM applications with us? We would love to hear from you! Reach out to us on Twitter @lanarky_io.

Let's connect and explore the possibilities of working together to create amazing LLM applications with Lanarky!

Download files

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

Source Distribution

lanarky-0.7.11.tar.gz (16.6 kB view details)

Uploaded Source

Built Distribution

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

lanarky-0.7.11-py3-none-any.whl (20.9 kB view details)

Uploaded Python 3

File details

Details for the file lanarky-0.7.11.tar.gz.

File metadata

  • Download URL: lanarky-0.7.11.tar.gz
  • Upload date:
  • Size: 16.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.5.1 CPython/3.9.17 Linux/5.15.0-1039-azure

File hashes

Hashes for lanarky-0.7.11.tar.gz
Algorithm Hash digest
SHA256 38b4ef2cafb2f9cb3f97e0fa77e8136f0f133f738390f163ba299450d58fedd2
MD5 5e8b6c5b2309a3ebc10b93c5470b55f1
BLAKE2b-256 7aa5b9958acb20e19a1f8e4c3e4caa54e9fcf83f2ea97d7ee6f9f671b8467c4b

See more details on using hashes here.

File details

Details for the file lanarky-0.7.11-py3-none-any.whl.

File metadata

  • Download URL: lanarky-0.7.11-py3-none-any.whl
  • Upload date:
  • Size: 20.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.5.1 CPython/3.9.17 Linux/5.15.0-1039-azure

File hashes

Hashes for lanarky-0.7.11-py3-none-any.whl
Algorithm Hash digest
SHA256 2363bf6c3611c2fb9fa5ed3b6a0b497a4354655bedff630ed5d2c1890da2a142
MD5 e11f43020916c822e8671a481cebaefb
BLAKE2b-256 d87bde9053f8b9dad7e41c90cfadf0f12d89df95cf94369d9f2d001af353e93f

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 Sentry Error logging StatusPage Status page