Observability & Evaluation · Software component
Cost Attribution Aggregator
Software componentObservability & EvaluationObservability & Evaluationarc:CostAttributionAggregator
An aggregation component that groups request-level token and cost metrics by feature, customer, model or time period, computing total tokens, total cost, request count, average cost per request and trends.
Responsibility. Rolls request-level cost records up into per-feature, per-customer and per-model cost totals.
Also known as: Feature-level aggregation, Tier 2 token monitoring, Cost breakdown by customer/feature/model
Relationships
is invoked by dependency
reads dependency
sends data to dynamic
Design guidance
- SHOULD group costs using a feature tag attached to request-level metrics rather than inspecting millions of individual requests.
- SHOULD rank optimization targets by total spend (volume x per-request cost) together with optimization difficulty, not by per-request cost alone.
- SHOULD track costs at multiple levels: request, customer and feature (Ref8.05).
Quantitative guidance
As stated by the sources; verify before use.
- Example: support chatbot 100,000 req/day x $0.003 = $300/day (85% input); code assistant 5,000 x $0.08 = $400/day (75% output); research summarization 2,000 x $0.15 = $300/day (70% input) (Ch8.3).
- Halving code-assistant cost saves $200/day ($6,000/month) versus $60/day ($1,800/month) for a 20% support-chatbot reduction (Ch8.3).
- Feature-level analysis attributed 68% of an unexpected 33% monthly increase to one feature ($4,200 -> $9,800), traced to injecting an 8,000-token catalog instead of 500-800 retrieved tokens (Ch8.3).
Classification
- Patterns
- Tag-based cost attributionThree-tier token monitoring (request / feature / organization)
- Technologies
- Prometheus
- Quality attributes
- Maintainability (ISO/IEC 25010)
- Risks mitigated
- Optimization effort misdirected at high per-request but low total-spend featuresUnnoticed cost growth in features considered finished (e.g., accidentally disabled caching)
Sources
- Ch8.3: T. Nguyen, "Token Economics and Architecture," in Mastering Agentic AI Systems: Guide for the NVIDIA NCP-AAI Exam, 1st ed. 2026, ch. 8.3. ISBN: 9798244538229.
- Ref8.05: "Cost Optimization and Resource Monitoring for Agent Systems," unpublished reference note (05-Cost-Optimization-Resource-Monitoring.md), Mastering Agentic AI Systems: Guide for the NVIDIA NCP-AAI Exam supplementary materials, 2026. unpublished note