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): 1/3 Claude + 2/3 cockpit tour GIF; RUFLO_CONSOLE_COLUMNS; status row above tall views

ruv589e05881fab
diff --git a/README.md b/README.md
index c8c7226f11..8c5d129d22 100644
--- a/README.md
+++ b/README.md
@@ -52,7 +52,7 @@ User --> Ruflo (CLI/MCP) --> Router --> Swarm --> Agents --> Memory --> LLM Prov
![The ruflo console inside Claude Code: swarm topology, claims, approvals, missions, events and more](docs/assets/ruflo-console-tour.gif)
-<sub>The <code>/ruflo</code> console running in Claude Code — <code>npx ruflo init</code>, restart Claude Code, then <code>/ruflo</code>.</sub>
+<sub>The <code>/ruflo</code> console running in Claude Code (Claude on the left, the cockpit on the right): agents spawned and tasks created from the prompt show up live in the swarm, claims and memory views. <code>npx ruflo init</code>, restart Claude Code, then <code>/ruflo</code>.</sub>
**Install the mods from the ruflo marketplace** (Claude Code 2.1.287 or later; mods run with your account's permissions and are not sandboxed, so read the code first):
diff --git a/docs/assets/ruflo-console-tour.gif b/docs/assets/ruflo-console-tour.gif
index 78edefbac8..91eb6f8e89 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/controller.ts b/plugins/ruflo-console/hooks/controller.ts
index 062616039f..be292bd0f0 100644
--- a/plugins/ruflo-console/hooks/controller.ts
+++ b/plugins/ruflo-console/hooks/controller.ts
@@ -332,7 +332,7 @@ export function createController(state: State, host: Host): Controller {
/** `closeOnEscape` false: take the keys but leave Esc handing them back, as an auto-opened pane does. */
async function open(focus = true, closeOnEscape = focus): Promise<{ isPlaced: boolean; reason: string }> {
try {
- const result = await host.openPane({ id: PANE_ID, title: 'ruflo', rows: rowsOf(state.view), ...(focus && { focus: true, holdToasts: true }), ...(closeOnEscape && { closeOnEscape: true }) })
+ const result = await host.openPane({ id: PANE_ID, title: 'ruflo', rows: rowsOf(state.view), ...(state.dockColumns > 0 && { columns: state.dockColumns }), ...(focus && { focus: true, holdToasts: true }), ...(closeOnEscape && { closeOnEscape: true }) })
const isPlaced = result === undefined || result.isPlaced !== false
if (isPlaced && !state.pane.isOpen) state.pane.bootAtMs = Date.now()
@@ -392,7 +392,7 @@ export function createController(state: State, host: Host): Controller {
state.mounted.clear()
persist()
// A new view asks for its own height inline; the dock ignores it.
- if (state.pane.isOpen) void host.openPane({ id: PANE_ID, title: 'ruflo', rows: rowsOf(view) }).catch(() => undefined)
+ if (state.pane.isOpen) void host.openPane({ id: PANE_ID, title: 'ruflo', rows: rowsOf(view), ...(state.dockColumns > 0 && { columns: state.dockColumns }) }).catch(() => undefined)
void probe(true)
}
diff --git a/plugins/ruflo-console/hooks/register.ts b/plugins/ruflo-console/hooks/register.ts
index be87bc66b1..185305362f 100644
--- a/plugins/ruflo-console/hooks/register.ts
+++ b/plugins/ruflo-console/hooks/register.ts
@@ -88,6 +88,10 @@ export const register: Register = (on, raw: PluginOptions) => {
state.home = (await bound.home().catch(() => undefined)) ?? null
state.configDir = (await bound.configDir().catch(() => undefined)) ?? (state.home === null ? null : `${state.home}/.claude`)
+ // A recording or a wide screen can ask for a wider dock: RUFLO_CONSOLE_COLUMNS, whole columns, 40 to 400.
+ const asked = Number(await (async () => $.env.get('RUFLO_CONSOLE_COLUMNS'))().catch(() => ''))
+
+ state.dockColumns = Number.isInteger(asked) && asked >= 40 && asked <= 400 ? asked : 0
// The x.ruv.io board's admin rows: only whether the token is set is kept, never its value.
state.xruv.hasAdminToken = await (async () => $.env.get('RUFLO_X_ADMIN_TOKEN'))().then(
value => typeof value === 'string' && value !== '',
diff --git a/plugins/ruflo-console/hooks/state.ts b/plugins/ruflo-console/hooks/state.ts
index d840865c44..fd6fafc2b7 100644
--- a/plugins/ruflo-console/hooks/state.ts
+++ b/plugins/ruflo-console/hooks/state.ts
@@ -199,6 +199,8 @@ export type State = {
eventFilter: 'all' | ConsoleEvent['kind']
/** When the newest learning point arrived: the curve draws it in from there. */
curveGrewAtMs: number
+ /** The dock width asked for (RUFLO_CONSOLE_COLUMNS, 40 to 400); 0 leaves the engine's share. A request: a dragged width wins. */
+ dockColumns: number
pane: { isOpen: boolean; isShown: boolean; isFocused: boolean; columns: number; rows: number; placement: 'dock' | 'inline'; isClosedByPerson: boolean; autoTried: boolean; autoReason: string; /** When the pane last opened: the BBS boot screen plays from here. */ bootAtMs: number }
/** The size of each Raster as last mounted, by key: a blit of any other size is refused, so none is sent. */
mounted: Map<string, { columns: number; rows: number }>
@@ -284,6 +286,7 @@ export function newState(raw: PluginOptions | undefined): State {
statusLog: new Map(),
eventFilter: 'all',
curveGrewAtMs: 0,
+ dockColumns: 0,
pane: { isOpen: false, isShown: false, isFocused: false, columns: 0, rows: 0, placement: 'inline', isClosedByPerson: false, autoTried: false, autoReason: '', bootAtMs: 0 },
mounted: new Map(),
select: { claim: 0, agent: 0, task: 0, item: 0 },
diff --git a/plugins/ruflo-console/hooks/views/menu.ts b/plugins/ruflo-console/hooks/views/menu.ts
index f041c7397b..6943623a56 100644
--- a/plugins/ruflo-console/hooks/views/menu.ts
+++ b/plugins/ruflo-console/hooks/views/menu.ts
@@ -23,7 +23,7 @@ const GROUPS: readonly { title: string; sections: readonly { name: string; items
{
title: 'INTELLIGENCE',
sections: [
- { name: 'learn', items: [{ key: '6', label: 'Learning', go: 'learning' }, { key: '·', label: 'Neural', go: 'neural' }, { key: '·', label: 'Self-Evolution', go: 'evolve' }, { key: '7', label: 'MetaHarness', go: 'metaharness' }, { key: '·', label: 'Self-Evolution', go: 'evolve' }] },
+ { name: 'learn', items: [{ key: '6', label: 'Learning', go: 'learning' }, { key: '·', label: 'Neural', go: 'neural' }, { key: '7', label: 'MetaHarness', go: 'metaharness' }, { key: '·', label: 'Self-Evolution', go: 'evolve' }] },
{ name: 'remember', items: [{ key: '8', label: 'Memory Lab', go: 'memory' }, { key: '·', label: 'Vector Lab', go: 'vector' }] },
{ name: 'spend', items: [{ key: '9', label: 'Cost & Budget', go: 'cost' }, { key: '·', label: 'Performance', go: 'perf' }] },
],
@@ -32,7 +32,7 @@ const GROUPS: readonly { title: string; sections: readonly { name: string; items
title: 'SAFETY & OPS',
sections: [
{ name: 'protect', items: [{ key: '·', label: 'Security & Doctor', go: 'secure' }] },
- { name: 'build', items: [{ key: '·', label: 'Automation', go: 'automate' }, { key: '·', label: 'Dev Tools', go: 'devtools' }] },
+ { name: 'build', items: [{ key: '·', label: 'Dev Tools', go: 'devtools' }] },
],
},
{
diff --git a/plugins/ruflo-console/hooks/views/pane.ts b/plugins/ruflo-console/hooks/views/pane.ts
index 0ec67d0fe2..e6d97d6654 100644
--- a/plugins/ruflo-console/hooks/views/pane.ts
+++ b/plugins/ruflo-console/hooks/views/pane.ts
@@ -251,12 +251,16 @@ export function paneView(ctx: Ctx): RenderElement {
const title = !isCompact && header !== undefined && ctx.kit.Raster !== undefined ? [ctx.kit.Raster(header.toRaster('header'))] : []
const about = blurb(ctx)
const bbs = isBbs() ? wildcat(ctx) : { strip: [], art: [] }
+ // The status row (keys, sync, Palette, Actions) sits above the body, so a tall view cannot push it off the screen; only the main menu keeps it below its prompt, as a BBS does.
+ const isMenu = ctx.state.view === 'menu'
+ // The terminal's own Enter-again confirm stays under its field, where the field is.
+ const isTerminal = ctx.state.view === 'terminal'
const gap = isBbs() && !isCompact ? [text(ctx, ' ')] : []
// The confirm row sits above the body in both layouts: below it, a tall view would push the question off the screen.
// Compact keeps every page's title and its line of purpose; only the banner and the spacing go.
const parts = isCompact
? [tabs(ctx), ...bbs.art, ...(about !== null ? [about] : []), ...(confirm !== null ? [confirm] : []), footer(ctx), body]
- : [...title, ...bbs.strip, ...gap, tabs(ctx), ...gap, ...bbs.art, ...(about !== null ? [about] : []), ...gap, ...(confirm !== null ? [confirm] : []), body, ...gap, footer(ctx)]
+ : [...title, ...bbs.strip, ...gap, tabs(ctx), ...gap, ...bbs.art, ...(about !== null ? [about] : []), ...gap, ...(isMenu ? [] : [footer(ctx)]), ...(confirm !== null && !isTerminal ? [confirm] : []), body, ...(confirm !== null && isTerminal ? [confirm] : []), ...gap, ...(isMenu ? [footer(ctx)] : [])]
return ctx.kit.Box({ flexDirection: 'column', children: parts })
}