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: Add support for Flexible Model #1671

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

Conversation

shellc
Copy link

@shellc shellc commented Jun 19, 2024

Flexible Model is a customizable inference pipeline within xinference, supporting a range of tasks including image segmentation, traditional machine learning regression, and more.

Mechanism:

Create the model object with custom definitions and initialization functions.
Use xinference.model.flexible.launchers.transformers to load transformer models.
Invoke the model via the /v1/flexible/infers endpoint.
Access the model using the SDK’s infer interface.

Examples:

from xinference.client import Client

client = Client("http://localhost:9997")

model = client.get_model("flexible-model")

result = model.infer(inputs="happy")

image

@XprobeBot XprobeBot added this to the v0.12.2 milestone Jun 19, 2024
@qinxuye
Copy link
Contributor

qinxuye commented Jun 24, 2024

@yiboyasss Could you review the frontend part of this PR?

Copy link
Contributor

@qinxuye qinxuye left a comment

Choose a reason for hiding this comment

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

I left some comments

xinference/api/restful_api.py Show resolved Hide resolved
xinference/model/flexible/core.py Outdated Show resolved Hide resolved
@XprobeBot XprobeBot modified the milestones: v0.12.2, v0.12.4 Jun 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants