anomalyco / anomalyco/opencode
[FEATURE]: Add generation completion sentinels
@kitlangton is already working on this.
Since Aug 9, 2026.
- Dominant language
- TypeScript
- Stars
- 209k
- Forks
- 27.5k
- PR merge metrics
- PR metrics pending
Description
Feature hasn't been suggested before.
- I checked that there is no active issue. This replaces #25921, which was closed as stale.
Describe the enhancement you want to request
I previously opened #25921 and #25924 for this. The PR passed its checks, and I have kept the branch rebased against dev since then. Automated cleanup closed the PR before a maintainer reviewed it, and the issue was later closed for inactivity.
Current dev still has the same problem. script/generate.ts and packages/sdk/js/script/build.ts can produce a lot of output, but neither prints a clear final success line. If an agent or tool truncates the output, I cannot tell whether generation finished.
The change would stay small:
await $`bun ./packages/sdk/js/script/build.ts`;
console.log("opencode generate: sdk build complete");
await $`bun dev generate > ../sdk/openapi.json`.cwd("packages/opencode");
console.log("opencode generate: openapi export complete");
await $`./script/format.ts`;
console.log("opencode generate: format complete");
console.log("opencode generate complete");
- add logs only after successful steps
- add
opencode sdk js build completeto the SDK script because it is also run directly - leave
packages/opencode/src/cli/cmd/generate.tsunchanged because its stdout is redirected toopenapi.json
I still think this is worth implementing. I have been keeping branch linked in #25924 continuously maintained and updated against dev, so you can check that out for my reference implementation.
Process: human-directed and reviewed, with agentic assistance from openai/gpt-5.6-sol/high.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.