СледваСледващо ръководство
Наказание за повторение и контроли за декодиране
Езиков AI
Език AI РЪКОВОДСТВО
Mirostat is a feedback-based decoding algorithm that aims to regulate the average surprisal of generated tokens toward a target.
Чуйте това ръководствоAI-разказан · ~2 min
In its standard formulation tau specifies a target cross-entropy in bits, corresponding to perplexity 2^tau; it adjusts a truncation threshold, without guaranteeing every passage’s perplexity or factual correctness.
Standard top-k and top-p decoding apply fixed cutoffs, while the predictability of generated text can vary across a passage. Mirostat, proposed by Basu and colleagues in 2020, treats decoding as a feedback-control problem. In the standard formulation, tau is a target average surprisal or cross-entropy in bits; the corresponding perplexity is 2^tau. The sampler measures token surprisal and adjusts a truncation threshold based on the difference from the target. If generated tokens are less surprising than the target, the threshold can be loosened; if they are more surprising, it can be tightened. This aims to regulate average surprise over generation and does not require each token or passage to match the target exactly. It does not measure factual correctness.
Поддържане на дълги поколения истории или ролеви игри в местни LLM приложения като KoboldAI от колапс в повтарящи се цикли.
Излага се в llama.cpp и Ollama като настройки на mirostat (режим 1 или 2, tau, eta) за любители, настройващи качеството на изхода.
Стабилизиране на отговорите на чатбота, така че те нито да повтарят фрази, нито да се отклоняват в несвързани допирателни по време на дълга сесия.
Използва се от писатели, които искат постоянно ниво на креативност в целия генериран пасаж, вместо променливо качество.
Mirostat options are exposed in some local inference tools; llama.cpp, for example, documents mode, tau and eta parameters. Availability and behavior depend on the runtime and version. Its control-theoretic framing is inspiring further adaptive decoders that regulate other signals like factuality or diversity. As long-form generation grows, expect feedback-driven sampling to be combined with retrieval and repetition penalties, and possibly auto-tuned tau values that adapt to genre, replacing manual perplexity targets.
Безплатен бюлетин
Три проверени AI истории всяка делнична сутрин, написани на достъпен език. Безплатно завинаги, без реклами.
Един имейл всеки делничен ден. Отписване с едно кликване. Никога не продаваме и не споделяме вашия имейл адрес.
Тествайте себе си
Незабавна обратна връзка за всеки отговор и сертификат за споделяне с подлежащ на проверка идентификационен номер, след като преминете курс.
Подкрепете безплатното AI образование. AI Understanding е 501(c)(3) с нестопанска цел — без реклами, без платен достъп, никога. Направете дарение
Mirostat is a feedback-based decoding algorithm that aims to regulate the average surprisal of generated tokens toward a target. In its standard formulation tau specifies a target cross-entropy in bits, corresponding to perplexity 2^tau; it adjusts a truncation threshold, without guaranteeing every passage’s perplexity or factual correctness.
Mirostat uses feedback to adjust its sampling threshold toward a target surprise or perplexity level.
Top-k и top-p прилагат фиксиран праг, докато Mirostat непрекъснато коригира своето съкращаване въз основа на наблюдаваната изненада, като система за контрол.
Eta е скоростта на обучение; той мащабира колко силно се актуализира контролната променлива mu в отговор на грешката между наблюдаваната и целевата изненада.
Mirostat 2 премахва зависимостта от предположенията на закона на Zipf, използвани във версия 1, което прави алгоритъма по-прост и по-широко надежден в различните модели.
llama.cpp documents a Mirostat mode plus tau and eta parameters for its sampling implementation.
Продължавай да учиш
Още ръководства, избрани за тази тема
СледваСледващо ръководство
Наказание за повторение и контроли за декодиране
Езиков AI