Skip to content

Instantly share code, notes, and snippets.

View Nekuromento's full-sized avatar
💭
Watched Over by Machines of Loving Grace

Max Klyga Nekuromento

💭
Watched Over by Machines of Loving Grace
View GitHub Profile
@Nekuromento
Nekuromento / copilot.mjs
Last active June 4, 2025 12:33
Simple proxy to make Github Copilot API compatible with OpenAI responses expected by clients
#!/usr/bin/env bun
const host = 'api.githubcopilot.com';
const base_url = `https://${host}` // github doesn't have a /v1 prefix
const key = 'YOUR API GITHUB TOKEN GOES HERE';
let authState = {};
const refreshToken = async () => {
console.log(`${Date()} * refreshing token...`);
const authResponse = await fetch(`https://api.github.com/copilot_internal/v2/token`, {
method: 'GET',
@Nekuromento
Nekuromento / samba-proxy.mjs
Last active September 3, 2024 15:54
Simple proxy to make Sambanova fast api compatible with OpenAI auth
#!/usr/bin/env bun
const host = 'fast-api.snova.ai';
const base_url = `https://${host}/v1`
const key = 'YOUR API KEY GOES HERE';
const models = [
"Meta-Llama-3.1-8B-Instruct-8k",
"Meta-Llama-3.1-8B-Instruct",
"Meta-Llama-3.1-70B-Instruct",
"Meta-Llama-3.1-405B-Instruct",
" vim: foldlevelstart=0 foldcolumn=1
" |Vundle configuration| {{{
set nocompatible " switch VI compatibility off
filetype off " turn off filetype detection. Required by Vundle
set rtp+=~/.vim/bundle/Vundle.vim/
call vundle#begin()
" let Vundle manage Vundle
float sum(vec4 rgb) {
return rgb.r + rgb.g + rgb.b;
}
void mainImage(out vec4 fragColor, in vec2 fragCoord) {
const float glyphSize = 8.;
const float glyphCount = 16.;
vec2 index = floor(fragCoord / glyphSize);
float charIndex = 14.;
0x7e9A732AD60BD1A0BF4Ff59164399584B1A63Fe8
@Nekuromento
Nekuromento / keybase.md
Created September 15, 2017 14:09
keybase.md

Keybase proof

I hereby claim:

  • I am nekuromento on github.
  • I am maxklyga (https://keybase.io/maxklyga) on keybase.
  • I have a public key ASDh4Mz2j5DeaRnqVlsCYbCcfH1RfQmuFnUv9BtVZEIMzQo

To claim this, I am signing this object:

@Nekuromento
Nekuromento / monadic-transaction-test.js
Created August 17, 2015 11:51
Testing out using Reader monad for wrapping SQL operations in a transaction
'use strict';
var Promise = require('pacta');
var Reader = require('fantasy-readers');
var pg = require('pg');
var ReaderPromise = Reader.ReaderT(Promise);
var doM = f => {
const get = f();
" |Vundle configuration| {{{
set nocompatible " switch VI compatibility off
filetype off " turn off filetype detection. Required by Vundle
set rtp+=~/.vim/bundle/vundle/
call vundle#rc()
" let Vundle manage Vundle
Bundle 'gmarik/vundle'
" |Vundle configuration| {{{
set nocompatible " switch VI compatibility off
filetype off " turn off filetype detection. Required by Vundle
set rtp+=~/.vim/bundle/vundle/
call vundle#rc()
" let Vundle manage Vundle
Bundle 'gmarik/vundle'