-
Notifications
You must be signed in to change notification settings - Fork 2.5k
feature(models): added vllm provider #2103
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
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
Greptile OverviewGreptile SummaryThis PR adds vLLM as a new self-hosted provider with OpenAI-compatible API support. The implementation follows the established patterns from the Ollama and OpenAI providers, providing comprehensive support for tool calling, streaming, response formats, and dynamic model discovery. Key Changes:
Implementation Quality:
Confidence Score: 5/5
Important Files ChangedFile Analysis
Sequence DiagramsequenceDiagram
participant User
participant UI as Agent Block UI
participant Loader as ProviderModelsLoader
participant API as /api/providers/vllm/models
participant vLLM as vLLM Server
participant Provider as vllmProvider
participant Store as ProvidersStore
Note over User,Store: Initialization Flow
Loader->>API: GET /api/providers/vllm/models
API->>vLLM: GET /v1/models
vLLM-->>API: Return {data: [{id: "model-name"}]}
API-->>Loader: Return {models: ["vllm/model-name"]}
Loader->>Store: updateVLLMProviderModels(models)
Store->>Store: setProviderModels('vllm', models)
Note over User,Store: Model Execution Flow
User->>UI: Select vLLM model & configure agent
UI->>Provider: executeRequest(request)
Provider->>vLLM: POST /v1/chat/completions
alt Streaming without tools
vLLM-->>Provider: Stream chunks
Provider-->>UI: Return StreamingExecution
UI-->>User: Display streaming response
else With tool calls
vLLM-->>Provider: Response with tool_calls
loop For each tool call
Provider->>Provider: executeTool(toolName, params)
Provider->>vLLM: POST /v1/chat/completions (with tool results)
end
vLLM-->>Provider: Final response
Provider-->>UI: Return ProviderResponse
UI-->>User: Display final result
end
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
14 files reviewed, no comments
* Add vLLM self-hosted provider * updated vllm to have pull parity with openai, dynamically fetch models --------- Co-authored-by: MagellaX <[email protected]>
Summary
Type of Change
Testing
Tested manually
Checklist