/vibe:anthropic-sdk-expertfrom vibe
Expert guidance on the Anthropic Claude API: tool use, prompt caching, computer use, agent loops, streaming, and extended thinking. Use when building AI applications with the Anthropic SDK.
Ships in vibe. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
You are an expert in the Anthropic Claude API. You squeeze every drop of value out of prompt caching, design clean tool use loops, and know when to reach for the Computer Use beta. You think in terms of cache breakpoints, message turns, and stop reasons.
anthropic.Anthropic() and AsyncAnthropic() clients (Python); @anthropic-ai/sdk (TS)messages.create with system, messages, tools, tool_choicecache_control: {"type": "ephemeral"} (5-minute and 1-hour TTL)stop_reason == "tool_use", run tools, append tool_result, repeatbash_20241022, text_editor_20241022, computer_20241022 beta)messages.stream and event handlersthinking={"type": "enabled", "budget_tokens": ...}while stop_reason == "tool_use" — never assume one round.from anthropic import Anthropic
client = Anthropic()
resp = client.messages.create(
model="claude-sonnet-4-5",
max_tokens=1024,
system="You are a precise assistant.",
messages=[{"role": "user", "content": "Summarize photosynthesis."}],
)
print(resp.content[0].text)
resp = client.messages.create(
model="claude-sonnet-4-5",
max_tokens=1024,
system=[
{"type": "text", "text": "You are a legal assistant."},
{
"type": "text",
"text": LONG_STYLE_GUIDE,
"cache_control": {"type": "ephemeral"},
},
],
tools=[
{
"name": "search_cases",
"description": "...",
"input_schema": {...},
"cache_control": {"type": "ephemeral"},
}
],
messages=[{"role": "user", "content": "Find precedent on..."}],
)
print(resp.usage.cache_read_input_tokens, resp.usage.cache_creation_input_tokens)
tools = [{
"name": "get_weather",
"description": "Get current weather for a city.",
"input_schema": {
"type": "object",
"properties": {"city": {"type": "string"}},
"required": ["city"],
},
}]
messages = [{"role": "user", "content": "Weather in Tokyo?"}]
while True:
resp = client.messages.create(
model="claude-sonnet-4-5",
max_tokens=1024,
tools=tools,
messages=messages,
)
messages.append({"role": "assistant", "content": resp.content})
if resp.stop_reason != "tool_use":
break
tool_results = []
for block in resp.content:
if block.type == "tool_use":
result = run_local_tool(block.name, block.input) # your code
tool_results.append({
"type": "tool_result",
"tool_use_id": block.id,
"content": str(result),
})
messages.append({"role": "user", "content": tool_results})
print(resp.content[-1].text)
with client.messages.stream(
model="claude-sonnet-4-5",
max_tokens=1024,
messages=[{"role": "user", "content": "Tell me a story."}],
) as stream:
for text in stream.text_stream:
print(text, end="", flush=True)
resp = client.messages.create(
model="claude-sonnet-4-5",
max_tokens=8000,
thinking={"type": "enabled", "budget_tokens": 4000},
messages=[{"role": "user", "content": "Plan a 5-step migration..."}],
)
stop_reason — end_turn, tool_use, max_tokens, stop_sequence all mean different things.max_tokens is required.Pick the Anthropic SDK when you're calling Claude directly and want full control: prompt caching tuning, tool loop ergonomics, computer use beta, citations, batch API. Reach for OpenAI Agents SDK / LangGraph when you need a higher-level agent framework on top.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
anthropic-sdk, claude-api, prompt-caching, tool-use, computer-use, agent-loops
npx claudepluginhub anubhavg-icpl/vibe --plugin vibe5,304 skills in this plugin
/3d-pipelineChoose a 3D generation or reconstruction pipeline given input type, output format, and use case. Use when you need help with 3d pipeline./8-bit-orbit-video-templateHyperframes Video TemplateShip a premium template-mode Hyperframes composition with a ready default showcase and deterministic timeline behavior./a2a-agent-specProduce the Agent Card and skills schema for an agent that should be callable over A2A. Use when you need help with a2a agent spec.Other plugins' skills for the same job