mirror of
https://github.com/WenPai-org/wpmind.git
synced 2025-08-05 21:05:13 +08:00
added support for Anthropic and it is recommended
move code to work with AI from rest class to separate class
This commit is contained in:
parent
1eda5f0e15
commit
e67eca2ee0
14 changed files with 797 additions and 342 deletions
4
src/utils/is-valid-anthropic-api-key/index.js
Normal file
4
src/utils/is-valid-anthropic-api-key/index.js
Normal file
|
@ -0,0 +1,4 @@
|
|||
export default function isValidAnthropicApiKey(apiKey) {
|
||||
const regex = /^sk-ant-[a-zA-Z0-9]/;
|
||||
return regex.test(apiKey);
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue