Skip to content

feat: model configuration and embedding configuration optimization. #2414

Merged
fanlv merged 9 commits intomainfrom
fanlv
Oct 30, 2025
Merged

feat: model configuration and embedding configuration optimization. #2414
fanlv merged 9 commits intomainfrom
fanlv

Conversation

@fanlv
Copy link
Collaborator

@fanlv fanlv commented Oct 30, 2025

  • Model supports configuring thinking mode
  • Removed Request Dims from OpenAI embedding
  • Improved configuration interface
  • Optimize the modelbuilder code.

fanlv and others added 9 commits October 30, 2025 09:13
- Add min="0" attribute to all dims input fields in HTML
- Add JavaScript validation to ensure dims >= 0 for all embedding types (Ark, OpenAI, Ollama, Gemini, HTTP)
- Validate both embedding_info.dims and openai.request_dims for OpenAI provider
- Display error messages when dims values are negative
- Add ThinkingType dropdown selector to model creation modal
- Show ThinkingType for: Ark (2), Claude (3), Gemini (11), Qwen (15), Ollama (20)
- Ark provider includes Auto option (value 3)
- Other providers: Disable (2) and Enable (1) options
- Include thinking_type in base_conn_info when submitting model creation
- Add i18n strings for ThinkingType options
- Add thinking_type field to model list display
- Map thinking_type values: 0=Default, 1=Enable, 2=Disable, 3=Auto
- Add getThinkingTypeText() helper function for value mapping
- Add i18n translations for thinking_type values in both Chinese and English

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
- Add condition to display thinking_type field only for supported providers
- Supported providers: OpenAI (1), Ark (2), Claude (3), Gemini (11), Qwen (15), DeepSeek (19), Ollama (20)
- Now OpenAI and DeepSeek models will properly display the Thinking Type field in model list

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
- Remove OpenAI (1) and DeepSeek (19) from thinking_type display list
- Only display thinking_type for: Ark (2), Claude (3), Gemini (11), Qwen (15), Ollama (20)
- OpenAI and DeepSeek model lists will no longer show Thinking Type field

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
- Remove 'Embedding Request Dims' text input from OpenAI connection UI
- Remove openai_embedding_request_dims from initial values
- Remove request_dims from OpenAI payload in buildKnowledgePayloadFromInputs
- Remove requestDimsVal validation from saveKnowledgeConfig function

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
@codecov-commenter
Copy link

codecov-commenter commented Oct 30, 2025

Codecov Report

❌ Patch coverage is 0% with 126 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
backend/api/model/admin/config/config.go 0.00% 61 Missing ⚠️
backend/bizpkg/llm/modelbuilder/ark.go 0.00% 11 Missing ⚠️
backend/api/handler/coze/config_service.go 0.00% 10 Missing ⚠️
backend/bizpkg/llm/modelbuilder/claude.go 0.00% 8 Missing ⚠️
backend/bizpkg/llm/modelbuilder/gemini.go 0.00% 8 Missing ⚠️
backend/bizpkg/llm/modelbuilder/ollama.go 0.00% 8 Missing ⚠️
backend/bizpkg/llm/modelbuilder/qwen.go 0.00% 6 Missing ⚠️
backend/bizpkg/llm/modelbuilder/model_builder.go 0.00% 5 Missing ⚠️
backend/bizpkg/config/knowledge/knowledge.go 0.00% 2 Missing ⚠️
backend/infra/embedding/impl/impl.go 0.00% 2 Missing ⚠️
... and 5 more
Files with missing lines Coverage Δ
...pi/model/conversation/conversation/conversation.go 0.00% <ø> (ø)
.../conversation/conversation/conversation_service.go 0.00% <ø> (ø)
backend/bizpkg/llm/modelbuilder/deepseek.go 0.00% <0.00%> (ø)
backend/bizpkg/llm/modelbuilder/openai.go 0.00% <0.00%> (ø)
backend/infra/embedding/impl/ark/ark.go 0.00% <0.00%> (ø)
backend/infra/embedding/impl/http/http.go 0.00% <0.00%> (ø)
backend/infra/embedding/impl/wrap/dense_only.go 0.00% <0.00%> (ø)
backend/bizpkg/config/knowledge/knowledge.go 0.00% <0.00%> (ø)
backend/infra/embedding/impl/impl.go 0.00% <0.00%> (ø)
backend/bizpkg/llm/modelbuilder/model_builder.go 0.00% <0.00%> (ø)
... and 7 more

... and 1 file with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@fanlv fanlv enabled auto-merge October 30, 2025 05:25
@fanlv fanlv added this pull request to the merge queue Oct 30, 2025
Merged via the queue into main with commit b3d6357 Oct 30, 2025
18 checks passed
@fanlv fanlv deleted the fanlv branch October 30, 2025 06:06
junwen-lee pushed a commit that referenced this pull request Nov 5, 2025
…2414)

Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants