Add stage execution limits and result-first workflow views

This commit is contained in:
2026-10-10 03:03:46 +01:00
parent 7b10e3889e
commit a66d540125
35 changed files with 1392 additions and 93 deletions
+16
View File
@@ -0,0 +1,16 @@
package opencode
import (
"context"
"fmt"
)
// BudgetMessages uses the same owned endpoint and credentials, without sharing
// mutable request diagnostics or generation state with the main connection.
func (c *Connection) BudgetMessages(ctx context.Context, id string) ([]byte, error) {
if !sessionID.MatchString(id) {
return nil, fmt.Errorf("invalid session ID")
}
reader := &Connection{Backend: c.Backend, Executable: c.Executable, Directory: c.Directory, URL: c.URL, password: c.password}
return reader.Messages(ctx, id)
}