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

Livepool llm rebase #3178

Closed

Conversation

ad-astra-video
Copy link
Collaborator

@ad-astra-video ad-astra-video commented Sep 20, 2024

What does this pull request do? Explain your changes. (required)

Rebases Livepool LLM PR

Specific updates (required)

  • rebased Livepool LLM PR for codegen updates and couple other minor updats

How did you test each of these updates (required)

  • modified reflex-chat repo to test chat completions with history using Livepool openai-middleware
  • curl cmd sent to gateway with stream=false and stream=true
    • curl -N -X POST http://127.0.0.1:6666/llm-generate -F "prompt=tell me a story about Mario taking a beach vacation" -F "model_id=meta-llama/Meta-Llama-3.1-8B-Instruct" -F max_tokens=256 -F stream=true

Does this pull request close any open issues?

Checklist:

@github-actions github-actions bot added the AI Issues and PR related to the AI-video branch. label Sep 20, 2024
@@ -23,6 +23,7 @@ type AI interface {
Upscale(context.Context, worker.GenUpscaleMultipartRequestBody) (*worker.ImageResponse, error)
AudioToText(context.Context, worker.GenAudioToTextMultipartRequestBody) (*worker.TextResponse, error)
SegmentAnything2(context.Context, worker.GenSegmentAnything2MultipartRequestBody) (*worker.MasksResponse, error)
LlmGenerate(context.Context, worker.GenLlmFormdataRequestBody) (interface{}, error)
Copy link
Contributor

Choose a reason for hiding this comment

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

@kyriediculous, @ad-astra-video can we rename this to LLMGenerate?

Copy link
Contributor

Choose a reason for hiding this comment

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

Yes sounds good

@ad-astra-video ad-astra-video changed the title DRAFT: Livepool llm rebase Livepool llm rebase Sep 23, 2024
line := scanner.Text()
if strings.HasPrefix(line, "data: ") {
data := strings.TrimPrefix(line, "data: ")
if data == "[DONE]" {
Copy link
Contributor

Choose a reason for hiding this comment

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

@kyriediculous why do we need both status DONE and a done boolean?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Per discord message, SSE streams end with a [DONE] message. This comment can be addressed in update to Livepool LLM PR.

@ad-astra-video
Copy link
Collaborator Author

Closing, Livepool LLM PR will be used to take this across the finish line. This PR was created to hopefully save some time on the updates needed to get there since I had to make these changes to test the pipeline end-to-end.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
AI Issues and PR related to the AI-video branch.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants