trait HasLlamaCppInferenceProperties extends AnyRef
Contains settable inference parameters for the AutoGGUFModel.
- Self Type
- HasLlamaCppInferenceProperties with ParamsAndFeaturesWritable with HasProtectedParams
- Grouped
- Alphabetic
- By Inheritance
- HasLlamaCppInferenceProperties
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
- val cachePrompt: BooleanParam
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
- val disableTokenIds: IntArrayParam
- val dynamicTemperatureExponent: FloatParam
- val dynamicTemperatureRange: FloatParam
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
- val frequencyPenalty: FloatParam
- def getCachePrompt: Boolean
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def getDisableTokenIds: Array[Int]
- def getDynamicTemperatureExponent: Float
- def getDynamicTemperatureRange: Float
- def getFrequencyPenalty: Float
- def getGrammar: String
- def getIgnoreEos: Boolean
-
def
getInferenceParameters: InferenceParameters
- Attributes
- protected
- def getInputPrefix: String
- def getInputSuffix: String
- def getMinKeep: Int
- def getMinP: Float
- def getMiroStat: String
- def getMiroStatEta: Float
- def getMiroStatTau: Float
- def getNKeep: Int
- def getNPredict: Int
- def getNProbs: Int
- def getPenalizeNl: Boolean
- def getPenaltyPrompt: String
- def getPresencePenalty: Float
- def getRepeatLastN: Int
- def getRepeatPenalty: Float
- def getSamplers: Array[String]
- def getSeed: Int
- def getStopStrings: Array[String]
- def getTemperature: Float
- def getTfsZ: Float
- def getTokenBias: Map[String, Float]
- def getTokenIdBias: Map[Int, Float]
- def getTopK: Int
- def getTopP: Float
- def getTypicalP: Float
- def getUseChatTemplate: Boolean
- val grammar: Param[String]
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- val ignoreEos: BooleanParam
- val inputPrefix: Param[String]
- val inputSuffix: Param[String]
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- val minKeep: IntParam
- val minP: FloatParam
- val miroStat: Param[String]
- val miroStatEta: FloatParam
- val miroStatTau: FloatParam
- val nKeep: IntParam
- val nPredict: IntParam
- val nProbs: IntParam
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- val penalizeNl: BooleanParam
- val penaltyPrompt: Param[String]
- val presencePenalty: FloatParam
- val repeatLastN: IntParam
- val repeatPenalty: FloatParam
- val samplers: StringArrayParam
- val seed: IntParam
-
def
setCachePrompt(cachePrompt: Boolean): HasLlamaCppInferenceProperties.this
Whether to remember the prompt to avoid reprocessing it
-
def
setDisableTokenIds(disableTokenIds: Array[Int]): HasLlamaCppInferenceProperties.this
Set the token ids to disable in the completion.
Set the token ids to disable in the completion. This corresponds to
setTokenBias
with a value ofFloat.NEGATIVE_INFINITY
. -
def
setDynamicTemperatureExponent(dynatempExponent: Float): HasLlamaCppInferenceProperties.this
Set the dynamic temperature exponent
-
def
setDynamicTemperatureRange(dynatempRange: Float): HasLlamaCppInferenceProperties.this
Set the dynamic temperature range
-
def
setFrequencyPenalty(frequencyPenalty: Float): HasLlamaCppInferenceProperties.this
Set the repetition alpha frequency penalty
-
def
setGrammar(grammar: String): HasLlamaCppInferenceProperties.this
Set BNF-like grammar to constrain generations
-
def
setIgnoreEos(ignoreEos: Boolean): HasLlamaCppInferenceProperties.this
Set whether to ignore end of stream token and continue generating (implies --logit-bias 2-inf)
-
def
setInputPrefix(inputPrefix: String): HasLlamaCppInferenceProperties.this
Set the prompt to start generation with
-
def
setInputSuffix(inputSuffix: String): HasLlamaCppInferenceProperties.this
Set a suffix for infilling
-
def
setMinKeep(minKeep: Int): HasLlamaCppInferenceProperties.this
Set the amount of tokens the samplers should return at least (0 = disabled)
-
def
setMinP(minP: Float): HasLlamaCppInferenceProperties.this
Set min-p sampling
-
def
setMiroStat(mirostat: String): HasLlamaCppInferenceProperties.this
Set MiroStat sampling strategies.
Set MiroStat sampling strategies.
- DISABLED: No MiroStat
- V1: MiroStat V1
- V2: MiroStat V2
-
def
setMiroStatEta(mirostatEta: Float): HasLlamaCppInferenceProperties.this
Set the MiroStat learning rate, parameter eta
-
def
setMiroStatTau(mirostatTau: Float): HasLlamaCppInferenceProperties.this
Set the MiroStat target entropy, parameter tau
-
def
setNKeep(nKeep: Int): HasLlamaCppInferenceProperties.this
Set the number of tokens to keep from the initial prompt
-
def
setNPredict(nPredict: Int): HasLlamaCppInferenceProperties.this
Set the number of tokens to predict
-
def
setNProbs(nProbs: Int): HasLlamaCppInferenceProperties.this
Set the amount top tokens probabilities to output if greater than 0.
-
def
setPenalizeNl(penalizeNl: Boolean): HasLlamaCppInferenceProperties.this
Set whether to penalize newline tokens
-
def
setPenaltyPrompt(penaltyPrompt: String): HasLlamaCppInferenceProperties.this
Override which part of the prompt is penalized for repetition.
-
def
setPresencePenalty(presencePenalty: Float): HasLlamaCppInferenceProperties.this
Set the repetition alpha presence penalty
-
def
setRepeatLastN(repeatLastN: Int): HasLlamaCppInferenceProperties.this
Set the last n tokens to consider for penalties
-
def
setRepeatPenalty(repeatPenalty: Float): HasLlamaCppInferenceProperties.this
Set the penalty of repeated sequences of tokens
-
def
setSamplers(samplers: Array[String]): HasLlamaCppInferenceProperties.this
Set which samplers to use for token generation in the given order .
Set which samplers to use for token generation in the given order .
Available Samplers are:
- TOP_K: Top-k sampling
- TFS_Z: Tail free sampling
- TYPICAL_P: Locally typical sampling p
- TOP_P: Top-p sampling
- MIN_P: Min-p sampling
- TEMPERATURE: Temperature sampling
-
def
setSeed(seed: Int): HasLlamaCppInferenceProperties.this
Set the RNG seed
-
def
setStopStrings(stopStrings: Array[String]): HasLlamaCppInferenceProperties.this
Set strings upon seeing which token generation is stopped
-
def
setTemperature(temperature: Float): HasLlamaCppInferenceProperties.this
Set the temperature
-
def
setTfsZ(tfsZ: Float): HasLlamaCppInferenceProperties.this
Set tail free sampling, parameter z
-
def
setTokenBias(tokenBias: HashMap[String, Double]): HasLlamaCppInferenceProperties.this
Set the tokens to disable during completion.
Set the tokens to disable during completion. (Override for PySpark)
-
def
setTokenBias(tokenBias: Map[String, Float]): HasLlamaCppInferenceProperties.this
Set the tokens to disable during completion.
-
def
setTokenIdBias(tokenIdBias: HashMap[Integer, Double]): HasLlamaCppInferenceProperties.this
Set the token ids to disable in the completion.
Set the token ids to disable in the completion. (Override for PySpark)
-
def
setTokenIdBias(tokenIdBias: Map[Int, Float]): HasLlamaCppInferenceProperties.this
Set the token ids to disable in the completion.
-
def
setTopK(topK: Int): HasLlamaCppInferenceProperties.this
Set top-k sampling
-
def
setTopP(topP: Float): HasLlamaCppInferenceProperties.this
Set top-p sampling
-
def
setTypicalP(typicalP: Float): HasLlamaCppInferenceProperties.this
Set locally typical sampling, parameter p
-
def
setUseChatTemplate(useChatTemplate: Boolean): HasLlamaCppInferenceProperties.this
Set whether or not generate should apply a chat template
- val stopStrings: StringArrayParam
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
- val temperature: FloatParam
- val tfsZ: FloatParam
-
def
toString(): String
- Definition Classes
- AnyRef → Any
- val tokenBias: StructFeature[Map[String, Float]]
- val tokenIdBias: StructFeature[Map[Int, Float]]
- val topK: IntParam
- val topP: FloatParam
- val typicalP: FloatParam
- val useChatTemplate: BooleanParam
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
Inherited from AnyRef
Inherited from Any
Parameter setters
Parameter getters
Parameters
A list of (hyper-)parameter keys this annotator can take. Users can set and get the parameter values through setters and getters, respectively.