Amazon Bedrock on premise and open-source alternatives

The closest self-hosted replacement for Bedrock's multi-model API is LiteLLM as the gateway, vLLM or Ollama as the inference layer, and the Apache-2.0 gpt-oss models. The main trade-off is that your team runs, secures and upgrades the stack and carries the hardware, with no AWS terms, BAA or managed retention settings behind it.

On this page

Which open-source alternative replaces Amazon Bedrock in your own infrastructure

If a regulation, a customer contract, a residency rule or a lock-in concern blocks sending patient or EU personal data to Amazon Bedrock, the open-source replacement is a stack you run yourself: LiteLLM (MIT) as the OpenAI-format gateway, vLLM (Apache-2.0) as the inference server, and Ollama (MIT) as a local REST server for smaller deployments, with gpt-oss-120b and gpt-oss-20b (Apache-2.0) as open-weight models. The trade-off is that your organization operates the stack, so patching, access control, logging, capacity and retention are your responsibility rather than a managed service's. LiteLLM can route to Bedrock, vLLM and Ollama through one API with virtual keys, spend tracking and logging, which lets teams keep one client integration while moving sensitive workloads onto hardware they control. Confirm that the LiteLLM license applies to the parts you deploy, since its litellm/enterprise directory carries a separate license (LiteLLM repository).

None of these projects is a vendor with a business associate agreement or a data processing agreement. The vLLM repository and the gpt-oss repository are software and model distributions, so the compliance load sits with your own controls and with any contract you hold with your hosting provider, colocation facility or GPU cloud. Before approval, your privacy and security teams should document where the GPUs sit, who holds administrative access to the hosts and gateway, how prompts and completions are logged (LiteLLM logging can capture full request bodies, so confirm the setting you enable), and how long those logs are kept. Your hosting provider's BAA or DPA, if one exists for the chosen infrastructure, must cover the physical and operational layer you rely on. For the AWS terms that apply if you keep Bedrock in the mix, including data retention modes and abuse detection, read the sibling Bedrock pages on HIPAA eligibility and GDPR rather than relying on this stack's documentation.

License terms for each open-source layer of the stack

This table compares the four open-source components that can replace Bedrock's multi-model API inside your own infrastructure: LiteLLM, vLLM, Ollama and the gpt-oss models. Read each row for the role the component plays, its license and what to check before approval. The main takeaway is that LiteLLM's enterprise directory carries a separate license, and no plan or support tier is published in the facts, so read each LICENSE file in the version you deploy.

ComponentRole against BedrockLicense and what it allowsWhat to check
LiteLLMOpenAI-format gateway that routes to Bedrock, vLLM and Ollama, with virtual keys, spend tracking and loggingMIT, except the litellm/enterprise directory, which has its own licenseConfirm which directories your version uses and whether enterprise features you need sit under the separate license
vLLMInference server for open-weight models with an OpenAI-compatible API, replacing Bedrock's hosted model endpointsApache-2.0, permitting commercial use, modification and internal redistribution with noticeReview the NOTICE and third-party components in the version you deploy, and the license of each model you load separately
OllamaLocal runtime for open-weight models behind a REST API, suited to smaller or single-host deploymentsMIT, permitting commercial use with the license notice retainedCheck the license of each model pulled, since the runtime license does not cover model weights
gpt-oss-120b and gpt-oss-20bOpen-weight models that Bedrock also hosts, which you can run on your own hardwareApache-2.0 for the weights, per the gpt-oss repositoryConfirm the model card and any usage policy in the release you download; gpt-oss-120b fits a single 80GB GPU
Plan or support tierCommercial terms for paid support or enterprise featuresNo plan or support tier is published in the researched facts for these componentsAsk each project or a commercial provider for written support and indemnity terms before relying on them

How the open-source stack fits inside your network

The diagram starts with internal applications and staff tools sending OpenAI-format requests to the LiteLLM gateway, which applies virtual keys, spend tracking and logging before routing each call. From there, requests go to vLLM or Ollama, which serve gpt-oss models on the organization's own GPUs or CPUs. Every component sits inside the organization's boundary, and the audit log and identity provider are organization-managed. Check that no route leaves that boundary, including any fallback to a hosted provider configured in the gateway.

Requests stay inside the organization's boundary from client to model hardware.

