Skip to content

Instantly share code, notes, and snippets.

View elena-kolevska's full-sized avatar

Elena Kolevska elena-kolevska

View GitHub Profile
@elena-kolevska
elena-kolevska / .bashrc
Last active October 16, 2018 14:21
Coloured prompt
#...
PS1="\[\e[32m\]\u\[\e[m\]\[\e[32m\]@\[\e[m\]\[\e[32m\]\h\[\e[m\] \[\e[33m\]\w\[\e[m\] \[\e[33m\]\\$\[\e[m\] "
#...
# Online prompt generator: http://ezprompt.net/
@elena-kolevska
elena-kolevska / .zshrc
Last active September 26, 2023 23:47
My powerlevel9k theme config
# elena.zsh-theme
#
# Author: Elena Kolevska
# Based on Andy Flemin's afmagic theme
# dashed separator size
function afmagic_dashes {
# check either virtualenv or condaenv variables
local python_env_dir="${VIRTUAL_ENV:-$CONDA_DEFAULT_ENV}"
local python_env="${python_env_dir##*/}"
@elena-kolevska
elena-kolevska / memtier_start.sh
Last active December 23, 2019 12:41
Small cli tool for setting up parameters of the memtier_benchmark tool
#!/usr/bin/env bash
# Colours definition
HIGHLIGHT1='\033[0;34m'
HIGHLIGHT2='\033[0;33m'
SUCCESS='\033[0;32m'
ERROR='\033[0;31m'
GRAY='\033[0;37m'
NC='\033[0m' # No Color
@elena-kolevska
elena-kolevska / main.go
Last active September 12, 2023 10:34
Get embeddings from Hugging face, save them in Redis and run a vector similarity search
// Run this gist with Redis Stack 6.2
// Tested with:
// docker run -p 6381:6379 redis/redis-stack-server:6.2.6-v9-arm64
package main
import (
"bytes"
"context"
"encoding/binary"