Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add descriptions and show defaults for all command line parameters #435

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

A-Joshi
Copy link
Contributor

@A-Joshi A-Joshi commented Jan 1, 2024

Not all the commandline options had descriptions.
Also the defaults were not showing up in the documentation - fix that.

Copy link
Member

@jakethekoenig jakethekoenig left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have some thoughts on what the descriptions should be. But it mostly looks good.

"auto_completions": list(known_models.keys()),
"description": "Choose from one of the supported models: " + ",".join(
list(known_models.keys())
),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd prefer not to put the models in the description. This description will make sense in the command line but not in the sphinx documentation. I prefer "The LLM used to respond to user requests and make edits."

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Description sounds good. Models, I feel, can be in the description since they are hard-coded in the code rather than being driven by a configuration.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree with @jakethekoenig on this one; I would prefer not to put the list of models in the description. If argument parser has a way to add autocomplete, I would be ok with that.

mentat/config.py Outdated Show resolved Hide resolved
mentat/config.py Outdated Show resolved Hide resolved
mentat/config.py Outdated Show resolved Hide resolved
"The model used to prune the features before sending to the main model"
" for edits. Only used if llm_feature_filter is greater than 0."
" Possible models are: "
+ ", ".join(list(known_models.keys()))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Again, would prefer not to have model names in description.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Curious why the preference against listing the supported models? Its a common approach to list the supported "items" - e.g. pandoc documentation lists the supported file formats, etc. It also helps when using the options on the commandline and selecting a model without having to run the app first or read the code.

Perhaps better formatting on the list of models? The list is exactly the same as the autocomplete. In the case of generated documentation there is typically no autocomplete (at most you might have some generated javascript with the list hidden and then displayed for html version of the documentation).

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For one, there are going to be a lot of available models and I think it would bloat the description way too much. I'm working on switching us to a new library right now that can support models from any provider easily, and I don't want 10 or 20 lines of models in the descriptions.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was going to suggest moving to a lib like llmware that had a lot of other support (like vetors, local models etc.). I would change the description from the hardcoded list (which will hopefully e gone with the change) to one referencing the lib at that point.

mentat/config.py Outdated Show resolved Hide resolved
mentat/config.py Outdated
validator=[validators.le(1), validators.ge(0)],
metadata={
"description": (
"The model's temperature. Temprature is a number between 0 to 1"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
"The model's temperature. Temprature is a number between 0 to 1"
"The model's temperature. Temperature is a number between 0 to 1"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants