Repository navigation
Agent Manager - Install and Manage Agents with lemonade agents + GUI
#3857
Replies: 7 comments 32 replies
|
I like the overall direction. Making agents installable and configurable directly through Lemonade is a natural next step, and reusing the existing backend installer makes a lot of sense. For Phase 2, especially agent sessions and remote access, I'd prefer to build on Nexus once its identity and access-control infrastructure is ready, rather than introducing a separate solution. @Geramy fyi One thing we should discuss when we get there is how existing agent installations and user configurations are handled during the transition. |
|
That's a great improvement for Lemonade Project and is well written with a great PoC 🔥 Becoming an agent manager as was for IA model at the start of the project is the natural development of lemonade, therefore the change is more than welcome. ✔️ What I like from the Proposal : Great integration with the GUi3 and the workflow stack across the block 🔝 What I would prioritize : Pi agent first and OpenCode second, both top agents for local. 🟨 What is missing : Need a stack to let the user to control the level of access and freedom an agent can have on the system and task he runs. That will give the control over the agents and solve the privacy matter and safety risk. From Full access where agents does everything without intervention ( YOLO as microsoft called it, full unprotected) to stop and ask to the user at every task to full lockdown with a kill switch to prevent agents doing anything outside of authorisation. AMD Gaia not in the list, this is a big miss from my side. From my Point of view is a green light for the change 💚 |
|
Would it make sense for also setting up nono for sandboxing at the exact same time? Then set up profiles for the agents you installed with agent manager? I was thinking it could drop some wrappers that automatically run the right profile. IE |
Let's discuss whether pinning versions makes sense for agents. My main concern is that the agents themselves constantly prompt me to update them with Would it make more sense to have a recommended/validated version, but to also flexibly support a spectrum of versions? Similar to how #3786 gates |
Right now all configuration is accessed through Perhaps the dream scenario is that
similar to how backend config is accessed like
|
|
Do you want to add anything about how we deal with Claude Code, Hermes, or AnythingLLM? I know everyone has their agent preferences, but for me personally those rank in my top-5 and I would like to know how they fit in to the plan (despite not having github release artifacts). Even if its just 2-3 sentences of "non-github-artifact agents may be handled in phase 3 via..." |
Proposal: Minimal Pi-powered Coding Mode in GUII have a proposal for a simple implementation, simpler than building a separate coding workspace or agent backend. It would be based on Pi since it suits Lemonade so well. Lemonade already supports launch pi and we have the [Lemonade Pi plugin](https://github.com/lemonade-sdk/lemonade-pi-plugin). The idea is to extend that integration and reuse GUI3's existing chat UI. Pi remains the coding agent. Lemonade provides inference and the UI. For those who dislike CLI. UX (GUI)Add a "Switch to Coding Mode" option to the existing starter suggestions in an empty chat. This is a GUI action, not a prompt sent to the LLM. If Pi is not connected, show simple installation and startup instructions. Users can also ask the regular Lemonade chat for setup help. Once Pi is connected, the user can start a Coding conversation. The conversation type is fixed when created. A conversation is either a regular Lemonade chat or a Pi coding session. There is no mode switching inside an existing conversation. This keeps history, session restoration and future diff management much cleaner. For the Coding UI, reuse the existing chat composer, Markdown rendering and tool display. The current Logs side panel gets a Diff / Logs pill to switch between the two views. We do not need both panels open simultaneously. Action points
Explicitly out of scope for the first versionAutomatic Pi installation or startup, a separate local agent host, sandbox/container management, undo/redo, per-hunk revert and complete workspace change tracking. Pi already has extension-based approaches for sandboxing and workspace history. We can integrate those later without inventing our own implementations now. The goal is a small, optional Coding Mode in GUI3, not a second coding-agent framework inside Lemonade. Thoughts? |

Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Proposal size
Major feature (spans multiple well-scoped PRs)
Updates
No response
User story
The auto-BKC vision (#3846) describes Lemonade as a hub where users pick an agent, get a recommended model and engine for their system, and install the whole recommended stack in one click. It describes an Agent Manager that installs, configures and launches agents as one of the parts of that stack. This RFC proposes that first phase: the agent leg of the stack.
As a Lemonade user who has a model running and wants a coding agent working on my project, I want
lemonade launch pito get me from zero to a working agent in one command, so that I can try local agentic coding.Today this is process involves some friction. The docs send me to install Node.js 22+, then
npm i -gthe agent, then come back to Lemonade.Each agent also publishes a one-line install script (
curl -fsSL https://pi.dev/install.sh | sh, and similar for Codex, OpenCode, Goose and Kilo Code). That is quicker, but it means trusting a shell script from a live URL:.bashrc/.zshrcandPATH, or install other software.Scenarios enabled:
lemonade launch pioffers to install pi, then configures it for my local models and starts it. No Node.js, npm or admin rights needed.High-level design
New Subcommand
A new
lemonade agentscommand, modeled onlemonade backends:lemonade agents listlemonade agents install <agent>lemonade agents update <agent>lemonade agents configure <agent>lemonade agents uninstall <agent>--purgealso removes the agent's sessions and settingslemonade launch <agent>uses the Agent Manager: it uses an agent the user already has, or offers to install one, then configures and starts it as it does today.GUI Changes
Create Agents tab in GUI for Agent Manager functions. See screenshot below for PoC

Installing from GitHub Release Binaries
Each agent is installed from the self-contained per-platform archives its project publishes on GitHub Releases. These run without Node.js or any other runtime, on Linux, macOS and Windows, x64 and arm64.
Lemonade ships a pin file listing each agent's release version and the checksum of every archive. Once the installer exists, adding an agent means adding its entry, its pin and its config writer.
Reusing the Backend Installer
Installing an agent is the same job Lemonade already does for backends such as llamacpp: download a pinned GitHub release archive, verify it, extract it, and swap it into place without breaking the working copy. The Agent Manager reuses that machinery and its design:
.tar.gzand.zipextraction on every platformlemonade backendsThe backend installer itself is unchanged.
Where It Runs
The Agent Manager only handles files: installs, config and version pins. It never runs long-lived processes. It runs as the user, from the CLI, and keeps agents in a per-user folder that doesn't depend on how lemond is installed. A lemond running as a system service and the user's own CLI therefore always agree on where that user's agents are.
It's built as a standalone library that the CLI links. lemond does not link it.
New agents and install methods plug in without changing this design.
How This Prepares for Agent Sessions (Phase 2)
Phase 2 brings agent sessions to the web and desktop apps as well as "agent as an endpoint". I propose that agents always run in a small per-user agent host (
lemonade agents host) and never inside lemond:flowchart LR B["Web / desktop app"] --> L["lemond<br/>access checks + relay"] L <--> H["Agent host<br/>(runs as the user)"] H --> P["pi"] H --> AM["Agent Manager"]lemonadeuser and can't see home folders, and on macOS lemond runs as root. An agent has to run as the person who started it, in their project.The host starts on demand from the CLI, tray or desktop app, and exits when idle.
Breaking changes
None.
Maintenance plan
lemonade agentscommands against a locally served fixture releaseRisks
Downloading and running executables. Lemonade only installs pinned versions and verifies checksums it comes with. A compromised upstream release is caught at pin time only if the maintainer reviews it, so pin bumps are reviewed like dependency bumps.
Edits:
Phase 2
Architecture
Why a separate host
lemonadewithProtectHomeandNoNewPrivileges, so it can't run anything as the user or touch their home./agents/*. The CLI, GUI and third-party clients all use the same routes, so they get the same features.Lifecycle
systemctl --user start, or a detached process). The host exits when idle.lemonade agents enableinstalls an opt-insystemd --userunit. Headless machines also needloginctl enable-linger. There is no new system service./agents/*returns503along with the command to run.Identity and auth
SO_PEERCRED) and re-checks it on every reconnect.0600token file for the local CLI, and a pairing code for browsers. Remote browser sessions are off at first.All reactions