{"uid":"cap_R9gJd-3ylmKubkudUf1m8","slug":"finmath-text-stats-d0710ba2","name":"finmath Text Stats","description":"Deterministic finance and crypto math for AI agents: TradFi (NPV, IRR, XIRR, Black-Scholes + Greeks, bonds, VaR, Sharpe) and DeFi (impermanent loss, perp liquidation, funding, Uniswap v3, health factor, cost basis). Exact, model-free arithmetic that LLMs get wrong — priced per call in USDC.","url":"https://finmath.qzqh5rrbkz.workers.dev/v1/text_stats?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","required":["text"],"properties":{"text":{"type":"string","description":"text"}}},"responseSchema":{"type":"object","required":["result","meta"],"properties":{"meta":{"type":"object"},"result":{}}},"example":{"request":{"text":"The quick brown fox jumps over the lazy dog. Pack my box with five dozen liquor jugs."},"response":{"meta":{"tool":"text_stats","disclaimer":"Deterministic calculation utility. Not financial, investment, or trading advice.","deterministic":true},"result":{"lines":1,"words":17,"sentences":2,"characters":85,"token_estimate":22,"characters_no_spaces":69}}},"exampleRequest":{"text":"The quick brown fox jumps over the lazy dog. Pack my box with five dozen liquor jugs."},"tags":["x402"],"displayCostAmount":"0.001","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"settled","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.001/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_luic-ula7YKzzxrOgOkBy","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.001","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Computes text statistics for a given string using the finmath deterministic computation service","exampleAgentPrompt":"Can you run text stats on this passage: 'The quick brown fox jumps over the lazy dog. Pack my box with five dozen liquor jugs.' — I want to know things like word count and character count.","exampleUseCases":null,"resultDescription":"Returns a result object with computed text statistics (such as word count, character count, or other string metrics) plus a meta object with call metadata.","failureModes":["Missing required 'text' field returns validation error","Empty string may return zero-value stats or an error","Payment not included or insufficient USDC returns 402 Payment Required","Extremely long text strings may be rejected or time out","Malformed JSON body returns 400 error"],"whenToPreferThis":"Use this endpoint when you need deterministic, exact text statistics computed server-side rather than relying on an LLM's approximate counting. Useful when you need reliable word or character counts for billing, truncation, or validation purposes and want a paid-per-call microservice with x402 USDC payment.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-12T00:40:08.522Z","isFirstParty":false,"canonicalSlug":"finmath-text-stats-d0710ba2"}