Repository navigation
feat(core): add official search-to-chat workflow and release 1.6.1 - #100
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Caution Review failedThe pull request is closed. No actionable comments were generated in the recent review.
|
| Layer / File(s) | Summary |
|---|---|
Validate and prepare search context deepseek4j-core/src/main/java/io/github/pigmesh/ai/deepseek/core/SearchChatContext.java, deepseek4j-core/src/test/java/io/github/pigmesh/ai/deepseek/core/DeepSeekSearchChatTest.java |
SearchChatContext validates queries and chat requests, copies the request, and adds bounded search references. Tests cover context selection, validation, and size limits. |
Run search, stream chat, and propagate cancellation deepseek4j-core/src/main/java/io/github/pigmesh/ai/deepseek/core/DeepSeekClient.java, deepseek4j-core/src/main/java/io/github/pigmesh/ai/deepseek/core/ResponseHandle.java, deepseek4j-core/src/main/java/io/github/pigmesh/ai/deepseek/core/StreamingRequestExecutor.java, deepseek4j-core/src/test/java/io/github/pigmesh/ai/deepseek/core/DeepSeekSearchChatTest.java |
DeepSeekClient adds three chatSearchCompletion(...) overloads. Each subscription searches, adds results to a chat request, and streams the response. Cancellation reaches the active search or chat request. Tests cover request behavior, errors, and cancellation. |
Document the API and update release versions README.md, pom.xml, deepseek4j-core/pom.xml, deepseek-spring-boot-starter/pom.xml, deepseek4j-example/pom.xml |
README guidance distinguishes standalone search from search-backed chat completion and documents the new API. Project and dependency versions change to 1.6.1. |
Release workflow token permissions
| Layer / File(s) | Summary |
|---|---|
Set release action permissions and token .github/workflows/release.yaml |
The workflow grants contents: write and passes secrets.GITHUB_TOKEN to the release action. |
Priority:
Estimated code review effort: 3 (Moderate) | ~25 minutes
Change: Feature
Sequence Diagram(s)
sequenceDiagram
participant Subscriber
participant DeepSeekClient
participant SearchEndpoint
participant StreamingRequestExecutor
Subscriber->>DeepSeekClient: Subscribe to chatSearchCompletion
DeepSeekClient->>SearchEndpoint: Execute search call
SearchEndpoint-->>DeepSeekClient: Return search results
DeepSeekClient->>StreamingRequestExecutor: Stream chat request with search context
StreamingRequestExecutor-->>Subscriber: Emit chat response events
Possibly related PRs
- pig-mesh/deepseek4j#98: This PR adds
chatSearchCompletion(...)using DeepSeek Search, following a similar workflow name after PR#98removed its former Bocha-based version. - pig-mesh/deepseek4j#97: This PR uses the official Search API, request and response types, and endpoint infrastructure added in PR
#97.
Merge Risk: 
Minimal · up to 6f14e
-
No actionable issue is established for this release update; it is ready to merge after normal checks.
Pre-merge checks: 
4 · 
1
-
Failed checks: 1 warning Passed checks: 4 passedFull details: Docstring Coverage
-
Explanation
Docstring coverage is 12.50% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 40 functions across 5 files. (6 skipped: 6 unsupported.)
Resolution
Write docstrings for the functions missing them to satisfy the coverage threshold.
-
Finishing Touches
-
📝 Generate docstrings
-
- Commit to this branch
- Create a new PR
🧪 Generate unit tests (beta)
-
- Commit to this branch
- Create a new PR
-
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Comment @coderabbitai help to get the list of available commands.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 6f14e421f5
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
1.6.0的官方 Search 只返回结构化结果,调用方仍需自行拼接上下文并调用模型。1.6.1新增三个chatSearchCompletion(...)重载,自动先搜索再流式回答,支持简单问题、独立搜索参数和完整对话请求。search(...),不恢复 Bocha 配置。contents: write,修复此前自定义 GH_TOKEN 失效导致的 Release 创建失败。验证:Java 8 下
mvn -B -ntp -Prelease -Dgpg.skip=true spring-javaformat:apply clean verify spring-javaformat:validate通过;38 个测试全部通过,其中 19 个新增组合调用测试覆盖配置继承、覆盖参数、历史消息、Unicode 查询限制、上下文上限、错误、总超时传递、冷订阅和两个阶段的 HTTP 取消。README XML 示例、代码围栏与git diff --check通过。发布后另外验证 Maven Central 实际工件及独立消费者。