
smith-ctx-claude
by tianjianjiang
AGENTS.md as dotfiles: Personal coding standards that follow you everywhere, Mr. Anderson.
SKILL.md
name: smith-ctx-claude description: Claude Code context management with /compact and /clear commands, CLAUDE.md persistence, and Tool Search optimization. Use when operating in Claude Code IDE or when context exceeds 60%. Activate for context optimization in Claude sessions.
Claude Code Context Management
- Load if: Using Claude Code, context >60%
- Prerequisites: @smith-ctx/SKILL.md
CRITICAL: Context Commands (Primacy Zone)
Agent prompts for context status, then recommends action to user.
Thresholds: 60% warning, 70% critical, 90% emergency (see @smith-ctx/SKILL.md)
Decision tree:
- Same task, need space →
/compact keep [specifics] - New unrelated task → commit first, then
/clear
/compact - Selective Retention
Syntax: /compact keep [retention criteria]
Always specify what to keep:
- Task goals and requirements
- File paths with line numbers (file:line)
- Architectural decisions
- Incomplete todos/next steps
Recommendation format:
/compact keep task requirements, files (auth.ts:234, tokens.ts:89),
design decisions, remaining todos
- Claiming to execute
/compactdirectly (user must run it) - Vague criteria like "important stuff"
- Compacting away file:line references
- Compacting away incomplete work
/clear - Full Reset
Use when: Switching to unrelated task after committing work
Before /clear:
- Commit current work with detailed message
- Check for uncommitted changes
- Document session state
Preserved: Project files, CLAUDE.md Lost: All conversation history
/clearwithout checking uncommitted work/clearmid-task (use/compactinstead)/clearwhen context <90%
CLAUDE.md Persistence
Location: $WORKSPACE_ROOT/.claude/CLAUDE.md or $HOME/.claude/CLAUDE.md
Put in CLAUDE.md (always active):
- Critical guardrails (NEVER/ALWAYS)
- Reference to @AGENTS.md
- Project-specific preferences
Put in skill files (context-triggered):
- Detailed technical guidelines
- Platform-specific patterns
Tool Search Tool
85% token reduction - tools loaded on-demand, not upfront.
- Rely on Tool Search for documentation
- Use specific tool names for better retrieval
- Don't request full tool documentation dumps
Skills Directory Integration
Enable skill discovery:
ln -sf $HOME/.smith $HOME/.claude/skills
Claude Code discovers skills matching your tasks and asks before loading.
All skills prefixed with "smith-" to avoid conflicts with 50+ built-in commands.
Claude Code Features
Unique capabilities:
- Web search for current information
- Browser automation for testing
- MCP server integration (including Serena)
- 200k token context window
- Tool Search for on-demand tool loading
Plugin Discovery
Available plugin commands:
/code-review- Automated PR review with 4 parallel agents/commit- Auto-commit with message generation/commit-push-pr- Full PR workflow/clean_gone- Branch cleanup
Check installed plugins: /plugins or cat ~/.claude/plugins/installed_plugins.json
Official marketplace: anthropics/claude-plugins-official
- @smith-ctx/SKILL.md - Universal context strategies
@smith-ctx-cursor/SKILL.md- Cursor IDE context@smith-ctx-kiro/SKILL.md- Kiro platform context@smith-prompts/SKILL.md- Prompt caching optimization
ACTION (Recency Zone)
Proactive context management:
- Prompt for context status
- At 60%: Recommend
/compactwith retention criteria - At 70%: Warn of degradation, prepare criteria urgently
- At 90%: Recommend
/clearor aggressive compaction
Agent RECOMMENDS - user executes the command.
Workflow:
- Periodically prompt for context usage percentage
- Prepare retention criteria before hitting limits
- Recommend action with specific criteria
- Commit frequently for session recovery
スコア
総合スコア
リポジトリの品質指標に基づく評価
SKILL.mdファイルが含まれている
ライセンスが設定されている
100文字以上の説明がある
GitHub Stars 100以上
3ヶ月以内に更新がある
10回以上フォークされている
オープンIssueが50未満
プログラミング言語が設定されている
1つ以上のタグが設定されている
レビュー
レビュー機能は近日公開予定です