What is free in the software and what your team still runs

Replacing Bedrock with self-hosted tools removes the per-call service fee but not the cost of running the stack. The four cards below separate what you can download without a license fee from what your own team must buy, operate and keep patched.

Licensed software under permissive terms

LiteLLM is MIT-licensed, except the litellm/enterprise directory, which has its own license. vLLM is Apache-2.0 and Ollama is MIT. Read the LiteLLM LICENSE file yourself before deployment, and if you need features in the enterprise directory, have legal review that license separately. Permissive terms allow internal use without a license fee, but they do not give you vendor support, indemnity or a security patch commitment.

LiteLLM license

Open-weight model files

gpt-oss-120b and gpt-oss-20b are Apache-2.0 open-weight models that Bedrock also hosts. Downloading the weights is free, but you must still check the license text that ships with each model release and record which version your teams approved. Model files are large and need controlled storage, checksum verification and a process for approving new versions before they reach production.

gpt-oss repository

Hardware you buy or rent

The gpt-oss-120b model fits on a single 80GB GPU, and gpt-oss-20b is the smaller option. Hardware is your largest one-time or recurring cost, whether you buy GPUs or rent them in your own cloud account. Costs rise with concurrent users, context length and redundancy requirements. Ask your architects to size capacity for peak load and a failover node before you request a quote from any hardware vendor.

Staff work to run the stack

Someone must install the gateway, inference server and models, then harden them, apply upgrades, monitor latency and errors, rotate virtual keys and staff an on-call rota. This work recurs for as long as the stack is in use and is the cost most often underestimated. None of these open-source projects comes with a vendor support contract in the sources reviewed, so confirm whether any commercial support tier exists with each project before you rely on one.

Which open-source project replaces which Bedrock function

Bedrock bundles three functions that an organization must replace separately if it leaves the service: a single API across many model providers, managed hosting of models, and a catalog that includes open-weight models. In a self-hosted stack, LiteLLM takes the first role. It is an MIT-licensed gateway (except the litellm/enterprise directory, which has its own license) that exposes 100+ LLM providers through one OpenAI-format API, with virtual keys, spend tracking and logging. LiteLLM also lists Bedrock among the providers it can call, so applications can keep one client interface while traffic is shifted from Bedrock to in-house endpoints.

Model hosting maps to inference servers. vLLM (Apache-2.0) provides an OpenAI-compatible API for open-weight models on NVIDIA, AMD and Intel GPUs and on CPUs, and is the usual choice for multi-user serving. Ollama (MIT) runs open-weight models such as gpt-oss and Gemma locally behind a REST API, which suits smaller deployments and test environments. The open-weight models that Bedrock also hosts map to OpenAI's gpt-oss-120b and gpt-oss-20b, both Apache-2.0, with gpt-oss-120b fitting a single 80GB GPU. Confirm model license terms and hardware sizing against the gpt-oss repository before approving a model for production.

Several Bedrock controls do not transfer to this stack. Per-Region retention modes (none, default, aws_review and the legacy provider_data_share), the zero operator access model, model-specific abuse detection and CloudTrail logging of the processing Region are AWS-operated features. Your organization must build replacements: retention rules for prompts, completions and gateway logs, role-based access to the GPU hosts and gateway admin keys, and an audit trail that records who called which model and where. Because LiteLLM can call Bedrock, a migration can run both paths side by side while you move workloads, but the logs and retention settings for each path must be reviewed separately.

Which self-hosted setup fits your situation

A small team that wants a private chat assistant usually needs the simplest stack. Ollama, licensed MIT, runs open-weight models such as gpt-oss and Gemma on a workstation or single server and exposes a REST API that internal tools can call. Requests stay on the host you control, and no prompt leaves the network unless you add a connector that sends it elsewhere.

  • Hardware sizing: The model you pick sets the memory and GPU needs. gpt-oss-120b fits a single 80GB GPU, while smaller models run on modest hardware. Confirm the fit on your own machine before you approve the rollout.
  • Access control: Ollama does not give you per-user identity, so limit who can reach the host and place it behind your network controls.
  • Logging: Decide what you need recorded and confirm it is captured, since basic setups keep less audit evidence than a gateway does.
  • Model licenses: gpt-oss models are Apache-2.0. Check the license of every other model you pull, because open-weight licenses vary.
  • Scale limits: As the group grows, a single host becomes a bottleneck and a reason to move to the regulated pattern.

