3 ms·
Looking at the code, It can only delegate actions to the pre configured functions at: https://github.com/steven-tey/chathn/blob/main/app/api/chat/functions.ts
by yonixw 3y ago
Looking at the code, It can only delegate actions to the pre configured functions at:
https://github.com/steven-tey/chathn/blob/main/app/api/chat/functions.ts https://github.com/steven-tey/chathn/blob/main/app/api/chat/...
I wonder whether it is possible to create "atomic" functions to build high level queries from a user chat. Or maybe even create adapters to virtual db tables, and then tell ChatGPT to convert your query to SQL to be run on said tables.
- steventey 3y agoOP here – and yes, precisely! This is a PoC that is limited to the function/API endpoints you define for it! In this case we'll have to define a "timeframe" variable in the `get_top_stories` function that takes in values like "now", "week", "alltime" etc. to make that work
- politelemon 3y agoCan you explain how does the user's text get converted to one of those questions?
- sid_dubey0312 3y agohttps://github.com/caesarHQ/textSQL https://github.com/caesarHQ/textSQL <- this kind of does the natural language to SQL query thing pretty well