Legacy Context Budget Ladder
by Maha Context Budget Ladder in AI models & inference
Compare five ascending declared context budgets over the same supplied documents. No source lookup, model or answer-quality claim. Public/synthetic nonpersonal input only; 32 KiB input, 65 KB output. Result retention: 24 hours; minimal receipt metadata: 90 days. Local validation only; deployment and model spending on hold.
https://www.mahastrategies.com/api/v1/context/legacy/context-budget-ladder- Price
- $0.035
- per call in USDC
- Uptime
- 100%
- last 30 days
- Response time
- 224 ms
- 631 ms slowest 5%
- Last check
- Passed
- 32 min ago, next any minute now
Reliability
Status and outage history · Atom feed · Watch with other listings
How to call it
POST https://www.mahastrategies.com/api/v1/context/legacy/context-budget-ladder
Each call costs $0.035002 in USDC on Base, paid with the request over x402.
Run a free test callOne unpaid request, the way an agent sends it. You see the payment challenge it gets back. Nothing is charged.
Example request
From the listing.
POST https://www.mahastrategies.com/api/v1/context/legacy/context-budget-ladder
content-type: application/json
{
"dataClass": "synthetic",
"nonpersonalMetadata": true,
"request": {
"budgetMode": "guaranteed",
"clientRequestId": "synthetic-batch20",
"documents": [
{
"id": "doc1",
"text": "The synthetic release requires approval from the security owner.\n\nAn unrelated synthetic scheduling note.",
"title": "Synthetic release"
}
],
"provenance": "compact",
"scoring": "bm25",
"task": "Preserve the release condition and evidence source.",
"tokenBudgets": [
64,
96,
128,
192,
256
]
}
}Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
dataClass | string | Yes | One of: public, synthetic. |
nonpersonalMetadata | boolean | Yes | |
request | object | Yes |
Example response
The provider's example. We can't check it without paying. Shortened for display.
Example response, 91 lines
{
"data": {
"chargedAmount": "35002",
"inputHash": "sha256:0ed7674853a469cc28d3fe5dc19d9cc02d9aec342c5ba4fdeb4ba07c9…",
"limitations": [
"Public or synthetic nonpersonal input only; caller labels are no…"
],
"productId": "context-budget-ladder",
"result": {
"comparison": [
{
"compiledEstimatedTokens": 39,
"includedPassageIds": [
"doc1:1",
"doc1:2"
],
"outputHash": "sha256:bad8684935f98b379da45c12514806b9bc78b52a18bf58f040a3b968b…",
"sourceCoveragePercent": 100,
"tokenBudget": 64,
"tokensSaved": 0
}
],
"runs": [
{
"contextPack": {
"clientRequestId": "synthetic-batch20",
"context": "# Context Pack\n\nTask: Preserve the release condition and evidenc…",
"includedPassages": [
{
"passageHash": "sha256:1eb45d6ca604517d60f407452941bafb9926c8975c6dea84da2a639da…",
"passageId": "doc1:1",
"sourceId": "doc1",
"text": "The synthetic release requires approval from the security owner."
}
],
"inputHash": "sha256:94bb52d71cd4061ae31f396b1a3512604b78202a34b542235d2c37073…",
"metrics": {
"compiledBytes": 200,
"compiledEstimatedTokens": 39,
"duplicatePassagesRemoved": 0,
"estimatedReductionPercent": 0,
"originalBytes": 105,
"originalEstimatedTokens": 16,
"sourceCount": 1,
"sourceCoveragePercent": 100,
"tokensSaved": 0
},
"outputHash": "sha256:bad8684935f98b379da45c12514806b9bc78b52a18bf58f040a3b968b…",
"packId": "ctxpack_92043b6fe9fee63dc740d9fad4c045df",
"retentionBoundaries": {
"claimVerificationPerformed": false,
"completenessGuaranteed": false,
"evidenceRetention": "best_effort",
"hallucinationPreventionGuaranteed": false,
"selectionType": "extractive",
"tokenCountType": "model_neutral_estimate"
},
"sources": [
{
"includedEstimatedTokens": 16,
"includedPassageIds": [],
"originalEstimatedTokens": 16,
"passageCount": 2,
"sourceHash": "sha256:0000f0abf18f827b3904d93cfa1a3dfb8d80240f9e0dd7205f9f30994…",
"sourceId": "doc1",
"title": "Synthetic release"
}
],
"task": "Preserve the release condition and evidence source.",
"tokenBudget": 64,
"version": "0.1.0",
"warningCodes": [
"model_neutral_token_estimates",
"extractive_selection_not_verification"
],
"warnings": [
"Token counts are model-neutral estimates, not provider tokenizer…"
]
},
"tokenBudget": 64
}
]
},
"resultHash": "sha256:14f3db5ca417144c487b6749d6369cba9cdbb26bef4e3e77302771b75…",
"version": "maha-reviewed-legacy-port/1"
},
"proof": {
"settlement_id": "0x00000000000000000000000000000000000000000000000000000000000000…"
},
"success": true
}Call it from code
The curl command shows the payment challenge. The JavaScript and Python versions pay and call, and never pay more than $0.035002.
curl: see the payment challenge
# bash or zsh: see the payment challenge. Nothing is charged.
curl -sS -g -i -X POST 'https://www.mahastrategies.com/api/v1/context/legacy/context-budget-ladder' \
-H 'content-type: application/json' \
--data-raw '{"dataClass":"synthetic","nonpersonalMetadata":true,"request":{"budgetMode":"guaranteed","clientRequestId":"synthetic-batch20","documents":[{"id":"doc1","text":"The synthetic release requires approval from the security owner.\n\nAn unrelated synthetic scheduling note.","title":"Synthetic release"}],"provenance":"compact","scoring":"bm25","task":"Preserve the release condition and evidence source.","tokenBudgets":[64,96,128,192,256]}}'
# x402 v2 sends the challenge base64-encoded in the PAYMENT-REQUIRED header (v1 sends it in the body).
# To read the header:
curl -sS -g -o /dev/null -D - -X POST 'https://www.mahastrategies.com/api/v1/context/legacy/context-budget-ladder' \
-H 'content-type: application/json' \
--data-raw '{"dataClass":"synthetic","nonpersonalMetadata":true,"request":{"budgetMode":"guaranteed","clientRequestId":"synthetic-batch20","documents":[{"id":"doc1","text":"The synthetic release requires approval from the security owner.\n\nAn unrelated synthetic scheduling note.","title":"Synthetic release"}],"provenance":"compact","scoring":"bm25","task":"Preserve the release condition and evidence source.","tokenBudgets":[64,96,128,192,256]}}' \
| grep -i '^payment-required:' | cut -d' ' -f2 | tr -d '\r' | base64 --decodeJavaScript: pay and call
// npm i @x402/fetch @x402/evm viem
import { wrapFetchWithPayment, x402Client } from "@x402/fetch";
import { registerExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
// Pays at most $0.035002 per call.
const client = new x402Client().setSpendControls({ maxAmountPerPayment: "$0.035002" });
registerExactEvmScheme(client, { signer: privateKeyToAccount(process.env.EVM_PRIVATE_KEY) });
const pay = wrapFetchWithPayment(fetch, client);
// Not sure it's safe to pay? ToolVet checks it first for $0.005. Pay for that from a separate
// client: this one is capped at $0.035002 per payment. GET https://toolvet.app/api/v1/check?url=https%3A%2F%2Fwww.mahastrategies.com%2Fapi%2Fv1%2Fcontext%2Flegacy%2Fcontext-budget-ladder&method=POST
const res = await pay("https://www.mahastrategies.com/api/v1/context/legacy/context-budget-ladder", {
method: "POST",
headers: { "content-type": "application/json" },
body: JSON.stringify({
"dataClass": "synthetic",
"nonpersonalMetadata": true,
"request": {
"budgetMode": "guaranteed",
"clientRequestId": "synthetic-batch20",
"documents": [
{
"id": "doc1",
"text": "The synthetic release requires approval from the security owner.\n\nAn unrelated synthetic scheduling note.",
"title": "Synthetic release"
}
],
"provenance": "compact",
"scoring": "bm25",
"task": "Preserve the release condition and evidence source.",
"tokenBudgets": [
64,
96,
128,
192,
256
]
}
}),
});
console.log(res.status, await res.text());Python: pay and call
# pip install "x402[requests,evm]"
import os
from eth_account import Account
from x402 import x402ClientSync
from x402.http.clients import x402_requests
from x402.mechanisms.evm import EthAccountSigner
from x402.mechanisms.evm.exact.register import register_exact_evm_client
# Pays at most $0.035002 per call.
client = x402ClientSync().set_spend_controls({"max_amount_per_payment": "$0.035002"})
register_exact_evm_client(client, EthAccountSigner(Account.from_key(os.environ["EVM_PRIVATE_KEY"])))
with x402_requests(client) as session:
res = session.post(
"https://www.mahastrategies.com/api/v1/context/legacy/context-budget-ladder",
json={
"dataClass": "synthetic",
"nonpersonalMetadata": True,
"request": {
"budgetMode": "guaranteed",
"clientRequestId": "synthetic-batch20",
"documents": [
{
"id": "doc1",
"text": "The synthetic release requires approval from the security owner.\n\nAn unrelated synthetic scheduling note.",
"title": "Synthetic release",
},
],
"provenance": "compact",
"scoring": "bm25",
"task": "Preserve the release condition and evidence source.",
"tokenBudgets": [
64,
96,
128,
192,
256,
],
},
},
)
print(res.status_code, res.text)Security scan
No findings
We scan names, descriptions and tool definitions for hidden instructions and other prompt-injection patterns.
Recent checks
| When | Result | HTTP | Time | Price |
|---|---|---|---|---|
| 32 min ago | Passed | 402 | 216 ms | $0.035 |
| 5 h ago | Passed | 402 | 631 ms | $0.035 |
| 10 h ago | Passed | 402 | 221 ms | $0.035 |
| 14 h ago | Passed | 402 | 328 ms | $0.035 |
| 19 h ago | Passed | 402 | 224 ms | $0.035 |
Show 1 older checks
| 29 h ago | Passed | 402 | 224 ms | $0.035 |