Before approving, confirm which people and data sources the host will see and who administers it.

What drives total cost beyond the license

This table lists the cost components of running LiteLLM, vLLM or Ollama with open-weight models in your own environment, and whether each one is paid once or recurs. Read the drivers column to see what pushes each cost up and what keeps it down. The facts available do not give hardware prices or staffing estimates, so price these items from your own vendor quotes and internal staff plans.

Cost driverOne-time or recurringWhat raises itWhat lowers it
GPU or CPU hardwareOne-time purchase or recurring cloud capacityLarger open-weight models, more concurrent users, longer contexts and higher throughput targets. Per the supplied facts, gpt-oss-120b fits a single 80GB GPU, so smaller models or the gpt-oss-20b model reduce hardware needs.Choosing the smallest model that meets the use case, sizing for measured peak concurrency, and using capacity you already own. Ask vendors for quoted hardware and support terms.
Staff time for install, upgrades and security reviewOne-time for initial install and review, recurring for upgrades and re-reviewAir-gapped or multi-tenant designs, custom SSO and access control, and each new release of LiteLLM, vLLM, Ollama or a model that needs a new review.Standard deployment patterns, documented configuration, pinned versions and a fixed upgrade cadence agreed with security. Ask any implementation partner for a written scope.
Storage and retention for LiteLLM logsRecurringFull prompt and completion logging, long retention periods set by privacy or legal teams, and high request volume across many users.Logging only the metadata you need, defined retention periods, and automated deletion. Confirm your retention requirement with your privacy and records teams before sizing storage.
Monitoring and on-callRecurringMultiple inference nodes, GPU failures, queue backlogs, and a requirement for after-hours response for clinical or customer-facing use.Standard metrics and alerts on the gateway and inference server, clear runbooks, and a defined support hours model. Confirm the support model in writing before go-live.
Model evaluation when a new open-weight release arrivesRecurringFrequent model releases, use cases with patient, customer or EU personal data that need documented testing, and many internal applications relying on one model.A fixed evaluation set, a single approved model list, and a schedule that tests only major releases. Record results so reviewers can see what was tested.

Questions buyers ask before choosing a self-hosted Bedrock replacement

Do open-source AI gateways and inference servers offer a BAA or DPA?

No. LiteLLM, vLLM and Ollama are software you install and run, so no vendor contracts with you for the code, and none of them is a business associate or processor for your data. Compliance depends on how your organization hosts and controls the stack: who can reach the servers, where logs are written, how long prompts are kept, and whether the hosting provider you choose signs a BAA or DPA for the infrastructure underneath. Ask your cloud or data center provider for those agreements, and document the controls yourself so your privacy and security reviewers can assess them.

Is gpt-oss on Bedrock the same as gpt-oss running on my own servers?

The model weights are the same open-weight family, but the operating environment is not. gpt-oss-120b and gpt-oss-20b are Apache-2.0 models that Bedrock hosts in AWS-managed infrastructure, where Bedrock's data retention modes, abuse detection and AWS operating model apply. Running the same weights yourself moves prompts, completions and logs into your environment, so you set retention, access control and logging. Output quality and behavior can still differ between deployments depending on serving configuration, so test your own prompts before relying on either path.

What does it take to run an open-weight model inside my own infrastructure?

You need compute, a serving layer, identity and access controls, and an operating process. The gpt-oss repository documents the model family, and the gpt-oss-120b model fits a single 80GB GPU, which sets a minimum hardware class for that model. Around the model you typically add an inference server such as vLLM, a gateway such as LiteLLM for virtual keys and spend tracking, SSO integration, audit logging, patching and monitoring. Hardware, staffing and hosting are the main cost drivers, and most of that spend recurs, while initial design and hardening are largely one-time work.

Can my platform or security team run this without outside help?

Often yes, if the team already operates GPU workloads, Kubernetes or similar container platforms, and has an on-call rotation for production services. The harder parts are rarely the install. They are access control, logging that your compliance team accepts, secure configuration of the gateway and inference server, and keeping software current. Check whether you have owners for each layer, a tested rollback path, and reviewers who can read the configuration. If any of these are missing, the gap is usually a staffing question, not a technical one.

