diff options
Diffstat (limited to 'README.md')
| -rw-r--r-- | README.md | 28 |
1 files changed, 27 insertions, 1 deletions
@@ -288,7 +288,9 @@ there is no second thread. ```sql sessions (id, mode, title, model, prompt_name, prompt_custom, created_at, updated_at) -messages (id, session_id, role, content, reasoning, searches, created_at) +messages (id, session_id, role, content, reasoning, searches, + prompt_tokens, completion_tokens, model, provider, usage_json, + reported_cost_usd, created_at) attachments (id, message_id, path, kind, mime, size, sha256, thumb, truncated) messages_fts -- FTS5 external-content table over messages.content ``` @@ -307,6 +309,19 @@ per search with its query, results and any error, or NULL when nothing was searched. Like `reasoning` it stays out of the FTS index, or snippets from web pages would compete with messages the user actually wrote. +`provider` records which provider served the reply (`local` or a configured +provider name), written when the reply finishes so history stays +self-describing even if `config.toml` later renames or drops the provider. +`usage_json` keeps every round's raw usage block from the stream as a JSON +array — a searched turn makes one API call per search round, and each round +is billed separately, so all of them are kept verbatim and token details +beyond the two counts (e.g. cached or reasoning tokens on a cloud endpoint) +are recoverable later without re-guessing a field mapping. +`reported_cost_usd` is the GUI's hand-entered-price estimate for that one +reply (summed across rounds), stored as a sanity check for external +consumers — it is approximate and never a source of truth; it stays NULL for +a model with no entered prices rather than claiming the reply cost nothing. + `prompt_name` records which system prompt a conversation was built with, and `prompt_custom` holds the text when that prompt is a one-off rather than a file. Storing the name rather than the resolved text means editing a preset @@ -463,6 +478,8 @@ filter = ["qwen", "deepseek"] ctx_size = 32768 price_in = 0.60 price_out = 0.60 +# thinking_budget = 8192 # per-provider chain-of-thought cap +# replay_reasoning = false # see below ``` `api_key` accepts three forms: @@ -499,6 +516,15 @@ local router, but on a cloud provider every message is billed for the entire conversation so far. The projection in the cost label exists to make that visible before you send. +`thinking_budget` sets a provider-specific cap on chain-of-thought tokens +(currently sent to SiliconFlow; other endpoints ignore it when unset). + +`replay_reasoning` makes each assistant turn's thinking be sent back on the +next request while web search is enabled. DeepSeek's and SiliconFlow's +interleaved-thinking models require this when a `tools` key is present, and +return a 400 if it is missing. Leave it off elsewhere — replaying thinking +costs context and input tokens for providers that ignore it. + Tool calling and reasoning output vary between providers. Web search on a cloud model may not work as reliably as it does with a local router. |
