{"name":"Kreatix D1 API","version":"1.0.0","base_url":"https://d1.kreatix.dev","authentication":"none","openapi":"https://d1.kreatix.dev/openapi.json","model":{"id":"LiquidAI/d1-3B","card":"https://huggingface.co/LiquidAI/d1-3B","license":"Liquid LFM Open License v1.0","license_url":"https://huggingface.co/LiquidAI/d1-3B/blob/main/LICENSE","runtime":"llama.cpp with ARM KleidiAI kernels, local CPU inference in Frankfurt","quantization":"Q8_0","finnish":"Accepted as text, but not an officially listed language. Quality is experimental."},"scope":"Text and JSON typed decisions only. No images, files, generated explanations or chat completions.","limits":{"requests_per_minute_per_ip":10,"burst":2,"body_bytes":16384,"state_characters":4000,"input_tokens":1024,"questions":4,"choice_options":16,"score_levels":10,"total_options":32,"instructions_characters":512,"option_description_characters":256,"concurrent_inference":1,"token_accounting":"Serialized state and questions, using the model tokenizer. Actual prompt usage includes the internal template.","availability":"Free shared capacity, no SLA. Busy requests are rejected, not queued."},"endpoints":{"GET /":"These JSON docs","GET /docs":"These JSON docs","GET /openapi.json":"OpenAPI 3.1 request and response schemas","GET /health":"Readiness and busy status; 503 if unavailable","GET /v1/models":"Available model","POST /v1/systemone":"Answer named typed questions; Content-Type: application/json"},"request":{"state":"Non-empty string, JSON object or array. JSON is serialized into text.","questions":"Map of 1–4 named questions. Names: 1–64 letters, digits, underscores or hyphens.","types":{"choice":"criteria maps 2–16 option keys to descriptions or null. Returns winning key, per-option probabilities and confidence.","noul":"Returns the probability of yes, from 0 to 1. No criteria required; optional criteria must describe both true and false.","score":"criteria is 2–10 ordered labels, lowest first. Returns a probability-weighted zero-based score, legend, probabilities and confidence."}},"example_request":{"state":"I was charged twice. Please refund the duplicate payment.","questions":{"team":{"type":"choice","instructions":"Which team should handle this?","criteria":{"billing":"Payments and refunds","technical":"App crashes"}},"refund":{"type":"noul","instructions":"Is the customer requesting a refund?"},"urgency":{"type":"score","instructions":"How urgent is this?","criteria":["Can wait","Today","Blocking now"]}}},"example_response":{"model":"LiquidAI/d1-3B","answers":{"team":{"type":"choice","choice":"billing","probabilities":{"billing":0.96,"technical":0.04},"confidence":0.92},"refund":{"type":"noul","noul":0.97},"urgency":{"type":"score","score":1.05,"legend":{"0":"Can wait","1":"Today","2":"Blocking now"},"probabilities":{"0":0.05,"1":0.85,"2":0.1},"confidence":0.78}},"usage":{"input_tokens":183,"output_tokens":0},"latency_ms":650.0,"request_id":"unique-request-id"},"response_notes":{"examples":"Response values above are illustrative, not measured benchmarks.","probabilities":"Not calibrated correctness guarantees. Validate thresholds on your own labeled data.","latency_ms":"Upstream decision call only; excludes validation, token counting and network travel.","output_tokens":"Always zero; answers come from model probabilities rather than generated text."},"performance":{"hardware":"2 ARM Neoverse-N1 cores, 12 GB RAM, no GPU","measurement":"8 English/Finnish smoke-test requests, each containing one choice and one yes/no question, alternating baseline and optimized runtimes. Model load time excluded.","q8_median_ms":2066.75,"q8_max_ms":2713.2,"baseline_q8_median_ms":4026.15,"baseline_q8_max_ms":5249.9,"q4_median_ms":5610.8,"q4_measurement":"Earlier baseline runtime, without KleidiAI. Optimized Q4 not benchmarked.","optimization":"ARM KleidiAI kernels; same LiquidAI/d1-3B Q8_0 model file.","prediction_consistency":"All 18 choice/yes-no labels matched the baseline across 9 requests. One additional score request checked. Probabilities changed by up to 0.0544; this is not a guarantee for other inputs.","runtime_memory_gb_approx":3.0,"quality_smoke_test":{"english":"8/8 typed answers matched expected labels","finnish":"5/8 typed answers matched expected labels"},"caveat":"Tiny hand-written smoke test, not a general accuracy evaluation. Larger inputs take longer. This CPU service is not millisecond inference.","recommended_client_timeout_seconds":100},"errors":{"format":{"error":{"code":"model_busy","message":"Shared model is busy. Retry in a few seconds."}},"413":"Body exceeds 16 KiB","415":"JSON Content-Type required","422":"Invalid JSON, schema or token budget","429":"IP rate limit; respect Retry-After","503":"Model busy or unavailable; retry later with jitter"},"privacy":"No request or response bodies are stored by this service. Inference is local. Temporary per-IP rate counters are held in memory. Cloudflare processes HTTPS and has its own edge logging policies. Do not send secrets or confidential data.","curl":"curl https://d1.kreatix.dev/v1/systemone -H 'Content-Type: application/json' -d '{\"state\":\"I was charged twice. Please refund the duplicate payment.\",\"questions\":{\"team\":{\"type\":\"choice\",\"instructions\":\"Which team should handle this?\",\"criteria\":{\"billing\":\"Payments and refunds\",\"technical\":\"App crashes\"}},\"refund\":{\"type\":\"noul\",\"instructions\":\"Is the customer requesting a refund?\"},\"urgency\":{\"type\":\"score\",\"instructions\":\"How urgent is this?\",\"criteria\":[\"Can wait\",\"Today\",\"Blocking now\"]}}}'"}