mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-06-05 21:59:27 +02:00
implement messages api and selector for nuclaude models
This commit is contained in:
@ -1751,7 +1751,7 @@ async function sendOpenAIRequest(type, messages, signal) {
|
||||
|
||||
function getStreamingReply(data) {
|
||||
if (oai_settings.chat_completion_source == chat_completion_sources.CLAUDE) {
|
||||
return data?.completion || '';
|
||||
return data?.delta?.text || '';
|
||||
} else if (oai_settings.chat_completion_source == chat_completion_sources.MAKERSUITE) {
|
||||
return data?.candidates?.[0]?.content?.parts?.[0]?.text || '';
|
||||
} else {
|
||||
@ -3439,7 +3439,7 @@ async function onModelChange() {
|
||||
if (oai_settings.max_context_unlocked) {
|
||||
$('#openai_max_context').attr('max', max_200k);
|
||||
}
|
||||
else if (value == 'claude-2.1' || value == 'claude-2') {
|
||||
else if (value == 'claude-2.1' || value == 'claude-2' || value.startsWith('claude-3')) {
|
||||
$('#openai_max_context').attr('max', max_200k);
|
||||
}
|
||||
else if (value.endsWith('100k') || value.startsWith('claude-2') || value === 'claude-instant-1.2') {
|
||||
|
Reference in New Issue
Block a user