From b24f6d645b61713331470e46cfde5c7b87383944 Mon Sep 17 00:00:00 2001 From: Tim Lingo <1timlingo@gmail.com> Date: Tue, 30 Jun 2026 19:13:10 -0500 Subject: [PATCH] =?UTF-8?q?soul:=20let=20Neuron=20answer=20'what=20model?= =?UTF-8?q?=20am=20I=20running=20on=3F'=20=E2=80=94=20inject=20current=20e?= =?UTF-8?q?ngine=20into=20system=20prompt?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Additive: appends a factual [CURRENT ENGINE: ] line to the system prompt (model from the request body — accurate even under Auto routing; falls back to configured default). An LLM can't know its own model from training (name/version assigned post-training), so the harness must tell it. Identity-consistent: model = engine, self layered on top. Does NOT alter identity/values/safety. PARSES (elc chat.el exit 0); NOT built/tested — ships with the soul rebuild. Co-Authored-By: Claude Opus 4.8 (1M context) --- chat.el | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/chat.el b/chat.el index 0e0bf4d..489ef62 100644 --- a/chat.el +++ b/chat.el @@ -602,6 +602,21 @@ fn json_safe(s: String) -> String { return s4 } +// current_engine_note — a short, FACTUAL line appended to the system prompt so Neuron can answer +// "what model/LLM are you running on?" truthfully. An LLM cannot know its own model from training +// (the name/version is assigned AFTER training finishes), so the harness must tell it. This is +// identity-consistent: the model is the ENGINE; the self (identity, values, memory) is layered on +// top. ADDITIVE — it adds a fact, it does not alter identity, values, or the safety layer. +fn current_engine_note(model: String) -> String { + if str_eq(model, "") { + return "" + } + return "\n\n[CURRENT ENGINE: this turn is generated by the underlying model \"" + model + + "\". It is the engine beneath your self — your identity, values, and memory are layered on" + + " top of it. If the user asks which model or LLM you are running on, answer with this model" + + " id plainly and truthfully; never guess a different one.]" +} + // build_system_prompt — assemble the system prompt for a chat turn. // chat_mode: Bool — pass true from handle_chat (no tools), false from agentic paths. // Issue #9 fix: no_tools_rule only included when chat_mode=true. @@ -959,7 +974,12 @@ fn handle_chat(body: String) -> String { } let ctx: String = engram_compile(activation_seed) - let system: String = affective_prefix + build_system_prompt(ctx, true) + // Tell the LLM which engine it is running on this turn, so it can answer truthfully instead of + // guessing. The per-turn model rides in the request body (concrete even under Auto routing); + // fall back to the configured default when blank. + let sp_req_model: String = json_get(body, "model") + let sp_model: String = if str_eq(sp_req_model, "") { chat_default_model() } else { sp_req_model } + let system: String = affective_prefix + build_system_prompt(ctx, true) + current_engine_note(sp_model) let seen_ids: String = state_get("engram_compile_seen_ids")