AgentSkillsCN

Ai Context Window

AI上下文窗口

SKILL.md

Context Window Management

Manage LLM context windows. Token estimation, chunking, optimization.

Quick Start

bash
npx ai-context-window estimate "Your text"

What It Does

  • Estimate tokens in text
  • Split documents into chunks
  • Check if content fits models
  • Truncate oversized content

Usage

bash
# Estimate tokens
npx ai-context-window estimate "text"

# Chunk file
npx ai-context-window chunk document.txt --tokens 1000

# Check fit
npx ai-context-window fit document.txt gpt-4-turbo

# List models
npx ai-context-window models

Part of the LXGIC Dev Toolkit

One of 110+ free developer tools from LXGIC Studios.

License

MIT. Free forever.