Weld logo
Use Weld's AI assistant to easily use your tables for your prompts.
September 03, 2024Product Updates

New Feature - AI Context

Author image
by Miranda Speyer-Larsen

Our AI assistant Ed now lets you include contexts for your prompt, beyond all the useful features it already had!

What is Ed?

Some of you may be familiar with our AI assistant Ed. With Ed's help, you can effortlessly code SQL and analyze data, unlocking valuable business insights from your data in minutes!

Overview of some cool stuff Ed can do:

  • Create Auto Generated Insights
  • View Conversation History
  • Join multiple sources and tables
  • Re-size conversation chat box
  • Debug SQL errors
  • and so much more!

Auto Generated Insights

Easily explore your data with Ed's help. Click your data source, ask Ed to generate insights, and get 4 metrics based on the schema. For more insights, select 'Recreate Insights' for four additional metrics.

Ed auto generation video

History View

Want to review past interactions with Ed? Use the new history view to access your complete conversation history and run SQL queries directly from your editor for easy reference and use of past insights.

Ed history view video

Improved Context With Multiple Sources

Combine data from multiple sources and tables to give Ed more context. Just start typing the data source name, and a dynamic list of tables will appear for easy selection.

Ed multiple sources video

Re-size Chat Box

Expand the Ed chat box to view your conversations in greater detail, and minimize it again when needed.

Ed re-size chat box image

Debug SQL Errors

Encountering SQL errors? Click the 'help' button under the error, and Ed will diagnose the issue and provide solutions to resolve it.

Ed debug sql image

Introducing new Weld AI feature!

We are very happy to announce a new feature for Ed!

If you were looking for a more user-friendly approach to creating prompts for Ed, you're in luck. Instead of having to manually copy and paste the table or table link to include as context for your prompt, you can now easily select tables from your Data Sources and Models, using a simple and intuitive interface. This will help you save time and make the process of creating prompts more efficient and effortless.

Selecting tables for your prompts:

  1. Open checklist
    • Click on the 'Select tables' button inside the chatroom with Ed.
  2. Select either 'Data sources' or 'Models'
    • Click on the tables you want to include as context in your prompt.
Ed context selection video

What can Ed help you with using this new feature?

Let's say you would like to have an overview of your ad campaigns on Facebook. You can let Ed, our AI assistant, know what tables to consider in your prompts!

Ed context selection

A simple prompt to Ed can help you create the insights you need for your business:

Ed Facebook Ads query

... will provide you with a query such as:

1with
2    campaign_overview as (
3        select
4            ci.campaign_id
5          , ci.campaign_name
6          , ci.account_id
7          , ci.account_name
8          , ci.account_currency
9          , ci.date
10          , ci.cpc
11          , ci.cpm
12          , ci.ctr
13          , ci.frequency
14          , ci.impressions
15          , ci.clicks
16          , ci.inline_link_clicks
17          , ci.reach
18          , ci.spend
19          , sum(a.value) as total_actions
20          , avg(cpa.value) as avg_cost_per_action
21        from
22            {{raw.facebook_ads.campaign_insight}} ci
23            left join {{raw.facebook_ads.campaign_insight_actions}} a on ci.campaign_id = a.campaign_id
24            and ci.date = a.date
25            left join {{raw.facebook_ads.campaign_insight_cost_per_action_type}} cpa on ci.campaign_id = cpa.campaign_id
26            and ci.date = cpa.date
27        group by
28            ci.campaign_id
29          , ci.campaign_name
30          , ci.account_id
31          , ci.account_name
32          , ci.account_currency
33          , ci.date
34          , ci.cpc
35          , ci.cpm
36          , ci.ctr
37          , ci.frequency
38          , ci.impressions
39          , ci.clicks
40          , ci.inline_link_clicks
41          , ci.reach
42          , ci.spend
43    )
44select
45    campaign_id
46  , campaign_name
47  , account_id
48  , account_name
49  , account_currency
50  , date
51  , cpc
52  , cpm
53  , ctr
54  , frequency
55  , impressions
56  , clicks
57  , inline_link_clicks
58  , reach
59  , spend
60  , total_actions
61  , avg_cost_per_action
62from
63    campaign_overview
64order by
65    date desc
66  , campaign_name;

... which, in turn, will give you an output with all the relevant information!

campaign_idcampaign_nameaccount_idaccount_nameaccount_currencydatecpccpmctrfrequencyimpressionsclicksinline_link_clicksreachspendtotal_actionsavg_cost_per_action
123456789Campaign_01987654321CoolCompanyEUR2024-09-01T00:00:00.000Z231.5372563.242.584782.578629846323194324124323245231234.56234320.05268
123456790Campaign_02987654322CoolCompanyEUR2024-09-02T00:00:00.000Z210.78926002.345682.4510000000200000120003300001300.75240000.05432

