Skip to content

Commit 531c688

Browse files
committed
Make DRY sampling affected by the 'App defaults' button
1 parent 5e669e4 commit 531c688

File tree

2 files changed

+10
-4
lines changed

2 files changed

+10
-4
lines changed

server.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -498,7 +498,8 @@ def api_reset_to_app_defaults():
498498
sampling_params = [
499499
"temperature", "top_k", "top_p", "min_p", "tfs",
500500
"mirostat", "mirostat_tau", "mirostat_eta", "typical",
501-
"repp", "repr", "repd", "quad_sampling", "temperature_last", "skew"
501+
"repp", "repr", "repd", "quad_sampling", "temperature_last", "skew",
502+
"dry_base", "dry_multiplier", "dry_range"
502503
]
503504

504505
# Reset only sampling parameters to defaults

static/chatsettings.js

+8-3
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,10 @@ export class SessionSettings {
138138
mirostat: this.sss_i_mirostat.element,
139139
mirostat_tau: this.sss_i_mirostat_tau.element.querySelector(".sss-item-left"),
140140
mirostat_eta: this.sss_i_mirostat_eta.element.querySelector(".sss-item-left"),
141-
temperature_last: this.sss_i_temperature_last.element
141+
temperature_last: this.sss_i_temperature_last.element,
142+
dry_base: this.sss_i_dry_base.element.querySelector(".sss-item-left"),
143+
dry_multiplier: this.sss_i_dry_multiplier.element.querySelector(".sss-item-left"),
144+
dry_range: this.sss_i_dry_range.element.querySelector(".sss-item-left")
142145
};
143146

144147
// Helper function to toggle label highlights
@@ -193,7 +196,8 @@ export class SessionSettings {
193196
const samplingParams = [
194197
"temperature", "top_k", "top_p", "min_p", "tfs",
195198
"mirostat", "mirostat_tau", "mirostat_eta", "typical",
196-
"repp", "repr", "quad_sampling", "temperature_last", "skew"
199+
"repp", "repr", "quad_sampling", "temperature_last", "skew",
200+
"dry_base", "dry_multiplier", "dry_range"
197201
];
198202

199203
const diffParams = {};
@@ -255,7 +259,8 @@ export class SessionSettings {
255259
this.sss_i_minP, this.sss_i_quadSampling, this.sss_i_tfs,
256260
this.sss_i_typical, this.sss_i_skew, this.sss_i_repPenalty,
257261
this.sss_i_repRange, this.sss_i_mirostat, this.sss_i_mirostat_tau,
258-
this.sss_i_mirostat_eta, this.sss_i_temperature_last
262+
this.sss_i_mirostat_eta, this.sss_i_temperature_last,
263+
this.sss_i_dry_base, this.sss_i_dry_multiplier, this.sss_i_dry_range
259264
];
260265

261266
// Helper function to update button states

0 commit comments

Comments
 (0)