Documentation
¶
Index ¶
- func AddOrUpdateDoc(engine unsafe.Pointer, buffer []byte) int
- func BuildIndex(engine unsafe.Pointer) int
- func Close(engine unsafe.Pointer) int
- func CreateTable(engine unsafe.Pointer, table *Table) int
- func DeSerialize(buffer []byte, resp *vearchpb.SearchResponse)
- func DelDocByQuery(engine unsafe.Pointer, request *Request) int
- func DeleteDoc(engine unsafe.Pointer, docID []byte) int
- func Dump(engine unsafe.Pointer) int
- func GetDocByID(engine unsafe.Pointer, docID []byte, doc *Doc) int
- func GetEngineCfg(engine unsafe.Pointer, config *Config)
- func GetEngineStatus(engine unsafe.Pointer, status *EngineStatus)
- func Init(config *Config) unsafe.Pointer
- func Load(engine unsafe.Pointer) int
- func Search(engine unsafe.Pointer, reqByte []byte) (int, []byte)
- func SearchRequestSerialize(request *vearchpb.SearchRequest) []byte
- func SetEngineCfg(engine unsafe.Pointer, config *Config) int
- type Attribute
- type BatchResult
- type CacheInfo
- type Config
- type DataType
- type DistanceMetricType
- type Doc
- type EngineStatus
- type Field
- type FieldInfo
- type RangeFilter
- type Request
- type Response
- type ResultItem
- type SearchResult
- type SearchResultCode
- type Table
- type TermFilter
- type VectorInfo
- type VectorQuery
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuildIndex ¶
func DeSerialize ¶
func DeSerialize(buffer []byte, resp *vearchpb.SearchResponse)
func GetEngineCfg ¶
func GetEngineStatus ¶
func GetEngineStatus(engine unsafe.Pointer, status *EngineStatus)
func SearchRequestSerialize ¶
func SearchRequestSerialize(request *vearchpb.SearchRequest) []byte
Types ¶
type BatchResult ¶
func AddOrUpdateDocs ¶
func AddOrUpdateDocs(engine unsafe.Pointer, buffer [][]byte) BatchResult
func (*BatchResult) DeSerialize ¶
func (batch_result *BatchResult) DeSerialize(buffer []byte)
type Config ¶
type Config struct {
Path string
LogDir string
CacheInfos []*CacheInfo
// contains filtered or unexported fields
}
func (*Config) DeSerialize ¶
type DistanceMetricType ¶
type DistanceMetricType uint8
type Doc ¶
func (*Doc) DeSerialize ¶
type EngineStatus ¶
type EngineStatus struct {
IndexStatus int32
TableMem int64
VectorMem int64
FieldRangeMem int64
BitmapMem int64
DocNum int32
MaxDocid int32
MinIndexedNum int32
// contains filtered or unexported fields
}
func (*EngineStatus) DeSerialize ¶
func (status *EngineStatus) DeSerialize(buffer []byte)
func (*EngineStatus) Serialize ¶
func (status *EngineStatus) Serialize(buffer *[]byte) int
type RangeFilter ¶
type Request ¶
type Request struct {
ReqNum int32
TopN int32
BruteForceSearch int32
VecFields []VectorQuery
Fields []string
RangeFilters []RangeFilter
TermFilters []TermFilter
OnlineLogLevel string
RetrievalParams string
HasRank bool
MultiVectorRank int32
ParallelBasedOnQuery bool
L2Sqrt bool
IvfFlat bool
// contains filtered or unexported fields
}
type Response ¶
type Response struct {
Results []SearchResult
OnlineLogMessage string
// contains filtered or unexported fields
}
func (*Response) DeSerialize ¶
type ResultItem ¶
type SearchResult ¶
type SearchResult struct {
Total int32
ResultCode SearchResultCode
Msg string
ResultItems []ResultItem
}
type SearchResultCode ¶
type SearchResultCode uint8
const ( SUCCESS SearchResultCode = 0 INDEX_NOT_TRAINED SearchResultCode = 1 SEARCH_ERROR SearchResultCode = 2 )
type Table ¶
type Table struct {
Name string
Fields []FieldInfo
VectorsInfos []VectorInfo
IndexingSize int32
RetrievalType string
RetrievalParam string
RetrievalTypes []string
RetrievalParams []string
// contains filtered or unexported fields
}
func (*Table) DeSerialize ¶
type TermFilter ¶
type VectorInfo ¶
Click to show internal directories.
Click to hide internal directories.