AI Chart Recommendation
Recommend a chart that fits the selected fields instead of leaving the choice to guesswork.
What it adds
A suggestion of chart type and encoding for the fields a user has picked, with a short reason drawn from the shape of the data.
What your agent is told to do
5
What your agent is told to do
5-
1
Enumerate the chart types the app can actually render, with their real constraints on cardinality, field types, and series count. Give the model that catalogue and require it to choose from it.
-
2
Profile the selected fields in the app before asking for a recommendation: types, distinct counts, null density, whether a field is a continuous time axis, and the row count. The model reasons about the profile, not the data itself.
-
3
Present the recommendation as a proposal the user applies. Do not silently switch a chart the user has already configured, and keep their choice sticky once they have made one.
-
4
Return a reason in terms of the data shape, such as too many distinct categories for a proportional chart. A recommendation with no stated reason cannot be argued with or learned from.
-
5
Do not send the underlying rows to the model. A field profile is enough to pick a chart type, and shipping customer data to a provider to choose between a bar and a line is an unnecessary disclosure.
Edge cases it handles
8
Edge cases it handles
8- A recommendation naming a chart type the app cannot render is worse than no recommendation. Validate the returned choice against the catalogue and fall back to the deterministic default when it does not match.
- Some combinations are actively misleading and must be refused outright: a proportional chart across dozens of categories, a line across an unordered categorical axis, or a dual axis chosen to make two unrelated series appear correlated.
- The explanation must reference the actual profile, naming the distinct count or the field type that drove the choice, rather than offering a generic statement about clarity.
- A recommended chart still has to work at small widths, in both themes, and for a colour-blind reader. A type that needs a dozen distinguishable colours is not a valid recommendation regardless of what the model returns.
- When no visualization improves on the raw values, recommend a table. Sparse data, a single row, or a metric with no meaningful axis reads better as numbers.
- Set a token and time ceiling on the call and fall back to a deterministic rule set built from the same field profile. The user must never wait on a model to see a chart.
- A malformed or partial structured response must be discarded whole. Do not apply the chart type from a response whose encoding fields failed to parse.
- Recommendations must be recomputed when the field selection changes, and not left showing a reason about fields the user has since removed.
Definition of done
9
Definition of done
9- Recommendations are drawn only from chart types the app can render, and invalid returns fall back to a deterministic default.
- The app profiles the selected fields locally and sends no underlying rows to the provider.
- Known-misleading type and field combinations are refused.
- Each recommendation states a reason referencing the concrete data shape.
- A table is recommended when no chart improves comprehension.
- The recommendation is a proposal the user applies, and never overwrites a chart they configured.
- A model timeout or failure still produces a usable chart from deterministic rules.
- The feature matches the existing design system.
- No existing functionality is broken.
Related features
AI Insight Cards
AI Insight Cards
Turn a report into a few grounded cards, each tied to a number the app calculated.
What it does
A small set of cards summarising notable movements in a report, each linked to the query and figure that produced it.
How it works
- 1 Detect candidate movements in the app first, using the report's own aggregations. The model ranks and phrases the candidates it is given; it does not go looking for them and it does not produce the arithmetic.
- 2 Bind each card to the query, metric, and period that support it, and make the card link through to the filtered view so a reader can check it in one click.
- 3 Set a materiality threshold before generation, in both relative and absolute terms, so a swing on a metric with three events does not outrank a real change on a metric with thousands.
Copy the prompt
No account needed
Add this feature to my app:
https://addthisfeature.com/x/ai-insight-cards
AI Trend Analysis
AI Trend Analysis
Explain what a chart is actually showing, in sentences backed by computed numbers.
What it does
A written summary attached to a time series or metric set, describing direction, magnitude, and comparison period.
How it works
- 1 Compute every number in ordinary code before the model is involved: the change, the rate, the comparison period, the baseline, the seasonal adjustment. The model writes prose about figures it is given and must never produce a figure of its own.
- 2 State the comparison window and the time zone in the summary text, resolved from the workspace's configured zone rather than the server's. A change described as week over week is meaningless without saying which weeks.
- 3 Instruct the model to describe what the data shows and to stop there. Do not let it assert causes, attribute movement to campaigns or releases, or predict what happens next.
Copy the prompt
No account needed
Add this feature to my app:
https://addthisfeature.com/x/ai-trend-analysis
Retrieval-Augmented Generation
Retrieval-Augmented Generation
Ground AI answers in the app's own content by retrieving source passages first.
What it does
A retrieval layer that selects permitted passages from app content and supplies them to the model as cited evidence.
How it works
- 1 Decide which content is answerable from and treat everything else as out of scope. A retrieval feature pointed at the whole database returns confident answers about records nobody meant to expose.
- 2 Apply the requesting user's tenant, record, and field permissions during retrieval, before any passage is assembled into a request. Filtering the answer afterwards is too late — the content has already crossed the boundary.
- 3 Chunk on the content's own structure — sections, headings, rows, message boundaries — and carry enough surrounding context in each chunk that it still means something on its own.
Copy the prompt
No account needed
Add this feature to my app:
https://addthisfeature.com/x/retrieval-augmented-generation
How it works
-
1
Copy the link
Grab the Markdown instruction URL for this feature.
-
2
Give it to your AI
Paste it into Claude Code, Cursor, v0, Lovable — whatever you build with.
-
3
It inspects, then implements
Your agent reads your existing app first, then adds the feature to fit it.
Works with your stack
These instructions are written to adapt. They tell the agent to detect your framework, match your existing design system, and reuse what you already have — rather than assuming a particular stack.
Need it tighter than that? Customize the feature and tell it exactly what you're running.