LightEffort v2.0
Change Claude Code's effort level with a hotkey.
https://gabrielmoraru.com
Gabriel Moraru - i@gabrielmoraru.com


WHAT IT IS
----------
A small program that sits in the Windows tray and owns five hotkeys:

  Ctrl+Alt+1   /effort low
  Ctrl+Alt+2   /effort medium
  Ctrl+Alt+3   /effort high
  Ctrl+Alt+4   /effort xhigh
  Ctrl+Alt+5   /effort max

Press one while a terminal running Claude Code has the keyboard focus.
LightEffort types the command, presses Enter, and answers the
"Change effort level?" question that Claude Code shows.

It exists because Claude Code has no keyboard shortcut for this. Its only
two actions that touch the effort level, modelPicker:increaseEffort and
modelPicker:decreaseEffort, work only while the model picker window is
open, and a Claude Code plugin cannot add a keybinding. So the change has
to come from outside.


HOW TO USE IT
-------------
1. Unzip anywhere and run LightEffort.exe. No installer, no dependencies.
2. Click on a terminal that is running Claude Code.
3. Press Ctrl+Alt+1 to Ctrl+Alt+5.

The window hides itself after the first run. Click the tray icon once to
bring it back. There is a tick box in it for starting with Windows.

While the focused window is not a terminal, Ctrl+Alt+1 to Ctrl+Alt+5
belong to whatever program you are using. LightEffort takes them again
the moment a terminal comes to the front.

If you already typed something in the prompt box, it is not lost:
LightEffort empties the box, sends the command, and pastes your text
back about three seconds later.


SETTINGS
--------
Edited by hand, while the program is NOT running:

  C:\Users\<you>\AppData\Roaming\LightEffort\LightEffort.ini

The interesting keys are under [Sending] and [Target]:

  AcceptedClasses     window classes that count as a terminal.
                      CASCADIA_HOSTING_WINDOW_CLASS is Windows Terminal,
                      ConsoleWindowClass is the old console window.
  EnterCount          how many Enter presses answer the confirmation.
  EnterDelayMs        milliseconds between them.
  ClearPromptFirst    0 = do not empty the prompt box first.
  RestorePromptAfter  0 = do not paste your typed text back.
  BeepOnRefusal       0 = refuse silently.


WHAT YOU SHOULD KNOW BEFORE USING IT
------------------------------------
- Windows only. It is built on RegisterHotKey and SendInput.

- The exe is digitally signed by SciVance Technologies UG. That does not
  switch Windows SmartScreen off: the certificate is an OV one, not an
  EV one, so until enough people have downloaded the file SmartScreen
  can still say "Windows protected your PC". Click "More info", then
  "Run anyway" - and check that the publisher name in that window reads
  SciVance Technologies UG.

- A prompt longer than 16 screen rows gets cut short, and what is left of
  it is sent to Claude together with the command. Count what you see, not
  what you typed: a long line that wraps over four rows costs four, and
  each line break costs one more. Three short lines cost 5 rows.

- A hotkey press takes about 2.7 seconds before your typed text is back.

- It types into whatever window has the focus. It refuses when the window
  class is not on the list above, and when the target program runs at a
  higher Windows integrity level than LightEffort - Windows silently
  throws such keystrokes away and reports success, so the program checks
  and refuses instead of pretending.

- It takes Ctrl+Alt+1 to Ctrl+Alt+5 away from the whole machine while a
  terminal has the focus.

- Claude Code saves the level you pick as the default for new sessions
  started without an --effort flag.


WHAT IT WRITES ON YOUR PC
-------------------------
One settings file, C:\Users\<you>\AppData\Roaming\LightEffort\, and one
registry value under HKEY_CURRENT_USER\Software\Microsoft\Windows\
CurrentVersion\Run if you tick "start with Windows". Nothing else. It
never reads the text of your prompts - it presses keys, that is all.

It uses the network in exactly one situation: if the program crashes, a
window appears offering to send a bug report, and clicking "Send bug
report" uploads it over HTTPS to reports.scivance.tech. Nothing is sent
unless you click that button, and if you click "Continue application"
instead, nothing leaves your PC.

A bug report holds the call stack, your computer name, your Windows user
name, the operating system, processor and memory, the file paths of the
loaded modules, and the text you type into the report window yourself.
It does NOT hold a screenshot: that is switched off on purpose, because
the screenshot would show your whole desktop. Reports are deleted from
the server after 90 days.


Written in Delphi with the LightSaber library.
https://gabrielmoraru.com/my-delphi-code/
