Weekend Off-Peak Pricing: A Calendar-Level Strategy for Compute Costs

    A recent pricing update from a cloud provider introduces all-day off-peak rates on weekends, shifting compute cost optimization from an hourly strategy to a calendar-based one. This article analyzes how this pricing model impacts compute costs across two different usage scenarios and provides practical guidelines for migrating non-real-time tasks, such as CI/CD pipelines and log analysis, to weekend execution.

    What Changes with Weekend Off-Peak Pricing?

    A cloud provider recently announced that starting from Sunday midnight, both Saturday and Sunday will be fully included in the off-peak billing period. Previously, off-peak pricing was only available during late-night hours on weekdays, allowing developers to save costs by scheduling tasks for midnight. The new rule turns “weekends” into an independent billing dimension, meaning prices now vary not just by the time of day, but also by the day of the week.

    This means that even daytime API calls on Saturdays or Sundays can enjoy off-peak rates. For tasks that do not require real-time responses, the flexibility for scheduling execution times has significantly increased.

    Calculation Methodology

    The unit prices used in this article are hypothetical and are denominated in CNY per million tokens. Actual prices are subject to the official rates published by the provider on their website. The calculations are based on the following assumptions:

    • The daily call volume is 10 billion tokens, with input/output ratios of 95%/5% (Scenario 1) and 80%/20% (Scenario 2).
    • The cache hit rate is 95% of the input volume. The hit portion is billed at the cache hit unit price, while the missed portion is billed at the standard input unit price.
    • The weekend off-peak price is 50% of the corresponding peak price.
    Billing Item (CNY/Million Tokens) Model A Peak Model A Off-Peak Model B Peak Model B Off-Peak
    Cache Hit Input 0.10 0.05 0.30 0.15
    Cache Miss Input 3.00 1.50 9.00 4.50
    Output 9.00 4.50 27.00 13.50

    Using the cache hit input in Scenario 1 as an example: The daily call volume is 10 billion tokens, with input accounting for 95%, which equals 9.5 billion tokens. The cache hit portion is 9.025 billion tokens, or 9,025 million tokens. The cost for this portion during Model A’s peak hours is 9,025 × 0.10 = 902.5 CNY. All numbers in the following tables are calculated using this method.

    Scenario 1: 95% Input, 5% Output

    This scenario is suitable for input-heavy tasks such as Q&A and Retrieval-Augmented Generation (RAG).

    Billing Model Time Slot Cache Hit Input (9,025M Tokens) Cache Miss Input (475M Tokens) Output (500M Tokens) Total (CNY)
    Model A Peak 902.5 1425 4500 ~6828
    Model A Off-Peak 451.25 712.5 2250 ~3414
    Model B Peak 2707.5 4275 13500 ~20483
    Model B Off-Peak 1353.75 2137.5 6750 ~10241

    Scenario 2: 80% Input, 20% Output

    This scenario is suitable for generation-intensive tasks such as code completion and long-form writing. Since the output unit price is the highest, the bulk of the cost falls on the output.

    Billing Model Time Slot Cache Hit Input (7,600M Tokens) Cache Miss Input (400M Tokens) Output (2,000M Tokens) Total (CNY)
    Model A Peak 760 1200 18000 ~19960
    Model A Off-Peak 380 600 9000 ~9980
    Model B Peak 2280 3600 54000 ~59880
    Model B Off-Peak 1140 1800 27000 ~29940

    Interpreting the Numbers

    First, the savings ratio is fixed. Under the hypothetical pricing table in this article, the weekend off-peak price for every billing item is exactly half of the peak price. Therefore, regardless of the call structure, the savings ratio for a single call remains 50%.

    Second, the absolute savings amount increases as the output ratio rises. In Scenario 1, Model B saves about 10,241 CNY per day; in Scenario 2, Model B saves about 29,940 CNY per day. Model A saves about 3,414 CNY and 9,980 CNY in the two scenarios, respectively. This is because the output unit price is high; the higher the output ratio, the greater the price difference per token.

    Third, when calculated on a weekly or monthly basis, the overall savings ratio depends on the weekend call volume. Assuming a consistent daily call volume, with two weekend days per week, the savings ratio is approximately 2/7 × 50% ≈ 14.3%. Calculating with 8 to 10 weekend days per month, the savings ratio ranges from 13% to 17%. If the weekend call volume is higher than on weekdays, the ratio will be higher. Conversely, if weekend calls are minimal, the savings will be limited.

    How to Migrate Non-Real-Time Tasks to Weekends

    Tasks such as automated testing in CI/CD pipelines, documentation generation, static code analysis, and historical log analysis typically do not require second-level responses. In the past, these tasks were often scheduled for late-night hours on weekdays. However, if a failure occurs late at night when on-call personnel are fatigued, it is difficult to handle in a timely manner. Scheduling them for daytime weekend execution secures the same off-peak pricing while ensuring that staff are available during working hours.

    Before migrating, it is recommended to check the following items for each task:

    • Task delay capability: Will the results affect business decisions that need to be made before Monday?
    • Task retry capability: Will rerunning the task after a failure generate duplicate data?
    • Idempotency keys: Does executing the same task multiple times produce only one actual effect?
    • Failure alerts: If an error occurs on the weekend, who will be notified, and within what timeframe?
    • Sensitive data: Ensure data privacy and cross-border compliance regulations are met before calling third-party models.