mirror of
https://github.com/xtekky/gpt4free.git
synced 2024-11-26 09:57:24 +03:00
Fix issue with You.com and nodriver
Show global model list when unselect provider
This commit is contained in:
parent
74c399d675
commit
c9c1aa121d
@ -32,7 +32,7 @@ REQUEST_HEADERS = {
|
||||
'user-agent': 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/111.0.0.0 Safari/537.36',
|
||||
'x-same-domain': '1',
|
||||
}
|
||||
REQUEST_BL_PARAM = "boq_assistant-bard-web-server_20240201.08_p8"
|
||||
REQUEST_BL_PARAM = "boq_assistant-bard-web-server_20240421.18_p0"
|
||||
REQUEST_URL = "https://gemini.google.com/_/BardChatUi/data/assistant.lamda.BardFrontendService/StreamGenerate"
|
||||
UPLOAD_IMAGE_URL = "https://content-push.googleapis.com/upload/"
|
||||
UPLOAD_IMAGE_HEADERS = {
|
||||
|
@ -101,4 +101,4 @@ async def get_telemetry_ids(proxy: str = None) -> list:
|
||||
|
||||
return [await get_telemetry_id() for _ in range(1)]
|
||||
finally:
|
||||
await browser.stop()
|
||||
await tab.close()
|
@ -147,7 +147,7 @@
|
||||
</div>
|
||||
<div class="field box">
|
||||
<label for="OpenaiAccount-api_key" class="label" title="">OpenAI ChatGPT:</label>
|
||||
<textarea id="OpenaiAccount-api_key" name="OpenaiAccount[api_key]" placeholder="access_key"></textarea>
|
||||
<textarea id="OpenaiAccount-api_key" name="OpenaiAccount[api_key]" class="OpenaiChat-api_key" placeholder="access_key"></textarea>
|
||||
</div>
|
||||
<div class="field box">
|
||||
<label for="OpenRouter-api_key" class="label" title="">OpenRouter:</label>
|
||||
@ -230,9 +230,10 @@
|
||||
<select name="provider" id="provider">
|
||||
<option value="">Provider: Auto</option>
|
||||
<option value="Bing">Bing</option>
|
||||
<option value="OpenaiChat">OpenaiChat</option>
|
||||
<option value="OpenaiChat">OpenAI ChatGPT</option>
|
||||
<option value="Gemini">Gemini</option>
|
||||
<option value="Liaobots">Liaobots</option>
|
||||
<option value="MetaAI">Meta AI</option>
|
||||
<option value="You">You</option>
|
||||
<option value="">----</option>
|
||||
</select>
|
||||
|
@ -1246,6 +1246,8 @@ async function load_provider_models(providerIndex=null) {
|
||||
}
|
||||
const provider = providerSelect.options[providerIndex].value;
|
||||
if (!provider) {
|
||||
modelProvider.classList.add("hidden");
|
||||
modelSelect.classList.remove("hidden");
|
||||
return;
|
||||
}
|
||||
const models = await api('models', provider);
|
||||
|
Loading…
Reference in New Issue
Block a user