trustification / trustify

Apache License 2.0
10 stars 19 forks source link

Add API endpoint to interface with a Trustify tooled AI assistant. #811

Open chirino opened 2 months ago

chirino commented 2 months ago

The endpoints should provide a chat interface with an AI assistant that uses the Trustify database to respond to user questions.

chirino commented 2 months ago

This basically means figure out a good API that a web UI can use to do similar things to what was prototyped in this branch: https://github.com/chirino/trustify/tree/ai

chirino commented 2 months ago

@carlosthe19916 hey do you want to help design the API?

carlosthe19916 commented 1 month ago

@chirino I've been looking at some applications that use the "chat" way of interacting with AI. And almost all of them (including ChatGPT) use just a single REST endpoint with event streaming for sending the required text from the backend to the client.

Something like POST /conversation.

I am not sure how much of a complexity we might have but even for Chat GPT a single endpoint seemed to be enough. For starters, we you mentioned in the internal chat, having a blocking REST endpoints that gives back the whole response text would be enough. But as I mentioned I still need more exposure to this kind of APIs for better understanding.

chirino commented 1 month ago

Ok let's start simple and evolve as we go.