Add stage execution limits and result-first workflow views
This commit is contained in:
@@ -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)
|
||||
}
|
||||
Reference in New Issue
Block a user