anomalyco / anomalyco/opencode

[FEATURE]: v2 SDK: bind agent/model/variant options to queued prompts

Open
#48,356 1 comment 0 reactions 1 assignee View on GitHub

@neriousy is already working on this.

Since Sep 10, 2026.

Dominant language
TypeScript
Stars
209k
Forks
27.5k
Avg merge
7h 2m
Merged PRs (30d)
384

Description

Verification
  • I have verified this feature I'm about to request hasn't been suggested before.
Describe the enhancement you want to request

I am porting Kimaki to v2. I need to queue a prompt with its own agent, model, and variant without changing the work already running.

Proposed SDK API:

await client.session.prompt({
  sessionID,
  text: "Review the changes",
  delivery: "queue",
  agent: "review",
  model: {
    providerID: "anthropic",
    modelID: "claude-opus-4-6",
    variant: "high",
  },
})

Store these options with the durable input and apply them when it is delivered, not when it is queued. Omitted options keep the existing behavior.

Today, separate session.switchAgent() / session.switchModel() calls change session-wide selection before the queued prompt runs. Attaching options to the input would let Kimaki use the OpenCode queue directly instead of keeping a separate client-side queue to coordinate selection.

This is a proposed API capability, not a reproduced concurrency bug.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.