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

feat(tabby): Added --chat-device arg for serve subcommand #1685

Merged
merged 2 commits into from
Mar 16, 2024

Conversation

SpeedCrash100
Copy link
Contributor

@SpeedCrash100 SpeedCrash100 commented Mar 16, 2024

Brief

A implementation of issue #1659

Details

The very simple implementation of the --chat-device flag to override device to use for chat model. This implementation, however, rejects arguments if --chat-device specified without the --chat-model flag. The issue suggests giving a warning instead, but I found out a good clap macro to achieve the implemented behaviour. I decided to not implement a logging warning message and give the situation handling to the clap crate to keep the code clean.

Testing

Tested with rocm + cpu devices. I cannot test other devices myself.


closes #1659

@wsxiaoys wsxiaoys enabled auto-merge (squash) March 16, 2024 09:18
@wsxiaoys
Copy link
Member

Thanks for the PR, LGTM

@wsxiaoys wsxiaoys disabled auto-merge March 16, 2024 09:22
@wsxiaoys wsxiaoys enabled auto-merge (squash) March 16, 2024 09:23
Copy link

codecov bot commented Mar 16, 2024

Codecov Report

Attention: Patch coverage is 0% with 7 lines in your changes are missing coverage. Please review.

Project coverage is 53.94%. Comparing base (f216d77) to head (2b379dc).

Files Patch % Lines
crates/tabby/src/serve.rs 0.00% 7 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1685      +/-   ##
==========================================
- Coverage   53.97%   53.94%   -0.04%     
==========================================
  Files         115      115              
  Lines        9602     9608       +6     
==========================================
  Hits         5183     5183              
- Misses       4419     4425       +6     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@wsxiaoys wsxiaoys disabled auto-merge March 16, 2024 09:29
@wsxiaoys wsxiaoys merged commit 6f3db0a into TabbyML:main Mar 16, 2024
4 of 6 checks passed
wwayne pushed a commit that referenced this pull request Mar 19, 2024
* feat(tabby): Added --chat-device arg for serve subcommand

* chore(changelog): Added info about --chat-device flag
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.

Add a --chat-device flag for serve command
2 participants