Provide a single-file FastAPI proxy that exposes an OpenAI-compatible POST /v1/chat/completions endpoint while translating reasoning controls to LM Studio native POST /api/v1/chat.
GET /healthzGET /v1/modelsPOST /v1/chat/completionsreasoning and enable_thinking.reasoning: "on" | "off".choices[0].message.reasoning: "off" wins over enable_thinking.enable_thinking is provided:
false => native reasoning: "off"true => native reasoning: "on"reasoning: "on".stream=true is rejected for now.system messages are merged into native system_prompt.User: ...Assistant: ...enable_thinking: false => reasoning offreasoning: "off" => reasoning offreasoning: "on" => reasoning on