What should I ask a consultant for in a scoping call?

Ask for a written scope that names the models, serving components, gateway, identity integration, logging destinations and the hosting environment, plus the deliverables you will receive. Ask how the work will be tested before production use, what documentation covers configuration and controls, and what ongoing support or retainer options exist. DeployOpen plans, implements, hardens, documents and supports self-hosted open-source platforms inside the client's own cloud accounts, data centers or air-gapped networks, and most engagements are fixed-scope with scope and timelines agreed in writing before work starts. A quote follows from that written scope.

How do the licenses of gpt-oss, vLLM, Ollama and LiteLLM affect internal use?

All four are open source, so internal use is generally permitted, but you should confirm the terms with your legal team. gpt-oss-120b and gpt-oss-20b are Apache-2.0, vLLM is Apache-2.0, Ollama is MIT, and LiteLLM is MIT except the litellm/enterprise directory, which has its own license. Permissive licenses like these generally allow internal deployment and modification, but they do not provide a support or indemnity commitment. Record the license text and version you deploy, and review it again when you upgrade.

What does the LiteLLM enterprise directory change for my organization?

The enterprise directory in the litellm repository carries its own license rather than the MIT license that covers the rest of the project. If you use code from that directory, your legal team must review its terms before deployment, because they differ from the MIT terms that cover the core gateway. Using only the MIT-licensed core avoids that review, but you should confirm which features you need, such as SSO or advanced audit features, and whether they sit in the enterprise directory. Check the LICENSE file in the repository at the version you plan to deploy.

What catches buyers out when they leave Bedrock

Moving from Bedrock to a self-hosted stack replaces a managed service with components your team operates. The risks below share one pattern: controls that AWS previously handled now sit with your organization, and each one needs a test in your own environment before you approve the stack for patient or EU personal data.

Gateway license differs from the core

The LiteLLM core is MIT-licensed, but the litellm/enterprise directory carries its own license. Governance features your security team expects, such as access controls, audit views or advanced spend controls, may sit in that directory. Read the LICENSE file in the repository and the enterprise directory before you design around any feature, and get written confirmation from the vendor that the features you need are licensed for your use.

LiteLLM LICENSE

Losing AWS-managed controls

In Bedrock, retention is set per Region at the account or project level, and CloudTrail records the processing Region for cross-Region calls. Self-hosted, nothing equivalent exists by default. You must rebuild request logging, retention limits, deletion of prompt logs and an inventory of which models and regions were used. Test whether your gateway logs prompts, where those logs land, and who can read them.

Bedrock data retention

No vendor BAA or DPA for the software

Open-source projects such as LiteLLM, vLLM and Ollama are licensed software, not services. No vendor signs a business associate agreement or data processing agreement for them, and AWS's BAA covers only the AWS services you use. Compliance then rests on your hosting contract, your internal policy and your own controls. Confirm with counsel which agreement covers the infrastructure that runs the stack and who signs it.

Unpatched inference servers and gateways

Bedrock patches its managed infrastructure without action from you. A self-hosted gateway or inference server runs the version you deploy until you upgrade it. Track security advisories for each component, pin versions, and set a patch process with an owner and a test environment. Ask whether your team can apply a security fix within your own change window, because an old vLLM or LiteLLM build can stay in production unnoticed.

Model capability gaps

Bedrock hosts many models from several providers, while a self-hosted stack runs the open-weight models you load. OpenAI's gpt-oss-120b and gpt-oss-20b are Apache-2.0 options, and gpt-oss-120b fits a single 80GB GPU, but a smaller model may not match a hosted frontier model on your tasks. Run your own evaluation set covering accuracy, refusal behavior and output format before you switch any workflow over.

gpt-oss repository

Steps to approve a self-hosted Bedrock replacement

