Standard escape codes are prefixed with Escape:
- Ctrl-Key:
^[ - Octal:
\033 - Unicode:
\u001b - Hexadecimal:
\x1B - Decimal:
27
The package that linked you here is now pure ESM. It cannot be require()'d from CommonJS.
This means you have the following choices:
import foo from 'foo' instead of const foo = require('foo') to import the package. You also need to put "type": "module" in your package.json and more. Follow the below guide.await import(…) from CommonJS instead of require(…).| import * as Constants from './constants'; | |
| const randomInArray = <T>(arr: readonly T[]): T => | |
| arr[Math.floor(Math.random() * arr.length)]; | |
| export interface Card { | |
| suit: typeof Constants.SUITS[number]; | |
| face: typeof Constants.FACES[number]; | |
| baseValue: number; | |
| }; |
| from __future__ import annotations | |
| import string | |
| import code | |
| import sys | |
| import io | |
| from typing import Callable | |
| from textual.app import App | |
| from textual.widgets import Header, ScrollView |
| Language | Atom/Pulsar | VSCode | Brackets | Sublime | Lapce | Geany | Xed | Kate | Helix |
|---|---|---|---|---|---|---|---|---|---|
| Python | Y | Y | Y | Y | Y | Y | Y | Y | Y |
| Java | Y | Y | Y | Y | Y | Y | Y | Y | Y |
| JavaScript | Y | Y | Y | Y | Y | Y | Y | Y | Y |
| C# | Y | Y | Y | Y | Y | Y | Y | Y | Y |
| C | Y | Y | Y | Y | Y | Y | Y | Y | Y |
| """ | |
| The most atomic way to train and run inference for a GPT in pure, dependency-free Python. | |
| This file is the complete algorithm. | |
| Everything else is just efficiency. | |
| @karpathy | |
| """ | |
| import os # os.path.exists | |
| import math # math.log, math.exp |
| #!/usr/bin/env bash | |
| set -euo pipefail | |
| # patch-claude-code.sh — Rebalance Claude Code prompts to fix corner-cutting behavior | |
| # | |
| # What this does: | |
| # Patches the npm-installed @anthropic-ai/claude-code cli.js to rebalance | |
| # system prompt instructions that cause the model to cut corners, simplify | |
| # excessively, and defer complicated work. | |
| # |
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.