You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
package nn
|
|
|
|
import "github.com/ollama/ollama/ml"
|
|
|
|
type Embedding struct {
|
|
Weight ml.Tensor `gguf:"weight"`
|
|
}
|
|
|
|
func (m *Embedding) Forward(ctx ml.Context, hiddenState ml.Tensor) ml.Tensor {
|
|
return m.Weight.Rows(ctx, hiddenState)
|
|
}
|