An example SvelteKit project using https://github.com/semicognitive/sveltekit-modal, showing how easy it is to write Python endpoints in SvelteKit.
See the code for the example +server.py
route here. You'll see it largely mirrors the SvelteKit built-in +server.js
!
api/summarize
endpoint which takes a PDF upload, and summarizes it with the OpenAI Api! Written in Python with LangChain