Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions pkg/constants/constants.go
Original file line number Diff line number Diff line change
Expand Up @@ -424,8 +424,12 @@ const (
LLamaVllmFTServingServedModelNamePrefix = "/data"
)

// DefaultModelLocalMountPath is where models will be mounted by the storage-initializer
const DefaultModelLocalMountPath = "/mnt/models"
const (
// DefaultModelLocalMountPath is where models will be mounted by the storage-initializer.
DefaultModelLocalMountPath = "/mnt/models"
// ModelArtifactsDirectory is the node-local shared artifact directory under a model store.
ModelArtifactsDirectory = "_artifacts"
)

var (
ServiceAnnotationDisallowedList = []string{
Expand Down
30 changes: 30 additions & 0 deletions pkg/modelagent/artifact_object_filter.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
package modelagent

import (
"strings"

"github.com/oracle/oci-go-sdk/v65/objectstorage"
)

func filterInternalArtifactObjectSummaries(objects []objectstorage.ObjectSummary) []objectstorage.ObjectSummary {
filtered := make([]objectstorage.ObjectSummary, 0, len(objects))
for _, object := range objects {
if object.Name != nil && isInternalArtifactObjectName(*object.Name) {
continue
}
filtered = append(filtered, object)
}
return filtered
}

func isInternalArtifactObjectName(objectName string) bool {
return isArtifactCompleteMarkerObjectName(objectName) || isArtifactUploadLockObjectName(objectName)
}

func isArtifactCompleteMarkerObjectName(objectName string) bool {
return objectName == artifactCompleteMarkerFileName || strings.HasSuffix(objectName, "/"+artifactCompleteMarkerFileName)
}

func isArtifactUploadLockObjectName(objectName string) bool {
return objectName == artifactUploadLockFileName || strings.HasSuffix(objectName, "/"+artifactUploadLockFileName)
}
Loading
Loading