Skip to content

Instantly share code, notes, and snippets.

View heijligers's full-sized avatar

B.M.R. Heijligers heijligers

View GitHub Profile
from txtai import Embeddings
embeddings = Embeddings(
method="model2vec",
path="minishlab/M2V_base_output"
)
embeddings.index(["test"])
embeddings.search("test")
# [(0, 1.0)]
@mikeslattery
mikeslattery / git-syncr
Last active February 25, 2024 20:23
Git Directory Synchronizer
#!/bin/bash
help() { cat<<HELP
git-syncr - git worktree synchronizer
Usage: git syncr <command>
COMMANDS:
create <path> [<branch>]
Create new worktree at <path> forked from current directory.
@epoz
epoz / codesigning.md
Last active February 14, 2021 13:41
Code signing certificates prices/availability
@spectrvrc
spectrvrc / jwdownloader.py
Created December 10, 2017 09:19
Download JW Player Videos
import requests
import re
def download_file(url):
local_filename = url.split('/')[-1]
r = requests.get(url, stream=True)
with open(local_filename, 'wb') as f:
for chunk in r.iter_content(chunk_size=1024):
if chunk:
f.write(chunk)