Back to insightsThe knowledge journal

Self-Hosted AI Agents: What You Actually Control When You Bring Them In-House

Bringing an agent service in-house changes where execution, credentials, and history live, and who runs them. An ownership map for self-hosted AI agents and external inference.

18 min read

Bringing an agent service in-house changes where execution, credentials, and history live. It also changes who runs them. A practical ownership map for self-hosted AI agents, external inference, and the operational responsibilities behind “private” deployment.

TL;DR

  • Self-hosting an agent service and self-hosting a model are separate architecture decisions.

  • Anthropic’s new option moves the agent service and sandboxes into customer-operated infrastructure; model requests still go to a configured provider.

  • Map ownership separately for execution, identity, credentials, stored data, inference, networking, and operations.

  • Local session storage does not mean prompts and tool results remain inside the network during inference.

  • Greater control is useful when your team can configure, test, monitor, patch, and recover the resulting service.

  • Evaluate feature differences, trust isolation, retention, provider routing, and recovery before treating a hosted workflow as portable.

What Anthropic actually announced

“We will run the agents ourselves” sounds like a complete architecture decision. It leaves several important questions unanswered.

Will your team run the tool environment, the orchestration service, or both? Where will the model process the conversation? Who can read the session history? Who responds when a worker stops halfway through an external action?

Those questions became more immediate on 12 November 2026, when Anthropic introduced self-hosted Claude Managed Agents in private beta. Its announcement says customers can operate the agent harness, sandboxes, credentials, and session history in their own cloud or on-premises environment, while choosing where model requests go. Access is requested through the Anthropic account team. Source

The change expands the deployment choice beyond self-hosted tool sandboxes. It gives enterprise teams another way to control the service coordinating an agent’s work.

But the term “self-hosted” needs a noun after it. Self-hosted orchestration, execution, storage, and inference describe different boundaries.

Anthropic’s overview distinguishes three arrangements:

Deployment optionTool sandboxesAgent serviceModel inference
Default hosted arrangementAnthropic-operatedAnthropic-operatedAnthropic
Self-hosted sandboxesCustomer-operatedAnthropic-operatedAnthropic
Self-hosted Managed AgentsCustomer-operatedCustomer-operatedAnthropic or another configured provider

This table describes the product’s documented deployment options, not every possible agent architecture. Source

The business question is which boundary your organization needs to move and whether the additional responsibility is justified.

The ownership map enterprises need

Hosting a service provides control over its deployment and configuration. It does not remove dependencies on the software supplier, inference provider, identity platform, or connected business systems.

The following is a practical allocation of responsibilities for a customer-operated agent service. Validate the details against the product version, deployment, and contracts you actually use.

LayerWhat your organization can controlWhat still needs explicit agreement or validation
Agent executionWorker placement, sandbox configuration, network reachRuntime behavior and the strength of isolation
OrchestrationService deployment, configuration, rollout timingSupported capabilities, upgrades, and software dependencies
CredentialsStorage location, issuing identities, scopes, revocationEvery path through which credentials are injected or used
Session dataDatabase location, access, backups, deletion processesCopies in logs, memory stores, exports, and provider processing
Model inferenceApproved provider route and account configurationProcessing location, retention terms, availability, model access
Tool accessApproved integrations and downstream permissionsAuthorization enforcement in each connected system
OperationsMonitoring, incident response, capacity, recoverySupplier support boundaries and upstream failure behavior

Notice that control appears in the middle column. Demonstrating that the control works appears in the right column.

A database under your account can still be misconfigured. An internally hosted gateway can still forward requests elsewhere. A local agent can still act with an identity that has excessive access.

A useful architecture review replaces the broad question “Is this private?” with specific questions about location, access, purpose, authority, and accountability.

A reference deployment

This is an illustrative ownership map, not a required installation topology.

Flow diagram: Customer-operated environment → Internal application → Agent service → Workers in isolated session sandboxes → Session database → Credential services → Approved tool services → Permitted repositories and files → Approved inference route or gateway → Model inference provider Flow diagram: Customer-operated environment → Internal application → Agent service → Workers in isolated session sandboxes → Session database → Credential services → Approved tool services → Permitted repositories and files → Approved inference route or gateway → Model inference provider

The model boundary remains visible even when the database and tools are internal. A gateway is optional; its presence does not determine where inference ultimately happens.

Execution control comes with an isolation obligation

The immediate benefit of local execution is proximity. Workers can operate near private repositories, internal data, and existing services without exposing those services directly to a public agent runtime.

The associated responsibility is deciding exactly what the worker can reach and change.

Anthropic documents a separation between its service, which runs the agent loop, and workers, which execute shell and file tools. It explicitly warns that a worker’s shell inherits the worker process’s permissions and network access; isolation comes from the surrounding container, virtual machine, or other execution environment. Source

