star-whale / starwhale

an MLOps/LLMOps platform
https://starwhale.ai
Apache License 2.0
208 stars 35 forks source link

enhance(client): support text to img infer type #3044

Closed jialeicui closed 10 months ago

jialeicui commented 10 months ago

Description

Content of the web-handler's job.yaml:

serving:
- concurrency: 1
  expose: 8080
  extra_kwargs:
    search_modules:
    - main
  func_name: StandaloneModel._serve_handler
  module_name: starwhale.core.model.model
  name: serving
  replicas: 1
  service_spec:
    apis:
    - components:
      - component_spec_value_type: STRING
        name: user_input
      - component_spec_value_type: LIST
        name: history
      - componentValueSpecFloat:
          defaultVal: 0.5
        component_spec_value_type: FLOAT
        name: temperature
      - componentValueSpecFloat:
          defaultVal: 0.9
        component_spec_value_type: FLOAT
        name: top_p
      - componentValueSpecInt:
          defaultVal: 100
        component_spec_value_type: INT
        name: max_new_tokens
      inference_type: llm_chat
      uri: fake_chat_bot
    version: 0.0.2
  show_name: virtual handler for model serving
  virtual: true

Modules

Checklist

codecov[bot] commented 10 months ago

Codecov Report

Attention: 15 lines in your changes are missing coverage. Please review.

Comparison is base (24d2acc) 82.94% compared to head (2abc86a) 91.81%. Report is 3 commits behind head on main.

Files Patch % Lines
client/starwhale/api/_impl/service/types/types.py 64.51% 11 Missing :warning:
...t/starwhale/api/_impl/service/types/text_to_img.py 86.66% 4 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #3044 +/- ## ============================================ + Coverage 82.94% 91.81% +8.86% ============================================ Files 567 135 -432 Lines 31434 15898 -15536 Branches 1839 0 -1839 ============================================ - Hits 26074 14596 -11478 + Misses 4549 1302 -3247 + Partials 811 0 -811 ``` | [Flag](https://app.codecov.io/gh/star-whale/starwhale/pull/3044/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=star-whale) | Coverage Δ | | |---|---|---| | [console](https://app.codecov.io/gh/star-whale/starwhale/pull/3044/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=star-whale) | `?` | | | [controller](https://app.codecov.io/gh/star-whale/starwhale/pull/3044/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=star-whale) | `?` | | | [standalone](https://app.codecov.io/gh/star-whale/starwhale/pull/3044/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=star-whale) | `91.81% <79.45%> (-0.08%)` | :arrow_down: | | [unittests](https://app.codecov.io/gh/star-whale/starwhale/pull/3044/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=star-whale) | `91.81% <79.45%> (+0.18%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=star-whale#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.