Commit graph

3267 commits

Author SHA1 Message Date
Vitali sharp8n 7b05535089 parameters 2026-09-17 04:15:48 +03:00
Vitali sharp8n 9d6f5dc22d enchancements 2026-09-14 17:27:38 +03:00
Vitali sharp8n 833fffe722 prop change 2026-09-09 11:06:12 +03:00
Vitali sharp8n 71d97a5d8e bot update 11 2026-09-09 11:06:12 +03:00
Vitali sharp8n 7e971fe917 mcp preparation 2026-09-09 11:06:12 +03:00
Vitali sharp8n a6f3b36f77 upgrade to net11 2026-09-09 11:06:12 +03:00
Vitali sharp8n 1c2c7b7de0 botsharp enchance 2026-09-09 11:06:12 +03:00
Vitali sharp8n 9d4d824c1a add reasoning to stream 2026-09-09 11:06:12 +03:00
Vitali sharp8n aa132b1419 fix(DeepSeekAI): keep nameless arg fragments when grouping tool calls
The previous grouping pre-filtered tool-call updates on FunctionName
before grouping by index. In DeepSeek streaming only the FIRST fragment
of a call carries the name/id; the argument text arrives in later
fragments with FunctionName == null. The filter dropped them, so every
tool call got empty FunctionArgs (get_editor_state(), get_node() ->
'node_id is required').

Group ALL updates by Index first, then pick the first group that
contains a named fragment and concatenate every argument fragment in
that group. Verified via OpenPencil integration test: get_node now
carries {"node_id": "10"} intact instead of being empty or joined
across parallel calls.
2026-09-09 11:06:12 +03:00
Vitali sharp8n 9fe969a47c fix(DeepSeekAI): accumulate streaming tool-call args per call index
When the model emits several parallel tool calls in one streaming response,
the OpenAI SDK interleaves argument fragments by call index. The old code
joined ALL fragments of ALL calls into a single FunctionArgs string, which
produced corrupted arguments like get_node({"node_id": "10"}{"maxDepth": 2})
and made every tool call fail (e.g. 'node_id is required').

Group tool-call updates by Index and concatenate fragments only within the
first call that has a function name; other parallel calls are ignored (same
as before), but the selected call now gets clean, valid JSON arguments.

Also fix DecodePatchString: DeepSeek sends "reasoning_content": null in the
final delta; the decoder returned the literal string 'null' which was
appended to the accumulated reasoning text. Return null for the JSON null
literal instead.
2026-09-09 11:06:12 +03:00
Vitali sharp8n ce08fc132b fix(DeepSeekAI): capture and echo reasoning_content for thinking mode tool calls
DeepSeek thinking mode (deepseek-v4-flash/pro with reasoning enabled) returns
reasoning_content in every delta. For requests carrying tools, the reasoning_content
of previous assistant messages MUST be passed back in all subsequent requests,
otherwise DeepSeek answers 400 'The reasoning_content ... must be passed back'.

Changes:
- Bump OpenAI SDK 2.5.0 -> 2.12.0 (JsonPatch public API required to read/write
  the unknown reasoning_content property; 2.5.0 only stores it internally).
- Fix BotSharp.Plugin.OpenAI image quality enum names for SDK 2.12
  (GeneratedImageQuality.Low -> LowQuality, Medium -> MediumQuality).
- Add RoleDialogModel.ReasoningContent (serialized as reasoning_content) and
  persist it through DialogElement/DialogMetaData/ConversationStorage.
- DeepSeekAI ChatCompletionProvider:
  * capture reasoning_content from non-streaming responses (ExtractReasoningContent)
  * capture per-delta reasoning_content in the streaming loop and accumulate it
  * set ReasoningContent on assistant/function response messages
  * echo reasoning_content back via AssistantChatMessage JsonPatch in PrepareOptions
- RoutingService.InvokeAgent: copy response.ReasoningContent onto the stored
  Function/Assistant dialog so the echo survives the tool-call round trip.
2026-09-09 11:06:12 +03:00
Haiping Chen 099187fd5e Add image to Claude 2025-10-17 13:59:21 -05:00
Haiping Chen afeaa16738 Remove legacy Google PaLM 2025-10-17 13:58:38 -05:00
iceljc d1df7f782a
Merge pull request #1194 from iceljc/master
refine
2025-10-16 21:58:31 -05:00
Jicheng Lu 1118b4f0c8 refine 2025-10-16 21:57:33 -05:00
Haiping 630d1a08dc
Merge pull request #1193 from yileicn/master
optimize DistributedLocker
2025-10-16 20:39:18 -05:00
nick.yi cd31fe376b optimize DistributedLocker 2025-10-17 09:37:01 +08:00
Nick Yi 9520aa0747
Merge pull request #1190 from adenchen123/master
Reapply "Handling redis timeout in RedisSubscriber"
2025-10-16 11:40:25 +08:00
nick.yi 13d6f568fb hotfix IBotSharpRepository.cs(201,43): error CS0246 2025-10-16 11:39:20 +08:00
Nick Yi cf22033e30
Merge pull request #1191 from yileicn/master
instruct log optimize
2025-10-16 11:03:43 +08:00
nick.yi 2d387b6d31 add UpdateInstructionLogStates 2025-10-16 10:20:47 +08:00
aden.chen 840ee277ea Reapply "Handling redis timeout in RedisSubscriber"
This reverts commit b8636a7c40.
2025-10-16 08:57:21 +08:00
iceljc 9cbd8125f2
Merge pull request #1189 from iceljc/master
fix namespace
2025-10-15 19:53:08 -05:00
Jicheng Lu 20da9632cc minor change 2025-10-15 19:52:58 -05:00
Nick Yi c09214fefc
Merge pull request #1187 from adenchen123/master
Delay one second inside LockAsync in crontab watcher
2025-10-16 08:45:14 +08:00
Jicheng Lu 3ff5cd4233 rename 2025-10-15 19:41:30 -05:00
Jicheng Lu d8747d8fac move files 2025-10-15 19:37:01 -05:00
Jicheng Lu a1a2a6f0d3 rename namespace 2025-10-15 19:33:15 -05:00
Jicheng Lu 8fa683af8b refine 2025-10-15 14:22:18 -05:00
Jicheng Lu 74b2773223 fix namespace 2025-10-15 13:24:27 -05:00
nick.yi 5783d28100 instruct/agentId interface add logId response 2025-10-15 17:10:06 +08:00
aden.chen 79c6bf7fd3 Delay one second inside LockAsync 2025-10-15 14:38:42 +08:00
aden.chen b8636a7c40 Revert "Handling redis timeout in RedisSubscriber"
This reverts commit 1184528d70.
2025-10-15 14:25:44 +08:00
Jicheng Lu 5dfb38a107 fix missing agent file 2025-10-14 21:48:49 -05:00
aden.chen 1184528d70 Handling redis timeout in RedisSubscriber 2025-10-15 10:20:28 +08:00
Jicheng Lu 6fcd3602a8 fix typo 2025-10-14 20:59:54 -05:00
Jicheng Lu b8ecef3687 rename image handler utilities 2025-10-14 20:53:20 -05:00
Haiping Chen e1dc28beef Image Composition 2025-10-14 20:28:09 -05:00
Haiping e99cfac819
Merge pull request #1181 from iceljc/features/add-image-llm-config
Features/add image llm config
2025-10-14 14:23:34 -05:00
Jicheng Lu 40e8457dc9 rename 2025-10-14 14:14:55 -05:00
Jicheng Lu 749345d282 rename 2025-10-14 14:09:09 -05:00
Jicheng Lu ee9fdb56c8 minor change 2025-10-14 13:55:26 -05:00
Jicheng Lu 9dab7c8343 add file llm processor 2025-10-14 13:52:01 -05:00
Jicheng Lu 32bea332f8 fix typo 2025-10-14 10:16:49 -05:00
Jicheng Lu 6a78bec7ef minor change 2025-10-14 10:13:12 -05:00
nick.yi bce3e1cf11 optimze mongodb query default limit=10 2025-10-14 16:30:16 +08:00
nick.yi f6e9f4689b sql select support mongodb 2025-10-14 15:55:12 +08:00
Jicheng Lu 0d6127292b minor change 2025-10-13 14:41:06 -05:00
Jicheng Lu 96262c35d2 add CodeScript in ProgramCodeTemplateMessage 2025-10-13 11:53:36 -05:00
Jicheng Lu e92d97f8b4 minor change 2025-10-12 22:50:12 -05:00