Skip to content

armgit / ruflo

Public Imported from GitHub
0

🌊 The original agent harness. Deploy intelligent multi-player swarms, coordinate autonomous workflows, and build conversational AI systems. Features adaptive memory, self-learning intelligence, federation, vector RAG integration, and native Claude Code / Codex / Hermes and many more Integrated

feat(ruflo-console): switch harness from the terminal field (/codex /claude /swarm /ruflo); tour GIF

ruva967f153968e
diff --git a/docs/assets/ruflo-console-tour.gif b/docs/assets/ruflo-console-tour.gif
index b1c985f1d2..4a5cd3ffbe 100644
Binary files a/docs/assets/ruflo-console-tour.gif and b/docs/assets/ruflo-console-tour.gif differ
diff --git a/plugins/ruflo-console/hooks/bindings.ts b/plugins/ruflo-console/hooks/bindings.ts
index 72b50b5253..6530018b78 100644
--- a/plugins/ruflo-console/hooks/bindings.ts
+++ b/plugins/ruflo-console/hooks/bindings.ts
@@ -4,7 +4,7 @@
*/
import { claimTask, handoffClaim, releaseClaim, stealClaim, whyNot } from './actions'
import { EVENT_KINDS } from './data/events'
-import { harnessSpec, isLive, newSession, send, whyNotRun } from './harness'
+import { HARNESSES, harnessSpec, isLive, newSession, send, whyNotRun } from './harness'
import { plain } from './data/parse'
import type { Host } from './host'
import { filterPalette, paletteEntries } from './palette'
@@ -148,6 +148,20 @@ export function actionsOf(state: State, host: Host, runner: Runner, steps: Steps
return
}
+ // /codex /claude /swarm /ruflo switch harness from the field, which holds the keys (its hotkeys would type).
+ const pick = HARNESSES.find(entry => text.trim() === `/${entry.id}`)
+
+ if (pick !== undefined) {
+ state.terminal.draft = ''
+ state.terminal.harness = pick.id
+ // An ask the previous harness left on screen goes with it.
+ if (state.terminal.asked !== null && state.pending?.label === state.terminal.asked.label) runner.cancel()
+ state.terminal.asked = null
+ host.invalidate()
+
+ return
+ }
+
if (isLive(state)) {
const why = whyNotRun(state, text)
diff --git a/plugins/ruflo-console/hooks/commands.ts b/plugins/ruflo-console/hooks/commands.ts
index 489d553490..0485cae74a 100644
--- a/plugins/ruflo-console/hooks/commands.ts
+++ b/plugins/ruflo-console/hooks/commands.ts
@@ -106,7 +106,7 @@ export const HELP = [
'',
'Pane keys (while it holds the keyboard: /ruflo opens it with the keys, or click it; ctrl+x tab reaches the band, not the pane)',
' 0 main menu · 1-9 views · g timeline · q approvals · e events · m missions · w x.ruv.io · i terminal · p palette · x actions for the selection',
- ' terminal: c codex · l claude · v swarm (both) · u ruflo · sessions remember the conversation per project; the first message asks, then Enter sends · /new or o new session · s stop · z clear',
+ ' terminal: the field takes the keys; /codex /claude /swarm /ruflo switch harness, /new starts over · sessions remember the conversation per project; the first message asks, then Enter sends · Tab to s stop, o new, z clear',
' j/k select · d drill in · b back · r refresh · h help · f event filter · y/n confirm',
' Esc: a pane /ruflo opened closes; one that opened by itself (panel=auto) only hands the keys back. ✕ or /ruflo close closes either',
' (? and Enter cannot be pane hotkeys in this Claude Code build: use h, and d to drill in)',
diff --git a/plugins/ruflo-console/hooks/views/terminal.ts b/plugins/ruflo-console/hooks/views/terminal.ts
index 8c5f4493ce..8bdc4cf1be 100644
--- a/plugins/ruflo-console/hooks/views/terminal.ts
+++ b/plugins/ruflo-console/hooks/views/terminal.ts
@@ -121,7 +121,7 @@ export function terminalView(ctx: Ctx): RenderElement {
...(term.runs.size > 0 ? [button(ctx, 'term-stop', 'Stop', ctx.act.term.stop, { hotkey: 's' })] : []),
...(harness.id !== 'ruflo' ? [button(ctx, 'term-new', 'New session', ctx.act.term.fresh, { hotkey: 'o' })] : []),
button(ctx, 'term-clear', 'Clear', ctx.act.term.clear, { hotkey: 'z' }),
- text(ctx, isLive(state) ? ' live: Enter sends' : ' Enter shows the command · Enter again runs it', { dimColor: true }),
+ text(ctx, isLive(state) ? ' live: Enter sends · /codex /claude /swarm /ruflo switch · /new' : ' Enter shows the command, Enter again runs it · /codex /claude /swarm /ruflo switch', { dimColor: true }),
]),
)