Help us shape the future of Go! Take the 2026 Go Developer Survey

workspace

package
v0.1.58 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 26, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package workspace defines conversation-owned UI descriptors shared by renderers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Content

type Content struct {
	WindowID   string                 `json:"windowId,omitempty"`
	Renderer   string                 `json:"renderer"`
	WindowKey  string                 `json:"windowKey,omitempty"`
	Parameters map[string]interface{} `json:"parameters,omitempty"`
}

type Lifecycle

type Lifecycle struct {
	CreatedAt     string `json:"createdAt,omitempty"`
	UpdatedAt     string `json:"updatedAt,omitempty"`
	State         string `json:"state"`
	RestorePolicy string `json:"restorePolicy"`
	RefreshPolicy string `json:"refreshPolicy"`
}

type Object

type Object struct {
	LastActivatedBy Origin            `json:"lastActivatedBy,omitempty"`
	Content         Content           `json:"content"`
	Navigation      map[string]string `json:"navigation,omitempty"`
	Capabilities    map[string]bool   `json:"capabilities,omitempty"`
	StateRef        string            `json:"stateRef,omitempty"`
	Revision        int               `json:"revision"`
	Version         int               `json:"version"`
	ObjectID        string            `json:"objectId"`
	ConversationID  string            `json:"conversationId"`
	Kind            string            `json:"kind"`
	Origin          Origin            `json:"origin"`
	Placement       Placement         `json:"placement"`
	Lifecycle       Lifecycle         `json:"lifecycle"`
}

func New

func New(ctx context.Context, windowID, conversationID string) *Object

New constructs a pending descriptor. Only an acknowledged open may mark it ready. Origin comes from execution context, never resource parameters or assistant prose.

type Origin

type Origin struct {
	MessageID  string `json:"messageId,omitempty"`
	ToolName   string `json:"toolName,omitempty"`
	TurnID     string `json:"turnId,omitempty"`
	ToolCallID string `json:"toolCallId,omitempty"`
}

type Placement

type Placement struct {
	InitialWorkspaceMode string   `json:"initialWorkspaceMode,omitempty"`
	Preferred            string   `json:"preferred"`
	Allowed              []string `json:"allowed"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL