svir 0.1.6

A small, composable SDK for talking to large language models
Documentation
{
  "description": "The model refuses, in the refusal field rather than the content: the refusal is the answer's text, and the finish is refusal, not the stop on the wire.",
  "chunks": [
    "data: {\"id\":\"c\",\"model\":\"m\",\"choices\":[{\"index\":0,\"delta\":{\"role\":\"assistant\",\"content\":null,\"refusal\":\"\"},\"finish_reason\":null}]}\n\n",
    "data: {\"id\":\"c\",\"model\":\"m\",\"choices\":[{\"index\":0,\"delta\":{\"refusal\":\"I'm sorry, \"},\"finish_reason\":null}]}\n\n",
    "data: {\"id\":\"c\",\"model\":\"m\",\"choices\":[{\"index\":0,\"delta\":{\"refusal\":\"I can't help with that.\"},\"finish_reason\":null}]}\n\n",
    "data: {\"id\":\"c\",\"model\":\"m\",\"choices\":[{\"index\":0,\"delta\":{},\"finish_reason\":\"stop\"}]}\n\n",
    "data: {\"id\":\"c\",\"model\":\"m\",\"choices\":[],\"usage\":{\"prompt_tokens\":20,\"completion_tokens\":9,\"total_tokens\":29}}\n\n",
    "data: [DONE]\n\n"
  ],
  "strides": [1, 3, 8192],
  "expect": {
    "strict": {
      "completion": {
        "finish": "refusal",
        "text": "I'm sorry, I can't help with that.",
        "usage": {"input": 20, "output": 9, "total": 29}
      }
    },
    "lenient": "same"
  }
}