To utilize the LLaMaCpp library in PHP, follow these additional steps.
Install the LLaMaCpp adapter via Composer:
composer require kambo/llama-cpp-langchain-adapter
Obtain the model, for example, by using this command:
wget https://huggingface.co/LLukas22/gpt4all-lora-quantized-ggjt/resolve/main/ggjt-model.bin
You can use it like a regular LLM:
use Kambo\Langchain\LLMs\LLaMACpp;
$llm = new LLaMACpp(['model_path' => 'path/to/model.bin']);
$text = "What's the best programing language for web?";
echo $llm($text);