Repository navigation
fix(workflows): set a node's system prompt in Settings (#1393) - #1400
Merged
Merged
Conversation
Settings → Workflows could draw the graph but not set a node's system prompt, while the sidebar Workflow panel and `define_workflow` both could. Edit mode now renders a system-prompt field per node, pre-filled with the saved prompt, and saves it through the same `workflow/graph` call, so the prompt a run Bot receives is configurable where the graph is drawn. Docs: docs/subsystems/core-client.md gains the field in the Workflows paragraph.
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.
Owner: Dev
Reviewer: Reviewer
Written-by: Dev
Fixes #1393
What changed
Settings → Workflows could draw the graph but not set a node's system prompt, so a run Bot's prompt was configurable only from the sidebar Workflow panel or
define_workflowin a chat — althoughplugins/workflow/README.mdsays both surfaces edit the graph, prompt included. Edit mode now renders aSystem promptfield per node, pre-filled with the saved prompt; committing it saves the same graph throughworkflow/graph, so the prompt a node's run Bot receives can be typed where the graph is drawn.changelog.d/1393-workflow-settings-prompt.fixed.mdis the user-visible note.Verification at the tip
Tip SHA: 0cbf18f
Ran:
cd core && DSH_HARNESS=/data/har020 TZ=UTC node --import ./test/harness-resolve.mjs --test test/workflows-page.test.js→ 8/8 pass; the new case isedit mode sets a node system prompt and the commit keeps the edges.core/src/client/workflows.jstomainand re-ran that file → 7 pass / 1 fail, and the red one is exactly the new case.test/workflows-page.test.js test/settings-page-slot.test.js→ 14/14 pass;test/workflow.test.js test/workflow-run.test.js test/workflow-store.test.js test/workflow-preview.test.js test/workflow-doc.test.js test/workflow-repo-dev.test.js→ 64/64 pass.cd plugins/workflow && node --test test/*.test.js→ 27/27 pass.node core/scripts/build-client.mjs --check→ exit 0.node scripts/ds-bot-patches.mjs check→ok ds-bot/ = Fei2411/DeepSeek-Bot@2b10c70 (tree 5834c00, v0.1.5),ok 10 patches apply cleanly in order,ok core/ equals ds-bot/ + patches/ds-bot/.node core/scripts/check-arch-docs.mjs→OK (12 changed file(s)).Not run (and why): the full
coresuite cannot run in this sandbox — it dies onesbuild … EAGAIN, a missingjsdom, and a missing@deepseek-ai/dsh-session-referencepackage in the harness, before any file of this change loads; oxlint is not installed here (lint: no oxlint found). CI runs both.Checkpoint
{ "pr": 1400, "claim": "Dev", "issue": 1393, "summary": "Settings → Workflows now sets each node's system prompt. The field is pre-filled from the saved graph and commits through workflow/graph, the call the sidebar panel already uses, so a node's run Bot receives the prompt typed where the graph is drawn. A test pins the field, its saved value, that an untouched field commits nothing, and that a commit keeps the edges.", "files": ["core/src/client/workflows.js", "core/src/client/styles.js", "core/src/client/i18n.js", "core/test/workflows-page.test.js", "docs/subsystems/core-client.md", "changelog.d/1393-workflow-settings-prompt.fixed.md"], "checks": { "ran": "node scripts/ds-bot-patches.mjs check; core/test/workflows-page.test.js; plugins/workflow", "result": "green", "at": "0cbf18f7187c1ca52a45e01d57c3a8bbfe69016b" }, "next": "none — ready for review" }