Skip to content

Instantly share code, notes, and snippets.

@veekaybee
veekaybee / normcore-llm.md
Last active April 26, 2024 09:36
Normcore LLM Reads

Anti-hype LLM reading list

Goals: Add links that are reasonable and good explanations of how stuff works. No hype and no vendor content if possible. Practical first-hand accounts of models in prod eagerly sought.

Foundational Concepts

Screenshot 2023-12-18 at 10 40 27 PM

Pre-Transformer Models

@kfox
kfox / README.md
Last active December 4, 2023 11:08
TCP echo server for Node.js

TCP echo server for Node.js

Usage

  1. Make sure you have a modern-ish version of Node.js installed.
  2. Type npx https://gist.github.com/kfox/1280c2f0ee8324067dba15300e0f2fd3
  3. Connect to it from a client, e.g. netcat or similar: nc localhost 9000
@leegilmorecode
leegilmorecode / aws-block-stack.ts
Created December 31, 2021 13:49
Example of API Gateway caching on AWS using the CDK
// create the rest API for accessing our lambdas
const api: apigw.RestApi = new apigw.RestApi(this, "blogs-api", {
description: "blogs api gateway",
deploy: true,
deployOptions: {
// this enables caching on our api gateway, with a ttl of five minutes (unless overridden per method)
cachingEnabled: true,
cacheClusterEnabled: true,
cacheDataEncrypted: true,
stageName: "prod",
@emmanuelnk
emmanuelnk / cleanEmpty.js
Created May 13, 2020 08:07
Clean js object by recursive removal of undefined, null, NaN and empty strings
// A SO answer to https://stackoverflow.com/questions/286141/remove-blank-attributes-from-an-object-in-javascript
// based off the recursive cleanEmpty function by @chickens.
// This one can also handle Date objects correctly
// and has a defaults list for values you want stripped.
const cleanEmpty = function(obj, defaults = [undefined, null, NaN, '']) {
if (defaults.includes(obj)) return
if (Array.isArray(obj))
return obj
@blurayne
blurayne / ui-widget-select.sh
Last active March 15, 2024 20:27
Pure BASH interactive CLI/TUI menu (single and multi-select/checkboxes)
#!/bin/bash
##
# Pure BASH interactive CLI/TUI menu (single and multi-select/checkboxes)
#
# Author: Markus Geiger <mg@evolution515.net>
# Last revised 2019-09-11
#
# ATTENTION! TO BE REFACTORED! FIRST DRAFT!
#
@tomfa
tomfa / handler.py
Last active February 14, 2023 15:08
AWS Lambda: Python store to S3
# This file is your Lambda function
import json
import boto3
def save_to_bucket(event, context):
AWS_BUCKET_NAME = 'my-bucket-name'
s3 = boto3.resource('s3')
bucket = s3.Bucket(AWS_BUCKET_NAME)
path = 'my-path-name.txt'

Upload images to GitHub

  1. Create a new issue on GitHub.

  2. Drag an image into the comment field.

  3. Wait for the upload process to finish.

  4. Copy the URL and use it in your Markdown files on GitHub.

@Geoyi
Geoyi / install virtualenv ubuntu 16.04.md
Created September 16, 2017 12:19 — forked from frfahim/install virtualenv ubuntu 16.04.md
How to install virtual environment on ubuntu 16.04

How to install virtualenv:

Install pip first

sudo apt-get install python3-pip

Then install virtualenv using pip3

sudo pip3 install virtualenv 
@Geoff-Ford
Geoff-Ford / composing-software.md
Last active March 3, 2024 08:48
Eric Elliott's Composing Software Series

Eric Elliott's "Composing Software" Series

A collection of links to the excellent "Composing Software" series of medium stories by Eric Elliott.

Edit: I see that each post in the series now has index, previous and next links. However, they don't follow a linear flow through all the articles with some pointing back to previous posts effectively locking you in a loop.

@Geoff-Ford
Geoff-Ford / master-javascript-interview.md
Last active March 22, 2024 07:14
Eric Elliott's Master the JavaScript Interview Series