okami.mom/strata
git clone https://git.nkp.pet/okami.mom/strata
090e45adf
main
1# The Strata profile: DeepSeek Harness as the agent backend for a *local* model. 2# 3# This is a patch layer over the shipped base + web-app bundles (see package.json). It does two 4# things and nothing else: 5# 6# 1. points the agent's model at `strata-local`, the Strata API worker on loopback; 7# 2. declares that route to the pi-ai adapter as an ordinary OpenAI-completions endpoint with 8# explicit capabilities. 9# 10# It deliberately does NOT inherit the shipped web profile's `deepseek-official` default. Local use 11# must not require a DeepSeek account and must never silently fall back to a cloud model, so the 12# default model here is the local one and no cloud route is declared. 13- id : agent-default-model 14name : "@deepseek-ai/dsh-agent-default-model" 15config : 16provider : strata-local 17model : qwen3.8-flash-next 18 19- id : llm-pi-ai 20name : "@deepseek-ai/dsh-llm-pi-ai" 21# NOTE: the schema is `{ providers: { "<route>": <profile> } }` — a dict *keyed by route* under 22# `providers`, not route keys at the top level. A top-level route key is silently ignored and the 23# adapter then never registers, which surfaces much later as 24# `no adapter registered for provider "<route>"`. 25config : 26providers : 27strata-local : 28displayName : Strata (local) 29# An OpenAI-compatible dialect. `supportedProtocols()` in llm-pi-ai is 30# openai-completions | openai-responses | anthropic-messages; the Strata worker implements 31# the documented subsets of all three, and chat completions is the one exercised here. 32api : openai-completions 33baseURL : http://127.0.0.1:8095/v1 34# The Strata worker does not require a key on loopback, but pi-ai's OpenAI-compatible 35# client insists on one before it will send a request at all. Two things were tried and 36# both fail before reaching the worker, which is worth recording: 37# * `apiKeyEnv: <NAME>` with the variable unset -> `no credential for provider route` 38# * naming no credential at all -> `No API key for provider` (PI_AI_ERROR) 39# A literal placeholder satisfies the client. It is NOT a secret, must never be treated as 40# one, and is scoped to loopback by baseURL. If the worker is started with `--api-key`, 41# this must become an `apiKeyEnv` credential reference instead. 42headers : 43Authorization : "Bearer strata-local" 44compat : 45# The worker's Chat Completions implementation is plain OpenAI; disable the provider 46# conveniences pi-ai would otherwise assume. 47supportsStore : false 48models : 49- id : qwen3.8-flash-next 50name : Qwen3.8-Flash-Next (local) 51# These are the *actual* limits the selected local profile reports, not catalog 52# defaults. Setup recommends 32K below 96 GB unified memory and measures to 32K; see 53# docs/MAC.md. Over-claiming here would let the agent build a request the engine 54# refuses mid-turn. 55contextWindow : 32768 56# Sized against the *whole* request, not just the visible prompt: the Harness system 57# prompt plus its tool definitions is already ~29K tokens of the 32K window, so an 8K 58# output budget makes every turn fail with the worker's 59# "request exceeds the context window ... requests are never truncated". 60# The worker will not silently shrink a request, which is correct; the route must 61# declare a budget that fits. The real-machine profile should either raise the engine's 62# context (docs/MAC.md measures to 32K, and the model supports more) or set the engine 63# config's `fit_max_tokens` so the server trims with a label rather than refusing. 64maxTokens : 2048 65input : 66- text