mirror of
https://github.com/syntrex-lab/gomcp.git
synced 2026-05-10 20:12:36 +02:00
chore: add copyright headers, CI tests, and sanitize gitignore
This commit is contained in:
parent
5cbb3d89d3
commit
d1f844235e
325 changed files with 2267 additions and 902 deletions
|
|
@ -1,3 +1,7 @@
|
|||
// Copyright 2026 Syntrex Lab. All rights reserved.
|
||||
// Use of this source code is governed by an Apache-2.0 license
|
||||
// that can be found in the LICENSE file.
|
||||
|
||||
// Package vectorstore — PolarQuant multi-bit vector compression.
|
||||
//
|
||||
// Based on Google's TurboQuant research (ICLR 2026, §3.2).
|
||||
|
|
@ -187,7 +191,7 @@ func (c *PolarQuantCodec) CompressedBytes() int {
|
|||
|
||||
// CompressionRatio returns the ratio of original to compressed size.
|
||||
func (c *PolarQuantCodec) CompressionRatio() float64 {
|
||||
origBytes := c.dim * 8 // float64
|
||||
origBytes := c.dim * 8 // float64
|
||||
compBytes := c.CompressedBytes() + 4 // + float32 radius
|
||||
return float64(origBytes) / float64(compBytes)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue