Repository navigation
feat(serve): server sessions get the default prompt and review guidance - #960
Merged
Merged
Conversation
A session from tole serve, tole acp or the MCP-over-HTTP host with no explicit prompt now pins the shared default prompt (workspace in its context line, plan mode sentence, review guidance when both cora review tools are present). Resume keeps the header-pinned prompt. docs/faces.md and face_parity compare the text. Refs #945, #941.
🔍 Cora AI Code Review✅ No issues found. Code looks good! Review powered by cora-code · BYOK · MIT |
This was referenced Nov 19, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Capability 1 of #945 (step 4 of #941): a session created by
tole serve,tole acpor the MCP-over-HTTP host now gets the same default tool-discipline prompt and cora review guidance as the CLI, when no explicit prompt is set.Why
Those sessions built their system prompt from a profile persona,
TOLE_SYSTEM_PROMPTor a trusted config only, so with none of them the agent had no system prompt at all and behaved differently fromtole chatin the same repository. This finishes #536 for the server faces.Changes
session/assemble.rs:build_default_prompt_in(plan_mode, workspace)(the context line names the given workspace;build_default_promptis unchanged for the CLI and delegates to the same code) andserver_session_prompt(explicit, plan_mode, workspace, registry): an explicit prompt wins as--systemdoes, else the shared default; the review section is appended only when both cora review tools are in the registry.session/host.rs(open_session_with): a new session pins that prompt in its header, with the SESSION workspace in the context line (not the process cwd). A resumed session keeps its header-pinned prompt unless an explicit prompt applies (a profile chosen on resume still takes over, as before); a session created before this change has none pinned and does not gain one.docs/faces.md: the(system prompt)row of the machine-checked table is gone; the default prompt and review guidance rows of the capability matrix are now shared. Skills, routing and MCP clients are unchanged.tests/face_parity.rs: the prompt comparison is on the prompt text (modulo the context line), not on presence.Testing
face_paritypasses, and fails with(system prompt) differs between faces ... no rowwhen a difference is reintroduced (checked with a temporary mutation, reverted).assemble_goldenpasses unchanged.cargo fmt, clippy-D warningsin the default,--no-default-featuresand--no-default-features --features shell-toolsprofiles, andcargo test -p tole-cliin full.