That warning should shape the deployment review.

For each workload, identify the files it needs, the services it may contact, the software it may install, and the actions it may perform. Give disposable workspaces only the mounts, identities, and network routes those tasks require.

A code-review task should not inherit production deployment authority simply because both run on the same platform. A document-analysis task should not receive broad shell access to unrelated repositories as a side effect of a shared worker image.

Test failure containment. If an agent executes an unexpected command, what prevents it from reading another session’s workspace, modifying its own acceptance checks, or reaching an unrelated internal service?

The value of moving execution in-house depends on the answer. Physical or account-level proximity to your systems can increase usefulness and increase potential consequences at the same time.

Credentials need more than a local vault

A secrets manager answers where a credential is stored. An authorization design answers who may use it, for which action, on which resource, and under what conditions.

Start by separating administrative access, model access, worker access, and business-tool access.

Anthropic’s overview identifies three infrastructure credentials: a server application programming interface (API) key for calls to the agent service, an inference credential held by the server, and an environment key used by polling workers. Applications and workers do not need the inference credential. Source

Keep application-specific tool credentials distinct from those infrastructure credentials. A token for a document service should not double as a platform administration token.

The agent-identity documentation describes integrations with customer secret managers, short-lived signed agent tokens for supported receivers, and an egress gateway that can replace placeholders with credentials on supported outbound requests. Configuring an external secret store affects new vault secrets; existing database-held secrets need separate attention. Source

These capabilities are useful building blocks. They still need an access policy at the receiving service.

For example, identifying an agent as “research assistant” does not establish that it may read every research folder. The downstream service must validate the relevant user, project, resource, and operation.

Test credential rotation while sessions are running. Confirm that revoked access actually stops working, that legitimate replacement access succeeds, and that long-running workers do not silently continue using an old credential.

Finally, inspect diagnostic output. Keeping a credential in an internal vault provides little protection if a tool echoes it into a conversation, log, or exported trace.

Local history and external inference coexist

This is the distinction most likely to be lost in an executive summary.

Anthropic’s data-and-access documentation states that each model call includes the conversation so far, including prompts, tool inputs, and tool results. That material goes to the configured inference provider. Retaining the session database internally therefore does not imply that its content never leaves during processing. Source

A private document can remain in your repository while excerpts from it travel to a model. A computation can run locally while its results become part of the next inference request. A credential can stay outside the sandbox while sensitive business information is intentionally sent to a permitted destination.

Map these flows separately.

Provider choice is a routing decision

The documented routes include the Claude API, Amazon Bedrock, Claude Models on Google Cloud under Google management, Microsoft Foundry, and a customer-run model gateway. Provider-specific configuration and model availability matter. This is not an announcement that Claude model weights are delivered for local inference. Source

A gateway adds a policy and integration point. It does not, by itself, make the destination internal or make every model interchangeable. Validate the final provider, supported request format, enabled model, and actual processing route.

If processing geography matters, inspect the chosen provider’s region and routing configuration rather than inferring geography from the location of your agent server. Anthropic’s provider guide, for example, documents a default cross-region profile convention for its Bedrock configuration. Source

Retention is more than the session table

The documentation says sessions remain until deleted, and that deletion does not remove copies from backups, exported logs and traces, memory stores, or a Kubernetes workspace volume. Model requests remain subject to the chosen inference provider’s agreement. Source

Build a retention policy across all those locations. Decide which artifacts are business records, which are temporary execution data, and which should never be collected.

For zero data retention arrangements, check the eligible request path and applicable agreement. Local storage and provider retention are separate parts of the same review.

Tenant isolation is an architecture decision

A deployment can be internal and still contain users who should not share access.

A service-line workspace, an external-client workload, and an agent processing untrusted code can have different trust requirements even when all three belong to the same company.

Anthropic’s current documentation makes a significant boundary explicit: each self-hosted deployment serves one tenant at one trust level. Environments within a deployment do not separate those trust levels, and the server API key spans its environments. It calls for separate deployments across tenants or trust levels. Source

Treat that as an input to architecture, capacity, and cost planning.

For an enterprise platform, define trust boundaries before choosing how many deployments to create. Consider who can submit work, which files and credentials workers can reach, and what happens if submitted content or executable code is hostile.

Where isolation is required, preserve it through supporting services as well: identity configuration, databases, secret stores, tool authorization, and observability access. An isolated server connected to an overly broad shared credential can reintroduce the access path the separation was intended to remove.

Role labels are useful only within their documented limits. Test cross-boundary access with real identities and representative workloads rather than assuming the platform’s organizational structure matches yours.

The operating model you inherit

Self-hosting creates an internal service with a dependency chain: application, agent server, database, identity system, workers, tool services, network path, and inference provider.

A healthy server process does not establish that the agent can complete useful work across that chain.

