getcursor / cursor

The AI-powered code editor
https://cursor.sh
20.58k stars 1.38k forks source link

Support for poe.com (quora's chatbot service) api #1384

Open knamnguyen opened 3 months ago

knamnguyen commented 3 months ago

Hey team, thank you so much for your hard work! I'm using poe.com on their web interface. Can I propose the feature to support adding poe.com api as an option to access their model through my personal poe.com api key, which will be counted towards my poe.com montly limit?

Context

import asyncio
import fastapi_poe as fp

# Create an asynchronous function to encapsulate the async for loop
async def get_responses(api_key, messages):
    async for partial in fp.get_bot_response(messages=messages, bot_name="GPT-3.5-Turbo", api_key=api_key):
        print(partial)

# Replace <api_key> with your actual API key, ensuring it is a string.
api_key = <api_key>
message = fp.ProtocolMessage(role="user", content="Hello world")

# Run the event loop
# For Python 3.7 and newer
asyncio.run(get_responses(api_key, [message]))

Again, thank you so much for your hardwork!