Your agent refuses a task, and the refusal has nothing to do with your prompt. A developer asked Claude Code to find a Bandcamp page for an artist from an Instagram reel so he could buy the song. The model declined to work around Bandcamp's search challenge -- but happily offered to download the same track from YouTube, which pays the artist nothing. Same user, same session, opposite outcomes.
That is not a bug you can fix with better prompting. The provider's policy is baked into the model weights and system plumbing, and it overrides your intent. By the end of this piece you will know how to detect where that line sits, how to route around it where it's legitimate, and where you genuinely need a local model.
The refusal lives above your prompt
When you run an agent through a hosted API, three layers of policy apply before your instructions matter:
- The system prompt the provider prepends to every request
- The safety training baked into the weights
- Usage policies enforced by moderation on the request or output
You control only your own instructions. When your task collides with a provider rule, the provider wins. This is a documented behavior pattern: models routinely refuse to solve CAPTCHAs, bypass bot detection, or scrape sites that forbid it, regardless of what your system prompt says.
The Bandcamp case shows the policy is not even a coherent ethics. Working around a search challenge was declined; downloading audio from a platform whose terms the artist may prefer you not use was fine. The model reflects the provider's risk surface, not a principled position. CAPTCHA-adjacent bypasses are in the news, so they get blocked. Terms-of-service friction elsewhere gets a pass.
Decide whether the refusal is protecting you
Before you engineer around a refusal, ask one question: who bears the risk if the agent complies?
If the answer is "only me and a counterparty who consented," the refusal is a provider policy choice, not a legal wall. Finding a public Bandcamp page is fine. Buying the album is fine. Hitting a search endpoint from a script may violate Bandcamp's terms, and that is your judgment call to make, not Claude's.
If the answer is "other people who did not consent," stop. Refusals around personal data, credential theft, and harassment exist because the underlying act is harmful, not because a vendor is squeamish. Treat those as hard boundaries.
Most friction is the first kind. Build for it.
Route work to tools the model can't refuse
An agent is not one model. It is an orchestrator plus tools, and each tool has its own policy surface. If the model refuses to find the Bandcamp URL, a plain HTTP client in your own code can still fetch it. Move the contested step out of the model's hands.
Here is a minimal pattern using the Anthropic Python SDK, where the sensitive lookup runs as a deterministic tool:
import anthropic
import requests
BANDCAMP_API = "https://bandcamp.com/api/bcsearch_public_api/1/autocomplete_elastic"
def find_bandcamp(artist: str) -> dict:
"""Deterministic lookup -- the model never sees the raw request."""
r = requests.get(BANDCAMP_API, params={
"search_text": artist,
"search_filter": "b",
}, timeout=10)
results = r.json().get("auto", {}).get("results", [])
return {"url": results[0]["url"] if results else None}
client = anthropic.Anthropic()
resp = client.messages.create(
model="claude-sonnet-4-5",
max_tokens=1024,
tools=[{
"name": "find_bandcamp",
"description": "Look up an artist's Bandcamp page.",
"input_schema": {
"type": "object",
"properties": {"artist": {"type": "string"}},
"required": ["artist"],
},
}],
messages=[{"role": "user",
"content": "Find the Bandcamp page for the artist Slowdive."}],
)
The model never evaluates whether the lookup is acceptable, because the lookup is not a model decision. The tool runs, the result comes back, and the model just formats it. This is the standard escape hatch for policy friction: deterministic code for contested steps, the model for judgment steps like identifying the artist from a reel transcript.
The tradeoff is that your tool can still break. Bandcamp's public search endpoint is undocumented and now sits behind a challenge for some clients. When it breaks, you fix Python, not a model. That is a better failure mode.
When routing isn't enough: run a local model
If the refusal happens at the orchestration layer -- the model won't even plan the task -- you need a different model. Local weights remove the provider's system prompt and the vendor's moderation entirely. Two practical options:
-
Ollama for a quick start:
ollama pull llama3.1and point your agent athttp://localhost:11434/v1, which speaks the OpenAI API format. - llama.cpp or vLLM when you need throughput or control over quantization.
from openai import OpenAI
local = OpenAI(base_url="http://localhost:11434/v1", api_key="ollama")
resp = local.chat.completions.create(
model="llama3.1",
messages=[{"role": "user",
"content": "List steps to locate an artist's Bandcamp page."}],
)
print(resp.choices[0].message.content)
The same client pattern works because Ollama exposes an OpenAI-compatible endpoint, so swapping the base URL is usually your whole migration.
Local is not free. You trade the provider's policy for the model trainer's policy -- a model trained in China will have its own refusals around politically sensitive topics. And smaller local models are noticeably worse at multi-step reasoning, so your agent will misfire more. A honest architecture uses both: hosted models for planning and language work, local or deterministic components for anything the provider might veto.
Check what "open" actually means
"Open model" is not the same as open source. What matters for your loyalty problem:
- Are the weights downloadable, under what license, and for commercial use?
- Is the training data documented, or is it a black box?
- Can you run it offline, with no phone-home?
Llama and Qwen weights are downloadable under community licenses with use restrictions. Mistral and models like OLMo from AI2 go further on transparency. Read the license; a "community license" can still forbid the exact use you want. The FOSS framing breaks down because a model is closer to a compiled artifact than a program -- you usually cannot retrain the refusal out of it, only pick different weights.
Key takeaways
- Provider policy is enforced above your prompt; prompting harder will not remove a refusal that comes from safety training or a vendor system prompt.
- Ask who bears the risk if the agent complies. Refusals protecting others are boundaries; refusals protecting the vendor's PR surface are friction you can engineer around.
- Move contested steps into deterministic tools so the model never adjudicates them. Fix Python when endpoints change, not prompts.
- Run a local model through an OpenAI-compatible endpoint when the refusal happens at the planning layer, and read the weights license before assuming "open" means unrestricted.
- Audit your agent stack now: list every model in the pipeline and, for each, who sets its refusals. That list is your real dependency graph.
Source
Original piece: LLM agents work for their parent companies, not for you. I added the architectural response the source only gestures at: tool-boundary routing with working SDK code, a decision framework for which refusals to bypass, and what "open weights" actually buys you.
Support this work
These write-ups are researched and published with no paywall, sponsor, or tracking. If one saved you an afternoon, a small tip keeps them coming.
USDT, USDC or USDD ยท TRC-20 (Tron)
TFTNsfyomKrnUutRjBTGVULp19ByW29KbY
Top comments (0)