Mancer parameters:

- Add XTC
- Add DRY
- Remove Mirostat
This commit is contained in:
50h100a
2025-05-10 19:04:32 -04:00
parent e6530cb22d
commit 2aa5addb1d
2 changed files with 14 additions and 3 deletions

View File

@@ -1406,7 +1406,7 @@
</div>
</div>
<div data-tg-type="koboldcpp, aphrodite, tabby, ooba, llamacpp" id="xtc_block" class="wide100p">
<div data-tg-type="koboldcpp, aphrodite, mancer, tabby, ooba, llamacpp" id="xtc_block" class="wide100p">
<h4 class="wide100p textAlignCenter">
<label data-i18n="Exclude Top Choices (XTC)">Exclude Top Choices (XTC)</label>
<a href="https://github.com/oobabooga/text-generation-webui/pull/6335" target="_blank">
@@ -1427,7 +1427,7 @@
</div>
</div>
<div data-tg-type="aphrodite, ooba, koboldcpp, tabby, llamacpp, dreamgen" id="dryBlock" class="wide100p">
<div data-tg-type="aphrodite, mancer, ooba, koboldcpp, tabby, llamacpp, dreamgen" id="dryBlock" class="wide100p">
<h4 class="wide100p textAlignCenter" title="DRY penalizes tokens that would extend the end of the input into a sequence that has previously occurred in the input. Set multiplier to 0 to disable." data-i18n="[title]DRY_Repetition_Penalty_desc">
<label data-i18n="DRY Repetition Penalty">DRY Repetition Penalty</label>
<a href="https://github.com/oobabooga/text-generation-webui/pull/5677" target="_blank">
@@ -1493,7 +1493,7 @@
</div>
</div>
</div>
<div data-tg-type="ooba,infermaticai,koboldcpp,llamacpp,mancer,ollama,tabby" id="mirostat_block_ooba" class="wide100p">
<div data-tg-type="ooba,infermaticai,koboldcpp,llamacpp,ollama,tabby" id="mirostat_block_ooba" class="wide100p">
<h4 class="wide100p textAlignCenter">
<label data-i18n="Mirostat (mode=1 is only for llama.cpp)">Mirostat</label>
<div class=" fa-solid fa-circle-info opacity50p " data-i18n="[title]Mirostat_desc" title="Mirostat is a thermostat for output perplexity.&#13;Mirostat matches the output perplexity to that of the input, thus avoiding the repetition trap&#13;(where, as the autoregressive inference produces text, the perplexity of the output tends toward zero)&#13;and the confusion trap (where the perplexity diverges).&#13;For details, see the paper Mirostat: A Neural Text Decoding Algorithm that Directly Controls Perplexity by Basu et al. (2020).&#13;Mode chooses the Mirostat version. 0=disable, 1=Mirostat 1.0 (llama.cpp only), 2=Mirostat 2.0."></div>

View File

@@ -1439,6 +1439,17 @@ export async function getTextGenGenerationData(finalPrompt, maxTokens, isImperso
params.dynatemp_max = params.dynatemp_high;
delete params.dynatemp_low;
delete params.dynatemp_high;
const sequenceBreakers = (() => {
try {
return JSON.parse(params.dry_sequence_breakers);
} catch {
if (typeof params.dry_sequence_breakers === 'string') {
return params.dry_sequence_breakers.split(',');
}
return undefined;
}
})();
params.dry_sequence_breakers = sequenceBreakers;
}
if (settings.type === TABBY) {