YC (S26) | Open Computer History | Continuously record your company computer work, map your workflows, help you find work worth automating, and power your agents' context
Rust agentsagiaiai-memoryaudio-recordingcomputer-visionhermeshermes-agentllmlocal-ailocal-firstmachine-learningmcpmultimodalopenclawprivacyrewindscreen-recordingspeech-to-textycombinator
feat(pipes): brand-aligned pipe cards with run / edit / remix (#4208)
Louis Beaumontfd1e79207815
diff --git a/apps/screenpipe-app-tauri/components/settings/pipes-section.tsx b/apps/screenpipe-app-tauri/components/settings/pipes-section.tsxindex 832ae0d3d..f56fbaf2e 100644--- a/apps/screenpipe-app-tauri/components/settings/pipes-section.tsx+++ b/apps/screenpipe-app-tauri/components/settings/pipes-section.tsx@@ -23,6 +23,7 @@ import {MoreHorizontal,Plus,ArrowRight,+ GitFork,Search,Share2,Link,@@ -306,6 +307,20 @@ function buildOptimizeDisplayLabel(pipeName: string): string {return `Optimize pipe: ${pipeName.trim()}`;}+// "remix" = make your own version of an existing pipe. We don't mutate the+// original — the agent reads it and creates a NEW customized pipe. Framing+// authoring as "customize a working thing" is the lever that turns installers+// into creators (see Replit remix / Notion duplicate).+function buildRemixPrompt(pipeName: string): string {+ return `i want to remix my existing pipe "${pipeName}" into a new one.++## your task+1. read the original pipe: ~/.screenpipe/pipes/${pipeName}/pipe.md+2. ask me what i want to change or do differently+3. create a NEW pipe (a new name + folder) with those changes — do NOT modify or overwrite "${pipeName}"+4. install and enable the new pipe, then tell me what it does.`;+}+function parsePipeError(stderr: string): {type: "daily_limit" | "credits_exhausted" | "rate_limit" | "unknown";message: string;@@ -2059,7 +2074,7 @@ export function PipesSection() {<buttonkey={ex.label}onClick={() => startPipeGeneration(ex.prompt, "empty_state_example")}- className="inline-flex items-center gap-1.5 px-2.5 py-1.5 rounded-full border border-border bg-muted/50 text-xs hover:bg-muted transition-colors"+ className="inline-flex items-center gap-1.5 px-2.5 py-1.5 border border-border bg-muted/50 text-xs hover:bg-muted transition-colors">{ex.label}</button>@@ -2072,7 +2087,7 @@ export function PipesSection() {detail: { tab: 'discover' }}));}}- className="inline-flex items-center gap-2 px-4 py-2 rounded-md border border-border text-sm font-medium hover:bg-muted transition-colors"+ className="inline-flex items-center gap-2 px-4 py-2 border border-border text-sm font-medium hover:bg-muted transition-colors">or browse the pipe store →</button>@@ -2081,7 +2096,7 @@ export function PipesSection() {</CardContent></Card>) : (- <div className="border border-border rounded-md divide-y divide-border">+ <div className="flex flex-col gap-2">{filteredPipes.map((pipe) => {const recentExecs = pipeExecutions[pipe.config.name] || [];const isRunning = pipe.is_running || runningPipe === pipe.config.name;@@ -2109,9 +2124,9 @@ export function PipesSection() {: "idle";return (- <div key={pipe.config.name} className={cn("group", !pipe.config.enabled && "opacity-50")}>- {/* Table row */}- <div className="flex items-center gap-3 px-4 py-2.5 hover:bg-accent/50 transition-colors">+ <div key={pipe.config.name} className={cn("group border border-border hover:bg-accent/40 transition-colors", !pipe.config.enabled && "opacity-60")}>+ {/* Card top line */}+ <div className="flex items-center gap-3 px-4 pt-3 pb-1">{/* Status indicator — monochrome, brand-aligned */}<spanclassName={cn(@@ -2148,13 +2163,21 @@ export function PipesSection() {/></button>- {/* Pipe name — click to expand */}- <button- onClick={() => toggleExpand(pipe.config.name)}- className="text-sm font-medium truncate text-left min-w-0 flex-1 hover:underline"- >- {pipe.config.name}- </button>+ {/* Pipe name + outcome — click name to expand */}+ <div className="flex flex-col min-w-0 flex-1 gap-0.5">+ <button+ onClick={() => toggleExpand(pipe.config.name)}+ className="text-sm font-medium truncate text-left hover:underline"+ >+ {pipe.config.name}+ </button>+ {typeof pipe.config.description === "string" &&+ (pipe.config.description as string).trim() && (+ <span className="text-xs text-muted-foreground truncate">+ {(pipe.config.description as string).trim()}+ </span>+ )}+ </div>{/* Team sharing badges */}{sharedByMe.has(pipe.config.name) && (@@ -2274,9 +2297,57 @@ export function PipesSection() {"—")}</span>+ </div>- {/* Hover-reveal actions */}- <div className="flex items-center gap-0.5 opacity-0 group-hover:opacity-100 transition-opacity shrink-0">+ {/* Action bar — always visible, brand-aligned (sharp, monochrome).+ edit + remix are the install->create lever. */}+ <div className="flex items-center gap-1 px-3 pb-2.5 pt-0.5">+ {/* edit with ai — opens a chat to tweak this pipe in plain english */}+ {!isReceivedTeamPipe(pipe) && (+ <Button+ variant="ghost"+ size="sm"+ className="h-7 gap-1.5 px-2 shrink-0 text-muted-foreground hover:text-foreground"+ onClick={() => {+ posthog.capture("pipe_edit_started", { source: "row_button" });+ navigateHomeAndPrefill({+ context: "the user wants to edit their pipe",+ prompt: buildOptimizePrompt(pipe.config.name),+ displayLabel: buildOptimizeDisplayLabel(pipe.config.name),+ autoSend: true,+ });+ }}+ title="edit this pipe with ai — describe what you want to change"+ >+ <Sparkles className="h-3.5 w-3.5" />+ edit+ </Button>+ )}++ {/* remix — create a NEW pipe based on this one and customize it */}+ {!isReceivedTeamPipe(pipe) && (+ <Button+ variant="ghost"+ size="sm"+ className="h-7 gap-1.5 px-2 shrink-0 text-muted-foreground hover:text-foreground"+ onClick={() => {+ posthog.capture("pipe_remix_started", { source: "row_button" });+ navigateHomeAndPrefill({+ context: "the user wants to remix their pipe into a new one",+ prompt: buildRemixPrompt(pipe.config.name),+ displayLabel: `Remix pipe: ${pipe.config.name}`,+ autoSend: true,+ });+ }}+ title="remix — create a new pipe based on this one and customize it"+ >+ <GitFork className="h-3.5 w-3.5" />+ remix+ </Button>+ )}++ {/* run + overflow */}+ <div className="flex items-center gap-0.5 shrink-0">{/* Run / Stop button */}{isRunning ? (<Button@@ -2314,20 +2385,6 @@ export function PipesSection() {</Button>)}- {/* Publish button — not for received team pipes (someone- else's work; fork first) */}- {!isReceivedTeamPipe(pipe) && (- <Button- variant="ghost"- size="icon"- className="h-7 w-7"- onClick={() => setPublishPipeName(pipe.config.name)}- title="publish to store"- >- <Upload className="h-3.5 w-3.5" />- </Button>- )}-{/* Overflow menu */}<DropdownMenu><DropdownMenuTrigger asChild>@@ -2336,21 +2393,7 @@ export function PipesSection() {</Button></DropdownMenuTrigger><DropdownMenuContent align="end">- {!isReceivedTeamPipe(pipe) && (- <DropdownMenuItem- onClick={() => {- navigateHomeAndPrefill({- context: "the user wants to optimize their pipe",- prompt: buildOptimizePrompt(pipe.config.name),- displayLabel: buildOptimizeDisplayLabel(pipe.config.name),- autoSend: true,- });- }}- >- <Sparkles className="h-3.5 w-3.5 mr-2" />- optimize with ai- </DropdownMenuItem>- )}+ {/* "edit with ai" lives on the row as a visible button now */}{/* Team sharing — own pipes can be shared, updated,unshared; received team pipes are read-only and can@@ -2450,12 +2493,12 @@ export function PipesSection() {</DropdownMenu></div>- {/* Toggle — only visible on hover.+ {/* Enable toggle — always visible, pushed to the far right.Missing connections block ENABLING (can't run), but neverblock DISABLING — a stuck-on pipe with broken deps mustalways be turn-off-able. */}<div- className="opacity-0 group-hover:opacity-100 transition-opacity"+ className="ml-auto flex items-center"title={hasMissingConnections && !pipe.config.enabled? "configure required connections before enabling auto-run"