Documentation
¶
Overview ¶
Package generatedclient provides primitives to interact with the openapi HTTP API.
Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.5.1 DO NOT EDIT.
Index ¶
- func NewCreateFactoryRequest(server string, body CreateFactoryJSONRequestBody) (*http.Request, error)
- func NewCreateFactoryRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)
- func NewGetCurrentFactoryRequest(server string) (*http.Request, error)
- type BundledFile
- type BundledFileContent
- type BundledFileContentEncoding
- type BundledFileType
- type Client
- func (c *Client) CreateFactory(ctx context.Context, body CreateFactoryJSONRequestBody, ...) (*http.Response, error)
- func (c *Client) CreateFactoryWithBody(ctx context.Context, contentType string, body io.Reader, ...) (*http.Response, error)
- func (c *Client) GetCurrentFactory(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
- type ClientInterface
- type ClientOption
- type ClientWithResponses
- func (c *ClientWithResponses) CreateFactoryWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, ...) (*CreateFactoryClientResponse, error)
- func (c *ClientWithResponses) CreateFactoryWithResponse(ctx context.Context, body CreateFactoryJSONRequestBody, ...) (*CreateFactoryClientResponse, error)
- func (c *ClientWithResponses) GetCurrentFactoryWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetCurrentFactoryClientResponse, error)
- type ClientWithResponsesInterface
- type CreateFactoryBadRequest
- type CreateFactoryClientResponse
- type CreateFactoryConflict
- type CreateFactoryJSONRequestBody
- type CurrentFactoryNotFound
- type ErrorFamily
- type ErrorResponse
- type ErrorResponseCode
- type Factory
- type FactoryGuard
- type FactoryName
- type GetCurrentFactoryClientResponse
- type Guard
- type GuardMatchConfig
- type GuardType
- type HttpRequestDoer
- type InputKind
- type InputType
- type InternalError
- type RequestEditorFn
- type RequiredTool
- type Resource
- type ResourceManifest
- type ResourceRequirement
- type StringMap
- type WorkState
- type WorkStateType
- type WorkType
- type Worker
- type WorkerModelProvider
- type WorkerProvider
- type WorkerType
- type Workstation
- type WorkstationCron
- type WorkstationIO
- type WorkstationKind
- type WorkstationLimits
- type WorkstationType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewCreateFactoryRequest ¶
func NewCreateFactoryRequest(server string, body CreateFactoryJSONRequestBody) (*http.Request, error)
NewCreateFactoryRequest calls the generic CreateFactory builder with application/json body
Types ¶
type BundledFile ¶
type BundledFile struct {
// Content Inline content payload for a portable bundled file.
Content BundledFileContent `json:"content"`
// TargetPath Canonical factory-relative restoration target for the bundled file. Absolute paths, backslash-separated paths, and paths that require dot-segment normalization are rejected.
TargetPath string `json:"targetPath"`
// Type Portable file class. SCRIPT entries target factory/scripts/..., DOC entries target factory/docs/..., and ROOT_HELPER entries target supported project-root helper files such as Makefile.
Type BundledFileType `json:"type"`
}
BundledFile One explicit portable bundled file entry carried by the factory portability manifest. SCRIPT files target factory/scripts/..., DOC files target factory/docs/..., and ROOT_HELPER files target supported project-root helper paths such as Makefile.
type BundledFileContent ¶
type BundledFileContent struct {
// Encoding Declared content encoding for the inline payload. V1 bundled files use UTF-8 text content.
Encoding BundledFileContentEncoding `json:"encoding"`
// Inline Inline bundled file content carried in the manifest. Files under factory/scripts/, factory/docs/, and supported root helper paths are only bundled when they appear in bundledFiles.
Inline string `json:"inline"`
}
BundledFileContent Inline content payload for a portable bundled file.
type BundledFileContentEncoding ¶
type BundledFileContentEncoding string
BundledFileContentEncoding Declared content encoding for the inline payload. V1 bundled files use UTF-8 text content.
const (
Utf8 BundledFileContentEncoding = "utf-8"
)
Defines values for BundledFileContentEncoding.
type BundledFileType ¶
type BundledFileType string
BundledFileType Portable file class. SCRIPT entries target factory/scripts/..., DOC entries target factory/docs/..., and ROOT_HELPER entries target supported project-root helper files such as Makefile.
const ( DOC BundledFileType = "DOC" ROOTHELPER BundledFileType = "ROOT_HELPER" SCRIPT BundledFileType = "SCRIPT" )
Defines values for BundledFileType.
type Client ¶
type Client struct {
// The endpoint of the server conforming to this interface, with scheme,
// https://api.deepmap.com for example. This can contain a path relative
// to the server, such as https://api.deepmap.com/dev-test, and all the
// paths in the swagger spec will be appended to the server.
Server string
// Doer for performing requests, typically a *http.Client with any
// customized settings, such as certificate chains.
Client HttpRequestDoer
// A list of callbacks for modifying requests which are generated before sending over
// the network.
RequestEditors []RequestEditorFn
}
Client which conforms to the OpenAPI3 specification for this service.
func NewClient ¶
func NewClient(server string, opts ...ClientOption) (*Client, error)
Creates a new Client, with reasonable defaults
func (*Client) CreateFactory ¶
func (c *Client) CreateFactory(ctx context.Context, body CreateFactoryJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
func (*Client) CreateFactoryWithBody ¶
func (*Client) GetCurrentFactory ¶
type ClientInterface ¶
type ClientInterface interface {
// CreateFactoryWithBody request with any body
CreateFactoryWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)
CreateFactory(ctx context.Context, body CreateFactoryJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
// GetCurrentFactory request
GetCurrentFactory(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)
}
The interface specification for the client above.
type ClientOption ¶
ClientOption allows setting custom parameters during construction
func WithHTTPClient ¶
func WithHTTPClient(doer HttpRequestDoer) ClientOption
WithHTTPClient allows overriding the default Doer, which is automatically created using http.Client. This is useful for tests.
func WithRequestEditorFn ¶
func WithRequestEditorFn(fn RequestEditorFn) ClientOption
WithRequestEditorFn allows setting up a callback function, which will be called right before sending the request. This can be used to mutate the request.
type ClientWithResponses ¶
type ClientWithResponses struct {
ClientInterface
}
ClientWithResponses builds on ClientInterface to offer response payloads
func NewClientWithResponses ¶
func NewClientWithResponses(server string, opts ...ClientOption) (*ClientWithResponses, error)
NewClientWithResponses creates a new ClientWithResponses, which wraps Client with return type handling
func (*ClientWithResponses) CreateFactoryWithBodyWithResponse ¶
func (c *ClientWithResponses) CreateFactoryWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateFactoryClientResponse, error)
CreateFactoryWithBodyWithResponse request with arbitrary body returning *CreateFactoryClientResponse
func (*ClientWithResponses) CreateFactoryWithResponse ¶
func (c *ClientWithResponses) CreateFactoryWithResponse(ctx context.Context, body CreateFactoryJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateFactoryClientResponse, error)
func (*ClientWithResponses) GetCurrentFactoryWithResponse ¶
func (c *ClientWithResponses) GetCurrentFactoryWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetCurrentFactoryClientResponse, error)
GetCurrentFactoryWithResponse request returning *GetCurrentFactoryClientResponse
type ClientWithResponsesInterface ¶
type ClientWithResponsesInterface interface {
// CreateFactoryWithBodyWithResponse request with any body
CreateFactoryWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*CreateFactoryClientResponse, error)
CreateFactoryWithResponse(ctx context.Context, body CreateFactoryJSONRequestBody, reqEditors ...RequestEditorFn) (*CreateFactoryClientResponse, error)
// GetCurrentFactoryWithResponse request
GetCurrentFactoryWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetCurrentFactoryClientResponse, error)
}
ClientWithResponsesInterface is the interface specification for the client with responses above.
type CreateFactoryBadRequest ¶
type CreateFactoryBadRequest = ErrorResponse
CreateFactoryBadRequest defines model for CreateFactoryBadRequest.
type CreateFactoryClientResponse ¶
type CreateFactoryClientResponse struct {
Body []byte
HTTPResponse *http.Response
JSON201 *Factory
JSON400 *CreateFactoryBadRequest
JSON409 *CreateFactoryConflict
JSON500 *InternalError
}
func ParseCreateFactoryClientResponse ¶
func ParseCreateFactoryClientResponse(rsp *http.Response) (*CreateFactoryClientResponse, error)
ParseCreateFactoryClientResponse parses an HTTP response from a CreateFactoryWithResponse call
func (CreateFactoryClientResponse) Status ¶
func (r CreateFactoryClientResponse) Status() string
Status returns HTTPResponse.Status
func (CreateFactoryClientResponse) StatusCode ¶
func (r CreateFactoryClientResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type CreateFactoryConflict ¶
type CreateFactoryConflict = ErrorResponse
CreateFactoryConflict defines model for CreateFactoryConflict.
type CreateFactoryJSONRequestBody ¶
type CreateFactoryJSONRequestBody = Factory
CreateFactoryJSONRequestBody defines body for CreateFactory for application/json ContentType.
type CurrentFactoryNotFound ¶
type CurrentFactoryNotFound = ErrorResponse
CurrentFactoryNotFound defines model for CurrentFactoryNotFound.
type ErrorFamily ¶
type ErrorFamily string
ErrorFamily Stable machine-readable error family for broader client grouping.
const ( ErrorFamilyBadRequest ErrorFamily = "BAD_REQUEST" ErrorFamilyConflict ErrorFamily = "CONFLICT" ErrorFamilyInternalServerError ErrorFamily = "INTERNAL_SERVER_ERROR" ErrorFamilyNotFound ErrorFamily = "NOT_FOUND" )
Defines values for ErrorFamily.
type ErrorResponse ¶
type ErrorResponse struct {
// Code Stable machine-readable error code.
Code ErrorResponseCode `json:"code"`
// Family Stable machine-readable error family for broader client grouping.
Family ErrorFamily `json:"family"`
Message string `json:"message"`
}
ErrorResponse defines model for ErrorResponse.
type ErrorResponseCode ¶
type ErrorResponseCode string
ErrorResponseCode Stable machine-readable error code.
const ( BADREQUEST ErrorResponseCode = "BAD_REQUEST" FACTORYALREADYEXISTS ErrorResponseCode = "FACTORY_ALREADY_EXISTS" FACTORYNOTIDLE ErrorResponseCode = "FACTORY_NOT_IDLE" INTERNALERROR ErrorResponseCode = "INTERNAL_ERROR" INVALIDFACTORY ErrorResponseCode = "INVALID_FACTORY" INVALIDFACTORYNAME ErrorResponseCode = "INVALID_FACTORY_NAME" NOTFOUND ErrorResponseCode = "NOT_FOUND" )
Defines values for ErrorResponseCode.
type Factory ¶
type Factory struct {
// FactoryDirectory Directory that contained the factory.json used for this serialized runtime config.
FactoryDirectory *string `json:"factoryDirectory,omitempty"`
// Guards Root-level guards that apply across the factory instead of one specific workstation or input.
Guards *[]FactoryGuard `json:"guards,omitempty"`
// Id Factory identifier used as the factory-level template context fallback.
Id *string `json:"id,omitempty"`
// InputTypes Named input kinds accepted by the factory. The default input type is implicit and must not be declared.
InputTypes *[]InputType `json:"inputTypes,omitempty"`
Metadata *StringMap `json:"metadata,omitempty"`
// Name Customer-facing identifier for one stored named factory. `GET /factory/~current` may also return the reserved `UNDEFINED` identifier when the active runtime is still the default root factory and no durable current-factory pointer exists. Semantic validation failures return `INVALID_FACTORY_NAME`, including attempts to activate a named factory with the reserved identifier.
Name FactoryName `json:"name"`
// Resources Shared capacity pools that workers or workstations can consume while work is executing.
Resources *[]Resource `json:"resources,omitempty"`
// SourceDirectory Original source directory for record/replay and drift diagnostics.
SourceDirectory *string `json:"sourceDirectory,omitempty"`
// SupportingFiles Canonical portability manifest for Agent Factory bundles. Required tools are validation-only PATH dependencies; bundled files carry portable content for restoration inside the factory boundary.
SupportingFiles *ResourceManifest `json:"supportingFiles,omitempty"`
// WorkTypes Customer-authored work item categories and the lifecycle states each one can occupy.
WorkTypes *[]WorkType `json:"workTypes,omitempty"`
// Workers Reusable worker definitions that workstations reference by name when dispatching work.
Workers *[]Worker `json:"workers,omitempty"`
// Workstations Processing steps that consume work, invoke workers, and emit the next work states.
Workstations *[]Workstation `json:"workstations,omitempty"`
}
Factory Top-level factory.json contract. Declare the work types, resources, portability resources, workers, and workstations that make up one authored factory here. Guarded loop breakers should be authored as guarded LOGICAL_MOVE workstations using VISIT_COUNT guards instead of a top-level exhaustion-rules field.
type FactoryGuard ¶
type FactoryGuard struct {
// Model Optional model name to scope throttling more narrowly than the provider-level window.
Model *string `json:"model,omitempty"`
// ModelProvider Provider whose inference-throttle history controls this factory-level guard.
ModelProvider WorkerModelProvider `json:"modelProvider"`
// RefreshWindow Duration string that controls how long the factory should keep re-checking throttle history before allowing the lane again.
RefreshWindow string `json:"refreshWindow"`
// Type Factory-level guard condition to evaluate before dispatch-ready transitions can proceed.
Type GuardType `json:"type"`
}
FactoryGuard Factory-level guard attached at the root factory definition.
type FactoryName ¶
type FactoryName = string
FactoryName Customer-facing identifier for one stored named factory. `GET /factory/~current` may also return the reserved `UNDEFINED` identifier when the active runtime is still the default root factory and no durable current-factory pointer exists. Semantic validation failures return `INVALID_FACTORY_NAME`, including attempts to activate a named factory with the reserved identifier.
type GetCurrentFactoryClientResponse ¶
type GetCurrentFactoryClientResponse struct {
Body []byte
HTTPResponse *http.Response
JSON200 *Factory
JSON404 *CurrentFactoryNotFound
JSON500 *InternalError
}
func ParseGetCurrentFactoryClientResponse ¶
func ParseGetCurrentFactoryClientResponse(rsp *http.Response) (*GetCurrentFactoryClientResponse, error)
ParseGetCurrentFactoryClientResponse parses an HTTP response from a GetCurrentFactoryWithResponse call
func (GetCurrentFactoryClientResponse) Status ¶
func (r GetCurrentFactoryClientResponse) Status() string
Status returns HTTPResponse.Status
func (GetCurrentFactoryClientResponse) StatusCode ¶
func (r GetCurrentFactoryClientResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type Guard ¶
type Guard struct {
// MatchConfig For `MATCHES_FIELDS` guards, the field-selector configuration used to compare candidate inputs.
MatchConfig *GuardMatchConfig `json:"matchConfig,omitempty"`
// MatchInput For `SAME_NAME` input guards, the peer input workType name from another input in the same workstation.
MatchInput *string `json:"matchInput,omitempty"`
// MaxVisits For `VISIT_COUNT` guards, the visit threshold.
MaxVisits *int `json:"maxVisits,omitempty"`
// ParentInput For parent-aware input guards, the parent workType name from another input in the same workstation.
ParentInput *string `json:"parentInput,omitempty"`
// SpawnedBy For dynamic fanout input guards, the workstation that spawns the children for count tracking.
SpawnedBy *string `json:"spawnedBy,omitempty"`
// Type Guard condition to evaluate for this workstation-level or input-level attachment.
Type GuardType `json:"type"`
// Workstation For `VISIT_COUNT` guards, the workstation whose visits are counted.
Workstation *string `json:"workstation,omitempty"`
}
Guard Shared guard attached either to a workstation as a whole or to one specific workstation input.
type GuardMatchConfig ¶
type GuardMatchConfig struct {
// InputKey Field selector resolved against each candidate input, such as `.Name` or `.Tags["_last_output"]`.
InputKey string `json:"inputKey"`
}
GuardMatchConfig defines model for GuardMatchConfig.
type GuardType ¶
type GuardType string
GuardType Guard condition attached to a workstation or one of its specific inputs.
const ( GuardTypeAllChildrenComplete GuardType = "ALL_CHILDREN_COMPLETE" GuardTypeAnyChildFailed GuardType = "ANY_CHILD_FAILED" GuardTypeInferenceThrottle GuardType = "INFERENCE_THROTTLE_GUARD" GuardTypeMatchesFields GuardType = "MATCHES_FIELDS" GuardTypeSameName GuardType = "SAME_NAME" GuardTypeVisitCount GuardType = "VISIT_COUNT" )
Defines values for GuardType.
type HttpRequestDoer ¶
Doer performs HTTP requests.
The standard http.Client implements this interface.
type InputKind ¶
type InputKind string
InputKind Kinds of input. `DEFAULT` passes opaque input through to workstations as-is.
const (
InputKindDefault InputKind = "DEFAULT"
)
Defines values for InputKind.
type InputType ¶
type InputType struct {
// Name Input type name. The reserved name "default" is implicit.
Name string `json:"name"`
// Type Kinds of input. `DEFAULT` passes opaque input through to workstations as-is.
Type InputKind `json:"type"`
}
InputType Declared types of inputs. Used to force the inputs of a certain work type to be of a certain shape, like a specific JSON structure.
type InternalError ¶
type InternalError = ErrorResponse
InternalError defines model for InternalError.
type RequestEditorFn ¶
RequestEditorFn is the function signature for the RequestEditor callback function
type RequiredTool ¶
type RequiredTool struct {
// Command Executable lookup token that must resolve on PATH.
Command string `json:"command"`
// Name Human-readable tool name used in manifests and validation output.
Name string `json:"name"`
// Purpose Optional explanation of why the portable factory requires this tool.
Purpose *string `json:"purpose,omitempty"`
// VersionArgs Optional argument vector used by future validation flows to probe the tool version without changing the executable lookup token.
VersionArgs *[]string `json:"versionArgs,omitempty"`
}
RequiredTool One declarative external tool dependency for a portable factory.
type Resource ¶
type Resource struct {
// Capacity Total units of this resource available to the factory at one time.
Capacity int `json:"capacity"`
// Name Resource name referenced from worker requirements and workstation resourceUsage entries.
Name string `json:"name"`
}
Resource Shared capacity that limits how much work the factory can run at once, such as worker slots or external service quotas.
type ResourceManifest ¶
type ResourceManifest struct {
// BundledFiles Portable bundled files that belong inside the factory boundary. Entries are explicit only, use factory-relative target paths, and must stay under the canonical script or docs roots for SCRIPT or DOC entries, or match the supported root-helper allowlist for ROOT_HELPER entries.
BundledFiles *[]BundledFile `json:"bundledFiles,omitempty"`
// RequiredTools Declarative external tools that must already resolve on PATH. These entries are validated but not embedded or installed.
RequiredTools *[]RequiredTool `json:"requiredTools,omitempty"`
}
ResourceManifest Canonical portability manifest for Agent Factory bundles. Required tools are validation-only PATH dependencies; bundled files carry portable content for restoration inside the factory boundary.
type ResourceRequirement ¶
ResourceRequirement defines model for ResourceRequirement.
type WorkState ¶
type WorkState struct {
// Name Customer-authored state name referenced by workstation inputs and outputs.
Name string `json:"name"`
// Type Categories of work states. The factory runtime treats these categories differently for lifecycle tracking and metrics purposes. Initial: The work is waiting to be picked up by a workstation. Processing: The work has been partially processed, and is continuing through its lifecycle. Terminal: The work has completed successfully. Failed: The work has failed.
Type WorkStateType `json:"type"`
}
WorkState A lifecycle state that a work item can occupy inside one work type.
type WorkStateType ¶
type WorkStateType string
WorkStateType Categories of work states. The factory runtime treats these categories differently for lifecycle tracking and metrics purposes. Initial: The work is waiting to be picked up by a workstation. Processing: The work has been partially processed, and is continuing through its lifecycle. Terminal: The work has completed successfully. Failed: The work has failed.
const ( WorkStateTypeFAILED WorkStateType = "FAILED" WorkStateTypeINITIAL WorkStateType = "INITIAL" WorkStateTypePROCESSING WorkStateType = "PROCESSING" WorkStateTypeTERMINAL WorkStateType = "TERMINAL" )
Defines values for WorkStateType.
type WorkType ¶
type WorkType struct {
// Name Customer-authored work type name referenced by workstation inputs, outputs, and submitted work.
Name string `json:"name"`
// States Lifecycle states available for work items of this type.
States []WorkState `json:"states"`
}
WorkType A named category of work that can move through the factory. Each work type declares the lifecycle states its work items can occupy.
type Worker ¶
type Worker struct {
// Args Additional command arguments passed to the configured command.
Args *[]string `json:"args,omitempty"`
// Body Inline worker instructions or script body when the worker is authored directly in factory config.
Body *string `json:"body,omitempty"`
// Command Command to execute when this worker runs through a command or script provider.
Command *string `json:"command,omitempty"`
// ExecutorProvider Concrete worker-provider wrappers supported by the public factory-config contract.
ExecutorProvider *WorkerProvider `json:"executorProvider,omitempty"`
// Model Model identifier to request from the configured model provider when this worker uses model execution.
Model *string `json:"model,omitempty"`
// ModelProvider Canonical model-provider identifiers supported by model workers in factory config.
ModelProvider *WorkerModelProvider `json:"modelProvider,omitempty"`
// Name Worker name referenced by Workstation.worker.
Name string `json:"name"`
// Resources Resource capacity this worker requires before it can be dispatched.
Resources *[]ResourceRequirement `json:"resources,omitempty"`
// SkipPermissions When true, bypasses permission checks for providers that support permission gating.
SkipPermissions *bool `json:"skipPermissions,omitempty"`
// StopToken Marker that tells model-oriented workers where to stop generated output when the provider supports it.
StopToken *string `json:"stopToken,omitempty"`
// Timeout Optional Go duration that caps one worker execution attempt.
Timeout *string `json:"timeout,omitempty"`
// Type Worker implementation families supported by the public factory-config contract.
Type *WorkerType `json:"type,omitempty"`
}
Worker A reusable worker definition that tells the factory how a workstation should execute work, such as through a model-backed agent or a script.
type WorkerModelProvider ¶
type WorkerModelProvider string
WorkerModelProvider Canonical model-provider identifiers supported by model workers in factory config.
const ( WorkerModelProviderClaude WorkerModelProvider = "CLAUDE" WorkerModelProviderCodex WorkerModelProvider = "CODEX" )
Defines values for WorkerModelProvider.
type WorkerProvider ¶
type WorkerProvider string
WorkerProvider Concrete worker-provider wrappers supported by the public factory-config contract.
const (
WorkerProviderScriptWrap WorkerProvider = "SCRIPT_WRAP"
)
Defines values for WorkerProvider.
type WorkerType ¶
type WorkerType string
WorkerType Worker implementation families supported by the public factory-config contract.
const ( WorkerTypeModelWorker WorkerType = "MODEL_WORKER" WorkerTypeScriptWorker WorkerType = "SCRIPT_WORKER" )
Defines values for WorkerType.
type Workstation ¶
type Workstation struct {
// Behavior Scheduling kind for a workstation, which determines how the engine schedules and dispatches work to it. Standard workstations are scheduled as soon as their inputs are ready, and can have multiple work items in-flight at the same time. Repeater workstations are triggered whenever their inputs change, and will reloop the outputs on rejection back to the initial place. Cron workstations create internal time work and dispatch their configured worker when time and input guards are satisfied.
Behavior *WorkstationKind `json:"behavior,omitempty"`
// Body Inline workstation instructions or script body when authored directly in factory config.
Body *string `json:"body,omitempty"`
// CopyReferencedScripts Copy supported referenced script files into the expanded workstation layout when config expand runs.
CopyReferencedScripts *bool `json:"copyReferencedScripts,omitempty"`
// Cron Trigger timing for cron workstations. Cron workstations use a schedule expression; interval triggers are not supported.
Cron *WorkstationCron `json:"cron,omitempty"`
Env *StringMap `json:"env,omitempty"`
// Guards Guarded loop breakers should use `VISIT_COUNT` guards here with a `LOGICAL_MOVE` workstation instead of top-level exhaustion rules.
Guards *[]Guard `json:"guards,omitempty"`
// Id Optional stable identifier for this workstation in serialized runtime and replay payloads.
Id *string `json:"id,omitempty"`
// Inputs Work states this workstation can consume before it dispatches.
Inputs []WorkstationIO `json:"inputs"`
// Limits Retry and execution ceilings applied to one workstation definition.
Limits *WorkstationLimits `json:"limits,omitempty"`
// Name Customer-authored workstation name used by guards, diagnostics, and authored references.
Name string `json:"name"`
// OnContinue Optional destination emitted when the workstation makes partial progress and should continue iterating.
OnContinue *[]WorkstationIO `json:"onContinue,omitempty"`
// OnFailure Optional destination emitted when the workstation fails permanently.
OnFailure *[]WorkstationIO `json:"onFailure,omitempty"`
// OnRejection Optional destination emitted when the worker rejects the current work without a hard failure.
OnRejection *[]WorkstationIO `json:"onRejection,omitempty"`
// OutputSchema JSON schema string used to validate or parse structured model output when configured.
OutputSchema *string `json:"outputSchema,omitempty"`
// Outputs Work states emitted after this workstation succeeds.
Outputs []WorkstationIO `json:"outputs"`
// PromptFile Path to a prompt template file loaded for model-oriented workstation execution.
PromptFile *string `json:"promptFile,omitempty"`
// Resources Resource capacity this workstation consumes while one dispatch is in flight.
Resources *[]ResourceRequirement `json:"resources,omitempty"`
// StopWords Stop words authored on the topology entry for model-oriented dispatches.
StopWords *[]string `json:"stopWords,omitempty"`
// Type Runtime workstation implementation types supported by the public factory-config contract.
Type *WorkstationType `json:"type,omitempty"`
// Worker Name of a worker declared in the workers list.
Worker string `json:"worker"`
// WorkingDirectory Go template resolved from token tags at dispatch time.
WorkingDirectory *string `json:"workingDirectory,omitempty"`
// Worktree Go template resolved and passed as the worktree path to CLI dispatchers.
Worktree *string `json:"worktree,omitempty"`
}
Workstation A processing step in the factory graph. Workstations consume authored work states, run a worker or logical move, and emit the next work states.
type WorkstationCron ¶
type WorkstationCron struct {
// ExpiryWindow Positive Go duration after due_at before a stale cron time token expires and can be consumed by the system expiry transition. Defaults to the duration until the next scheduled cron fire when omitted.
ExpiryWindow *string `json:"expiryWindow,omitempty"`
// Jitter Non-negative Go duration used as the maximum deterministic delay added to scheduled time tokens. Defaults to "0s".
Jitter *string `json:"jitter,omitempty"`
// Schedule Standard five-field cron expression used to produce internal time work while the factory service is running.
Schedule string `json:"schedule"`
// TriggerAtStart When true, service startup submits one immediate internal time work item before waiting for the next scheduled cron fire.
TriggerAtStart *bool `json:"triggerAtStart,omitempty"`
}
WorkstationCron Trigger timing for cron workstations. Cron workstations use a schedule expression; interval triggers are not supported.
type WorkstationIO ¶
type WorkstationIO struct {
// Guards Per-input guards that must pass before this specific input can be used.
Guards *[]Guard `json:"guards,omitempty"`
// State Name of the work state consumed or emitted for the referenced work type.
State string `json:"state"`
// WorkType Name of the work type consumed or emitted at this edge of the workstation.
WorkType string `json:"workType"`
}
WorkstationIO One authored work-state reference consumed or emitted by a workstation.
type WorkstationKind ¶
type WorkstationKind string
WorkstationKind Scheduling kind for a workstation, which determines how the engine schedules and dispatches work to it. Standard workstations are scheduled as soon as their inputs are ready, and can have multiple work items in-flight at the same time. Repeater workstations are triggered whenever their inputs change, and will reloop the outputs on rejection back to the initial place. Cron workstations create internal time work and dispatch their configured worker when time and input guards are satisfied.
const ( WorkstationKindCron WorkstationKind = "CRON" WorkstationKindRepeater WorkstationKind = "REPEATER" WorkstationKindStandard WorkstationKind = "STANDARD" )
Defines values for WorkstationKind.
type WorkstationLimits ¶
type WorkstationLimits struct {
// MaxExecutionTime Go duration limit for one dispatch attempt before it times out.
MaxExecutionTime *string `json:"maxExecutionTime,omitempty"`
// MaxRetries Maximum number of retry attempts after a failed dispatch before the workstation gives up.
MaxRetries *int `json:"maxRetries,omitempty"`
}
WorkstationLimits Retry and execution ceilings applied to one workstation definition.
type WorkstationType ¶
type WorkstationType string
WorkstationType Runtime workstation implementation types supported by the public factory-config contract.
const ( WorkstationTypeLogicalMove WorkstationType = "LOGICAL_MOVE" WorkstationTypeModelWorkstation WorkstationType = "MODEL_WORKSTATION" )
Defines values for WorkstationType.