mirror of
https://github.com/songquanpeng/one-api.git
synced 2025-11-12 03:13:41 +08:00
feat: enhance error handling and reasoning mechanisms across middleware
- Improve error handling across multiple middleware and adapter components, ensuring consistent error response formats in JSON. - Enhance the functionality of request conversion functions by including context parameters and robust error wrapping. - Introduce new features related to reasoning content in the messaging model, providing better customization and explanations in the documentation.
This commit is contained in:
26
README.md
26
README.md
@@ -30,6 +30,10 @@ Also welcome to register and use my deployed one-api gateway, which supports var
|
||||
- [Support claude-3-7-sonnet \& thinking](#support-claude-3-7-sonnet--thinking)
|
||||
- [Stream](#stream)
|
||||
- [Non-Stream](#non-stream)
|
||||
- [Automatically Enable Thinking and Customize Reasoning Format via URL Parameters](#automatically-enable-thinking-and-customize-reasoning-format-via-url-parameters)
|
||||
- [Reasoning Format - reasoning-content](#reasoning-format---reasoning-content)
|
||||
- [Reasoning Format - reasoning](#reasoning-format---reasoning)
|
||||
- [Reasoning Format - thinking](#reasoning-format---thinking)
|
||||
- [Bug fix](#bug-fix)
|
||||
|
||||
## Turtorial
|
||||
@@ -172,6 +176,28 @@ By default, the thinking mode is not enabled. You need to manually pass the `thi
|
||||
|
||||

|
||||
|
||||
### Automatically Enable Thinking and Customize Reasoning Format via URL Parameters
|
||||
|
||||
Supports two URL parameters: `thinking` and `reasoning_format`.
|
||||
|
||||
- `thinking`: Whether to enable thinking mode, disabled by default.
|
||||
- `reasoning_format`: Specifies the format of the returned reasoning.
|
||||
- `reasoning_content`: DeepSeek official API format, returned in the `reasoning_content` field.
|
||||
- `reasoning`: OpenRouter format, returned in the `reasoning` field.
|
||||
- `thinking`: Claude format, returned in the `thinking` field.
|
||||
|
||||
#### Reasoning Format - reasoning-content
|
||||
|
||||

|
||||
|
||||
#### Reasoning Format - reasoning
|
||||
|
||||

|
||||
|
||||
#### Reasoning Format - thinking
|
||||
|
||||

|
||||
|
||||
## Bug fix
|
||||
|
||||
- [BUGFIX: 更新令牌时的一些问题 #1933](https://github.com/songquanpeng/one-api/pull/1933)
|
||||
|
||||
Reference in New Issue
Block a user