- Python 3
- Pip 3
$ brew install python3| from scipy.stats.distributions import binom | |
| data = [ | |
| {'name': 'ISTJ', 'count': 12, 'expected': 0.1160}, | |
| {'name': 'ISFJ', 'count': 4, 'expected': 0.1380}, | |
| {'name': 'INFJ', 'count': 14, 'expected': 0.0150}, | |
| {'name': 'INTJ', 'count': 206, 'expected': 0.0210}, | |
| {'name': 'ISTP', 'count': 16, 'expected': 0.0540}, | |
| {'name': 'ISFP', 'count': 1, 'expected': 0.0880}, | |
| {'name': 'INFP', 'count': 56, 'expected': 0.0430}, |
| #!/usr/bin/python | |
| """Convert CSV table to MindMap format | |
| Usage: python csv_to_mm.py sometable.csv > mymap.mm | |
| CSV format is rows representing tree leaves, e.g.: | |
| A1, | |
| A1,B1 | |
| A1,B1,C1 | |
| A1,B1,C2 |
| # checkDuplicates.py | |
| # Python 2.7.6 | |
| """ | |
| Given a folder, walk through all files within the folder and subfolders | |
| and get list of all files that are duplicates | |
| The md5 checcksum for each file will determine the duplicates | |
| """ | |
| import os |
Largely based on the Tensorflow 1.6 gist, and Tensorflow 1.7 gist for xcode and Tensorflow 1.7 gist for eGPU, this should hopefully simplify things a bit.
| #!/usr/bin/env python | |
| # -*- coding: utf-8 -*- | |
| """ | |
| Outputs some information on CUDA-enabled devices on your computer, | |
| including current memory usage. | |
| It's a port of https://gist.github.com/f0k/0d6431e3faa60bffc788f8b4daa029b1 | |
| from C to Python with ctypes, so it can run without compiling anything. Note | |
| that this is a direct translation with no attempt to make the code Pythonic. |
Press minus + shift + s and return to chop/fold long lines!
A pattern for building personal knowledge bases using LLMs.
This is an idea file, it is designed to be copy pasted to your own LLM Agent (e.g. OpenAI Codex, Claude Code, OpenCode / Pi, or etc.). Its goal is to communicate the high level idea, but your agent will build out the specifics in collaboration with you.
Most people's experience with LLMs and documents looks like RAG: you upload a collection of files, the LLM retrieves relevant chunks at query time, and generates an answer. This works, but the LLM is rediscovering knowledge from scratch on every question. There's no accumulation. Ask a subtle question that requires synthesizing five documents, and the LLM has to find and piece together the relevant fragments every time. Nothing is built up. NotebookLM, ChatGPT file uploads, and most RAG systems work this way.