provider

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2026 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ConvertRequest

type ConvertRequest struct {
	OriginalTaskID string `json:"originalTaskId" jsonschema:"Task ID of the model to convert"`
	Format         string `json:"format" jsonschema:"Desired output format: GLTF, FBX, OBJ, STL, USDZ, or 3MF"`
}

ConvertRequest describes a format conversion request.

type ImageToModelRequest

type ImageToModelRequest struct {
	ImagePath      string `json:"imagePath,omitempty" jsonschema:"Local file path to the reference image. Mutually exclusive with imageUrl"`
	ImageURL       string `json:"imageUrl,omitempty" jsonschema:"Public URL of the reference image. Mutually exclusive with imagePath"`
	ModelVersion   string `json:"modelVersion,omitempty" jsonschema:"Model version. Defaults to latest"`
	FaceLimit      int    `json:"faceLimit,omitempty" jsonschema:"Target polygon face count"`
	TextureQuality string `json:"textureQuality,omitempty" jsonschema:"Texture quality: standard or detailed"`
	Orientation    string `json:"orientation,omitempty" jsonschema:"Model orientation: default or align_image"`
}

ImageToModelRequest describes an image-to-3D generation request.

type ModelGenerator

type ModelGenerator interface {
	TextToModel(ctx context.Context, req TextToModelRequest) (*ModelOperation, error)
	ImageToModel(ctx context.Context, req ImageToModelRequest) (*ModelOperation, error)
	MultiviewToModel(ctx context.Context, req MultiviewToModelRequest) (*ModelOperation, error)
}

ModelGenerator handles 3D model creation from various inputs.

type ModelInfo

type ModelInfo struct {
	Name         string   `json:"name"`
	ID           string   `json:"id"`
	Description  string   `json:"description"`
	Capabilities []string `json:"capabilities"`
}

ModelInfo describes an available model version and its capabilities.

type ModelLister

type ModelLister interface {
	ListModels(ctx context.Context) ([]ModelInfo, error)
}

ModelLister provides model/version discovery.

type ModelOperation

type ModelOperation struct {
	TaskID string `json:"taskId"`
	Status string `json:"status"`
}

ModelOperation represents an in-progress async 3D generation task.

type ModelPostProcessor

type ModelPostProcessor interface {
	Retopologize(ctx context.Context, req RetopologyRequest) (*ModelOperation, error)
	ConvertFormat(ctx context.Context, req ConvertRequest) (*ModelOperation, error)
	Stylize(ctx context.Context, req StylizeRequest) (*ModelOperation, error)
}

ModelPostProcessor handles retopology, format conversion, and stylization.

type ModelResult

type ModelResult struct {
	FilePath     string `json:"filePath"`
	Format       string `json:"format"`
	TaskID       string `json:"taskId"`
	ModelVersion string `json:"modelVersion,omitempty"`
}

ModelResult contains the result of a completed model download.

type ModelStatus

type ModelStatus interface {
	Status(ctx context.Context, taskID string) (*ModelTaskStatus, error)
	Download(ctx context.Context, taskID string, format string) (*ModelResult, error)
}

ModelStatus handles async task polling and model download.

type ModelTaskStatus

type ModelTaskStatus struct {
	TaskID   string `json:"taskId"`
	Status   string `json:"status"`
	Progress int    `json:"progress"`
	Error    string `json:"error,omitempty"`
}

ModelTaskStatus represents the current state of a 3D generation task.

type MultiviewToModelRequest

type MultiviewToModelRequest struct {
	ImagePaths   []string `` /* 138-byte string literal not displayed */
	ImageURLs    []string `` /* 134-byte string literal not displayed */
	ModelVersion string   `json:"modelVersion,omitempty" jsonschema:"Model version. Defaults to latest"`
	FaceLimit    int      `json:"faceLimit,omitempty" jsonschema:"Target polygon face count"`
}

MultiviewToModelRequest describes a multi-view image-to-3D generation request.

type RetopologyRequest

type RetopologyRequest struct {
	OriginalTaskID string `json:"originalTaskId" jsonschema:"Task ID of the model to retopologize"`
	Quad           bool   `json:"quad,omitempty" jsonschema:"Produce quad mesh instead of triangles"`
	TargetFaces    int    `json:"targetFaces,omitempty" jsonschema:"Target face count for the lowpoly output"`
}

RetopologyRequest describes a retopology/lowpoly conversion request.

type StylizeRequest

type StylizeRequest struct {
	OriginalTaskID string `json:"originalTaskId" jsonschema:"Task ID of the model to stylize"`
	Style          string `json:"style" jsonschema:"Stylization style: lego, voxel, voronoi, or minecraft"`
}

StylizeRequest describes a stylization request.

type TextToModelRequest

type TextToModelRequest struct {
	Prompt         string `json:"prompt" jsonschema:"Text description of the 3D model to generate"`
	NegativePrompt string `json:"negativePrompt,omitempty" jsonschema:"What to avoid in the generation"`
	ModelVersion   string `json:"modelVersion,omitempty" jsonschema:"Model version (e.g. v2.5, v3.0, v3.1). Defaults to latest"`
	FaceLimit      int    `json:"faceLimit,omitempty" jsonschema:"Target polygon face count"`
}

TextToModelRequest describes a text-to-3D generation request.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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