-
Notifications
You must be signed in to change notification settings - Fork 169
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Insights Copilot #108
base: develop
Are you sure you want to change the base?
Conversation
* use langchain as LLM framework * ingest data source schema locally * use ingested data to find relavant tables
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## develop #108 +/- ##
===========================================
- Coverage 57.58% 55.16% -2.42%
===========================================
Files 49 51 +2
Lines 2775 2922 +147
===========================================
+ Hits 1598 1612 +14
- Misses 1177 1310 +133
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report in Codecov by Sentry. |
Nice work! What made you stop working on this?
Maybe with newer models with a bigger context window, like |
The accuracy wasn't very good. Most of the time I had to point out what's wrong in the generated query, which isn't feasible for someone who isn't good with SQL. However I think it'll be useful for developers. I'll try to merge it soon then |
Makes sense. Hopefully the accuracy will improve with newer models, bigger context and fine-tuning the prompt. |
@barredterra, isn't it about giving the model the local knowledge, Database tables their structure and meanings? |
FYI: Using Question: SELECT p.product_category_name, SUM(op.payment_value) AS total_order_value
FROM orderpayments op
JOIN orders o ON op.order_id = o.order_id
JOIN orderitems oi ON o.order_id = oi.order_id
JOIN products p ON oi.product_id = p.product_id
GROUP BY p.product_category_name
ORDER BY total_order_value DESC
LIMIT 10 Using Question: SELECT product_category_name, SUM(price) as order_value
FROM orderitems
JOIN products ON orderitems.product_id = products.product_id
GROUP BY product_category_name
ORDER BY order_value DESC
LIMIT 10 |
InsightsCopilotDemo.mp4
Todo:
frappe.publish_realtime