Skip to content

Instantly share code, notes, and snippets.

View usmanakram232's full-sized avatar
:octocat:
Do not be afraid of devs - we don't eat people, at least usually we don't.

wolfi3 usmanakram232

:octocat:
Do not be afraid of devs - we don't eat people, at least usually we don't.
View GitHub Profile
@theory
theory / extension-ecosystem-jobs-tools.md
Last active April 22, 2024 19:44
This document sketches an idealized Postgres extension ecosystem

NOTE: Moved to the Postgres Wiki

Extension Ecosystem: Jobs and Tools

This document sketches an idealized Postgres extension ecosystem.

Why?

The past year has seen a surge in interest in Postgres extension distribution. A number of people have noted in particular the challenges in finding and

@tdmalone
tdmalone / aws-services.py
Created December 28, 2023 04:39
Using an undocumented (and thus subject-to-change) API, provides a list of all AWS services colourised as to whether or not they're available in the given region. Alternatively, given two regions, colourised based on whether services are available in one region, both regions, or neither of them.
#!/usr/bin/env python
import json, sys
from urllib.request import urlopen
def green(str): return f'\033[92m{str}\033[0m'
def orange(str): return f'\033[38;5;214m{str}\033[0m'
def red(str): return f'\033[91m{str}\033[0m'
def yellow(str): return f'\033[93m{str}\033[0m'
@ssteo
ssteo / Prompt routing demo
Last active December 22, 2023 08:35
Prompt routing demo
I created this Proof of Concept (PoC) and video demonstrate how prompt routing can be used to make ChatGPT dynamically
select the targeted prompt, achieving better results. The concept involves categorizing the initial prompt using ChatGPT
and then selecting a more specific prompt based on the tag to resend targeted prompt to ChatGPT. This PoC showcases the
efficiency we can gain when using speech recognition and AI tools in development. I will release the code-assist tool on
GitHub once I have more free time to clean up the code. If we have a set of well-tested prompts for different types of
specific tasks, I believe this tooling approach can help us increase our productivity by skipping a few steps in our
repetitious daily work tasks than just code generation. Editing code, issuing commands (with safety checks), and
automated scope-down online search are the next steps to multiply work productivity.
Video Demo: Code generation and editing via streaming speech recognition
@INCHMAN1900
INCHMAN1900 / Hilbert_Curve.pde
Created October 11, 2023 07:39
Create Hilbert Curve in under 40 lines of code in Processing.
void setup() {
size(800, 800);
background(255);
noFill();
translate(width * 0.5, height * 0.5); // center of the curve.
hilbert_curve(6, width);
}
void hilbert_curve(int n, float size) {
@owulveryck
owulveryck / Makefile
Last active March 29, 2024 15:58
Makefile to convert images to a pdf suitable for presentatio on reMarkable 2
# Makefile to convert images (JPG or PNG) to a grayscale 4-bit PDF with a custom message, contrast adjustment, 8 levels of gray, and a background image using ImageMagick
# Output PDF file name
OUTPUT = output.pdf
# File containing the list of image filenames
IMAGE_LIST_FILE = slides.txt
# Temporary directory for images with messages
TEMP_DIR = temp_msg
@veekaybee
veekaybee / normcore-llm.md
Last active May 4, 2024 05:37
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

@boukeversteegh
boukeversteegh / e2e-implementation.md
Created August 11, 2023 13:39
Rethinking Boundaries: Merging End-to-End Testing and Implementation with Macro Abstractions

Rethinking Boundaries: Merging End-to-End Testing and Implementation with Macro Abstractions

In traditional software development, there's a clear boundary separating end-to-end testing and implementation. This conventional mindset, however, faces a challenge with the introduction of a unique software development paradigm proposing the unification of these two aspects.

Underpinning this concept, a Domain-Specific Language (DSL) is used. This language serves to sketch out a detailed sequence of actions and responses - acting as test specifications. Interestingly, at the same time, these sequences also provide a functional model of the system's behavior and thus can serve as an efficient implementation.

Let's dive deeper with an example. Consider you are crafting multiple test cases for a basic addition operation in a calculator application. After designing a few tests, you spot a consistent pattern of steps - you enter two numbers, add them together, and finally, you expect a result.

Here is how it would

@ykk648
ykk648 / gist:cf7bf2b64897c29cfb0c67003bbbbea3
Created July 11, 2023 09:59
GPT-4 Architecture, Infrastructure, Training Dataset, Costs, Vision, MoE
2023/7/11 08:59
GPT-4 Architecture, Infrastructure, Training Dataset, Costs, Vision, MoE
GPT-4 Architecture, Infrastructure,
Training Dataset, Costs, Vision, MoE
Demystifying GPT-4: The engineering tradeoffs that led OpenAI to their
architecture.
DYLAN PATEL AND GERALD WONG
2023 年 7 月 11 日 ∙ PAID
38
8
@yzdbg
yzdbg / auto-dr.md
Last active November 3, 2023 17:11

Automating Daily Reports, because fuck it, really...

Each day at our company, developers are required to document their activities, painstakingly jotting down their daily work and future plans. A monotonous chore that I just really dislike.

So now, there's a scribe for that :

auto-dr-

Code

@e7d
e7d / remove-obsolete-gpg-key-from-dnf.md
Last active April 25, 2024 20:21
Remove obsolete GPG key from DNF (Fedora)