OpenCode’s Skill System

Skills are essentially reusable prompt templates that encode project-specific knowledge. Instead of explaining "use Bun APIs, not Node fs" every time, you write it once in a skill. The LLM automatically loads it when relevant. OpenCode intentionally supports Claude Code's .claude/skills/ directory structure, so skills written for Claude Code work in OpenCode too. This is … Continue reading OpenCode’s Skill System

Three Kinds of Prompts Used in OpenCode

There are three main locations storing prompts: Each prompt type serves a different purpose: agents configure specialized AI behaviors, session prompts set global LLM instructions, tool prompts define how tools should be used, and command templates provide command structure. 1. Agent Prompts (/agent/) generate.txt - Meta-prompt for generating new agents /agent/prompt/ (5 files): title.txt - Generate message titles summary.txt - Create PR-style summaries compaction.txt - Compress conversation history explore.txt - Fast codebase exploration 2. Session Prompts (/session/prompt/) - 12 files Provider-specific: anthropic.txt, beast.txt, gemini.txt, qwen.txt, … Continue reading Three Kinds of Prompts Used in OpenCode

Navigate a Large Codebase – OpenCode

Large codebases are like onions - layers upon layers. You don't need to understand everything. Focus on: Entry points - where does execution start? Core domain - what's the main business logic? Interfaces - how do users/systems interact? Everything else is implementation detail you can explore when needed. 1: Start with Entry Points: Always find … Continue reading Navigate a Large Codebase – OpenCode

Open-Source AI Coding Agent – OpenCode

OpenCode is a an open-source AI coding agent - essentially a terminal-based AI assistant for software development. It's comparable to Claude Code, but open-sourced and provide-agnostic. It's been attracting lots of community adoption now. Core Architecture Pattern: OpenCode uses a hierarchical agent model with two tiers: Primary Agents - User-facing, switchable via Tab key, there … Continue reading Open-Source AI Coding Agent – OpenCode

How Did Pauli Derive the Pauli Matrices

In 1920s, Pauli faced the problem to solve properties of electrons: Magnetic behavior like a tiny bar magnet Two-valued “intrinsic” angular momentum (spin up / spin down) Spectral line splittings (Zeeman effect) that orbital angular momentum alone could not explain So Pauli needed a mathematical object that: Acts like angular momentum But has only two … Continue reading How Did Pauli Derive the Pauli Matrices

Algebra Defines Symmetry, Representation Tells the Physical Thing Carries that Symmetry

The algebra defines the symmetry. The representation tells you what kind of physical thing carries that symmetry. The Lie algebra su(2)\mathfrak{su}(2)su(2) is like a universal rotation engine. A representation answers: “Rotation of what?” Spin-1/2 rep → rotates electron spin states Spin-1 rep → rotates vectors in space Higher reps → describe higher spin particles