analyze
Turn event data into a finished product analytics report in one call: choose value event, detect aha moment, build funnel/retention, and write HTML.
Instructions
START HERE. Event data in, finished report out, one call.
Use this whenever the user asks anything general — "analyze my product", "how are my users doing", "find my aha moment". The other tools are parts; this is the whole thing. Only reach for them when the user asks for one specific number ("just show me retention").
It picks a value event, draws the dot plot, finds the aha moment, builds the funnel and retention curve, and writes the HTML report — then tells you what it found so you can say it out loud.
csv_path: a CSV with user_id, date, event (platform optional). No CSV yet? Call with no arguments and follow the instructions you get back — for a project with a database you will explore its schema and turn ordinary business tables (orders, sessions, posts) into events with load_from_db. Most early products have no events table; that is expected.
value_event: the action that means "this user got real value".
Leave it out and the code picks the candidate most users repeat. Pass it
yourself when you have read the codebase and know better — you can tell
purchase from view_item and the code cannot. The result always names
what was chosen and what else was available, so you can call again with a
different one if the choice looks wrong.
lang: the user's language. en/ko/ja are built in; for any other language call get_report_strings, translate, and use generate_report directly.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| lang | No | en | |
| csv_path | No | ||
| output_path | No | dotplot_report.html | |
| value_event | No |