Run a local model behind an OpenAI-compatible endpoint on your machine.
xynthis-llm-serve runs a language model on your machine and exposes it through an OpenAI-compatible HTTP API at http://127.0.0.1:8080/v1. Anything that speaks the OpenAI API (an SDK, an editor integration, curl) can use it by changing one base URL. Nothing leaves your machine.
xynthis-llm-serve# xynthis-llm-serve listening on http://127.0.0.1:8080/v1
The first run downloads the model weights (roughly 1-3 GB depending on the backbone) from Hugging Face and caches them. Later starts load from the cache.
Streaming follows the OpenAI convention: one SSE chunk per token delta, then a finish chunk, then data: [DONE].When the request omits them, temperature defaults to 0.7, top_p to 0.9, and max_tokens to 256. The usage block in responses is an estimate (character count divided by 4), not a true token count; tokenize client-side if you need exact numbers.
Requests are stateless by default: every call re-processes the full message history. To skip that work across the turns of one conversation, send a stable session_id with each request:
The server keeps the attention KV cache from the end of each turn, keyed by session_id. When the next request’s prompt extends the previous turn (the normal append-a-message chat pattern), generation resumes from the cache instead of re-reading the whole history. If the prompt diverges (edited history, different system message), the server detects it and starts fresh, so reuse never changes outputs. Sessions idle for 30 minutes are evicted; the sweep runs every 5 minutes.
The server has no authentication. Keep the default loopback bind unless you are putting it behind something. Set XYNTHIS_LLM_BIND=0.0.0.0 only behind a tunnel or VPN, never on an open network.
By default the endpoint serves the base backbone weights. The server can also learn from your data over time (see Training), and with XYNTHIS_JSPACE=1 it reports the concepts the model weighed while generating (see Workspace readouts).
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Xynthis","colors":{"primary":"#56C8DA","light":"#7FD8E6","dark":"#1A8FA2"},"logo":{"light":"https://mintcdn.com/xynthis/fFr-ztX4EjXZXM_Y/logo/light.svg?fit=max\u0026auto=format\u0026n=fFr-ztX4EjXZXM_Y\u0026q=85\u0026s=b9a6e0bf28f18817d704cbca6371eaa2","dark":"https://mintcdn.com/xynthis/fFr-ztX4EjXZXM_Y/logo/dark.svg?fit=max\u0026auto=format\u0026n=fFr-ztX4EjXZXM_Y\u0026q=85\u0026s=0d17c0658f164135a41bc823a8978cff"},"favicon":"https://mintcdn.com/xynthis/fFr-ztX4EjXZXM_Y/favicon.svg?fit=max\u0026auto=format\u0026n=fFr-ztX4EjXZXM_Y\u0026q=85\u0026s=ae87851d708d83fd27bebc167ddd80fe","navbar":{"primary":{"type":"button","label":"Get Xynthis","href":"https://xynthis.com"}},"footer":{"socials":{"github":"https://github.com/Xynthis","website":"https://xynthis.com"}},"contextual":{"options":["copy","view","claude","cursor","vscode","mcp"],"display":"header"},"styling":{"latex":true},"navigation":{"global":{"anchors":[{"anchor":"Website","icon":"globe","href":"https://xynthis.com"},{"anchor":"GitHub","icon":"github","href":"https://github.com/Xynthis"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"xynthis","hasAudioNarration":false,"actualSubdomain":"xynthis","customDomains":["docs.xynthis.com"],"gitSource":{"type":"github","owner":"xynthis","repo":"xynthis-doc","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"entitlements":{"AI_CHAT":{"status":"DISABLED"}},"buildId":"6ac889cca607de1201438609","clientVersion":"0.0.4087","searchFilterCounts":[{"language":"default","tag":"Guides","count":9},{"language":"default","tag":"Getting started","count":6},{"language":"default","tag":"Core concepts","count":5},{"language":"default","tag":"Reference","count":4},{"language":"default","tag":"On-device model","count":3}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"comment-mode","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"llm/overview","slug":"/llm/overview","pageMetadata":{"title":"Model server","description":"Run a local model behind an OpenAI-compatible endpoint on your machine.","href":"/llm/overview"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Run a local model behind an OpenAI-compatible endpoint on your machine.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,p:`p`,pre:`pre`,span:`span`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,..._provideComponents(),...props.components},{CodeBlock,Heading,Table,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsxs(_components.p,{children:[_jsx(_components.code,{children:`xynthis-llm-serve`}),` runs a language model on your machine and exposes it through an OpenAI-compatible HTTP API at `,_jsx(_components.code,{children:`http://127.0.0.1:8080/v1`}),`. Anything that speaks the OpenAI API (an SDK, an editor integration, `,_jsx(_components.code,{children:`curl`}),`) can use it by changing one base URL. Nothing leaves your machine.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`2`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`xynthis-llm-serve`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# xynthis-llm-serve listening on http://127.0.0.1:8080/v1`})}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`The first run downloads the model weights (roughly 1-3 GB depending on the backbone) from Hugging Face and caches them. Later starts load from the cache.`}),`\n`,_jsx(Heading,{level:`2`,id:`endpoints`,children:`Endpoints`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Method`}),_jsx(_components.th,{children:`Path`}),_jsx(_components.th,{children:`Purpose`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`POST`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`/v1/chat/completions`})}),_jsxs(_components.td,{children:[`Chat, OpenAI request/response shape. Set `,_jsx(_components.code,{children:`\"stream\": true`}),` for SSE.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`GET`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`/v1/models`})}),_jsxs(_components.td,{children:[`Lists the served model (`,_jsx(_components.code,{children:`xynthis-local`}),` by default).`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`GET`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`/health`})}),_jsxs(_components.td,{children:[`Liveness probe. Returns `,_jsx(_components.code,{children:`ok`}),`.`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`GET`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`/status`})}),_jsx(_components.td,{children:`Model id, which weights are serving, vocab size, whether workspace readouts are on.`})]})]})]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`/chat/completions`}),` and `,_jsx(_components.code,{children:`/models`}),` also work without the `,_jsx(_components.code,{children:`/v1`}),` prefix, for clients that omit it.`]}),`\n`,_jsx(_components.p,{children:`A basic request:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`6`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`6`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` http://127.0.0.1:8080/v1/chat/completions \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` -H `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Content-Type: application/json\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` -d `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'{`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"model\": \"xynthis-local\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"messages\": [{\"role\": \"user\", \"content\": \"Name one color.\"}]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` }'`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`Streaming follows the OpenAI convention: one SSE chunk per token delta, then a finish chunk, then `,_jsx(_components.code,{children:`data: [DONE]`}),`.`]}),`\n`,_jsxs(_components.p,{children:[`When the request omits them, `,_jsx(_components.code,{children:`temperature`}),` defaults to 0.7, `,_jsx(_components.code,{children:`top_p`}),` to 0.9, and `,_jsx(_components.code,{children:`max_tokens`}),` to 256. The `,_jsx(_components.code,{children:`usage`}),` block in responses is an estimate (character count divided by 4), not a true token count; tokenize client-side if you need exact numbers.`]}),`\n`,_jsx(Heading,{level:`2`,id:`backbones`,children:`Backbones`}),`\n`,_jsx(_components.p,{children:`The server loads one backbone model at startup:`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Preset`}),_jsx(_components.th,{children:`Model`}),_jsx(_components.th,{children:`Download`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`Default`}),_jsx(_components.td,{children:`SmolLM2-1.7B-Instruct`}),_jsx(_components.td,{children:`~3.4 GB`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`XYNTHIS_LLM_SMALL=1`})}),_jsx(_components.td,{children:`TinyLlama-1.1B-Chat`}),_jsx(_components.td,{children:`smaller, faster first download`})]})]})]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`XYNTHIS_LLM_SMALL=1 xynthis-llm-serve`})}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`The server holds one model and runs one generation at a time; concurrent requests queue. On Apple Silicon it uses Metal when available, otherwise CPU.`}),`\n`,_jsx(Heading,{level:`2`,id:`sessions-and-kv-cache-reuse`,children:`Sessions and KV-cache reuse`}),`\n`,_jsxs(_components.p,{children:[`Requests are stateless by default: every call re-processes the full message history. To skip that work across the turns of one conversation, send a stable `,_jsx(_components.code,{children:`session_id`}),` with each request:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`5`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`5`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"model\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"xynthis-local\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"messages\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`}),_jsx(_components.span,{style:{color:`#82071E`,\"--shiki-light-font-style\":`italic`,\"--shiki-dark\":`#F44747`,\"--shiki-dark-font-style\":`inherit`},children:`...`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`],`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"session_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"my-conversation-1\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`The server keeps the attention KV cache from the end of each turn, keyed by `,_jsx(_components.code,{children:`session_id`}),`. When the next request’s prompt extends the previous turn (the normal append-a-message chat pattern), generation resumes from the cache instead of re-reading the whole history. If the prompt diverges (edited history, different system message), the server detects it and starts fresh, so reuse never changes outputs. Sessions idle for 30 minutes are evicted; the sweep runs every 5 minutes.`]}),`\n`,_jsx(Heading,{level:`2`,id:`configuration`,children:`Configuration`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Variable`}),_jsx(_components.th,{children:`Default`}),_jsx(_components.th,{children:`Effect`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`XYNTHIS_LLM_PORT`})}),_jsx(_components.td,{\"data-numeric\":`true`,children:_jsx(_components.code,{children:`8080`})}),_jsx(_components.td,{children:`TCP port to listen on.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`XYNTHIS_LLM_BIND`})}),_jsx(_components.td,{\"data-numeric\":`true`,children:_jsx(_components.code,{children:`127.0.0.1`})}),_jsx(_components.td,{children:`Bind address.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`XYNTHIS_LLM_SMALL`})}),_jsx(_components.td,{children:`unset`}),_jsx(_components.td,{children:`Load the TinyLlama backbone instead of SmolLM2.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`XYNTHIS_LLM_MODEL_ID`})}),_jsx(_components.td,{children:_jsx(_components.code,{children:`xynthis-local`})}),_jsxs(_components.td,{children:[`The model id advertised by `,_jsx(_components.code,{children:`/v1/models`}),`.`]})]})]})]}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[`The server has no authentication. Keep the default loopback bind unless you are putting it behind something. Set `,_jsx(_components.code,{children:`XYNTHIS_LLM_BIND=0.0.0.0`}),` only behind a tunnel or VPN, never on an open network.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`what-it-serves`,children:`What it serves`}),`\n`,_jsxs(_components.p,{children:[`By default the endpoint serves the base backbone weights. The server can also learn from your data over time (see `,_jsx(_components.a,{href:`/llm/training`,children:`Training`}),`), and with `,_jsx(_components.code,{children:`XYNTHIS_JSPACE=1`}),` it reports the concepts the model weighed while generating (see `,_jsx(_components.a,{href:`/llm/workspace-readouts`,children:`Workspace readouts`}),`).`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Model server","description":"Run a local model behind an OpenAI-compatible endpoint on your machine.","href":"/llm/overview"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Endpoints","slug":"endpoints","depth":2,"children":[]},{"title":"Backbones","slug":"backbones","depth":2,"children":[]},{"title":"Sessions and KV-cache reuse","slug":"sessions-and-kv-cache-reuse","depth":2,"children":[]},{"title":"Configuration","slug":"configuration","depth":2,"children":[]},{"title":"What it serves","slug":"what-it-serves","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"subdomain":"xynthis","siteName":"Xynthis","title":"Model server - Xynthis","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-07-10T20:51:50.363Z","originalFileLocation":"llm/overview.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Run a local model behind an OpenAI-compatible endpoint on your machine.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Xynthis\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/xynthis/z6DNxgIq0RWmpEfH/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/xynthis/z6DNxgIq0RWmpEfH/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/xynthis/z6DNxgIq0RWmpEfH/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/xynthis/z6DNxgIq0RWmpEfH/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/xynthis/z6DNxgIq0RWmpEfH/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/xynthis/z6DNxgIq0RWmpEfH/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/xynthis/z6DNxgIq0RWmpEfH/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/xynthis/z6DNxgIq0RWmpEfH/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/xynthis/z6DNxgIq0RWmpEfH/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Model server - Xynthis\">\u003cmeta data-mint-head property=\"og:description\" content=\"Run a local model behind an OpenAI-compatible endpoint on your machine.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Xynthis\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.xynthis.com/llm/overview\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://xynthis.mintlify.site/_mintlify/api/og/v2?division=On-device+model\u0026amp;title=Model+server\u0026amp;description=Run+a+local+model+behind+an+OpenAI-compatible+endpoint+on+your+machine.\u0026amp;theme=98a8d65b51ef24ed465e1675\u0026amp;signature=2b945bfc90a1ae5cf941753b9df49f4fb20a9fb35b1a2bd0c7d3e9513c23ca11\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Model server - Xynthis\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Run a local model behind an OpenAI-compatible endpoint on your machine.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://xynthis.mintlify.site/_mintlify/api/og/v2?division=On-device+model\u0026amp;title=Model+server\u0026amp;description=Run+a+local+model+behind+an+OpenAI-compatible+endpoint+on+your+machine.\u0026amp;theme=98a8d65b51ef24ed465e1675\u0026amp;signature=2b945bfc90a1ae5cf941753b9df49f4fb20a9fb35b1a2bd0c7d3e9513c23ca11\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/xynthis/z6DNxgIq0RWmpEfH/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Xynthis\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#56C8DA\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.xynthis.com/llm/overview\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/llm/overview.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.xynthis.com/#organization\",\"name\":\"Xynthis\",\"url\":\"https://docs.xynthis.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/xynthis/fFr-ztX4EjXZXM_Y/logo/light.svg?fit=max\u0026auto=format\u0026n=fFr-ztX4EjXZXM_Y\u0026q=85\u0026s=b9a6e0bf28f18817d704cbca6371eaa2\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.xynthis.com#website\",\"name\":\"Xynthis\",\"url\":\"https://docs.xynthis.com\",\"publisher\":{\"@id\":\"https://docs.xynthis.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.xynthis.com/llm/overview#webpage\",\"url\":\"https://docs.xynthis.com/llm/overview\",\"name\":\"Model server\",\"description\":\"Run a local model behind an OpenAI-compatible endpoint on your machine.\",\"dateModified\":\"2026-07-10T20:51:50.363Z\",\"isPartOf\":{\"@id\":\"https://docs.xynthis.com#website\"},\"breadcrumb\":{\"@id\":\"https://docs.xynthis.com/llm/overview#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.xynthis.com/llm/overview#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Xynthis\",\"item\":\"https://docs.xynthis.com\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Model server\",\"item\":\"https://docs.xynthis.com/llm/overview\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.xynthis.com/llm/overview#article\",\"headline\":\"Model server\",\"name\":\"Model server\",\"description\":\"Run a local model behind an OpenAI-compatible endpoint on your machine.\",\"url\":\"https://docs.xynthis.com/llm/overview\",\"mainEntityOfPage\":{\"@id\":\"https://docs.xynthis.com/llm/overview#webpage\"},\"dateModified\":\"2026-07-10T20:51:50.363Z\",\"publisher\":{\"@id\":\"https://docs.xynthis.com/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.xynthis.com#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Xynthis\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Xynthis","nav":{"global":{"anchors":[{"anchor":"Website","icon":"globe","href":"https://xynthis.com"},{"anchor":"GitHub","icon":"github","href":"https://github.com/Xynthis"}]},"pages":[{"group":"Getting started","pages":[{"title":"What is Xynthis","href":"/index"},{"title":"Why Xynthis exists","href":"/vision"},{"title":"Everything Xynthis does","href":"/features"},{"title":"Quickstart","href":"/quickstart"},{"title":"Installation","href":"/getting-started/installation"},{"title":"The macOS app","href":"/getting-started/mac-app"}]},{"group":"Core concepts","pages":[{"title":"Architecture","href":"/concepts/architecture"},{"title":"Memory","href":"/concepts/memory"},{"title":"Binary Memory Core","href":"/concepts/bmc"},{"title":"Learning","href":"/concepts/learning"},{"title":"Truthful memory","href":"/concepts/truthful-memory"}]},{"group":"Guides","pages":[{"title":"Chatting","href":"/guides/chat"},{"title":"Working with memory","href":"/guides/memory"},{"title":"Model providers","href":"/guides/models"},{"title":"Smart Auto","href":"/guides/auto-mode"},{"title":"Local models","href":"/guides/local-models"},{"title":"Computer use","href":"/guides/computer-use"},{"title":"Watchers","href":"/guides/watchers"},{"title":"Skills","href":"/guides/skills"},{"title":"Codebase memory","description":"Point Xynthis at a repo so recall can answer questions about your code's content and structure.","href":"/guides/codebase-memory"}]},{"group":"On-device model","pages":[{"title":"Model server","href":"/llm/overview"},{"title":"Training","description":"How the local model fine-tunes itself from your brain's data, with eval-gated checkpoints.","href":"/llm/training"},{"title":"Workspace readouts","href":"/llm/workspace-readouts"}]},{"group":"Reference","pages":[{"title":"CLI reference","href":"/reference/cli"},{"title":"HTTP API","href":"/reference/http-api"},{"title":"Configuration","href":"/reference/configuration"},{"title":"MCP integration","href":"/reference/mcp"},{"title":"Licensing","href":"/reference/licensing"}]}]},"basePath":"","title":"Model server - Xynthis","buildId":"dpl_FWZhTb2vab28gFGFH4ojka6qEznQ","deploymentId":"dpl_FWZhTb2vab28gFGFH4ojka6qEznQ","dynamics":[],"chunks":[]}