Installation and Setup
Prerequisites:
You must first follow the Access & SDK Installation guide
Installation:
- Install Konko:
pip install konko
- Install LlamaIndex:
pip install llama-index
Before proceeding, ensure that you've set up the required environment variables.
export KONKO_API_KEY={your_KONKO_API_KEY_here}
export OPENAI_API_KEY={your_OPENAI_API_KEY_here}
#Optional
Verification:
To verify the successful installation and setup, run the following in your Python environment:
from llama_index.llms import Konko
from llama_index.llms.base import ChatMessage
llm = Konko(model="meta-llama/llama-2-13b-chat")
message = ChatMessage(role="user", content="Generate a Product Description for Apple Iphone 15")
response = llm.chat([message])
print(response)
If there are no errors, your setup is complete, and you're ready to start using Konko with LlamaIndex!
Updated 8 months ago
Whatβs Next