This sequence turns a proposed move off Amazon Bedrock into a documented decision that security, privacy and procurement can each sign. It covers licensing, feature gaps, model and hardware fit, data boundaries, ownership and an exit path, and ends with a record the auditor can review.

  1. Read the license for each project version

    Before anything is deployed, the legal or open-source review owner reads the LICENSE file for each project at the exact version you plan to run. For LiteLLM, that file is published in its repository under the MIT terms, with the exception of the litellm/enterprise directory. Record the version, the license name and the date of review. The step is done when every component in the stack has a recorded license entry. Confirm with counsel whether the license notices that must accompany the software differ for internal use compared with software shipped to customers, because that distinction changes what you must include in documentation or products.

  2. Check whether needed features sit in enterprise code

    The security or platform lead lists every feature the business needs from the gateway, such as SSO, virtual key management, spend tracking, audit logging or team-level controls. Each item is then checked against the LiteLLM repository to see whether it lives outside the litellm/enterprise directory, which has its own license. Any feature that depends on that directory is either covered by a separate license agreement or replaced by an internal control. The output is a feature-to-license table that shows which capabilities are under MIT terms and which need a commercial decision.

  3. Confirm the gpt-oss license and hardware fit

    The model owner confirms the license for the gpt-oss model you intend to run. OpenAI's gpt-oss-120b and gpt-oss-20b are Apache-2.0 open-weight models, and the gpt-oss repository is the place to confirm the current model terms. Match the model to hardware: gpt-oss-120b is documented as fitting a single 80GB GPU, so an organization without that hardware should test gpt-oss-20b or confirm other supported sizes. The step closes with a hardware sheet listing GPU model, memory, host location and the serving software version, signed off by infrastructure engineering.

  4. Define data handling inside your boundary

    The privacy and security owners write the data rules for prompts, completions and anything LiteLLM logs, such as request metadata, spend records and virtual key activity. Specify where logs are stored, who can read them, how long they are kept, how patient or EU personal data is masked or excluded, and how the gateway, inference server and model host are isolated from unapproved networks. Unlike Bedrock, where AWS publishes retention modes and a zero operator access model, a self-hosted stack puts these controls entirely in your hands, so each one must be written down. The step is done when a data flow diagram and a retention table have been approved.

  5. Assign support, upgrades and an exit path

    The platform owner names one accountable team for patching the gateway, the inference server and the model runtime, and for tracking security advisories in each repository. That team also defines an exit path: because LiteLLM can route to Bedrock as one of its providers, the configuration can be pointed back to Bedrock if the self-hosted service must be retired. Test that switch in a non-production environment and record the steps, the credentials needed and the expected behavior. The output is a named owner, an upgrade procedure and a tested fallback runbook.

  6. Record the decision for the auditor

    The compliance lead assembles one decision record that links the license review, feature table, model and hardware sheet, data flow diagram, retention table, ownership statement and exit test. The record states which Bedrock terms it replaces, what the organization still relies on from AWS, and which controls the auditor should sample. Ask your assessor early which evidence format they expect. The step is complete when the record is approved by security, privacy, legal and the business owner, and filed where it can be retrieved during an assessment.

How DeployOpen helps you run a private AI stack under your compliance rules

DeployOpen plans, implements, hardens and documents a self-hosted stack that replaces Amazon Bedrock's multi-model API inside your own cloud accounts, data centers or air-gapped network. The work starts with a written scope that names each model, gateway and control your compliance team needs to review.

How we scope

  • Map which Bedrock workloads carry patient or EU personal data and which models they call today
  • Agree in writing which gateway, inference server and open-weight models replace each one
  • Define the access control, SSO, audit logging and data handling controls your reviewers expect
  • Engagements are fixed-scope, with deliverables and timelines agreed before work starts

How we build

  • Deploy LiteLLM as the OpenAI-format gateway with virtual keys, spend tracking and logging enabled
  • Serve open-weight models such as gpt-oss through vLLM or Ollama on your own GPU or CPU hardware
  • Test the stack for prompt injection, key handling, data exposure and access permissions before handover
  • Record configuration, licenses and sizing decisions so the stack can be reviewed by your team

How we hand over

  • Deliver architecture, network and data flow documentation that shows where prompts and logs stay
  • Provide a findings report with fixes and a retest, plus the evidence your auditors will ask for
  • Document the license terms of each component, including the separate license on LiteLLM's enterprise directory
  • Train your platform and security staff to operate, patch and back up the stack independently

How we support

  • Ongoing upgrades, backups and continuous security testing are available as a retainer
  • Review new model releases and gateway versions against your written scope before adoption
  • Confirm with your legal and privacy teams any AWS or model terms still in use during migration
  • Keep compliance evidence current as your control framework, vendors or regulators change

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.