- Transformers
- Ollama
- llama.cpp
- ExLlamaV2
- AutoGPTQ
- AutoAWQ
This file contains hidden or 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
import ollama from "ollama"; | |
import fs from "fs"; | |
const systemRole = `You are a senior software Engineer who is very picky with code-quality. You have read and memorised Clean Code from Robert Cecil Martin. Your goal is to read other people's code and improve then based on what you learned with that book.`; | |
const [, , fileToBeImproved] = process.argv; | |
if (fileToBeImproved) { | |
const fileContent = fs.readFileSync(fileToBeImproved, { encoding: "utf8" }); |
This file contains hidden or 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
:let ratio = split(execute('!curl --silent https://api.exchangeratesapi.io/latest\?base\=USD | jq .rates.BRL'))[-1] | let currentLine = getline(line('.')) | echo printf('%f', str2float(currentLine) * str2float(ratio)) |
This file contains hidden or 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
:let a = 1 | let b = 1 | let c = 1 | let fib = 10 | for i in range(1, fib) | let c = a + b | put =printf('%d + %d = %d', a, b, c) | let a = b | let b = c | endfor |
This file contains hidden or 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
:let fat = 10 | let aux = 1 | for i in range(1, fat) | let prevAux = aux | let aux = aux * i | put =printf('%d x %d = %d', prevAux, i, aux) |
This file contains hidden or 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
fd -e js | xargs -n1 bash -c '</dev/tty vim -c "normal! gg=G" -c "x" "$@"' ignoreme |
This file contains hidden or 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
<?xml version="1.0" encoding="utf-8"?> | |
<opml version="2.0"> | |
<head> | |
<title>gPodder subscriptions</title> | |
<dateCreated>Mon, 05 Feb 2018 16:48:18 -0300</dateCreated> | |
</head> | |
<body> | |
<outline text="Aprimore o seu inglês diáriamente com estes mini-podcasts de 5 minutos com o professor Tim Barrett de www.domineingles.com.br. Aprenda inglês do dia a dia, expressões, phrasal verbs, preposições, collocations e muito mais!" title="Inglês Todos os Dias" type="rss" xmlUrl="http://feeds.feedburner.com/inglestodososdias"/> | |
<outline text="O mundo vira piada no Jovem Nerd" title="NerdCast" type="rss" xmlUrl="https://jovemnerd.com.br/feed-nerdcast/"/> | |
<outline text="Discussões acaloradas sobre startups, programação, ux, gadgets e as últimas tendências em tecnologia." title="Hipsters Ponto Tech" type="rss" xmlUrl="https://hipsters.tech/feed/podcast/"/> |
This file contains hidden or 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
spot_song=$(qdbus org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Metadata); echo $(echo $spot_song | sed -ne 's/xesam:artist: \(.*\)$/\1/p') "-" $(echo $spot_song | sed -ne 's/xesam:title: \(.*\)$/\1/p') |
This file contains hidden or 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
import re | |
import pandas as pd | |
import matplotlib.pyplot as plt | |
artist = open('top_artists.csv') | |
csv = [(line[0], int(line[1].replace('.', ''))) for line in re.findall(r"\d+\s(.+?)\s([\d\.]+)$", artist.read(), re.MULTILINE)] | |
df = pd.DataFrame(csv, columns=['artist', 'scrobbles']) | |
# print df |
This file contains hidden or 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
#!/usr/bin/python | |
# -*- coding: utf-8 -*- | |
matrix = [[None for j in xrange(10)] for i in xrange(10)] | |
def print_matrix(): | |
for line in matrix: | |
for col in line: | |
print str(col)+'\t', | |
print '' |
NewerOlder