Monitor the work as well as the infrastructure

Track worker availability, queueing time, inference failures, tool failures, completed outcomes, and spend. Preserve enough evidence to distinguish a missing worker from a denied tool call or an unavailable model.

Session history and operational telemetry serve different purposes. A business record of tool calls does not replace alerts for a database approaching capacity or a rising error rate. Your monitoring also needs its own access and retention policy.

Choose service objectives that reflect the workflow. For a research task, useful measures may include accepted completion time and evidence quality. For a maintenance agent, they may include verified resolution and the rate of unnecessary escalation.

Own the upgrade path

The software supplier ships releases. Your team decides when and how to adopt them, including the compatibility work required by your environment.

Anthropic’s upgrade guide distinguishes rollback cases that can reuse the database from those requiring a restored backup. It also warns that restoring a backup changes environment-key state: keys revoked after the backup can become valid again, while keys created afterward can disappear. Source

That is a useful example of why recovery is an application-and-identity problem as well as a database problem.

Test upgrades with representative sessions, tool integrations, provider routing, and secrets configuration. After a restore, reconcile security-sensitive state with the intended current policy. Preserve the information needed to identify changes that occurred after the backup.

A backup is valuable when the organization can restore a usable, appropriately restricted service from it.

Name the operational owner

Assign responsibility for capacity, patching, certificates, backups, incident response, provider failures, and user support. Decide who can pause new work and what happens to running sessions during maintenance.

For external actions, define recovery behavior before a failure occurs. If a tool request times out after creating a record, the system should reconcile the result before repeating the action. Bringing the runtime in-house does not make distributed operations atomic.

Hosted and self-hosted are not feature-identical

Compatible core APIs do not establish complete workflow portability.

As reviewed on 15 November, Anthropic’s differences page documents several relevant exceptions:

CapabilityCurrent documented self-hosted difference
Scheduled deploymentsUse your own scheduler to start sessions; the hosted routes are unavailable.
WebhooksThe server sends none; consumers need event streams or event listing.
Hosted file resourcesFile session resources and the Files API are unavailable; data handling needs adaptation.
OAuth vault refreshThe hosted mcp_oauth credential type is unavailable; token renewal requires another approach.
Multi-agent orchestrationDelegation uses predefined agents; dynamic workflows and the advisor are unavailable.

The page also says hosted agents and session history are not copied automatically. Recreate the required configuration and resources on your server. These are current product differences, not permanent limitations of self-hosted agents as a category. Source

Before migration, inventory the complete workflow. Include background triggers, uploaded files, memory, tool authentication, observability consumers, and anything that depends on a hosted console.

Then test the user journey through the new deployment. A session starting successfully does not prove that scheduled work begins, credentials refresh, artifacts arrive, or downstream systems receive completion events.

Preserve a feature-gap register with an owner and an explicit resolution for each item. A workaround that adds a scheduler or credential-renewal service also adds something your team must operate.

When self-hosting earns its cost

The strongest case begins with a concrete control requirement.

You may need session history in a customer-operated database, tools near internal systems, a specific inference route, or integration with an established identity and secrets platform. Those requirements can justify operating more of the stack.

The weakest case begins with an assumption that “in-house” is automatically safer or cheaper.

Compare the minimum boundary that meets the requirement

RequirementArchitecture to investigate first
Tools need local access; managed session storage is acceptableSelf-hosted sandboxes with a hosted service
The service and history must be customer-operatedSelf-hosted agent service, with a validated inference route
Prompts cannot leave a defined processing boundaryA separately validated inference architecture that satisfies that boundary
The team mainly needs rapid delivery with standard controlsA hosted option that demonstrably meets those requirements

This is a decision lens rather than a universal deployment recommendation. Evaluate the product, information sensitivity, and operating capability behind each choice.

Include the full cost of accepted work

Your estimate should include software and support terms, compute for the service and workers, database capacity, storage, network traffic, inference usage, monitoring, operational engineering, and incident-response effort.

Also account for isolation requirements. Separate deployments, duplicated supporting services, and smaller utilization pools can change the economics. So can an internal workaround for a missing hosted capability.

A useful comparison is total operating cost per accepted task, measured at an agreed quality, latency, and availability level. Divide the complete cost by independently accepted outcomes, including the cost of failed attempts and human remediation.

Self-hosting may improve control without reducing cost. It may improve integration while increasing maintenance. State which benefit justifies the choice and how the team will measure it.

A practical enterprise example

Consider an internal research agent that reads approved project documents, performs calculations, produces a cited comparison, and saves the result to a controlled workspace.

The organization wants project records stored internally and model requests routed through its approved cloud account.

A self-hosted service can be a candidate architecture, but the requirement should be decomposed before choosing components.

