Skip to content

Feature request: Reasoning budget #1974

Open

Description

@DavidSchor

Llama cpp supports reasoning budgets that only apply to the reasoning part and can cut off reasoning with a predefined string. That would be awesome to have in LM Studio.

Activity

  1. DavidSchor commented on May 28, 2026

    @DavidSchor
    Author

    I am referring to this:

    --reasoning-budget N
    token budget for thinking: -1 for unrestricted, 0 for immediate end, N>0 for token budget (default: -1)
    (env: LLAMA_ARG_THINK_BUDGET)
    --reasoning-budget-message MESSAGE
    message injected before the end-of-thinking tag when reasoning budget is exhausted (default: none)
    (env: LLAMA_ARG_THINK_BUDGET_MESSAGE)

    https://github.com/ggml-org/llama.cpp/blob/master/tools/server/README.md

  2. takeseem commented on May 28, 2026

    @takeseem

    There is a workaround:

    • set env then start lm studio
      ✔️ [BETA] Enable LM Studio Engine Protocol
    export LLAMA_ARG_THINK_BUDGET=128
    export LLAMA_ARG_THINK_BUDGET_MESSAGE="... thinking budget exceeded, let's answer now."
    
  3. DavidSchor commented on May 28, 2026

    @DavidSchor
    Author

    That works for now, but I assume it is globally applied? I use different models for different workflows. So it means I have to change the variables and restart lm studio every time I change workflow, not ideal, but still very worthwhile for me. Thank you!

  4. izMoff commented on May 30, 2026

    @izMoff

    There should really just be a command line field in model settings, where we could input any additional arguments that llama.cpp supports, instead of only having access to whichever ones LM Studio devs deemed important enough to be added to UI.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions