Raxx · internal docs

internal · gated

ADR 0054 — Reasonator deployment target: Heroku Standard-2X

Status: Accepted Date: 2026-05-09 UTC Refs: #1385, docs/architecture/reasonator/design.md (Decision 1), docs/architecture/reasonator/cost-model.md, ADR-0052


Context

Reasonator is a standalone FinBERT sentiment scoring service. FinBERT (ProsusAI/finbert) is ~400 MB of model weights. The service must stay warm to serve Pro+ sync requests with a p99 < 2s latency target. The operator's stated reason for extracting Reasonator from the main Raxx app is scalability.

Three deployment targets were evaluated: Heroku (Tier B per ADR-0052), AWS ECS Fargate, and AWS Lambda with provisioned concurrency.


Decision

Deploy Reasonator on a Heroku Standard-2X dyno (1 GB RAM), minimum 1 dyno always running.


Consequences


Alternatives Considered

AWS ECS Fargate: Better at high throughput, finer-grained scaling, no dyno-restart model loss. Costs ~$96/month vs $51/month at 1k req/day. Setup requires ECS task definition, ALB, ECR pipeline, IAM roles, and VPC peering with the Heroku app. Overkill for Phase 1 load; correct choice at Phase 2+ scale. This is the designated migration path.

AWS Lambda (provisioned concurrency): Lambda cold start with a 400 MB model is 30+ seconds — disqualifying for the Pro+ sync path even with provisioned concurrency. Provisioned concurrency eliminates cold starts but costs $50/month per instance regardless of traffic, negating Lambda's pay-per-use advantage. Costs more than Heroku at every load tier for this workload. Rejected.