ConcernDesign decision to makeEvidence to collect
Document accessEnforce user and project authorization at retrievalAllowed and denied retrieval tests
ComputationRun calculations in a constrained workspaceReproducible inputs, outputs, and execution records
Model contextSend only material permitted for the chosen inference routeRepresentative captured request payloads with safe test data
CredentialsSeparate platform, provider, and document-service accessScoped policies and successful revocation tests
Session historyDefine internal access and retentionDatabase access checks and lifecycle tests
Final artifactSave to the intended workspace with confirmationPersistent artifact identity and destination checks

This is a reference scenario, not a claim that those controls appear automatically after installation.

The important distinction is between the original document and the information derived from it. Keeping the source file in a private repository does not settle whether a retrieved excerpt may be sent for inference.

Similarly, retaining the session internally does not establish that only the project team can read it. Application authorization, administrative privileges, observability access, and backups all deserve consideration.

If projects have different trust requirements, apply the product’s isolation model before consolidating them. A broad platform ambition should not outrun the actual boundaries the chosen release supports.

The useful result is a workflow whose controls can be demonstrated end to end, rather than a collection of internally hosted components.

What to validate before production

Use the pilot to answer a small number of consequential questions with observable results.

1. Confirm the information boundary. Run representative tasks with safe test data. Inspect server and worker traffic separately. Record the prompts, tool results, provider route, and auxiliary services involved. Compare observation with the intended architecture.

2. Prove access restrictions. Test unauthorized users, disallowed tool destinations, excessive resource access, and credentials presented to the wrong service. Confirm that enforcement remains effective when the agent proposes an invalid action.

3. Exercise isolation. Try workloads from different trust levels against the planned separation. Check workspaces, identities, data stores, and monitoring access. Use dedicated test environments for these exercises.

4. Test interruption and recovery. Stop a worker, make an upstream service unavailable, interrupt an external write, and restore the service from a tested backup. Check for lost work, duplicate actions, and unintended credential validity.

5. Validate lifecycle controls. Create, archive, delete, export, and restore representative session data. Track what persists in databases, workspaces, logs, memory, and backups. Verify that observed behavior matches the stated retention policy.

6. Complete the operating handoff. Name the on-call owner, escalation path, maintenance process, service objectives, and provider-support route. Confirm that the team can pause risky work without relying on a developer who happens to remember the setup.

The release decision should connect each requirement to evidence, an owner, and an accepted residual risk.

The wider market implication

My expectation is that enterprise agent platforms will increasingly compete on where customers can place control, how clearly responsibilities are documented, and how well the product fits existing operations.

Model capability remains essential. But a provider offering the right model through the wrong data path may be unusable for a particular workload. A flexible deployment option with weak operational ownership can be equally unsuitable.

For platform teams, the opportunity is to offer a supported internal agent service with clear boundaries. For vendors, it is to make those boundaries inspectable and migration costs understandable. For buyers, it is to purchase the controls they need without taking on responsibilities they cannot reliably operate.

Frequently asked questions

What are self-hosted AI agents?

They are agent systems in which an organization operates specified components on infrastructure it controls. Always identify which components are included: tool execution, orchestration, storage, and model inference can have different operators.

Does self-hosted Claude Managed Agents mean Claude runs on our servers?

The announced option hosts the agent service and execution infrastructure. Model calls go to a configured inference provider. Local model inference is a separate requirement and should be evaluated separately.

Does storing history locally keep all data inside the network?

No. Information selected for inference can leave in model requests. Tools, gateways, telemetry, and support processes can introduce other flows. Review the actual paths rather than relying on storage location alone.

Can we use our existing cloud and secrets platform?

The documentation describes supported cloud inference routes and secret-manager integrations. Validate the specific provider, identity mechanism, permissions, region, and product-version support required by your environment.

Is self-hosting automatically more secure?

It provides opportunities to apply your own controls and also gives your team more to configure and maintain. Compare demonstrated protections, threat exposure, and operational capability for the proposed deployment.

What should we decide first?

Identify the exact requirement the hosted arrangement cannot meet. Then choose the smallest change to the deployment boundary that satisfies it and assign responsibility for operating that change.

Control should be specific enough to test

Bringing an agent service in-house can be a meaningful architectural step. It can put execution, stored records, and administrative decisions closer to the systems your organization already operates.

The benefit becomes concrete when the team can say what it controls and show the evidence: where requests go, which identities can act, what information persists, how isolation works, and how the service recovers.

That clarity also makes external dependencies easier to manage. The model provider, software supplier, and connected services remain visible parts of the design.

Choose the boundary you need to control, then make sure you can operate everything you bring inside it.

Sources and further reading

Thanks for reading.
More on enterprise ai & ai agents, software & systems architecture and ai security & governance

Back to top ↑
Find a new perspective

Explore the site

↑↓ to move ↵ to openSearch the entire collection