DeabLabs / cannoli

Cannoli allows you to build and run no-code LLM scripts using the Obsidian Canvas editor.
MIT License
230 stars 15 forks source link

anthropic claude not working #41

Open winne617 opened 5 days ago

winne617 commented 5 days ago

hey, openai works fine, with claude i get nothing out of it but an error message image

api-key and model name ("claude-3-5-sonnet-20240620", "claude-2.1" etc) seem not to be the issue. any idea?

cephalization commented 5 days ago

We've spotted this internally but haven't had the chance to really come up with a great fix.

The main issue is that anthropic servers enforce CORS security, which is somewhat of a non starter in obsidian plugins unless you use a special API that can circumvent that security.

As the plugin attempts to treat all providers generically, it is difficult to special case anthropic and use obsidian's cors workaround for LLM calls using Claude.

We are still thinking of the best way around this problem, sorry for the inconvenience

winne617 commented 5 days ago

good luck! hope you'll manage to solve that somehow;) thanks for the plugin anyway