Skip to main content

LangChain integrations for llama-server inference

Project description

langchain-llama-server

This LangChain integration supports llama-server for remote inference over HTTP/S.

Normally you can use ChatOpenAI from langchain-openai for OpenAI compatible APIs. But, anything beyond the OpenAI spec is not supported. Hence why this integration exists.

This package was created to fill in the gaps between the OpenAI spec and extra fields llama-server returns:

  • Access reasoning_content on both streaming and non-streaming chat completions.
  • Capture timings, __verbose and other llama-server specific response fields.
  • Uses BaseChatOpenAI from langchain-openai to implement a chat_model called ChatLlamaServer

Similar to other server integrations:

TODO

  • LlamaServerLLM ?
  • LlamaServerEmbedding ?

What about ChatLlamaCpp?

The langchain_community package provides ChatLlamaCpp? This chat model targets in-process hosting using llama.cpp. It doesn't support llama-server for remote hosting.

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

langchain_llama_server-0.1.2.tar.gz (130.8 kB view details)

Uploaded Source

Built Distribution

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

langchain_llama_server-0.1.2-py3-none-any.whl (4.7 kB view details)

Uploaded Python 3

File details

Details for the file langchain_llama_server-0.1.2.tar.gz.

File metadata

  • Download URL: langchain_llama_server-0.1.2.tar.gz
  • Upload date:
  • Size: 130.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for langchain_llama_server-0.1.2.tar.gz
Algorithm Hash digest
SHA256 31a0c0f0ff032cb55cbf024fa4bf5defedeb3c476bcbfada5e0fab5a1feb4647
MD5 ec679a7636de7cf855ec5a1bda5c8406
BLAKE2b-256 8cb779a66bb688ddaf5fa3323df13910b9e1a26f42517839df11a3dfd2779dce

See more details on using hashes here.

File details

Details for the file langchain_llama_server-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: langchain_llama_server-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 4.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.6 {"installer":{"name":"uv","version":"0.11.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for langchain_llama_server-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 8f8ae6ff0a6b3351b08b5bb89df9fced08b4a671340b011c246aa26b3108a0c4
MD5 5ae9857ccb64c7c08220ec6030a35ea0
BLAKE2b-256 1101e5ed84aecab80e3cc2a011fb3aeb826b8a1bb0049389fc53222d99dd72ae

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