@astrosheep/square 0.3.37 → 0.3.38

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.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "square",
3
- "version": "0.3.37",
3
+ "version": "0.3.38",
4
4
  "description": "Native Claude Code turn-boundary delivery for Square participants",
5
5
  "author": {
6
6
  "name": "Square"
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "square",
3
- "version": "0.3.37",
3
+ "version": "0.3.38",
4
4
  "description": "Shared Square activity with reliable participant attention at Codex boundaries.",
5
5
  "author": {
6
6
  "name": "Square"
@@ -16,8 +16,7 @@
16
16
  "type": "command",
17
17
  "command": "square codex-hook",
18
18
  "timeout": 5,
19
- "statusMessage": "square-codex-hook",
20
- "additionalContextLimit": 1200
19
+ "statusMessage": "square-codex-hook"
21
20
  }
22
21
  ]
23
22
  }
@@ -1,5 +1,5 @@
1
1
  import type { DirectedNotificationRoute } from './model.js';
2
- export declare const ATTENTION_BODY_MAX = 120;
2
+ export declare const ATTENTION_BODY_MAX = 100;
3
3
  export interface AttentionPreview {
4
4
  squarePath: string;
5
5
  actIndex: number;
@@ -2,7 +2,7 @@ import { homedir } from 'node:os';
2
2
  import { notificationMessageId } from './delivery.js';
3
3
  import { participantIdentity } from './presentation.js';
4
4
  import { formatActivityId } from './square-core.js';
5
- export const ATTENTION_BODY_MAX = 120;
5
+ export const ATTENTION_BODY_MAX = 100;
6
6
  export function previewAttentionBody(body) {
7
7
  const compact = body.replace(/\r\n/g, '\n');
8
8
  if (compact.length <= ATTENTION_BODY_MAX)
@@ -23,6 +23,5 @@ export function renderAttentionPreview(attention) {
23
23
  return [
24
24
  `${id}: ${participantIdentity(attention.recipient)} from ${participantIdentity(attention.actor)} (${attentionKind})`,
25
25
  previewAttentionBody(normalizedBody),
26
- ...(normalizedBody.length <= ATTENTION_BODY_MAX ? ['✓ shown in full'] : []),
27
26
  ].join('\n');
28
27
  }
@@ -39,6 +39,7 @@ function renderBoundary(inbox) {
39
39
  const blocks = [];
40
40
  const complete = [];
41
41
  let omitted = 0;
42
+ const duplicateHint = 'ignore if you have already seen this.';
42
43
  for (const [index, entry] of queued.entries()) {
43
44
  const { membership, notification } = entry;
44
45
  const block = [
@@ -59,6 +60,7 @@ function renderBoundary(inbox) {
59
60
  ...(omittedAfter > 0
60
61
  ? [`… ${omittedAfter} unread ${omittedAfter === 1 ? 'notification' : 'notifications'} omitted.`]
61
62
  : []),
63
+ duplicateHint,
62
64
  ...footer,
63
65
  ].join('\n');
64
66
  if (prospective.length > CONTEXT_MAX) {
@@ -79,6 +81,7 @@ function renderBoundary(inbox) {
79
81
  ...(omitted > 0
80
82
  ? [`… ${omitted} unread ${omitted === 1 ? 'notification' : 'notifications'} omitted.`]
81
83
  : []),
84
+ duplicateHint,
82
85
  ...footer,
83
86
  ].join('\n'),
84
87
  complete,
@@ -125,7 +125,7 @@ export async function deliverPending(input) {
125
125
  continue;
126
126
  }
127
127
  const attemptN = attempts.reduce((highest, record) => Math.max(highest, record.attemptN ?? 0), 0) + 1;
128
- const request = { location: input.location, participant: membership.recipient, activity, route: requestRoute };
128
+ const request = { location: input.location, participant: membership.recipient, activity, actor: notification.item.actor, route: requestRoute };
129
129
  let outcome;
130
130
  const claim = await input.hostLedger.claimEvidence({ location: input.location, participant: membership.recipient, session: route.session, activity, kind: 'wake', leaseMs, now: input.now });
131
131
  if (claim.status !== 'acquired') {
@@ -33,7 +33,7 @@ function renderWakePayload(request) {
33
33
  return [
34
34
  `<system-reminder source="square" wake="${wakeLabel(request.route.kind)}">`,
35
35
  `square: ${displayAttentionPath(request.location)}`,
36
- `attention: ${request.activity} for ${request.participant}`,
36
+ `attention: ${request.activity} for ${request.participant} from ${request.actor}`,
37
37
  '</system-reminder>',
38
38
  ].join('\n');
39
39
  }
package/dist/ports.d.ts CHANGED
@@ -30,6 +30,7 @@ export interface WakeRequest {
30
30
  readonly location: string;
31
31
  readonly participant: string;
32
32
  readonly activity: string;
33
+ readonly actor: string;
33
34
  readonly route: WakeRoute;
34
35
  }
35
36
  /** Executor-neutral presentation capability; intentionally separate from wake transport. */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@astrosheep/square",
3
- "version": "0.3.37",
3
+ "version": "0.3.38",
4
4
  "description": "A shared public square where agents join, catch activity, express, and step out when done.",
5
5
  "type": "module",
6
6
  "bin": {