Skip to content

Instantly share code, notes, and snippets.

@badlogic
badlogic / session.html
Created January 13, 2026 13:50
Token Clicker - We don't need your bank account, we need tokens
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Token Clicker - We don't need your bank account</title>
<style>
* {
margin: 0;
padding: 0;
@badlogic
badlogic / token-clicker.html
Last active January 13, 2026 13:49
Token Clicker - We don't need your bank account, we need tokens
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Token Clicker - We don't need your bank account</title>
<style>
* {
margin: 0;
padding: 0;
@badlogic
badlogic / session.html
Created January 1, 2026 11:28
pi session export - export-html rewrite conversation
This file has been truncated, but you can view the full file.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Session 7609c215-fea3-4e26-af1e-44a78b432602 - pi</title>
<style>
:root {
--accent: #8abeb7;
--border: #5f87ff;
@badlogic
badlogic / this-session.html
Created January 1, 2026 11:26
pi session export - export-html rewrite conversation
This file has been truncated, but you can view the full file.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Session 7609c215-fea3-4e26-af1e-44a78b432602 - pi</title>
<style>
:root {
--accent: #8abeb7;
--border: #5f87ff;

Mom Artifacts Server Setup Guide

Share HTML files, visualizations, and interactive demos publicly via Cloudflare Tunnel with live reload support.

What is it?

The artifacts server lets Mom create HTML/JS/CSS files that you can instantly view in a browser, with WebSocket-based live reload for development. Perfect for dashboards, visualizations, prototypes, and interactive demos.

Installation

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Three.js Spinning Cube</title>
<style>
body {
margin: 0;
overflow: hidden;
@badlogic
badlogic / mistral-sdk.test.ts
Last active December 10, 2025 19:11
Mistral API limitation: user message after tool message not allowed
import { Mistral } from "@mistralai/mistralai";
import { describe, expect, it } from "vitest";
describe.skipIf(!process.env.MISTRAL_API_KEY)("Mistral SDK Direct", () => {
const client = new Mistral({ apiKey: process.env.MISTRAL_API_KEY });
it("tool call + result + user follow-up", async () => {
const response = await client.chat.complete({
model: "devstral-medium-latest",
messages: [
@badlogic
badlogic / compaction.md
Created December 2, 2025 14:11
Context Compaction Research: Claude Code, Codex CLI, OpenCode, Amp

Context Compaction

Research on how other coding assistants implement context compaction to manage long conversations.

Overview

Context compaction (also called "handoff" or "summarization") is a technique to manage the context window in long coding sessions. When conversations grow too long, performance degrades and costs increase. Compaction summarizes the conversation history into a condensed form, allowing work to continue without hitting context limits.

Claude Code

{
"query": "Waffenfunde (filtered for right-wing extremism in Austria)",
"totalArticles": 29,
"articles": [
{
"title": "Keine Statistiken über rechtsextreme Waffenfunde: Grüne werfen Innenminister vor, \"Unwahrheit\" gesagt zu haben",
"link": "https://www.derstandard.at/story/3000000271029/keine-statistiken-ueber-rechtsextreme-waffenfunde-gruene-werfen-innenminister-vor-unwahrheit-gesagt-zu-haben",
"date": "2025-05-22T17:24:00.000",
"kicker": "Parlament",
"teaser": "Eine Anfrage der Grünen zu einem Sprengstoffexperten mit Neonazi-Kontakten beantwortete das Innenministerium knapp. Am Donnerstag debattierte deshalb der Nationalrat",
@badlogic
badlogic / 01-update-docs.md
Last active January 8, 2026 03:43
Yakety Documentation (Ordered) - LLM-optimized docs with concrete file references

Update Documentation

You will generate LLM-optimized documentation with concrete file references and flexible formatting.

Your Task

Create documentation that allows humans and LLMs to:

  • Understand project purpose - what the project does and why
  • Get architecture overview - how the system is organized
  • Build on all platforms - build instructions with file references