Skip to content

Instantly share code, notes, and snippets.

View scott3j's full-sized avatar

Scott Jensen scott3j

View GitHub Profile
const SECRET_KEY = ENTER YOUR SECRET KEY HERE;
const MAX_TOKENS = 200;
// For more cool AI snippets and demos, follow me on Twitter: https://twitter.com/_abi_
/**
* Completes your prompt with GPT-3
*
* @param {string} prompt Prompt
* @param {number} temperature (Optional) Temperature. 1 is super creative while 0 is very exact and precise. Defaults to 0.4.
@sts10
sts10 / rust-command-line-utilities.markdown
Last active October 27, 2025 12:49
A curated list of command-line utilities written in Rust

A curated list of command-line utilities written in Rust

Note: I have moved this list to a proper repository. I'll leave this gist up, but it won't be updated. To submit an idea, open a PR on the repo.

Note that I have not tried all of these personally, and cannot and do not vouch for all of the tools listed here. In most cases, the descriptions here are copied directly from their code repos. Some may have been abandoned. Investigate before installing/using.

The ones I use regularly include: bat, dust, fd, fend, hyperfine, miniserve, ripgrep, just, cargo-audit and cargo-wipe.

  • atuin: "Magical shell history"
  • bandwhich: Terminal bandwidth utilization tool
@crshmk
crshmk / 11_svelte-file.svelte
Last active November 3, 2022 20:44
Learn Svelte in a gist
<script>
let x
</script>
<p>markup</p>
<style>
body {
background: white;
}
@rapatil
rapatil / Automating Salesforce Data Extraction Using Python.ipynb
Last active February 25, 2025 14:57
Approach: Automating Salesforce Data Extraction Using Python
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@n1snt
n1snt / Oh my ZSH with zsh-autosuggestions zsh-syntax-highlighting zsh-fast-syntax-highlighting and zsh-autocomplete.md
Last active October 27, 2025 16:55
Oh my ZSH with zsh-autosuggestions zsh-syntax-highlighting zsh-fast-syntax-highlighting and zsh-autocomplete.md

Oh my zsh.

Oh My Zsh

Install ZSH.

sudo apt install zsh-autosuggestions zsh-syntax-highlighting zsh

Install Oh my ZSH.

@phortuin
phortuin / postgres.md
Last active August 18, 2025 04:04
Set up postgres + database on MacOS (M1)

Based on this blogpost.

Install with Homebrew:

$ brew install postgresql@14

(The version number 14 needs to be explicitly stated. The @ mark designates a version number is specified. If you need an older version of postgres, use postgresql@13, for example.)

@yashprakash13
yashprakash13 / app.py
Created April 4, 2021 17:26
FastApi example
import uvicorn
from fastapi import FastAPI
from model import SentimentModel, SentimentQueryModel
app = FastAPI()
model = SentimentModel()
@app.post('/predict')
def predict(data: SentimentQueryModel):
data = data.dict()
@seblegall
seblegall / reverseproxy.go
Last active October 16, 2025 06:16
A reverse proxy in Golang using Gin
package main
import (
"fmt"
"net/http"
"net/http/httputil"
"net/url"
"github.com/gin-gonic/gin"
)
@luisangelma
luisangelma / main.js
Last active September 25, 2022 06:48
CLI RPG Game
// Requirement
// Readline Sync Node package
var readlineSync = require('readline-sync');
var name = readlineSync.question('Hey stranger, what is your name?: ');
var enemies = ['White Walker', 'White Orc', 'Wild Dragon'];
var wildAdventure = function() {
var self = this;
@yowu
yowu / HttpProxy.go
Last active July 20, 2025 12:48
A simple HTTP proxy by Golang
package main
import (
"flag"
"io"
"log"
"net"
"net/http"
"strings"
)