{"uid":"cap_FPplpi1m4mxB35sjUMhgc","slug":"writerslogic-lossy-conversion-identifier-mangling-detector-5d02eb8f","name":"WritersLogic Lossy Conversion & Identifier Mangling Detector","description":"Pay-per-call agents settled in USDC on Base via x402. Every response carries a signed provenance envelope.","url":"https://agents.writerslogic.com/api/v1/lossy-conversion?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"pairs":{"type":"array","items":{"type":"object","required":["before","after"],"properties":{"after":{"type":"string","maxLength":400},"before":{"type":"string","maxLength":400}},"additionalProperties":false},"maxItems":200,"description":"Identifier or text values before and after a round trip through another system."},"samples":{"type":"array","items":{"type":"string","maxLength":400},"maxItems":200,"description":"Raw JSON scalar literals exactly as written, e.g. 9007199254740993, \"007\", 1e400, 0.10, null."},"targets":{"type":"array","items":{"type":"string","maxLength":40},"maxItems":12,"description":"Target types: float64, float32, int8, int16, int32, int64, uint8, uint16, uint32, uint64, numeric(p,s), decimal128(p,s), decimal256(p,s), parquet-decimal(p,s), excel-number, pandas-int64."}}},"responseSchema":{"type":"json"},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.005","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","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.005/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_JIqyL3jtYEwTa-Yy7pEOH","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.005","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Analyzes JSON scalar literals against target numeric/decimal types to report exact, lossy, or overflow status, and diagnoses identifier mangling between before/after string pairs","exampleAgentPrompt":"Check whether the JSON literals 9007199254740993, 0.10, and \"007\" are exact or lossy when stored as float64, int32, and excel-number — and tell me what value each target would actually hold.","exampleUseCases":[{"title":"ETL pipeline numeric precision audit","prompt":"I'm moving data from a JSON API into PostgreSQL and pandas. Can you check if these JSON numbers — 9007199254740993, 1e400, 0.10, and -0 — will be stored exactly or with loss in float64, int64, and numeric(12,4)?"},{"title":"Excel round-trip identifier mangling check","prompt":"After exporting through Excel, my identifier '007' became '7' and '1E+15' appeared instead of '100000000000000'. Can you diagnose what mangling happened to each of those before/after pairs?"},{"title":"Arrow decimal schema fit check","prompt":"Before I write my Parquet file, check if the values 123456789.9999999 and 0.001 will fit exactly in decimal128(18,7) and parquet-decimal(10,3), or if they'll be rounded or overflow."}],"resultDescription":"For each (sample, target) pair: a status of exact, lossy, or overflow; the rule explaining why; and the actual value the target system would hold. For identifier pairs: a named diagnosis of what transformation occurred (e.g. leading zeros stripped, date coercion, 15-digit rounding, NFC normalization, scientific notation, trimming, truncation).","failureModes":["Invalid JSON literal syntax in samples array returns a parse error for that item","Unknown or malformed target type string returns an error for that pair","Samples or targets arrays exceeding max length (200/12) are rejected","Pairs array exceeding 200 items is rejected","Malformed before/after pair objects (missing required fields) return validation errors"],"whenToPreferThis":"Use this endpoint when an AI agent needs to verify data fidelity before moving JSON values across type boundaries — specifically into float64/float32, integer types, PostgreSQL numeric, Arrow/Parquet decimals, Excel cells, or pandas int64 — without actually performing the conversion. Also ideal for diagnosing why identifiers or strings changed after a round trip through a spreadsheet or database system. Prefer this over generic type-checking when you need the precise rule that caused lossiness, the exact value the target would hold, or a named diagnosis of string mangling.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-11-19T06:36:58.421Z","isFirstParty":false,"canonicalSlug":"writerslogic-lossy-conversion-identifier-mangling-detector-5d02eb8f"}