arisa 3.2.0 → 3.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,10 +1,10 @@
1
1
  # Arisa
2
2
 
3
- Arisa is a personal Telegram assistant powered by [Pi Agent](https://pi.dev).
3
+ [Arisa](https://arisa.sh) is a personal Telegram assistant powered by [Pi Agent](https://pi.dev).
4
4
 
5
5
  ## Origin
6
6
 
7
- The initial inspiration was [OpenClaw](https://github.com/openclaw/openclaw). OpenClaw has interesting ideas but carries a lot of weight (about **185 MB**) compared to Arisa (**76.7 kB**): when it generates tools they end up disorganized, and the overall framework feels overloaded.
7
+ The initial inspiration was OpenClaw, which has interesting ideas but carries a lot of weight (about **185 MB**) compared to Arisa (**76.7 kB**): when it generates tools they end up disorganized, and the overall framework feels overloaded.
8
8
 
9
9
  The real heart of OpenClaw is Pi Agent: a [minimal terminal coding harness](https://www.youtube.com/watch?v=Dli5slNaJu0) that lets an AI agent reason and act with very little infrastructure. That part is genuinely good.
10
10
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "arisa",
3
- "version": "3.2.0",
3
+ "version": "3.2.2",
4
4
  "description": "Telegram + Pi Agent modular assistant",
5
5
  "type": "module",
6
6
  "main": "src/index.js",
@@ -186,8 +186,16 @@ function sessionEventLogMessage(event) {
186
186
 
187
187
  async function collectText(session, prompt, { logger, chatId } = {}) {
188
188
  let text = "";
189
+ let shouldSeparateAssistantMessage = false;
189
190
  const unsubscribe = session.subscribe((event) => {
191
+ if (event.type === "message_start" && event.message.role === "assistant") {
192
+ shouldSeparateAssistantMessage = text.trim().length > 0;
193
+ }
190
194
  if (event.type === "message_update" && event.assistantMessageEvent.type === "text_delta") {
195
+ if (shouldSeparateAssistantMessage && event.assistantMessageEvent.delta) {
196
+ text += "\n\n";
197
+ shouldSeparateAssistantMessage = false;
198
+ }
191
199
  text += event.assistantMessageEvent.delta;
192
200
  }
193
201
  const logMessage = sessionEventLogMessage(event);