Skip to content

Instantly share code, notes, and snippets.

View shanev's full-sized avatar
💭
#BUIDL

Shane Vitarana shanev

💭
#BUIDL
View GitHub Profile
@awni
awni / mlx_distributed_deepseek.md
Last active December 15, 2025 18:50
Run DeepSeek R1 or V3 with MLX Distributed

Setup

On every machine in the cluster install openmpi and mlx-lm:

conda install conda-forge::openmpi
pip install -U mlx-lm

Next download the pipeline parallel run script. Download it to the same path on every machine:

@oca159
oca159 / tmux.conf
Last active December 9, 2025 15:15
tmux
# Set terminal colors
set-option -sa terminal-overrides ",xterm*:Tc"
# Enable mouse support
set -g mouse on
# Start windows and panes at 1, not 0
set -g base-index 1
set -g pane-base-index 1
set-window-option -g pane-base-index 1
@oca159
oca159 / config
Last active December 9, 2025 15:15
ghostty
theme = Catppuccin Mocha
adjust-cell-height = 0%
command = /bin/zsh -c "tmux new -A -s work"
copy-on-select = true
font-family = "BlexMono Nerd Font Mono"
font-size = 16
font-thicken = true
mouse-hide-while-typing = true
macos-non-native-fullscreen=visible-menu
ics title stage category author created modified
999
One Channel
draft
IBC/APP
Larry Engineer <[email protected]>
2023-03-02
2023-03-02
@bloqhub
bloqhub / gist:ba04d09891bd59c21d9ff228eefadb62
Created October 29, 2021 15:15
Stargaze cosmovisor setup
0. Upgrade node to resease 1.0.0 Using docs:
https://github.com/public-awesome/mainnet/tree/main/stargaze-1
1. setup cosmovisor
cd ~
git clone https://github.com/cosmos/cosmos-sdk
cd cosmos-sdk
git checkout v0.42.7
@webmaster128
webmaster128 / json-schema-ref-parser-cli.js
Created October 13, 2021 20:15
CosmWasm schema to TypeScript .d.ts
#!/usr/bin/env node
const $RefParser = require("@apidevtools/json-schema-ref-parser");
function printUsage() {
console.info("Usage: json-schema-ref-parser-cli FILE")
}
async function main(args) {
if (args.length !== 1) {
@fxn
fxn / 01 main.rs
Last active August 23, 2021 15:13
Mandelbrot set generator from "Programming Rust", with ports to Crystal and Ruby.
// Mandelbrot set generator from "Programming Rust", with I/O removed (the
// original code writes a PNG file).
use std::env;
use std::str::FromStr;
use num::Complex;
fn main() {
let args: Vec<String> = env::args().collect();

ICS: Cinderella Tokens: An Async/IBC friendly alternative to flash loans

Flashloans are a fascinating economic coordination mechanism that has emerged out the Ethereum architecture as a result of a synchronous, sequential, atomic transaction system. It allows anonymous coordination between capital providers and arbitrageurs because the capital providers can condition providing any capital on protocol enforced guarantee that the entire arbitrage is profitable denominated in the token being lent.

One of the effects of this process has been the it ensures an efficient and healthy liquidation market for the collateral in long term debt instruments. It also enables low cost scaling of economic exploits.

Why don’t flash loans exist in IBC world?

Flash loans are impossible in an IBC world because IBC semantics require finalizing a block on the origin chain rather than on the receiving chain. This makes atomicity for the lender difficult and moves us into the domain of over collateralized lending.

@progrium
progrium / README.md
Last active July 19, 2025 19:41
Setting up M1 Macs for x86 development with Homebrew

Key Points

  • In general, binaries built just for x86 architecture will automatically be run in x86 mode
  • You can force apps in Rosetta 2 / x86 mode by right-clicking app, click Get Info, check "Open using Rosetta"
  • You can force command-line apps by prefixing with arch -x86_64, for example arch -x86_64 go
  • Running a shell in this mode means you don't have to prefix commands: arch -x86_64 zsh then go or whatever
  • Don't just immediately install Homebrew as usual. It should most likely be installed in x86 mode.

Homebrew

Not all toolchains and libraries properly support M1 arm64 chips just yet. Although