Skip to main content

A Python package to get data from different llm's

Project description

🔷 Kynex

Kynex is a modular Python framework that simplifies connecting to multiple LLM providers such as Google Gemini and Groq via a unified, flexible interface. Whether you're building AI workflows, chatbots, or prompt-based applications, Kynex makes it seamless to integrate LLMs dynamically based on user input.


🚀 Features

  • Multi-LLM support**: Easily switch between different LLMs
  • API key flexibility**: Dynamically accept LLM type, model name, and API key at runtime
  • LangChain prompt integration**: Use PromptTemplate for advanced prompt formatting
  • Simple base architecture**: Extend to any new LLM provider with a custom class

📦 Installation

pip install kynex


Example Usage:

Create it:

Create a Python file and add the following:

from kynex.kynexa import Kynex

request = {
    "prompt": "your_prompt.",
    "model_name": "your_model_name",
    "api_key": "your_api_key",
    "llm_type": "type_llm"  # e.g: "gemini"
}

response = Kynex.get_llm_response(
    prompt=request["prompt"],
    model_name=request["model_name"],
    api_key=request["api_key"],
    llm_type=request.get("llm_type")
)

print(response)

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

kynex-0.1.8.tar.gz (4.1 kB view details)

Uploaded Source

Built Distribution

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

kynex-0.1.8-py3-none-any.whl (5.0 kB view details)

Uploaded Python 3

File details

Details for the file kynex-0.1.8.tar.gz.

File metadata

  • Download URL: kynex-0.1.8.tar.gz
  • Upload date:
  • Size: 4.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.11

File hashes

Hashes for kynex-0.1.8.tar.gz
Algorithm Hash digest
SHA256 116bf38178ac65c488d31bfb9a0b46beefcbf1005e9fd3ed8f39ec081fc8d6f3
MD5 9cc5e21dfe9b9b604690be7bbd8148c1
BLAKE2b-256 321a45b33d949eab6c317f684e1955dfb9131a646a354b89dc9def0973604f5d

See more details on using hashes here.

File details

Details for the file kynex-0.1.8-py3-none-any.whl.

File metadata

  • Download URL: kynex-0.1.8-py3-none-any.whl
  • Upload date:
  • Size: 5.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.11

File hashes

Hashes for kynex-0.1.8-py3-none-any.whl
Algorithm Hash digest
SHA256 34fd3cd82535d4a1718becba1eb80dd8a6d1c36c920038de3314572e1eb33137
MD5 1d68023b9ec77ea1c43a872f83d06dbd
BLAKE2b-256 57a748cfb8e395f1fd7974aa484586d3de0033841a5a34136651cb5c6bbeb68a

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