What about merging different sources?

If you have more sources you would like to combine, simply add the relevant tables from the needed sources to the context, and ask Ed to help you create new insights! For example, you can combine both Facebook and Google Ads tables to curate the relevant data for your business intelligence:

Ed Facebook and Google Ads query
1with
2    facebook_campaign_overview as (
3        select
4            ci.campaign_id
5          , ci.campaign_name
6          , ci.account_id
7          , ci.account_name
8          , ci.account_currency
9          , ci.date
10          , ci.cpc
11          , ci.cpm
12          , ci.ctr
13          , ci.frequency
14          , ci.impressions
15          , ci.clicks
16          , ci.inline_link_clicks
17          , ci.reach
18          , ci.spend
19          , sum(a.value) as total_actions
20          , avg(cpa.value) as avg_cost_per_action
21        from
22            {{raw.facebook_ads.campaign_insight}} ci
23            left join {{raw.facebook_ads.campaign_insight_actions}} a on ci.campaign_id = a.campaign_id
24            and ci.date = a.date
25            left join {{raw.facebook_ads.campaign_insight_cost_per_action_type}} cpa on ci.campaign_id = cpa.campaign_id
26            and ci.date = cpa.date
27        group by
28            ci.campaign_id
29          , ci.campaign_name
30          , ci.account_id
31          , ci.account_name
32          , ci.account_currency
33          , ci.date
34          , ci.cpc
35          , ci.cpm
36          , ci.ctr
37          , ci.frequency
38          , ci.impressions
39          , ci.clicks
40          , ci.inline_link_clicks
41          , ci.reach
42          , ci.spend
43    )
44  , google_campaign_overview as (
45        select
46            cast(cs.campaign_id as string) as campaign_id
47          , cs.campaign_name
48          , cast(cs.account_id as string) as account_id
49          , cs.account_descriptive_name as account_name
50          , ac.currency_code as account_currency
51          , cs.date
52          , null as cpc
53          , null as cpm
54          , null as ctr
55          , null as frequency
56          , cs.impressions
57          , cs.clicks
58          , null as inline_link_clicks
59          , null as reach
60          , cs.cost_micros / 1000000 as spend
61          , cs.conversions as total_actions
62          , null as avg_cost_per_action
63        from
64            {{raw.google_ads.campaign_stats}} cs
65            left join {{raw.google_ads.account}} ac on cs.account_id = ac.id
66    )
67select
68    'Facebook' as platform
69  , campaign_id
70  , campaign_name
71  , account_id
72  , account_name
73  , account_currency
74  , date
75  , cpc
76  , cpm
77  , ctr
78  , frequency
79  , impressions
80  , clicks
81  , inline_link_clicks
82  , reach
83  , spend
84  , total_actions
85  , avg_cost_per_action
86from
87    facebook_campaign_overview
88union all
89select
90    'Google' as platform
91  , campaign_id
92  , campaign_name
93  , account_id
94  , account_name
95  , account_currency
96  , date
97  , cpc
98  , cpm
99  , ctr
100  , frequency
101  , impressions
102  , clicks
103  , inline_link_clicks
104  , reach
105  , spend
106  , total_actions
107  , avg_cost_per_action
108from
109    google_campaign_overview
110order by
111    date desc
112  , campaign_name;

Output:

platformcampaign_idcampaign_nameaccount_idaccount_nameaccount_currencydatecpccpmctrfrequencyimpressionsclicksinline_link_clicksreachspendtotal_actionsavg_cost_per_action
Facebook123456789Campaign_FB_01987654321CoolCompanyEUR2024-09-02T00:00:00.000Z210.7892563.242.584782.578629846323194324124323245231234.56234320.05268
Google123456790Campaign_Goog_01987654322CoolCompanyEUR2024-09-03T00:00:00.000Z245.1232550.52.987652.6510500000210000130003400001350.8250000.05123

An even easier to use Weld!

With this new feature, we at Weld continue to improve on the user experience and we hope your queries are now even easier to create, so that you spend less time dealing with moving your data and more time getting the best insights from it!




🔧 I don't know SQL, can I still use Weld?

Absolutely! With Ed, our AI SQL assistant, you can get started creating data models and metrics without any prior knowledge of SQL.


🙋 Can I use Weld for free?

For sure! We offer a 14-day free trial for you to start exploring your data.

Weld logo

Tired of scattered data? Sync and analyze your data with AI in minutes. Connect to 150+ apps, files and databases.

Backed by leading investors
Frontline logoCherry logoInnnovation Fund logo
Twitter LogoLinkedIn Logo
GDPR logoSOC2
© 2024 Weld. All rights reserved.