Skip to content

Commit

Permalink
Remove flair from supported models
Browse files Browse the repository at this point in the history
  • Loading branch information
matteo-grella committed Oct 30, 2023
1 parent 200646a commit 4ca06be
Show file tree
Hide file tree
Showing 47 changed files with 2 additions and 3,867 deletions.
10 changes: 0 additions & 10 deletions pkg/converter/converter.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,8 @@ package converter

import (
"fmt"
"strings"

"github.com/nlpodyssey/cybertron/pkg/converter/bart"
"github.com/nlpodyssey/cybertron/pkg/converter/bert"
"github.com/nlpodyssey/cybertron/pkg/converter/flair"
"github.com/nlpodyssey/cybertron/pkg/models"
"github.com/nlpodyssey/spago/mat/float"
)
Expand All @@ -31,19 +28,12 @@ func Convert[T float.DType](modelPath string, overwriteIfExists bool) error {
return bert.Convert[T](modelPath, overwriteIfExists)
case "bart", "marian", "pegasus":
return bart.Convert[T](modelPath, overwriteIfExists)
case "flair":
return flair.Convert[T](modelPath, overwriteIfExists)
default:
return fmt.Errorf("unsupported model type: %#v", modelType)
}
}

func resolveModelType(modelPath string) (string, error) {
if strings.Contains(modelPath, "flair") {
// Handling the case where there is no configuration file
return "flair", nil
}

config, err := models.ReadCommonModelConfig(modelPath, "")
if err != nil {
return "", err
Expand Down
35 changes: 0 additions & 35 deletions pkg/converter/flair/conversion/builtins/getattr.go

This file was deleted.

3 changes: 0 additions & 3 deletions pkg/converter/flair/conversion/builtins/int.go

This file was deleted.

25 changes: 0 additions & 25 deletions pkg/converter/flair/conversion/collections/defaultdict.go

This file was deleted.

32 changes: 0 additions & 32 deletions pkg/converter/flair/conversion/flair/crf.go

This file was deleted.

89 changes: 0 additions & 89 deletions pkg/converter/flair/conversion/flair/dictionary.go

This file was deleted.

106 changes: 0 additions & 106 deletions pkg/converter/flair/conversion/flair/flairembeddings.go

This file was deleted.

Loading

0 comments on commit 4ca06be

Please sign in to comment.