code.oscarkilo.com/klex-git

Hash:
122d3847b9a4b32706c5e9d066ec5eda6020198a
Author:
Igor Naverniouk <[email protected]>
Date:
Sun May 18 20:05:30 2025 -0700
Message:
bug
diff --git a/api/embed.go b/api/embed.go
index a65d6ef..19e4042 100644
--- a/api/embed.go
+++ b/api/embed.go
@@ -15,5 +15,5 @@ type EmbedRequest struct {

// FullPath returns a sequence of vectors, one per prefix of Text.
// Instead of the usual array of numbers, you'll get a 2D array.
- FullPath bool `json:"whole_path"`
+ FullPath bool `json:"full_path"`
}
a/api/embed.go
b/api/embed.go
1
package api
1
package api
2
2
3
type EmbedRequest struct {
3
type EmbedRequest struct {
4
// Text should be shorter than ~8000 tokens.
4
// Text should be shorter than ~8000 tokens.
5
Text string `json:"text"`
5
Text string `json:"text"`
6
6
7
// Model is an embedding model name.
7
// Model is an embedding model name.
8
// These are hard-coded in //funky/builtins.
8
// These are hard-coded in //funky/builtins.
9
// A good choice is "openai:text-embedding-3-small".
9
// A good choice is "openai:text-embedding-3-small".
10
Model string `json:"model"`
10
Model string `json:"model"`
11
11
12
// Dims is the number of vector dimensions to return.
12
// Dims is the number of vector dimensions to return.
13
// A good chioce is 1536 for openai:text-embedding-3-small.
13
// A good chioce is 1536 for openai:text-embedding-3-small.
14
Dims int `json:"dims"`
14
Dims int `json:"dims"`
15
15
16
// FullPath returns a sequence of vectors, one per prefix of Text.
16
// FullPath returns a sequence of vectors, one per prefix of Text.
17
// Instead of the usual array of numbers, you'll get a 2D array.
17
// Instead of the usual array of numbers, you'll get a 2D array.
18
FullPath bool `json:"whole_path"`
18
FullPath bool `json:"full_path"`
19
}
19
}