Lemon

Agent systems · React · FastAPI

I co-developed Lemon through UCL's Industry Exchange Network with Avanade/Accenture. It is a visual and conversational editor for clinical decision workflows: users can draw a flowchart, describe changes in chat, or reconstruct a workflow from an image, then inspect and edit the resulting logic.

The team built a React/TypeScript canvas backed by FastAPI. Workflows contain typed nodes, branches, calculations, and reusable subworkflows. Validation checks the structure, while stepped execution lets users follow a path through the graph with test inputs. The system can also compile workflows into executable Python.

My contribution

My main work was the conversational runtime and its connection to the editor. I implemented a stateful task model, centralised turn handling, and streaming infrastructure for text, tool progress, and canvas updates. Background builders can work on subworkflows while the main conversation continues, with task and workflow identifiers keeping their updates associated with the correct context.

I also worked on the pluggable tool framework. Each tool declares its parameters and execution behaviour; the registry generates the model-facing schemas from those definitions. This gave teammates a consistent way to add editing, inspection, and validation capabilities without maintaining a separate copy of every tool interface.

Keeping the editor in sync

A browser connection should not determine whether a long-running task survives. I separated task lifetime from the server-sent event stream: disconnecting closes the stream while the backend task can continue and persist its result. On reconnection, buffered output and the latest workflow state are replayed, and the frontend reconciles with the saved conversation.

I developed integration and end-to-end coverage around cancellation, turn state, event delivery, and reconnect behaviour, including stop-button tests against the real backend. I also contributed authentication, ownership checks, and Azure deployment work. The focus was making a multi-step editing session remain coherent across refreshes, interruptions, and concurrent activity.

← All projects