setup-agent-config
FreeRuns bundled scriptsNot checkedToken-efficient AI agent hooks -- env vars, test flag optimization, output truncation, NODE_OPTIONS. Use when optimizing Claude Code for fewer tokens or…
by redpanda-data★ 34 GitHub starsAbout this skill
Setup LLM Optimization
What This Sets Up
- SessionStart:
AI_AGENT=1,CLAUDECODE=1,NODE_OPTIONS=--max-old-space-size=8192 - UserPromptSubmit: inject project state (git branch, dirty files, scripts, violations, config) -> Claude know state, no tool calls
- PreToolUse (Bash): optimize vitest commands -- strip
--verbose, suggest--pool=forks,--bail=1,--teardownTimeout=5000. Also handle jest/bun test (back-compat) - PostToolUse (Bash): truncate verbose output, cut context bloat
Steps
- Copy
scripts/llm-env.sh,scripts/llm-test-flags.sh,scripts/llm-truncate.sh->.claude/hooks/.chmod +x. - Configure in
.claude/settings.json:- SessionStart:
llm-env.sh - PreToolUse (Bash):
llm-test-flags.sh - PostToolUse (Bash):
llm-truncate.sh
- SessionStart:
Verify
-
AI_AGENT/CLAUDECODEset after session start -
vitest --verboserewrite tovitest - Long output truncated
See REFERENCE.md for vitest config optimizations.
Install setup-agent-config in Claude Code & Claude Desktop
Sign up to install this skill
Create a free account to reveal the install command and save the skill to your library.
- Reveal the one-line install command
- Save skills to your synced library
- Get notified when skills update
Allowed tools
Tools this skill is permitted to call.
No restriction — this skill can use any tool.
Bundled files
FAQ
What does the setup-agent-config skill do?
Token-efficient AI agent hooks -- env vars, test flag optimization, output truncation, NODE_OPTIONS. Use when optimizing Claude Code for fewer tokens or reducing context waste.
How do I install the setup-agent-config skill?
Copy the skill folder into ~/.claude/skills (the Claude Code tab above does this in one command), or install it as a plugin.
Does the setup-agent-config skill run scripts?
Yes, this skill bundles executable scripts. Review the source before installing.
Related skills
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
by Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
by Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
by Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
by Anthropic