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
| -- 创建主表 | |
| CREATE TABLE ChatConfig ( | |
| Id INTEGER PRIMARY KEY AUTOINCREMENT, | |
| HashCode INTEGER NOT NULL DEFAULT 0, | |
| ModelId INTEGER NOT NULL, | |
| SystemPrompt TEXT, | |
| Temperature REAL, | |
| WebSearchEnabled INTEGER NOT NULL, | |
| MaxOutputTokens INTEGER, | |
| ReasoningEffort INTEGER NOT NULL, |
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
| ------------------------------------------------------------------------------- | |
| -- 1~4 合并:ChatPreset 和 ChatPresetSpan 表的创建 + ModelReference 数据插入和更新 | |
| ------------------------------------------------------------------------------- | |
| -- ChatPreset 表 | |
| CREATE TABLE `ChatPreset` | |
| ( | |
| `Id` INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT, | |
| `Name` TEXT NOT NULL, | |
| `UserId` INTEGER NOT NULL, |
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
| -- 更新 AllowSearch 为 1 | |
| UPDATE `ModelReference` SET `AllowSearch` = 1 WHERE `Id` = 1301; | |
| -- 插入多行数据 | |
| INSERT INTO `ModelReference` (`Id`, `ProviderId`, `Name`, `DisplayName`, `PublishDate`, `MinTemperature`, `MaxTemperature`, `AllowSearch`, `AllowVision`, `AllowSystemPrompt`, `AllowStreaming`, `ReasoningResponseKindId`, `ContextWindow`, `MaxResponseTokens`, `TokenizerId`, `InputTokenPrice1M`, `OutputTokenPrice1M`, `CurrencyCode`) | |
| VALUES | |
| (1304, 13, 'gemini-2.0-flash-exp', 'gemini', '2025-03-25', 0, 2, 0, 1, 0, 1, 0, 32768, 8000, NULL, 0, 0, 'USD'), | |
| (209, 2, 'hunyuan-t1-latest', NULL, '2025-04-03', 0, 2, 1, 0, 1, 1, 1, 64000, 64000, NULL, 1, 4, 'RMB'), | |
| (210, 2, 'hunyuan-turbos-latest', NULL, '2025-03-13', 0, 2, 1, 0, 1, 1, 0, 32000, 8000, NULL, 0.8, 2, 'RMB'), | |
| (1104, 11, 'grok-3', 'grok-3', '2025-04-10', 0, 2, 0, 0, 1, 1, 0, 131072, 16384, NULL, 3, 15, 'USD'), |
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
| -- INSERT 语句 | |
| INSERT INTO `ModelReference` (`Id`, `ProviderId`, `Name`, `DisplayName`, `PublishDate`, `MinTemperature`, `MaxTemperature`, `AllowSearch`, `AllowVision`, `AllowSystemPrompt`, `AllowStreaming`, `ReasoningResponseKindId`, `ContextWindow`, `MaxResponseTokens`, `TokenizerId`, `InputTokenPrice1M`, `OutputTokenPrice1M`, `CurrencyCode`) | |
| VALUES | |
| (121, 1, 'gpt-4.1', 'gpt-4.1', '2025-04-14', 0, 2, 0, 1, 1, 1, 0, 1047576, 32768, 2, 2, 8, 'USD'), | |
| (122, 1, 'gpt-4.1-mini', 'gpt-4.1', '2025-04-14', 0, 2, 0, 1, 1, 1, 0, 1047576, 32768, 2, 0.4, 1.6, 'USD'), | |
| (123, 1, 'gpt-4.1-nano', 'gpt-4.1', '2025-04-14', 0, 2, 0, 1, 1, 1, 0, 1047576, 32768, 2, 0.1, 0.4, 'USD'), | |
| (521, 5, 'gpt-4.1', 'gpt-4.1', '2025-04-14', 0, 2, 0, 1, 1, 1, 0, 1047576, 32768, 2, 2, 8, 'USD'), | |
| (522, 5, 'gpt-4.1-mini', 'gpt-4.1', '2025-04-14', 0, 2, 0, 1, 1, 1, 0, 1047576, 32768, 2, 0.4, 1.6, 'USD'), | |
| (523, 5, 'gpt-4.1-nano', 'gpt-4.1', '2025-04-14', 0, 2, 0, 1, 1, 1, 0, 1047576, 32768, 2, 0.1, 0.4, 'USD'), | |
| (1223, 12, |
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
| -- UserApiCache 主表 | |
| CREATE TABLE `UserApiCache` ( | |
| `Id` INTEGER PRIMARY KEY AUTOINCREMENT, | |
| `UserApiKeyId` INTEGER NOT NULL, | |
| `ModelId` INTEGER NOT NULL, | |
| `RequestHashCode` INTEGER NOT NULL, | |
| `Expires` DATETIME NOT NULL, | |
| `ClientInfoId` INTEGER NOT NULL, | |
| `CreatedAt` DATETIME NOT NULL, | |
| FOREIGN KEY (`ClientInfoId`) REFERENCES `ClientInfo`(`Id`), |
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
| diff --git a/paddle/fluid/inference/api/analysis_predictor.cc b/paddle/fluid/inference/api/analysis_predictor.cc | |
| index c9d5b7c..dbac930 100644 | |
| --- a/paddle/fluid/inference/api/analysis_predictor.cc | |
| +++ b/paddle/fluid/inference/api/analysis_predictor.cc | |
| @@ -447,7 +447,9 @@ bool AnalysisPredictor::Init( | |
| paddle::platform::SetNumThreads(config_.cpu_math_library_num_threads()); | |
| std::string model_path = config_.prog_file(); | |
| - if (!model_path.empty()) { | |
| + if (config_.model_from_memory()) { |
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
| <Query Kind="Statements"> | |
| <NuGetReference Prerelease="true">ModelContextProtocol</NuGetReference> | |
| <Namespace>ModelContextProtocol</Namespace> | |
| <Namespace>ModelContextProtocol.Client</Namespace> | |
| <Namespace>System.Text.Json.Nodes</Namespace> | |
| </Query> | |
| var clientTransport = new SseClientTransport(new SseClientTransportOptions() | |
| { | |
| Name = "MyServer", |
OlderNewer