Slice 0 (#24): gbot_thread summary plus cursor by default - #45
Conversation
…ll:true Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
🦋 Changeset detectedLatest commit: d15d261 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
Co-authored-by: Zack Jackson <ScriptedAlchemy@users.noreply.github.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d15d261a94
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| inputSchema: z.object({ | ||
| // ponytail: the route inputJsonSchema type cannot express minimum/maximum, so the | ||
| // 1-200 bound lives here in zod (and in the CLI/gateway); widen the route type to align them. | ||
| after: z.string().min(1).max(RECEIPT_CURSOR_MAX).optional(), |
There was a problem hiding this comment.
Make the empty-thread cursor reusable
When the first poll targets an empty thread, transcriptDelta returns cursor: "", but this schema rejects that cursor on the next call because of .min(1). This breaks the advertised workflow of passing the previous cursor as after precisely when polling starts before the first message; return a non-empty sentinel cursor or accept the emitted empty cursor. The CLI has the same incompatibility in its --after length validation.
Useful? React with 👍 / 👎.
Slices 0–1 for epic #24: token-cheap thread receipts plus client-held watermark polling.
Behavior
gbot_threaddefaults to a bounded receipt containing onlysummary, opaquecursor,entryCount, andgapReset. Default structured content has no entries;Agent.Textis summary-only.full:trueadds bounded entries (20k chars each / 200k aggregate with truncation metadata) to structured content without duplicating bodies intoAgent.Text.afterand CLIgbot thread --after IDare exclusive, client-side filters. Known cursor returns only newer rows; unchanged returnsentryCount: 0; unknown/expired cursor returns one bounded reset receipt withgapReset: true(repeat withfull:trueto inspect that snapshot).limit; trailing idless rows produce an explicit gap reset instead of a healthy non-advancing poll.Subtractions
Agent.Textbodies.afterwithout creating a second persistence surface.Packaging
The private plugin is not part of the npm tarball and has no publishable changeset target. The patch changeset describes only the packaged CLI
--afterfeature. The existing hold-fixes changeset onmainand release PR #44 are unchanged.Scope
No watermark database, second history ledger, Desktop pipe, cargo-conductor, React components, room server, native delta endpoint, approval changes, or new production dependencies.
Gateway status
UNVERIFIED native capability: no claim is made that the live gateway accepts
after. Requests intentionally remaingetAgentTranscriptTail { id, limit }; filtering is local and covered by loopback tests.Verification
npm test— 113/113 passed.cd plugin && npm run check— validation, build, artifact validation, typecheck, and 13/13 route-unit tests passed.npm pack --dry-run --json— packagedsrc/cli.jsandsrc/transcript.js; excluded privateplugin/as expected.