Files
markbaseengine/Sources/MarkBase/Embedding/TextEmbeddingConfig.swift
T
MarkBase Admin 8a66b9086a
CI / build (push) Has been cancelled
CI / unit-tests (push) Has been cancelled
CI / lint (push) Has been cancelled
v2: Initial clean branch with unit tests + CI/CD pipeline
- Started from ac75faa (initial E4B-MarkBase integration)
- Kept Sources/ (all engine code) + Package.swift + .gitignore
- Removed all ad-hoc tests, documentation, scripts, Python files
- Added Tests/00_Unit/ (MathTest, TokenizerTest, SamplerTest)
- Added .gitea/workflows/ci.yaml (build + unit tests + lint)
- Added Scripts/check_resources.sh (memory-aware test runner)
- Added Tests/Manifest.json (resource requirements for all tests)
- Focus: 4-bit quantized models only
2026-07-05 13:29:25 +08:00

18 lines
446 B
Swift

import Foundation
public struct TextEmbeddingConfig: Codable, Sendable {
public var modelType: String
public var poolingMethod: PoolingMethod
public var normalize: Bool
public init(
modelType: String = "gemma-2b",
poolingMethod: PoolingMethod = .mean,
normalize: Bool = true
) {
self.modelType = modelType
self.poolingMethod = poolingMethod
self.normalize = normalize
}
}