Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Verbosity finding advertises `tj optimize --validate`, which rejects verbosity

Open
#782 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
cli, python
Domain
cli

Research direction

The bad advice is rendered by _render_verbosity in cli/cmd_optimize.py around lines 2956-2962, and the --validate option is a click.Choice(['downsize']) at lines 156-162. Start by reading the advertised-commands test in tests/unit/test_advertised_commands_are_invocable.py to see why it accepts a bare --validate. The fix direction is unsettled: the issue leans toward extending the feature, but the maintainer has not chosen between the options, so confirm the direction before editing. Done means no rendered screen advertises a flag value the command rejects, and the test fails before the change and passes after.

Written by the indexing model from the issue text.

Description

bug

Symptom

_render_verbosity tells the user to measure the remedy with tj optimize --validate:

Remedy to review (not applied): add a terse system-prompt line and/or a
max_tokens cap near ~620, then measure with tj optimize --validate.

cli/cmd_optimize.py:2956-2962.

The flag does not accept verbosity. --validate is type=click.Choice(["downsize"]) (cmd_optimize.py:156-162), so both forms a reader would try fail:

$ tj optimize --validate
Error: Option '--validate' requires an argument.

$ tj optimize --validate verbosity
Error: Invalid value for '--validate': 'verbosity' is not 'downsize'.

Why it matters beyond the typo

This is the Critical Rule 44 shape: a rendered screen advertises a command, and the command does not resolve. The verbosity finding is explicitly non-committal about its own figure — the caveat tells you to treat it as $0 until measured — so the --validate line is the one actionable next step the card offers. It is the step that does not work.

tests/unit/test_advertised_commands_are_invocable.py parses commands out of rendered screens and fails unless each resolves against the real command tree. It did not catch this one; worth understanding why before fixing, since the gap matters more than the instance. My guess is the bare tj optimize --validate with no argument parses as a resolvable command, so the check passes on a string that cannot actually be run.

Options

  1. Extend --validate to verbosity. The honest version of the feature: re-run a sample of the user's own calls under a max_tokens cap and report the measured delta. Most useful, most work, and it spends the user's money so it needs the same confirmation flow downsize has.
  2. Change the line to name a command that works. Smallest fix.
  3. Drop the sentence. The caveat already says to treat the figure as $0 until measured.

I lean 1, with 2 shipping immediately so the dead instruction is not in a release while 1 is built.

Also

Our Verbosity product page copies this instruction, so it is wrong on the site too. Tracked at Metabuilder-Labs/tokenjam-website#140; that half should not be fixed until this one is settled, or the page will just be wrong in a different direction.

Acceptance

  • No rendered screen advertises --validate for an analyzer the flag rejects.
  • The advertised-commands test fails against the current behaviour before the fix, and passes after. If it cannot, widen it so a command with an invalid argument value counts as unresolvable.
Dominant language
Python
Stars
122
Forks
35
Avg merge
1d 18h
Merged PRs (30d)
8

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Metabuilder-Labs/tokenjam

All issues in Metabuilder-Labs/tokenjam

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.