Changelog
Release notes for aparté 1.10.0: what changed in each @aparte package, and what to update.
On this page
Version 1.10.0
Every @aparte/* package ships at this version (they are released in lockstep).
Minor Changes
-
8436252: With several chats on one conversation manager, a chat’s first message now starts a conversation of its own, even when another chat has one open or is creating one.
Do you have to touch your code? Only if several chats share one manager and you create a conversation with
manager.createNew()for one of them: give it to that chat (conversationId, orsetConversationId()). With several chats on one manager, a chat whose first message was sent while another chat had a conversation open saved that message into the other chat’s conversation, marked the other chat’s row in the list as answering, and told the client the turn belonged to it. Two chats sending their first message at the same moment could end up in one conversation. Each chat now reads only its own conversation: the one it opened, or the one its first message is creating, which the controller exposes aspendingIduntilactiveIdholds it.The manager still has one
activeId, and it still names the conversation the last chat to move opened. It does not drive a chat: callingmanager.select()ormanager.createNew()yourself changes no chat’s transcript. A chat alone on its manager still saves its first message into the empty conversation you created withmanager.createNew(); with several chats, give that conversation to the chat it is for. To open a conversation in a chat, dispatchaparte-conversation-selectwith that chat’s id astargetId, set itsconversationId, or callsetConversationId()on it.@aparte/core -
5f96251: A plugin’s element can now be used from React as a typed component:
createAparteElement(approvalModeElement)from@aparte/react. Each plugin exports a spec for its element (approvalModeElement,modelSelectorElement,triggersElement,diffElement,subagentViewElement,askUserElement, andartifactPanelElementfrom@aparte/plugin-artifacts/panel), and Vue and Svelte type the tag from it withAparteVueElement<typeof spec>andAparteSvelteElement<typeof spec>.tsxconst ApprovalMode = createAparteElement(approvalModeElement); <ApprovalMode labels={{ ask: "Ask first" }} onApprovalModeChange={(detail) => save(detail.mode)} />;The spec is core’s new
AparteElementSpectype — the tag, its attributes, the members it has only as a property, its events with the name each binds under, and what it reads at connect — with phantom generics, so the attribute, property and event types travel with the value (AparteSpecAttributes,AparteSpecProperties,AparteSpecEventsread them back). It is data and defines nothing. A plugin generates its specs from its manifest; a third party writes one literal and every wrapper binds it the same way, since a plugin can depend on core but never on a wrapper. In Angular, a plugin’s element takesCUSTOM_ELEMENTS_SCHEMA, as any custom element does.Deprecated:
@aparte/plugin-model-selector/react,/vue,/svelteand/angular. They keep working until the next major; usemodelSelectorElementthe same way as any other plugin’s spec.@aparte/core,@aparte/plugin-approval,@aparte/plugin-artifacts,@aparte/plugin-ask-user,@aparte/plugin-diff,@aparte/plugin-model-selector,@aparte/plugin-subagents,@aparte/plugin-triggers,@aparte/react,@aparte/svelte,@aparte/vue -
b4ff550: Events sent from inside a chat now carry
targetId, the id of that chat —aparte-card-action,aparte-card-change,aparte-approval-mode-change,aparte-diff-commentand the others — so a page with several chats can tell them apart. New:chatIdOf(el)anddispatchChatEvent(el, type, detail).What carries it now: a message’s
aparte-action,aparte-feedback,aparte-feedback-reason,aparte-message-info,aparte-branch-navigate,aparte-link-clickandaparte-attachment-preview; the composer’saparte-composer-change,aparte-action-clickandaparte-attachment-preview; the viewport’saparte-path-changedandaparte-segment-update;aparte-suggestion;aparte-model-change;aparte-approval-mode-change;aparte-trigger-select;aparte-card-actionandaparte-card-change;aparte-diff-comment;aparte-artifact-openandaparte-artifact-version-change. Their detail types gaintargetId?: string; nothing is removed. A chat with noidnames none, and the detail then has notargetIdkey.chatIdOf(el)is the rule core uses everywhere it needs an element’s chat, exported: thetargetof the nearest aparté element that names one, else the id of the nearest<aparte-chat>or[data-aparte-chat]root that has one, across a shadow root. It replaces the copies the composer, the client, the bubble, the context gauge, the suggestions and the triggers each kept.dispatchChatEvent(el, type, detail, { cancelable })dispatches a bubbling, composed event with thattargetIdstamped on the detail (one the detail already has is kept) and returns whatdispatchEventreturns: a plugin’s element, or yours, sends its events the way core’s do.The plugins that use them need
@aparte/core1.10.0.@aparte/core,@aparte/plugin-approval,@aparte/plugin-artifacts,@aparte/plugin-cards,@aparte/plugin-diff,@aparte/plugin-model-selector,@aparte/plugin-triggers -
100a185: An approval question can now show what the call would do: a tool’s display takes
approvalPreview, and the panel mounts what it returns between the question and the buttons.approvalPreview(call)returns an element, a string of HTML (sanitised) ornull;requestUserInput()takes the same thing aspreviewon an approval request.setupDiff()registers a diff preview for an edit tool from its input (beforeandafter, orold_stringandnew_string), and takes apreviewoption for another shape, orfalsefor none.@aparte/core,@aparte/plugin-diff -
7476930: A new
configgiven to<AparteChat>is now applied; it was read once, when the chat mounted, and a later one was ignored without a word.Pass a config that keeps its identity across renders (created once, or memoized): each new object is applied as a new config, and every element inside re-resolves it. The same config handed again changes nothing.
When the prop changes, every element inside moves to the new config, and the chat’s two locale strings (the loading line, the waiting line) follow the new language. The messages on screen stay. If the new config registers another conversation manager, the open conversation is opened again from it when it holds that conversation; when it does not, or the new config has no manager, the chat keeps saving that conversation to the manager it had, and the next conversation it opens comes from the new config. A config given while a reply is streaming waits for that turn to end, so a reply is never half-drawn with one configuration’s renderers and finished with another’s; the last one given wins.
The wrappers call the new
AparteChatHost.setConfig(config), which does the same for a binding of your own.@aparte/core,@aparte/angular,@aparte/react,@aparte/svelte,@aparte/vue -
f65be56:
<aparte-conversation-list>takesgroup: { key, label }on an item to list it under a heading of your own, and arenderMeta(item)property to draw a mark of yours after a row’s title.Nothing to change in your code. A row with a
groupis listed there instead of under its date or Pinned; the groups come first, in order of first appearance, and the rows without one keep the date groups below them.renderMetareturns an element, a string (text, never markup) ornull; it sits beside the title button, not inside it, so a button of yours in it keeps its own name and tab stop. Setting it draws the rows again.@aparte/core -
e5d60b4: After a failed turn, every later request now sends the same history: the failed message goes with the next one from the next request on, or is left out of every request when its error says the same request fails again.
Do you have to touch your code? No. A server that compared histories and took a message ending in
"\n\n" + <a recorded message>for that message can drop that workaround: the history no longer changes from one request to the next.- What changed. The send cut the history at the last answered reply, so the request after a failed turn left the failed message out, and the request after that put it back, joined to the next message. A server that keeps its own record saw the past change under it. The send now cuts only the message being sent, and one rule, decided by the code on the failed reply’s error segment, says what a failed turn leaves:
- the network, a 5xx, a rate limit, a key, a Stop before the first token: the message is kept, and goes joined to the next one (
mergeAdjacentUserMessages), as retry and edit already sent it; USAGE_CONTEXT_EXCEEDED,PROVIDER_POLICY,USAGE_BAD_REQUEST: the message, and every message that went out with it, is left out of every later request, or the conversation could not go on;- a message that carried files is left out too: the history sends a message’s text, never the files a send read, and the model would be asked about a file it is not shown.
- the network, a 5xx, a rate limit, a key, a Stop before the first token: the message is kept, and goes joined to the next one (
- Who follows it. Send, retry, edit, the resume of a paused turn, the context gauge (
estimateWireTokens,measureContext) and@aparte/plugin-compaction, whose cut no longer weighs a message no request sends and whose summary no longer reads it. - New export.
withoutAbandonedTurns(messages)returns the messages a later request still sends, for ahistoryfunction or a server of your own. - What it fixes downstream. An AG-UI thread numbers its messages by place, and the ids no longer name two different messages in one thread. n8n, which receives only the last message, now hears the failed one with the next instead of never.
@aparte/core,@aparte/plugin-compaction
- What changed. The send cut the history at the last answered reply, so the request after a failed turn left the failed message out, and the request after that put it back, joined to the next message. A server that keeps its own record saw the past change under it. The send now cuts only the message being sent, and one rule, decided by the code on the failed reply’s error segment, says what a failed turn leaves:
-
ff401d3: A pause on a sub-agent’s call now survives a reload:
resumeDeferredasks it again under the sub-agent’s name, and the run resumes with the answer.Do you have to touch your code? No. A storage adapter that saves the message as it is keeps the new field; one that copies chosen fields should copy
deferredCallstoo.- What was wrong. An agent elsewhere (an AG-UI agent, a server loop of your own) can pause on a call its sub-agent made. That call has no row in the reply, so nothing the conversation saved said a call was waiting: after a reload,
resumeDeferredfound no pause, the question was never asked again, and the agent kept waiting for an answer. - What the reply keeps.
AparteMessage.deferredCalls, a list ofAparteDeferredCall—{ toolCallId, name, input, reason, agentId, agentName, ticket }— written when the run pauses, beforeaparte-message-paused, so the conversation saved then has it. It names nothing of a plugin: the call, why it waits, the sub-agent’s id and the name it was announced with, the server’s ticket. It is removed once the pause is answered, and closed by a Stop or a new message, like a row’sdeferred. - On a reload.
resumeDeferredresumes the reply’s own paused calls and these together, each sub-agent call with itsagentId, asked under its sub-agent’s name (Allow read_file for Researcher?), and anapprovalResolverreceivescall.agent. The call that opened the sub-agent stays open across the load, so the resume hands it back to the agent unanswered rather than “stopped”.@aparte/core
- What was wrong. An agent elsewhere (an AG-UI agent, a server loop of your own) can pause on a call its sub-agent made. That call has no row in the reply, so nothing the conversation saved said a call was waiting: after a reload,
-
8f8be35: Add
--aparte-warning-surfaceand--aparte-info-surface, and thechevronDownIcon,chevronUpIconandpanelLeftIconglyphs in@aparte/core/icons.The two surfaces complete the intent family: success and error had one, warning and info did not, so a rule reading them got an invalid value and painted nothing. They use the same recipe. The chevrons name by direction what
expandandcollapsename by state;panelLeftis the usual glyph for a desktop sidebar toggle.@aparte/core -
d2f054c:
approvalResolver, an approval policy andrequestInterceptornow receive the turn they are called for,{ conversationId, messageId, targetId }(AparteTurnContext), and so do the server handler’sapprovalPolicyandprepareRequest.tsnew AparteClient({ approvalResolver: (call, signal, { conversationId }) => cards.ask(conversationId, call, signal), });Do you have to touch your code? No. Each is an extra argument a callback is free to ignore. A resolver that read the open conversation from the app’s own state, or from a capturing listener on
aparte-conversation-loaded, can read it from the turn instead.- Why. The client asks again about a paused call the moment a conversation is loaded (
resumeDeferred), before a framework has rendered the new id: a resolver that read the app’s state filed the request under the conversation shown before, and its card never appeared. The turn is read when the person acted, at every call site: a turn in the page, a paused server run, a resume after a reload. - Where it goes. The third argument of
approvalResolver(call, signal, turn)and of an approval policy(call, tool, turn)(absent only whenconfig.ruleOnToolCall(call)is called by hand, which now takes the turn as an optional second argument); the second ofrequestInterceptor(request, turn); on the server,approvalPolicy(call, tool, turn)andprepareRequest(request, req, turn), with{ messageId, conversationId }as the page sent them. The sub-agent whose call it is stays oncall.agent. - On the event and the panel.
aparte-tool-approval-requestcarriesmessageIdandconversationId, and the approval core puts to the panel carries them on the request (AparteElicitationRequest.conversationId,messageId), for a presenter of your own.@aparte/plugin-ask-userand the n8nbuttonstool put the conversation on the question they ask. - The approval preview. The request also carries
preview, what the tool display’sapprovalPreviewdraws for the call. - A browser tool that answers a paused server run is now told its conversation (
context.conversationId), like a tool the page’s own loop runs. AparteToolApprovalResolveris now its own type, engine’s resolver plus the turn. Passing one straight torunStreamAgentneeds a wrapper:(call, signal) => resolver(call, signal, turn).@aparte/core,@aparte/engine,@aparte/runner-n8n,@aparte/plugin-ask-user
- Why. The client asks again about a paused call the moment a conversation is loaded (
-
c4e34a9: Giving a chat back the conversation it just created (
conversationIdset fromonConversationCreated, or bound to the conversation manager’sactiveId) no longer reloads it in the middle of the first reply. New:getConversationId()on every<AparteChat>says which conversation that chat shows.Do you have to touch your code? Only if a class of yours implements
AparteChatImperativeApi: addgetConversationId(). Otherwise nothing changes; the pattern the conversation persistence guide documents now works as written:tsxconst [conversationId, setConversationId] = useState<string | null>(null); <AparteChat conversationId={conversationId} onConversationCreated={setConversationId} />;Before, the id came back while the first reply was streaming and the chat took it as a new conversation to open: it re-read the conversation from the manager, which did not hold the reply yet, so the reply’s text landed in the person’s bubble, the person’s message disappeared and Send stayed disabled. Bound to the manager’s
activeId(natural in Vue, Svelte and Angular), the id came back even earlier, before the chat itself held it. AconversationIdprop is now a no-op for the conversation the chat already shows or is creating. The imperativesetConversationId(id)is unchanged: the same id again still re-reads the conversation.getConversationId()is onAparteChatImperativeApi, so it is on React’s ref handle, Vue’s and Svelte’s component instance, Angular’s component, anduseAparteChat()/createAparteChat(). It returns the conversation the chat opened, or the one its first message is creating, andnullbefore either. Unlike the manager’s singleactiveId, which names whichever chat opened a conversation last, it is per chat.AparteChatHostgains the two methods the wrappers call:syncConversationId(id)andgetConversationId().In Angular,
setConversationId()called on the component no longer leaves the[conversationId]input’s next value compared against a stale id.@aparte/core,@aparte/angular,@aparte/react,@aparte/svelte,@aparte/vue -
60b91c1: A question or approval whose options are buttons now answers to the keyboard: 1 to 9 press the matching option, and Escape means Skip (question) or the one refusing option (approval).
Each option wears its number and carries
aria-keyshortcuts. The digits work only while an option has the focus, so a number typed in a sentence stays text; a held key, a modifier, an IME composition and a text field (the “Other” field, the instruction) are ignored. Escape on an approval presses the option withtone: 'deny'only when there is exactly one, and it no longer closes a launcher the chat sits in while a panel is asking. On by default.@aparte/core -
aa20dd2: Add
.aparte-segmented: a pill-shaped row of choices over native radio buttons, with--smand--block, and keyboard focus drawn on the chosen segment.Wrap each
<input type="radio">and its text in a<label class="aparte-segmented__item">inside a<div class="aparte-segmented" role="radiogroup">. A row of buttons that each do something wears the same look, witharia-pressedon a.aparte-segmented__itembutton. The cards’ range buttons now use this recipe. Their markup keepsaria-pressed,data-card-keyand the class namesaparte-rich-card__segmentedandaparte-rich-card__segment, so a stylesheet of yours that reached them still does; the look itself now comes from.aparte-segmented.@aparte/core,@aparte/plugin-cards -
1306924:
<aparte-sidebar collapsed="rail">folds the column to a 56px rail that stays usable, and.aparte-tooltip-anchor--hovershows a tooltip on hover and focus with no script.Nothing to change in your code: a plain
collapsedstill folds to nothing, and an anchor without the modifier behaves as before. In a rail the children you markdata-railstay, the others and any.aparte-sidebar__labelor.aparte-sidebar__brandinside a marked one hide, and the sidebar takes noinert. The width is--aparte-sidebar-rail-width; the tooltip’s delay is--aparte-tooltip-delay(400ms). The rail has no keyboard shortcut and the element does not choose when to be one: your toggle sets the attribute.@aparte/core -
73253c3: A tool’s display can now set the row’s
noteandactivity(text, or a function of the call), andregisterToolLineProvider()adds a tool-line provider without replacing the one the app set.The app’s display wins over a provider, field by field. Providers are asked in order,
setToolLineProvider()first, and the first one that answers a call wins;registerToolLineProvider()returns the function that removes it, andgetToolLineProviders()lists them.setToolLineProvider()is unchanged.@aparte/plugin-subagentsregisters its provider instead of setting it, so it no longer overwrites the app’s.@aparte/core,@aparte/plugin-subagents -
aa20dd2: What
setupWeatherCard()and every other card setup returns now also has.refresh(), which runsactions(data, { origin })again for the cards on screen.Nothing to change in your code: the return is still the function that takes the card off. Use
refresh()when whatactionsreads changes after the card is drawn (the person signs in, an item is saved); the buttons are redrawn in place, with the focus kept, and a card that already left the page is left alone. The return type is the newCardSetupHandle.@aparte/plugin-cards -
ae2b087:
useAparteClientin React now calls the function options of the latest render, so a resolver that reads state sees the state of now; calling a conversation helper’sinit()a second time no longer leaves the first manager writing its lists.Nothing to change in your code; the ref you may have added to work around it keeps working.
- React: the client is still built once, on the first render, but
keyResolver,approvalResolver,requestInterceptor,history(as a function),targetResolverandfileInjectFilterare called through the latest render’s options.streamRunneris not: it is read once and handed to the client as it is, because the client recognises the engine’s own loop (runStreamAgent) by identity; a runner that reads state reads it through a ref. AnapprovalResolverover the conversation’s mode, or akeyResolverover a settings form, no longer sees the values it had at mount. The other options (config,scopeToTargetId,maxTurns…), and whether a function option is there at all, are still read once: remount with akeyto change them. Vue, Svelte and Angular closures already read live values (refs, stores, signals), and their pages now say so. init()of React’suseConversationManager, Vue’suseConversationManager, Svelte 4’screateConversationManagerand Angular’sConversationManagerService, called again, replaces the manager and stops following the one before; its subscription used to stay, and the first manager’s notifications went on overwritingconversationsandactiveId. (Svelte 5’screateConversations()already did this.) Itsoptionsare read when it runs: atitleProviderthat reads state reads it through a ref, or is replaced withmanager.setTitleProvider().@aparte/angular,@aparte/react,@aparte/svelte,@aparte/vue
- React: the client is still built once, on the first render, but
-
@aparte/runner-n8nsends n8n the message just typed, also after a failed turn; it sent the failed message again, joined to the new one, which n8n’s memory may already hold. The run now names the person’s message it answers:userMessage,{ content, messageId? }, onStreamRunOptions, whichAparteClientfills on a send, a retry and an edit.Do you have to touch your code? No. A runner whose agent keeps its own memory and is sent only the new message reads
opts.userMessagerather than the last user message ofbaseRequest.messages, which after a failed turn is that message joined to the one before it. With a client that does not name it,@aparte/runner-n8nreads the history as before. A first message whose turn failed now keeps its n8n session for the next one.@aparte/core,@aparte/engine,@aparte/runner-n8n
Patch Changes
-
81d38ee: An element handed a value it already holds no longer closes, unfocuses or resets what the person was doing in it — re-rendering a framework wrapper with the same props is now harmless.
<aparte-triggers>: re-settingtriggerskeeps the open list open, on the row the keyboard was on, when the trigger it shows is still declared at the same place; a child list opened from a row stays open, on its own row, while that row is still listed, and closes with it otherwise. The commands-and-mentions recipe re-set it on every React render, so the list opened on@and closed at once.<aparte-approval-mode>: re-settinglabelsrenames the options in place, so an open list stays open.<aparte-diff>: re-settingdiffwith the change it shows — the same text or object, or an equal one, such as an inline{ path, before, after }— keeps the lines picked, the comment field and its text, the folds and the focus. The same object mutated into another change is drawn and coloured from its new text, and keeps the folds and the lines picked that still exist in it.<aparte-artifact-panel>: re-settingrenderwith the same function keeps the tab and the preview the reader chose.<aparte-conversation-list>: re-settingconversationswhile a row’s menu is open or a title is being renamed waits for them to end, instead of closing the menu and dropping what was typed.<aparte-suggestions>: re-settingsuggestionskeeps the focused chip and the row’s scroll.- An attribute written again with the value it has does nothing, on every element of core and the plugins (eleven of them redrew or rewrote their parts).
applyElementProps, which everyAparteUiand the generated React components use, now writes an attribute or a CSS variable only when it differs from the value it last wrote on that element; an object or a function is still assigned every time, because it may have been mutated in place (a Vuepushbehind a deep watch, a Svelte 5 proxy, Svelte 4’sarr = arr). An element that changes its own attribute keeps what it did until the prop next changes, as the React components already behaved.A test reads every element of core and of the seven plugins with a manifest and holds each to this: an attribute written again makes no mutation under the element, and a property assigned again keeps the focus and what is open, selected or typed.
@aparte/core,@aparte/plugin-approval,@aparte/plugin-artifacts,@aparte/plugin-diff,@aparte/plugin-model-selector,@aparte/plugin-triggers -
1306924: A select’s trigger text is now the value it shows and nothing else, so
textContentof the trigger reads “gpt-4o” and not every option’s label run together.Nothing to change in your code, unless a test read the hidden width labels (
.aparte-select-label-sizer > span) as text: they now carry the label indata-labeland CSS draws it as generated content. The trigger keeps the width of its widest option, as before. The testing guide lists the select’s hook.@aparte/core -
9696160:
aparte-subagent-opennow names its chat intargetIdunder a framework wrapper too, not only inside<aparte-chat>.The line looked for the
<aparte-chat>tag, and the React, Vue and Svelte wrappers render a[data-aparte-chat]root instead, so on those three the event came without the chat’s id. It now finds its chat the way every chat-scoped event does (chatIdOf). A line in a standalone<aparte-subagent-view>still names the chat that view reads (for, orchat), wherever the view is mounted.@aparte/plugin-subagents
Version-only bumps (no changes of their own): @aparte/runner-ag-ui, @aparte/provider-ai-sdk, @aparte/provider-openai-compat, @aparte/provider-scenario, @aparte/provider-transformers, @aparte/plugin-chartjs, @aparte/plugin-echarts, @aparte/plugin-katex, @aparte/plugin-marked, @aparte/plugin-mermaid, @aparte/plugin-shiki, @aparte/plugin-storage-idb, @aparte/plugin-streaming-markdown, @aparte/plugin-titler, @aparte/locales, @aparte/docs-mcp.