models

package
v0.20231211.1135715 Latest Latest
Warning

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

Go to latest
Published: Dec 11, 2023 License: MPL-2.0 Imports: 13 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/cognitive/2023-05-01/models Documentation

The models SDK allows for interaction with the Azure Resource Manager Service cognitive (API Version 2023-05-01).

This readme covers example usages, but further information on using this SDK can be found in the project root.

Import Path

import "github.com/hashicorp/go-azure-sdk/resource-manager/cognitive/2023-05-01/models"

Client Initialization

client := models.NewModelsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: ModelsClient.List

ctx := context.TODO()
id := models.NewLocationID("12345678-1234-9876-4563-123456789012", "locationValue")

// alternatively `client.List(ctx, id)` can be used to do batched pagination
items, err := client.ListComplete(ctx, id)
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForModelLifecycleStatus

func PossibleValuesForModelLifecycleStatus() []string

func ValidateLocationID

func ValidateLocationID(input interface{}, key string) (warnings []string, errors []error)

ValidateLocationID checks that 'input' can be parsed as a Location ID

Types

type AccountModel

type AccountModel struct {
	BaseModel            *DeploymentModel       `json:"baseModel,omitempty"`
	CallRateLimit        *CallRateLimit         `json:"callRateLimit,omitempty"`
	Capabilities         *map[string]string     `json:"capabilities,omitempty"`
	Deprecation          *ModelDeprecationInfo  `json:"deprecation,omitempty"`
	FinetuneCapabilities *map[string]string     `json:"finetuneCapabilities,omitempty"`
	Format               *string                `json:"format,omitempty"`
	IsDefaultVersion     *bool                  `json:"isDefaultVersion,omitempty"`
	LifecycleStatus      *ModelLifecycleStatus  `json:"lifecycleStatus,omitempty"`
	MaxCapacity          *int64                 `json:"maxCapacity,omitempty"`
	Name                 *string                `json:"name,omitempty"`
	Skus                 *[]ModelSku            `json:"skus,omitempty"`
	Source               *string                `json:"source,omitempty"`
	SystemData           *systemdata.SystemData `json:"systemData,omitempty"`
	Version              *string                `json:"version,omitempty"`
}

type CallRateLimit

type CallRateLimit struct {
	Count         *float64          `json:"count,omitempty"`
	RenewalPeriod *float64          `json:"renewalPeriod,omitempty"`
	Rules         *[]ThrottlingRule `json:"rules,omitempty"`
}

type CapacityConfig

type CapacityConfig struct {
	Default *int64 `json:"default,omitempty"`
	Maximum *int64 `json:"maximum,omitempty"`
	Minimum *int64 `json:"minimum,omitempty"`
	Step    *int64 `json:"step,omitempty"`
}

type DeploymentModel

type DeploymentModel struct {
	CallRateLimit *CallRateLimit `json:"callRateLimit,omitempty"`
	Format        *string        `json:"format,omitempty"`
	Name          *string        `json:"name,omitempty"`
	Source        *string        `json:"source,omitempty"`
	Version       *string        `json:"version,omitempty"`
}

type ListCompleteResult

type ListCompleteResult struct {
	Items []Model
}

type ListOperationResponse

type ListOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]Model
}

type LocationId

type LocationId struct {
	SubscriptionId string
	LocationName   string
}

LocationId is a struct representing the Resource ID for a Location

func NewLocationID

func NewLocationID(subscriptionId string, locationName string) LocationId

NewLocationID returns a new LocationId struct

func ParseLocationID

func ParseLocationID(input string) (*LocationId, error)

ParseLocationID parses 'input' into a LocationId

func ParseLocationIDInsensitively

func ParseLocationIDInsensitively(input string) (*LocationId, error)

ParseLocationIDInsensitively parses 'input' case-insensitively into a LocationId note: this method should only be used for API response data and not user input

func (*LocationId) FromParseResult added in v0.20231127.1171502

func (id *LocationId) FromParseResult(input resourceids.ParseResult) error

func (LocationId) ID

func (id LocationId) ID() string

ID returns the formatted Location ID

func (LocationId) Segments

func (id LocationId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Location ID

func (LocationId) String

func (id LocationId) String() string

String returns a human-readable description of this Location ID

type Model

type Model struct {
	Kind    *string       `json:"kind,omitempty"`
	Model   *AccountModel `json:"model,omitempty"`
	SkuName *string       `json:"skuName,omitempty"`
}

type ModelDeprecationInfo

type ModelDeprecationInfo struct {
	FineTune  *string `json:"fineTune,omitempty"`
	Inference *string `json:"inference,omitempty"`
}

type ModelLifecycleStatus

type ModelLifecycleStatus string
const (
	ModelLifecycleStatusGenerallyAvailable ModelLifecycleStatus = "GenerallyAvailable"
	ModelLifecycleStatusPreview            ModelLifecycleStatus = "Preview"
)

func (*ModelLifecycleStatus) UnmarshalJSON

func (s *ModelLifecycleStatus) UnmarshalJSON(bytes []byte) error

type ModelOperationPredicate

type ModelOperationPredicate struct {
	Kind    *string
	SkuName *string
}

func (ModelOperationPredicate) Matches

func (p ModelOperationPredicate) Matches(input Model) bool

type ModelSku

type ModelSku struct {
	Capacity        *CapacityConfig  `json:"capacity,omitempty"`
	DeprecationDate *string          `json:"deprecationDate,omitempty"`
	Name            *string          `json:"name,omitempty"`
	RateLimits      *[]CallRateLimit `json:"rateLimits,omitempty"`
	UsageName       *string          `json:"usageName,omitempty"`
}

func (*ModelSku) GetDeprecationDateAsTime

func (o *ModelSku) GetDeprecationDateAsTime() (*time.Time, error)

func (*ModelSku) SetDeprecationDateAsTime

func (o *ModelSku) SetDeprecationDateAsTime(input time.Time)

type ModelsClient

type ModelsClient struct {
	Client *resourcemanager.Client
}

func NewModelsClientWithBaseURI

func NewModelsClientWithBaseURI(sdkApi sdkEnv.Api) (*ModelsClient, error)

func (ModelsClient) List

func (c ModelsClient) List(ctx context.Context, id LocationId) (result ListOperationResponse, err error)

List ...

func (ModelsClient) ListComplete

func (c ModelsClient) ListComplete(ctx context.Context, id LocationId) (ListCompleteResult, error)

ListComplete retrieves all the results into a single object

func (ModelsClient) ListCompleteMatchingPredicate

func (c ModelsClient) ListCompleteMatchingPredicate(ctx context.Context, id LocationId, predicate ModelOperationPredicate) (result ListCompleteResult, err error)

ListCompleteMatchingPredicate retrieves all the results and then applies the predicate

type RequestMatchPattern

type RequestMatchPattern struct {
	Method *string `json:"method,omitempty"`
	Path   *string `json:"path,omitempty"`
}

type ThrottlingRule

type ThrottlingRule struct {
	Count                    *float64               `json:"count,omitempty"`
	DynamicThrottlingEnabled *bool                  `json:"dynamicThrottlingEnabled,omitempty"`
	Key                      *string                `json:"key,omitempty"`
	MatchPatterns            *[]RequestMatchPattern `json:"matchPatterns,omitempty"`
	MinCount                 *float64               `json:"minCount,omitempty"`
	RenewalPeriod            *float64               `json:"renewalPeriod,omitempty"`
}

Jump to

Keyboard shortcuts

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