This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function TRANSLATE(text, repo_id="Helsinki-NLP/opus-mt-en-es") { | |
endpoint = "https://api-inference.huggingface.co/pipeline/translation/" + repo_id; | |
const payload = JSON.stringify({ | |
"inputs": text | |
}); | |
// Add your token from https://huggingface.co/settings/token | |
const options = { | |
"headers": {"Authorization": "Bearer <YOUR HUGGINGFACE API KEY>"}, | |
"wait_for_model": true, |
The following problems are equvalent of Grokking the coding interview course, and solutions are also attached
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Clone llama.cpp | |
git clone https://github.com/ggerganov/llama.cpp.git | |
cd llama.cpp | |
# Build it | |
make clean | |
LLAMA_METAL=1 make | |
# Download model | |
export MODEL=llama-2-13b-chat.ggmlv3.q4_0.bin |