{"uid":"cap_cot-CgwPNlieveC2CBk0F","slug":"anicca-context-compressor-a92ef173","name":"Anicca Context Compressor","description":"Context compressor for AI agents","url":"https://x402-agents-production.up.railway.app/context-compressor","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"mode":{"enum":["summary","facts","episodes"],"type":"string","default":"summary"},"text":{"type":"string","maxLength":50000,"minLength":1,"description":"Context to compress."},"language":{"enum":["en","ja"],"type":"string","default":"en","description":"Output language."},"target_tokens":{"type":"integer","default":500,"maximum":2000,"minimum":100}}},"responseSchema":{"type":"json","example":{"mode":"facts","compressed":"- Launch moved to Friday.\n- Alice owns the final checklist.","safe_t_flag":false,"key_entities":["Alice","Friday"],"compressor_id":"cmp_a1b2c3d4","original_chars":84,"compressed_chars":66,"compression_ratio":1.27}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.008","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.008/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.008","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.008","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_A3WTF9vpE2YQ6v3wVOYxQ","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.008","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Compresses long text into a token-limited summary, fact list, or episode sequence, returning key entities and compression stats, settled in USDC via x402.","exampleAgentPrompt":"Compress the following meeting transcript into a facts-mode bullet list with a target of 300 tokens in English — I need the key entities and a compression ratio too: [paste transcript here].","exampleUseCases":[{"title":"Shrinking context before chained LLM call","prompt":"I have a 40,000-character research document that I need to feed into a second AI step — can you compress it into a 500-token summary in English so it fits in the prompt window?"},{"title":"Extracting bullet facts from meeting notes","prompt":"Take these meeting notes and compress them into facts mode targeting 200 tokens in English — I want a clean bullet list and to know which key people and dates were mentioned."},{"title":"Condensing Japanese support log for triage","prompt":"Here's a long Japanese customer support log — compress it into episodes mode, targeting 400 tokens in Japanese, so our triage agent can quickly understand what happened."}],"resultDescription":"Returns a JSON object with the compressed text string (in the chosen mode: summary, facts, or episodes), a list of key entities found in the original, original and compressed character counts, compression ratio, a safe_t_flag boolean, and a unique compressor_id for traceability.","failureModes":["text field empty or missing — validation error returned","text exceeds 50,000 character limit — request rejected","target_tokens outside 100–2000 range — validation error","unsupported language code — enum validation failure","payment not settled via x402 — 402 Payment Required response","service unavailable on Railway — 5xx error"],"whenToPreferThis":"Choose this endpoint when an AI agent needs to reduce a large text blob to fit within a prompt budget or downstream token limit, especially when structured output modes (summary, facts, or episodes) and entity extraction are needed simultaneously. Prefer it over generic summarization when you need deterministic token targeting, compression ratio telemetry, and micropayment-based per-call billing via x402/USDC with no subscription overhead.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-13T18:35:25.298Z","isFirstParty":false}