Buy managed capabilities that are not your differentiation and build the contracts that are. For most teams, the practical answer is hybrid: use managed model/runtime infrastructure, retain control of prompts, tool schemas, authorization, evaluation datasets, traces, and business state, and keep an exit path for components with high switching risk.
Do not decide from a feature checklist. Decide from evidence produced by your real workflow.
Compare three options, not two
| Option | You own | Provider/framework owns |
|---|---|---|
| Managed platform | Use case, configuration, integrations, acceptance | Runtime and many operational services |
| Framework-based build | Application contracts, code, deployment, operations | Reusable orchestration abstractions |
| Custom runtime | Nearly every application and runtime layer | Models/cloud primitives only |
A framework is not the same as a hosted platform. Open source can reduce licensing lock-in while still creating deep API and state-format coupling. A managed service can be portable if your contracts and data remain cleanly separated.
Weighted decision matrix
Assign each criterion a weight totaling 100. Score each option from 1 (poor) to 5 (strong), then multiply:
weighted score = Σ(weight × option score)
| Criterion | Weight | Managed | Framework build | Custom | Evidence required |
|---|---|---|---|---|---|
| Time to first controlled pilot | Working vertical slice | ||||
| Tool/API integration fit | Two hardest integrations tested | ||||
| Identity and authorization control | Threat model and negative tests | ||||
| Evaluation and trace export | Raw case/trace portability test | ||||
| State and recovery semantics | Crash/resume and idempotency test | ||||
| Model/provider choice | Qualified route swap | ||||
| Data residency and retention | Contract plus deletion proof | ||||
| Reliability/operating burden | Load, failure, and on-call estimate | ||||
| Unit economics at target scale | Cost per successful task | ||||
| Exit cost | Small migration spike |
Scoring workshops are easy to manipulate. Write what evidence earns each score before vendors demonstrate their products.
Keep these contracts portable
Even when buying a platform, own versioned representations for:
- task inputs, terminal outcomes, abstention, and escalation;
- tool names, schemas, permissions, errors, and receipts;
- prompt/instruction bundles and model-route policy;
- evaluation cases, expectations, rubrics, and results;
- trace IDs, spans, version metadata, cost, and latency;
- durable business state and operation identities;
- source provenance, access scope, retention, and deletion state.
Exportability means you can reconstruct behavior outside the vendor UI. A CSV of final prompts is not enough if tool trajectories, evaluator decisions, or state transitions are missing.
Buy when operational leverage dominates
A managed platform is attractive when:
- the task fits supported patterns without security workarounds;
- the team lacks platform/on-call capacity;
- integrations use standard APIs and identity;
- built-in tracing and evaluation export the needed raw evidence;
- regional, retention, and customer requirements are contractually supported;
- expected usage fits the pricing and quotas;
- the exit spike demonstrates acceptable switching cost.
Google Cloud’s architecture guidance separates choices across frontend, agent framework, tools, memory, runtime, models, and model runtime. That decomposition is useful because “buying the platform” rarely transfers ownership of the complete outcome.
Build when the boundary is the product
Build more of the stack when:
- tool execution requires proprietary authorization or transaction semantics;
- long-running state, recovery, or auditability is differentiated;
- the evaluation and policy layer must be independently controlled;
- model/provider portability is a business requirement;
- high scale makes managed unit economics unfavorable;
- required controls cannot be verified through the managed surface.
Custom work has a continuing cost: upgrades, security response, observability, capacity, and on-call. Do not compare a vendor subscription with only the initial engineering sprint.
Run five proof tests before signing
- Hardest tool: authorize, execute, reconcile, and audit one consequential integration.
- Failure recovery: terminate execution after an external effect and prove one safe resume.
- Evaluation portability: export cases, traces, scores, evaluator versions, and rationales.
- Data deletion: remove one source/user and verify derived copies under the contract.
- Exit: reimplement one representative workflow component outside the platform.
These tests should use test identities and synthetic data. A procurement proof is not permission to expose production information.
Total-cost comparison
three-year cost = implementation + migration + platform/runtime usage+ evaluation/observability + human operations+ security/compliance + expected change cost
Normalize operating spend as cost per successful task, not tokens or seats alone. Include failures, retries, human review, and workload growth.
Decision record
Workflow and excluded scope:Architecture options:Weights and scoring evidence:Security/data red lines:Pilot results:Three-year assumptions:Exit test and switching risks:Selected option and owner:Reassessment trigger/date:
Reassess after material changes in scale, regulation, integration scope, vendor behavior, or model/runtime capability. Google’s guidance similarly describes agent architecture selection as iterative rather than one-time.
Use the single-versus-multi-agent framework before platform comparison so unnecessary orchestration does not distort the choice. JoinAI can run the matrix and proof tests against your architecture through an AI implementation assessment.




