Add LLM interface aggregation web extension#1532
Open
kongweiguang wants to merge 2 commits into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add a new
agentscope-extensions-llm-interfaces-webmodule and Spring Boot starter that let one AgentScopeReActAgentexpose stateless OpenAI Chat Completions, OpenAI Responses, and Anthropic Messages compatible endpoints under/v1.The existing Chat Completions web extension remains intact. The new module reuses its Chat path and adds protocol adapters for Responses and Anthropic requests, responses, tools, usage, finish reasons, and SSE event streams. It also adds
/v1/models, tolerant request parsing for common SDK extra fields, and clear unsupported-feature errors for stateful Responses fields.Additional fixes
Objectand normalizing inside the adapter layer.find, file URL extension detection, multimodal RAG injection, and local image inputs.Validation
mvn -pl agentscope-extensions/agentscope-extensions-llm-interfaces-web,agentscope-extensions/agentscope-spring-boot-starters/agentscope-llm-interfaces-web-starter -am testmvn spotless:checkmvn testagentscope-examples/documentation/llm-interfaces-web, then verified curl fixtures for/v1/models,/v1/chat/completions,/v1/responses,/v1/messages, Chat[DONE], Responsesresponse.created/response.output_text.delta/response.completed, and Anthropicmessage_start/content_block_delta/message_delta/message_stop.References