diff --git a/ee/hogai/assistant.py b/ee/hogai/assistant.py
index 35bc23e302f3e..17a1c6341b667 100644
--- a/ee/hogai/assistant.py
+++ b/ee/hogai/assistant.py
@@ -148,13 +148,8 @@ def _init_or_update_state(self):
if snapshot.next:
saved_state = validate_state_update(snapshot.values)
self._state = saved_state
- if saved_state.intermediate_steps:
- intermediate_steps = saved_state.intermediate_steps.copy()
- intermediate_steps[-1] = (intermediate_steps[-1][0], self._latest_message.content)
- self._graph.update_state(
- config,
- PartialAssistantState(messages=[self._latest_message], intermediate_steps=intermediate_steps),
- )
+ self._graph.update_state(config, PartialAssistantState(messages=[self._latest_message], resumed=True))
+
return None
initial_state = self._initial_state
self._state = initial_state
diff --git a/ee/hogai/schema_generator/nodes.py b/ee/hogai/schema_generator/nodes.py
index 3b12bbc65fe30..98a5d6ede2eae 100644
--- a/ee/hogai/schema_generator/nodes.py
+++ b/ee/hogai/schema_generator/nodes.py
@@ -107,15 +107,15 @@ def _run_with_prompt(
],
)
+ final_message = VisualizationMessage(
+ plan=generated_plan,
+ answer=message.query,
+ initiator=start_id,
+ id=str(uuid4()),
+ )
+
return PartialAssistantState(
- messages=[
- VisualizationMessage(
- plan=generated_plan,
- answer=message.query,
- initiator=start_id,
- id=str(uuid4()),
- )
- ],
+ messages=[final_message],
intermediate_steps=[],
plan="",
)
diff --git a/ee/hogai/summarizer/nodes.py b/ee/hogai/summarizer/nodes.py
index 513246bcc1238..f03db53879268 100644
--- a/ee/hogai/summarizer/nodes.py
+++ b/ee/hogai/summarizer/nodes.py
@@ -1,8 +1,10 @@
+import datetime
import json
from time import sleep
from uuid import uuid4
from django.conf import settings
+from django.utils import timezone
from django.core.serializers.json import DjangoJSONEncoder
from langchain_core.prompts import ChatPromptTemplate
from langchain_core.runnables import RunnableConfig
@@ -76,11 +78,17 @@ def run(self, state: AssistantState, config: RunnableConfig) -> PartialAssistant
chain = summarization_prompt | self._model
+ utc_now = timezone.now().astimezone(datetime.UTC)
+ project_now = utc_now.astimezone(self._team.timezone_info)
+
message = chain.invoke(
{
"query_kind": viz_message.answer.kind,
"product_description": self._team.project.product_description,
"results": json.dumps(results_response["results"], cls=DjangoJSONEncoder),
+ "utc_datetime_display": utc_now.strftime("%Y-%m-%d %H:%M:%S"),
+ "project_datetime_display": project_now.strftime("%Y-%m-%d %H:%M:%S"),
+ "project_timezone": self._team.timezone_info.tzname(utc_now),
},
config,
)
diff --git a/ee/hogai/summarizer/prompts.py b/ee/hogai/summarizer/prompts.py
index bf2272d9d4cbe..9a85ee039ed5c 100644
--- a/ee/hogai/summarizer/prompts.py
+++ b/ee/hogai/summarizer/prompts.py
@@ -1,17 +1,29 @@
SUMMARIZER_SYSTEM_PROMPT = """
-Act as an expert product manager. Your task is to summarize query results in a a concise way.
-Offer actionable feedback if possible. Only provide feedback that you're absolutely certain will be useful for this team.
+Act as an expert product manager. Your task is to help the user build a successful product and business.
+Also, you're a hedeghog named Max.
+
+Offer actionable feedback if possible. Only provide suggestions you're certain will be useful for this team.
+Acknowledge when more information would be needed. When query results are provided, note that the user can already see the chart.
+
+Use Silicon Valley lingo. Be informal but get to the point immediately, without fluff - e.g. don't start with "alright, …".
+NEVER use title case, even in headings. Our style is sentence case EVERYWHERE.
+You can use Markdown for emphasis. Bullets can improve clarity of action points.
The product being analyzed is described as follows:
{{product_description}}"""
SUMMARIZER_INSTRUCTION_PROMPT = """
-Here are the {{query_kind}} results for this question:
+Here are results of the {{query_kind}} you created to answer my latest question:
+
```json
{{results}}
```
-Answer my earlier question using the results above. Point out interesting trends or anomalies.
-Take into account what you know about my product. If possible, offer actionable feedback, but avoid generic advice.
-Limit yourself to a few sentences. The answer needs to be high-impact and relevant for me as a Silicon Valley engineer.
+The current date and time is {{utc_datetime_display}} UTC, which is {{project_datetime_display}} in this project's timezone ({{project_timezone}}).
+It's expected that the data point for the current period can have a drop in value, as it's not complete yet - don't point this out to me.
+
+Based on the results, answer my question and provide actionable feedback. Avoid generic advice. Take into account what you know about the product.
+The answer needs to be high-impact, no more than a few sentences.
+
+You MUST point out if the executed query or its results are insufficient for a full answer to my question.
"""
diff --git a/ee/hogai/taxonomy_agent/nodes.py b/ee/hogai/taxonomy_agent/nodes.py
index bd26a7a93918f..92fe74ae55bcb 100644
--- a/ee/hogai/taxonomy_agent/nodes.py
+++ b/ee/hogai/taxonomy_agent/nodes.py
@@ -267,12 +267,18 @@ def _run_with_toolkit(
)
if input.name == "ask_user_for_help":
# The agent has requested help, so we interrupt the graph.
- if not observation:
+ if not state.resumed:
raise NodeInterrupt(input.arguments)
# Feedback was provided.
+ last_message = state.messages[-1]
+ response = ""
+ if isinstance(last_message, HumanMessage):
+ response = last_message.content
+
return PartialAssistantState(
- intermediate_steps=[*intermediate_steps[:-1], (action, observation)],
+ resumed=False,
+ intermediate_steps=[*intermediate_steps[:-1], (action, response)],
)
output = ""
diff --git a/ee/hogai/test/test_assistant.py b/ee/hogai/test/test_assistant.py
index 4f4ad45170b99..48bb9b05d9b7e 100644
--- a/ee/hogai/test/test_assistant.py
+++ b/ee/hogai/test/test_assistant.py
@@ -252,7 +252,7 @@ def test_funnels_interrupt_when_asking_for_help(self):
)
self._test_human_in_the_loop(graph)
- def test_intermediate_steps_are_updated_after_feedback(self):
+ def test_messages_are_updated_after_feedback(self):
with patch("ee.hogai.taxonomy_agent.nodes.TaxonomyAgentPlannerNode._model") as mock:
graph = (
AssistantGraph(self.team)
@@ -286,6 +286,7 @@ def test_intermediate_steps_are_updated_after_feedback(self):
action, observation = snapshot.values["intermediate_steps"][0]
self.assertEqual(action.tool, "ask_user_for_help")
self.assertIsNone(observation)
+ self.assertNotIn("resumed", snapshot.values)
self._run_assistant_graph(graph, conversation=self.conversation, message="It's straightforward")
snapshot: StateSnapshot = graph.get_state(config)
@@ -298,6 +299,44 @@ def test_intermediate_steps_are_updated_after_feedback(self):
action, observation = snapshot.values["intermediate_steps"][1]
self.assertEqual(action.tool, "ask_user_for_help")
self.assertIsNone(observation)
+ self.assertFalse(snapshot.values["resumed"])
+
+ def test_resuming_uses_saved_state(self):
+ with patch("ee.hogai.taxonomy_agent.nodes.TaxonomyAgentPlannerNode._model") as mock:
+ graph = (
+ AssistantGraph(self.team)
+ .add_edge(AssistantNodeName.START, AssistantNodeName.FUNNEL_PLANNER)
+ .add_funnel_planner(AssistantNodeName.END)
+ .compile()
+ )
+ config: RunnableConfig = {
+ "configurable": {
+ "thread_id": self.conversation.id,
+ }
+ }
+
+ # Interrupt the graph
+ message = """
+ Thought: Let's ask for help.
+ Action:
+ ```
+ {
+ "action": "ask_user_for_help",
+ "action_input": "Need help with this query"
+ }
+ ```
+ """
+ mock.return_value = RunnableLambda(lambda _: messages.AIMessage(content=message))
+
+ self._run_assistant_graph(graph, conversation=self.conversation)
+ state: StateSnapshot = graph.get_state(config).values
+ self.assertIn("start_id", state)
+ self.assertIsNotNone(state["start_id"])
+
+ self._run_assistant_graph(graph, conversation=self.conversation, message="It's straightforward")
+ state: StateSnapshot = graph.get_state(config).values
+ self.assertIn("start_id", state)
+ self.assertIsNotNone(state["start_id"])
def test_new_conversation_handles_serialized_conversation(self):
graph = (
diff --git a/ee/hogai/utils/types.py b/ee/hogai/utils/types.py
index 2df027b6f85af..917edb3d4987e 100644
--- a/ee/hogai/utils/types.py
+++ b/ee/hogai/utils/types.py
@@ -27,6 +27,7 @@ class _SharedAssistantState(BaseModel):
The ID of the message from which the conversation started.
"""
plan: Optional[str] = Field(default=None)
+ resumed: Optional[bool] = Field(default=None)
class AssistantState(_SharedAssistantState):
@@ -34,7 +35,7 @@ class AssistantState(_SharedAssistantState):
class PartialAssistantState(_SharedAssistantState):
- messages: Optional[Annotated[Sequence[AssistantMessageUnion], operator.add]] = Field(default=None)
+ messages: Optional[Sequence[AssistantMessageUnion]] = Field(default=None)
class AssistantNodeName(StrEnum):
diff --git a/frontend/__snapshots__/scenes-app-insights--funnel-top-to-bottom-breakdown-edit--light.png b/frontend/__snapshots__/scenes-app-insights--funnel-top-to-bottom-breakdown-edit--light.png
index 6724b2a2d5179..00916265cd38b 100644
Binary files a/frontend/__snapshots__/scenes-app-insights--funnel-top-to-bottom-breakdown-edit--light.png and b/frontend/__snapshots__/scenes-app-insights--funnel-top-to-bottom-breakdown-edit--light.png differ
diff --git a/frontend/src/scenes/experiments/Experiment.stories.tsx b/frontend/src/scenes/experiments/Experiment.stories.tsx
deleted file mode 100644
index 737b7f2973c12..0000000000000
--- a/frontend/src/scenes/experiments/Experiment.stories.tsx
+++ /dev/null
@@ -1,1488 +0,0 @@
-import { Meta, StoryFn } from '@storybook/react'
-import { router } from 'kea-router'
-import { useEffect } from 'react'
-import { App } from 'scenes/App'
-import { urls } from 'scenes/urls'
-
-import { mswDecorator } from '~/mocks/browser'
-import { toPaginatedResponse } from '~/mocks/handlers'
-import {
- BreakdownAttributionType,
- ChartDisplayType,
- Experiment,
- FunnelConversionWindowTimeUnit,
- FunnelExperimentResults,
- FunnelsFilterType,
- FunnelVizType,
- InsightType,
- PropertyFilterType,
- PropertyOperator,
- SignificanceCode,
- TrendsExperimentResults,
-} from '~/types'
-
-const MOCK_FUNNEL_EXPERIMENT: Experiment = {
- id: 1,
- name: 'New sign-up flow',
- description:
- "We've rebuilt our sign-up page to offer a more personalized experience. Let's see if this version performs better with potential users.",
- start_date: '2022-12-10T08:06:27.027740Z',
- end_date: '2023-02-07T16:12:54.055481Z',
- feature_flag_key: 'signup-page-4.0',
- feature_flag: {
- id: 1,
- team_id: 1,
- name: 'New sign-up page',
- key: 'signup-page-4.0',
- active: false,
- deleted: false,
- ensure_experience_continuity: false,
- filters: {
- groups: [
- {
- properties: [
- {
- key: 'company_name',
- type: PropertyFilterType.Group,
- value: 'awe',
- operator: PropertyOperator.IContains,
- group_type_index: 1,
- },
- ],
- variant: null,
- rollout_percentage: undefined,
- },
- ],
- payloads: {},
- multivariate: {
- variants: [
- {
- key: 'control',
- rollout_percentage: 33,
- },
- {
- key: 'test',
- rollout_percentage: 33,
- },
- {
- key: 'test_group_2',
- rollout_percentage: 34,
- },
- ],
- },
- aggregation_group_type_index: 1,
- },
- },
- parameters: {
- feature_flag_variants: [
- {
- key: 'control',
- rollout_percentage: 50,
- },
- {
- key: 'test',
- rollout_percentage: 50,
- },
- ],
- recommended_sample_size: 137,
- minimum_detectable_effect: 1,
- },
- secondary_metrics: [],
- filters: {
- events: [
- {
- id: '$pageview',
- name: '$pageview',
- type: 'events',
- order: 0,
- properties: [
- {
- key: '$current_url',
- type: 'event',
- value: 'https://hedgebox.net/signup/',
- operator: 'exact',
- },
- ],
- },
- {
- id: 'signed_up',
- name: 'signed_up',
- type: 'events',
- order: 1,
- },
- ],
- actions: [],
- insight: InsightType.FUNNELS,
- interval: 'day',
- filter_test_accounts: true,
- },
- metrics: [],
- metrics_secondary: [],
- archived: false,
- created_by: {
- id: 1,
- uuid: '01863799-062b-0000-8a61-b2842d5f8642',
- distinct_id: 'Sopz9Z4NMIfXGlJe6W1XF98GOqhHNui5J5eRe0tBGTE',
- first_name: 'Employee 427',
- email: 'test2@posthog.com',
- },
- created_at: '2022-12-10T07:06:27.027740Z',
- updated_at: '2023-02-09T19:13:57.137954Z',
-}
-
-const MOCK_TREND_EXPERIMENT: Experiment = {
- id: 2,
- name: 'aloha',
- start_date: '2023-02-11T10:37:17.634000Z',
- end_date: null,
- feature_flag_key: 'aloha',
- feature_flag: {
- id: 1,
- team_id: 1,
- name: 'Hellp everyone',
- key: 'aloha',
- active: false,
- deleted: false,
- ensure_experience_continuity: false,
- filters: {
- groups: [
- {
- properties: [
- {
- key: 'company_name',
- type: PropertyFilterType.Person,
- value: 'awesome',
- operator: PropertyOperator.IContains,
- },
- ],
- variant: null,
- rollout_percentage: undefined,
- },
- ],
- payloads: {},
- multivariate: {
- variants: [
- {
- key: 'control',
- rollout_percentage: 50,
- },
- {
- key: 'test',
- rollout_percentage: 50,
- },
- ],
- },
- },
- },
- metrics: [],
- metrics_secondary: [],
- parameters: {
- feature_flag_variants: [
- {
- key: 'control',
- rollout_percentage: 50,
- },
- {
- key: 'test',
- rollout_percentage: 50,
- },
- ],
- recommended_sample_size: 0,
- recommended_running_time: 28.3,
- },
- secondary_metrics: [],
- filters: {
- events: [
- {
- id: '$pageview',
- math: 'avg_count_per_actor',
- name: '$pageview',
- type: 'events',
- order: 0,
- },
- ],
- actions: [],
- date_to: '2023-05-19T23:59',
- insight: InsightType.TRENDS,
- interval: 'day',
- date_from: '2023-05-05T11:36',
- filter_test_accounts: false,
- },
- archived: false,
- created_by: {
- id: 1,
- uuid: '01881f35-b41a-0000-1d94-331938392cac',
- distinct_id: 'Xr1OY26ZsDh9ZbvA212ggq4l0Hf0dmEUjT33zvRPKrX',
- first_name: 'SS',
- email: 'test@posthog.com',
- is_email_verified: false,
- },
- created_at: '2022-03-15T21:31:00.192917Z',
- updated_at: '2022-03-15T21:31:00.192917Z',
-}
-
-const MOCK_WEB_EXPERIMENT_MANY_VARIANTS: Experiment = {
- id: 4,
- name: 'web-experiment',
- type: 'web',
- start_date: '2023-02-11T10:37:17.634000Z',
- end_date: null,
- feature_flag_key: 'web-experiment',
- feature_flag: {
- id: 1,
- team_id: 1,
- name: 'Web Experiment on Hawaii.com',
- key: 'web-experiment',
- active: false,
- deleted: false,
- ensure_experience_continuity: false,
- filters: {
- groups: [
- {
- properties: [
- {
- key: 'company_name',
- type: PropertyFilterType.Person,
- value: 'awesome',
- operator: PropertyOperator.IContains,
- },
- ],
- variant: null,
- rollout_percentage: undefined,
- },
- ],
- payloads: {},
- multivariate: {
- variants: [
- {
- key: 'control',
- rollout_percentage: 16,
- },
- {
- key: 'test_1',
- rollout_percentage: 16,
- },
- {
- key: 'test_2',
- rollout_percentage: 16,
- },
- {
- key: 'test_3',
- rollout_percentage: 16,
- },
- {
- key: 'test_4',
- rollout_percentage: 16,
- },
- {
- key: 'test_5',
- rollout_percentage: 20,
- },
- ],
- },
- },
- },
- metrics: [],
- metrics_secondary: [],
- parameters: {
- feature_flag_variants: [
- {
- key: 'control',
- rollout_percentage: 16,
- },
- {
- key: 'test_1',
- rollout_percentage: 16,
- },
- {
- key: 'test_2',
- rollout_percentage: 16,
- },
- {
- key: 'test_3',
- rollout_percentage: 16,
- },
- {
- key: 'test_4',
- rollout_percentage: 16,
- },
- {
- key: 'test_5',
- rollout_percentage: 20,
- },
- ],
- recommended_sample_size: 0,
- recommended_running_time: 28.3,
- },
- secondary_metrics: [],
- filters: {
- events: [
- {
- id: '$pageview',
- math: 'avg_count_per_actor',
- name: '$pageview',
- type: 'events',
- order: 0,
- },
- ],
- actions: [],
- date_to: '2023-05-19T23:59',
- insight: InsightType.TRENDS,
- interval: 'day',
- date_from: '2023-05-05T11:36',
- filter_test_accounts: false,
- },
- archived: false,
- created_by: {
- id: 1,
- uuid: '01881f35-b41a-0000-1d94-331938392cac',
- distinct_id: 'Xr1OY26ZsDh9ZbvA212ggq4l0Hf0dmEUjT33zvRPKrX',
- first_name: 'SS',
- email: 'test@posthog.com',
- is_email_verified: false,
- },
- created_at: '2022-03-15T21:31:00.192917Z',
- updated_at: '2022-03-15T21:31:00.192917Z',
-}
-
-const MOCK_TREND_EXPERIMENT_MANY_VARIANTS: Experiment = {
- id: 3,
- name: 'aloha',
- start_date: '2023-02-11T10:37:17.634000Z',
- end_date: null,
- feature_flag_key: 'aloha',
- feature_flag: {
- id: 1,
- team_id: 1,
- name: 'Hellp everyone',
- key: 'aloha',
- active: false,
- deleted: false,
- ensure_experience_continuity: false,
- filters: {
- groups: [
- {
- properties: [
- {
- key: 'company_name',
- type: PropertyFilterType.Person,
- value: 'awesome',
- operator: PropertyOperator.IContains,
- },
- ],
- variant: null,
- rollout_percentage: undefined,
- },
- ],
- payloads: {},
- multivariate: {
- variants: [
- {
- key: 'control',
- rollout_percentage: 16,
- },
- {
- key: 'test_1',
- rollout_percentage: 16,
- },
- {
- key: 'test_2',
- rollout_percentage: 16,
- },
- {
- key: 'test_3',
- rollout_percentage: 16,
- },
- {
- key: 'test_4',
- rollout_percentage: 16,
- },
- {
- key: 'test_5',
- rollout_percentage: 20,
- },
- ],
- },
- },
- },
- metrics: [],
- metrics_secondary: [],
- parameters: {
- feature_flag_variants: [
- {
- key: 'control',
- rollout_percentage: 16,
- },
- {
- key: 'test_1',
- rollout_percentage: 16,
- },
- {
- key: 'test_2',
- rollout_percentage: 16,
- },
- {
- key: 'test_3',
- rollout_percentage: 16,
- },
- {
- key: 'test_4',
- rollout_percentage: 16,
- },
- {
- key: 'test_5',
- rollout_percentage: 20,
- },
- ],
- recommended_sample_size: 0,
- recommended_running_time: 28.3,
- },
- secondary_metrics: [],
- filters: {
- events: [
- {
- id: '$pageview',
- math: 'avg_count_per_actor',
- name: '$pageview',
- type: 'events',
- order: 0,
- },
- ],
- actions: [],
- date_to: '2023-05-19T23:59',
- insight: InsightType.TRENDS,
- interval: 'day',
- date_from: '2023-05-05T11:36',
- filter_test_accounts: false,
- },
- archived: false,
- created_by: {
- id: 1,
- uuid: '01881f35-b41a-0000-1d94-331938392cac',
- distinct_id: 'Xr1OY26ZsDh9ZbvA212ggq4l0Hf0dmEUjT33zvRPKrX',
- first_name: 'SS',
- email: 'test@posthog.com',
- is_email_verified: false,
- },
- created_at: '2022-03-15T21:31:00.192917Z',
- updated_at: '2022-03-15T21:31:00.192917Z',
-}
-
-const MOCK_EXPERIMENT_RESULTS: FunnelExperimentResults = {
- result: {
- fakeInsightId: '123',
- insight: [
- [
- {
- action_id: '$pageview',
- name: '$pageview',
- order: 0,
- people: [],
- count: 71,
- type: 'events',
- average_conversion_time: null,
- median_conversion_time: null,
- breakdown: ['test'],
- breakdown_value: ['test'],
- converted_people_url:
- '/api/person/funnel/?breakdown=%5B%22%24feature%2Fsignup-page-4.0%22%5D&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2022-12-10T08%3A06%3A27.027740%2B00%3A00&date_to=2023-02-07T16%3A12%3A54.055481%2B00%3A00&explicit_date=true&display=FunnelViz&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+null%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24current_url%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%22https%3A%2F%2Fhedgebox.net%2Fsignup%2F%22%7D%5D%7D%7D%2C+%7B%22id%22%3A+%22signed_up%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+1%2C+%22name%22%3A+%22signed_up%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+null%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&filter_test_accounts=True&funnel_step_breakdown=%5B%22test%22%5D&funnel_step=1&funnel_viz_type=steps&funnel_window_interval=14&funnel_window_interval_unit=day&insight=FUNNELS&interval=day&limit=100&smoothing_intervals=1',
- dropped_people_url: null,
- },
- {
- action_id: 'signed_up',
- name: 'signed_up',
- order: 1,
- people: [],
- count: 43,
- type: 'events',
- average_conversion_time: 53.04651162790697,
- median_conversion_time: 53,
- breakdown: ['test'],
- breakdown_value: ['test'],
- converted_people_url:
- '/api/person/funnel/?breakdown=%5B%22%24feature%2Fsignup-page-4.0%22%5D&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2022-12-10T08%3A06%3A27.027740%2B00%3A00&date_to=2023-02-07T16%3A12%3A54.055481%2B00%3A00&explicit_date=true&display=FunnelViz&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+null%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24current_url%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%22https%3A%2F%2Fhedgebox.net%2Fsignup%2F%22%7D%5D%7D%7D%2C+%7B%22id%22%3A+%22signed_up%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+1%2C+%22name%22%3A+%22signed_up%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+null%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&filter_test_accounts=True&funnel_step_breakdown=%5B%22test%22%5D&funnel_step=2&funnel_viz_type=steps&funnel_window_interval=14&funnel_window_interval_unit=day&insight=FUNNELS&interval=day&limit=100&smoothing_intervals=1',
- dropped_people_url:
- '/api/person/funnel/?breakdown=%5B%22%24feature%2Fsignup-page-4.0%22%5D&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2022-12-10T08%3A06%3A27.027740%2B00%3A00&date_to=2023-02-07T16%3A12%3A54.055481%2B00%3A00&explicit_date=true&display=FunnelViz&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+null%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24current_url%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%22https%3A%2F%2Fhedgebox.net%2Fsignup%2F%22%7D%5D%7D%7D%2C+%7B%22id%22%3A+%22signed_up%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+1%2C+%22name%22%3A+%22signed_up%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+null%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&filter_test_accounts=True&funnel_step_breakdown=%5B%22test%22%5D&funnel_step=-2&funnel_viz_type=steps&funnel_window_interval=14&funnel_window_interval_unit=day&insight=FUNNELS&interval=day&limit=100&smoothing_intervals=1',
- },
- ],
- [
- {
- action_id: '$pageview',
- name: '$pageview',
- custom_name: null,
- order: 0,
- people: [],
- count: 69,
- type: 'events',
- average_conversion_time: null,
- median_conversion_time: null,
- breakdown: ['control'],
- breakdown_value: ['control'],
- converted_people_url:
- '/api/person/funnel/?breakdown=%5B%22%24feature%2Fsignup-page-4.0%22%5D&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2022-12-10T08%3A06%3A27.027740%2B00%3A00&date_to=2023-02-07T16%3A12%3A54.055481%2B00%3A00&explicit_date=true&display=FunnelViz&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+null%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24current_url%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%22https%3A%2F%2Fhedgebox.net%2Fsignup%2F%22%7D%5D%7D%7D%2C+%7B%22id%22%3A+%22signed_up%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+1%2C+%22name%22%3A+%22signed_up%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+null%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&filter_test_accounts=True&funnel_step_breakdown=%5B%22control%22%5D&funnel_step=1&funnel_viz_type=steps&funnel_window_interval=14&funnel_window_interval_unit=day&insight=FUNNELS&interval=day&limit=100&smoothing_intervals=1',
- dropped_people_url: null,
- },
- {
- action_id: 'signed_up',
- name: 'signed_up',
- custom_name: null,
- order: 1,
- people: [],
- count: 31,
- type: 'events',
- average_conversion_time: 66.6774193548387,
- median_conversion_time: 63,
- breakdown: ['control'],
- breakdown_value: ['control'],
- converted_people_url:
- '/api/person/funnel/?breakdown=%5B%22%24feature%2Fsignup-page-4.0%22%5D&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2022-12-10T08%3A06%3A27.027740%2B00%3A00&date_to=2023-02-07T16%3A12%3A54.055481%2B00%3A00&explicit_date=true&display=FunnelViz&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+null%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24current_url%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%22https%3A%2F%2Fhedgebox.net%2Fsignup%2F%22%7D%5D%7D%7D%2C+%7B%22id%22%3A+%22signed_up%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+1%2C+%22name%22%3A+%22signed_up%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+null%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&filter_test_accounts=True&funnel_step_breakdown=%5B%22control%22%5D&funnel_step=2&funnel_viz_type=steps&funnel_window_interval=14&funnel_window_interval_unit=day&insight=FUNNELS&interval=day&limit=100&smoothing_intervals=1',
- dropped_people_url:
- '/api/person/funnel/?breakdown=%5B%22%24feature%2Fsignup-page-4.0%22%5D&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2022-12-10T08%3A06%3A27.027740%2B00%3A00&date_to=2023-02-07T16%3A12%3A54.055481%2B00%3A00&explicit_date=true&display=FunnelViz&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+null%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24current_url%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%22https%3A%2F%2Fhedgebox.net%2Fsignup%2F%22%7D%5D%7D%7D%2C+%7B%22id%22%3A+%22signed_up%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+1%2C+%22name%22%3A+%22signed_up%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+null%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&filter_test_accounts=True&funnel_step_breakdown=%5B%22control%22%5D&funnel_step=-2&funnel_viz_type=steps&funnel_window_interval=14&funnel_window_interval_unit=day&insight=FUNNELS&interval=day&limit=100&smoothing_intervals=1',
- },
- ],
- ],
- probability: {
- control: 0.03264999999999996,
- test: 0.96735,
- },
- significant: false,
- filters: {
- breakdown: ['$feature/signup-page-4.0'],
- breakdown_attribution_type: BreakdownAttributionType.FirstTouch,
- breakdown_normalize_url: false,
- breakdown_type: 'event',
- date_from: '2022-12-10T08:06:27.027740+00:00',
- date_to: '2023-02-07T16:12:54.055481+00:00',
- explicit_date: 'true',
- display: 'FunnelViz',
- events: [
- {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: null,
- math_property: null,
- math_group_type_index: null,
- properties: {
- type: 'AND',
- values: [
- {
- key: '$current_url',
- operator: 'exact',
- type: 'event',
- value: 'https://hedgebox.net/signup/',
- },
- ],
- },
- },
- {
- id: 'signed_up',
- type: 'events',
- order: 1,
- name: 'signed_up',
- custom_name: null,
- math: null,
- math_property: null,
- math_group_type_index: null,
- properties: {},
- },
- ],
- filter_test_accounts: true,
- funnel_viz_type: FunnelVizType.Steps,
- funnel_window_interval: 14,
- funnel_window_interval_unit: FunnelConversionWindowTimeUnit.Day,
- insight: InsightType.FUNNELS,
- interval: 'day',
- limit: 100,
- smoothing_intervals: 1,
- sampling_factor: 0.1,
- } as FunnelsFilterType,
- significance_code: SignificanceCode.NotEnoughExposure,
- expected_loss: 1,
- variants: [
- {
- key: 'control',
- success_count: 31,
- failure_count: 38,
- },
- {
- key: 'test',
- success_count: 43,
- failure_count: 28,
- },
- ],
- credible_intervals: {
- control: [0.0126, 0.0526],
- test: [0.0526, 0.0826],
- },
- },
-}
-
-const MOCK_TREND_EXPERIMENT_RESULTS: TrendsExperimentResults = {
- result: {
- fakeInsightId: '1234',
- insight: [
- {
- action: {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: undefined,
- math_group_type_index: undefined,
- },
- aggregated_value: 0,
- label: '$pageview - test',
- count: 26,
- data: [2.5416666666666, 4.5416666666665, 3.5416666665, 1.666666666665, 8.366666665],
- labels: ['11-Feb-2023', '12-Feb-2023', '13-Feb-2023', '14-Feb-2023', '15-Feb-2023'],
- days: ['2023-02-11', '2023-02-12', '2023-02-13', '2023-02-14', '2023-02-15'],
- breakdown_value: 'test',
- persons_urls: [
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- ],
- filter: {
- breakdown: '$feature/aloha',
- breakdown_normalize_url: false,
- breakdown_type: 'event',
- date_from: '2023-02-11T10:37:17.634000Z',
- date_to: '2023-02-16T10:37:17.634000Z',
- explicit_date: 'true',
- display: ChartDisplayType.ActionsLineGraph,
- events: [
- {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: null,
- math_group_type_index: null,
- properties: {},
- },
- ],
- insight: InsightType.TRENDS,
- interval: 'day',
- properties: [
- {
- key: '$feature/aloha',
- operator: PropertyOperator.Exact,
- type: PropertyFilterType.Event,
- value: ['control', 'test'],
- },
- ],
- sampling_factor: undefined,
- smoothing_intervals: 1,
- },
- },
- {
- action: {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: undefined,
- math_group_type_index: null,
- properties: undefined,
- },
- aggregated_value: 0,
- label: '$pageview - control',
- count: 11.421053,
- data: [
- 2.4210526315789473, 1.4210526315789473, 3.4210526315789473, 0.4210526315789473, 3.4210526315789473,
- ],
- labels: ['11-Feb-2023', '12-Feb-2023', '13-Feb-2023', '14-Feb-2023', '15-Feb-2023'],
- days: ['2023-02-11', '2023-02-12', '2023-02-13', '2023-02-14', '2023-02-15'],
- breakdown_value: 'control',
- persons_urls: [
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- ],
- filter: {
- breakdown: '$feature/aloha',
- breakdown_normalize_url: false,
- breakdown_type: 'event',
- date_from: '2023-02-11T10:37:17.634000Z',
- explicit_date: 'true',
- display: ChartDisplayType.ActionsLineGraph,
- events: [
- {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: null,
- math_group_type_index: null,
- properties: {},
- },
- ],
- insight: InsightType.TRENDS,
- interval: 'day',
- properties: [
- {
- key: '$feature/aloha',
- operator: PropertyOperator.Exact,
- type: PropertyFilterType.Event,
- value: ['control', 'test'],
- },
- ],
- sampling_factor: undefined,
- smoothing_intervals: 1,
- },
- },
- ],
- probability: {
- control: 0.407580005,
- test: 0.59242,
- },
- significant: false,
- filters: {
- breakdown: '$feature/aloha',
- breakdown_normalize_url: false,
- breakdown_type: 'event',
- date_from: '2023-02-11T10:37:17.634000Z',
- explicit_date: 'true',
- display: ChartDisplayType.ActionsLineGraph,
- events: [
- {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: null,
- math_group_type_index: null,
- properties: {},
- },
- ],
- insight: InsightType.TRENDS,
- interval: 'day',
- properties: [
- {
- key: '$feature/aloha',
- operator: PropertyOperator.Exact,
- type: PropertyFilterType.Event,
- value: ['control', 'test'],
- },
- ],
- sampling_factor: undefined,
- smoothing_intervals: 1,
- },
- exposure_filters: {
- breakdown: '$feature/aloha',
- breakdown_normalize_url: false,
- breakdown_type: 'event',
- date_from: '2023-02-11T10:37:17.634000Z',
- explicit_date: 'true',
- display: ChartDisplayType.ActionsLineGraph,
- events: [
- {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- math: 'dau',
- },
- ],
- insight: InsightType.TRENDS,
- interval: 'day',
- properties: [
- {
- key: '$feature/aloha',
- operator: PropertyOperator.Exact,
- type: PropertyFilterType.Event,
- value: ['control', 'test'],
- },
- ],
- },
- significance_code: SignificanceCode.NotEnoughExposure,
- p_value: 1,
- variants: [
- {
- key: 'control',
- count: 46,
- exposure: 1,
- absolute_exposure: 19,
- },
- {
- key: 'test',
- count: 61,
- exposure: 1.263157894736842,
- absolute_exposure: 24,
- },
- ],
- credible_intervals: {
- control: [1.5678, 3.8765],
- test: [1.2345, 3.4567],
- },
- },
- last_refresh: '2023-02-11T10:37:17.634000Z',
- is_cached: true,
-}
-
-const MOCK_TREND_EXPERIMENT_MANY_VARIANTS_RESULTS: TrendsExperimentResults = {
- result: {
- fakeInsightId: '12345',
- insight: [
- {
- action: {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: undefined,
- math_group_type_index: undefined,
- },
- aggregated_value: 0,
- label: '$pageview - test_1',
- count: 26,
- data: [2.5416666666666, 4.5416666666665, 3.5416666665, 1.666666666665, 8.366666665],
- labels: ['11-Feb-2023', '12-Feb-2023', '13-Feb-2023', '14-Feb-2023', '15-Feb-2023'],
- days: ['2023-02-11', '2023-02-12', '2023-02-13', '2023-02-14', '2023-02-15'],
- breakdown_value: 'test_1',
- persons_urls: [
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- ],
- filter: {
- breakdown: '$feature/aloha',
- breakdown_normalize_url: false,
- breakdown_type: 'event',
- date_from: '2023-02-11T10:37:17.634000Z',
- date_to: '2023-02-16T10:37:17.634000Z',
- explicit_date: 'true',
- display: ChartDisplayType.ActionsLineGraph,
- events: [
- {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: null,
- math_group_type_index: null,
- properties: {},
- },
- ],
- insight: InsightType.TRENDS,
- interval: 'day',
- properties: [
- {
- key: '$feature/aloha',
- operator: PropertyOperator.Exact,
- type: PropertyFilterType.Event,
- value: ['control', 'test_1', 'test_2', 'test_3', 'test_4', 'test_5'],
- },
- ],
- sampling_factor: undefined,
- smoothing_intervals: 1,
- },
- },
- {
- action: {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: undefined,
- math_group_type_index: undefined,
- },
- aggregated_value: 0,
- label: '$pageview - test_2',
- count: 26,
- data: [3.5416666666666, 5.5416666666665, 4.5416666665, 2.666666666665, 9.366666665],
- labels: ['11-Feb-2023', '12-Feb-2023', '13-Feb-2023', '14-Feb-2023', '15-Feb-2023'],
- days: ['2023-02-11', '2023-02-12', '2023-02-13', '2023-02-14', '2023-02-15'],
- breakdown_value: 'test_2',
- persons_urls: [
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- ],
- filter: {
- breakdown: '$feature/aloha',
- breakdown_normalize_url: false,
- breakdown_type: 'event',
- date_from: '2023-02-11T10:37:17.634000Z',
- date_to: '2023-02-16T10:37:17.634000Z',
- explicit_date: 'true',
- display: ChartDisplayType.ActionsLineGraph,
- events: [
- {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: null,
- math_group_type_index: null,
- properties: {},
- },
- ],
- insight: InsightType.TRENDS,
- interval: 'day',
- properties: [
- {
- key: '$feature/aloha',
- operator: PropertyOperator.Exact,
- type: PropertyFilterType.Event,
- value: ['control', 'test_1', 'test_2', 'test_3', 'test_4', 'test_5'],
- },
- ],
- sampling_factor: undefined,
- smoothing_intervals: 1,
- },
- },
- {
- action: {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: undefined,
- math_group_type_index: undefined,
- },
- aggregated_value: 0,
- label: '$pageview - test_3',
- count: 26,
- data: [1.8416666666666, 3.7416666666665, 2.2416666665, 1.166666666665, 8.866666665],
- labels: ['11-Feb-2023', '12-Feb-2023', '13-Feb-2023', '14-Feb-2023', '15-Feb-2023'],
- days: ['2023-02-11', '2023-02-12', '2023-02-13', '2023-02-14', '2023-02-15'],
- breakdown_value: 'test_3',
- persons_urls: [
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- ],
- filter: {
- breakdown: '$feature/aloha',
- breakdown_normalize_url: false,
- breakdown_type: 'event',
- date_from: '2023-02-11T10:37:17.634000Z',
- date_to: '2023-02-16T10:37:17.634000Z',
- explicit_date: 'true',
- display: ChartDisplayType.ActionsLineGraph,
- events: [
- {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: null,
- math_group_type_index: null,
- properties: {},
- },
- ],
- insight: InsightType.TRENDS,
- interval: 'day',
- properties: [
- {
- key: '$feature/aloha',
- operator: PropertyOperator.Exact,
- type: PropertyFilterType.Event,
- value: ['control', 'test_1', 'test_2', 'test_3', 'test_4', 'test_5'],
- },
- ],
- sampling_factor: undefined,
- smoothing_intervals: 1,
- },
- },
- {
- action: {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: undefined,
- math_group_type_index: undefined,
- },
- aggregated_value: 0,
- label: '$pageview - test_4',
- count: 26,
- data: [4.5416666666666, 6.5416666666665, 5.5416666665, 3.666666666665, 10.366666665],
- labels: ['11-Feb-2023', '12-Feb-2023', '13-Feb-2023', '14-Feb-2023', '15-Feb-2023'],
- days: ['2023-02-11', '2023-02-12', '2023-02-13', '2023-02-14', '2023-02-15'],
- breakdown_value: 'test_4',
- persons_urls: [
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- ],
- filter: {
- breakdown: '$feature/aloha',
- breakdown_normalize_url: false,
- breakdown_type: 'event',
- date_from: '2023-02-11T10:37:17.634000Z',
- date_to: '2023-02-16T10:37:17.634000Z',
- explicit_date: 'true',
- display: ChartDisplayType.ActionsLineGraph,
- events: [
- {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: null,
- math_group_type_index: null,
- properties: {},
- },
- ],
- insight: InsightType.TRENDS,
- interval: 'day',
- properties: [
- {
- key: '$feature/aloha',
- operator: PropertyOperator.Exact,
- type: PropertyFilterType.Event,
- value: ['control', 'test_1', 'test_2', 'test_3', 'test_4', 'test_5'],
- },
- ],
- sampling_factor: undefined,
- smoothing_intervals: 1,
- },
- },
- {
- action: {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: undefined,
- math_group_type_index: undefined,
- },
- aggregated_value: 0,
- label: '$pageview - test_5',
- count: 26,
- data: [0.5416666666666, 2.5416666666665, 1.5416666665, 0.666666666665, 5.366666665],
- labels: ['11-Feb-2023', '12-Feb-2023', '13-Feb-2023', '14-Feb-2023', '15-Feb-2023'],
- days: ['2023-02-11', '2023-02-12', '2023-02-13', '2023-02-14', '2023-02-15'],
- breakdown_value: 'test_5',
- persons_urls: [
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- ],
- filter: {
- breakdown: '$feature/aloha',
- breakdown_normalize_url: false,
- breakdown_type: 'event',
- date_from: '2023-02-11T10:37:17.634000Z',
- date_to: '2023-02-16T10:37:17.634000Z',
- explicit_date: 'true',
- display: ChartDisplayType.ActionsLineGraph,
- events: [
- {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: null,
- math_group_type_index: null,
- properties: {},
- },
- ],
- insight: InsightType.TRENDS,
- interval: 'day',
- properties: [
- {
- key: '$feature/aloha',
- operator: PropertyOperator.Exact,
- type: PropertyFilterType.Event,
- value: ['control', 'test_1', 'test_2', 'test_3', 'test_4', 'test_5'],
- },
- ],
- sampling_factor: undefined,
- smoothing_intervals: 1,
- },
- },
- {
- action: {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: undefined,
- math_group_type_index: null,
- properties: undefined,
- },
- aggregated_value: 0,
- label: '$pageview - control',
- count: 11.421053,
- data: [
- 2.8210526315789473, 2.4210526315789473, 1.4210526315789473, 1.4210526315789473, 2.4210526315789473,
- ],
- labels: ['11-Feb-2023', '12-Feb-2023', '13-Feb-2023', '14-Feb-2023', '15-Feb-2023'],
- days: ['2023-02-11', '2023-02-12', '2023-02-13', '2023-02-14', '2023-02-15'],
- breakdown_value: 'control',
- persons_urls: [
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- {
- url: 'api/projects/1/persons/trends/?breakdown=%24feature%2Faloha&breakdown_attribution_type=first_touch&breakdown_normalize_url=False&breakdown_type=event&date_from=2023-05-19T00%3A00%3A00%2B00%3A00&explicit_date=true&display=ActionsLineGraph&events=%5B%7B%22id%22%3A+%22%24pageview%22%2C+%22type%22%3A+%22events%22%2C+%22order%22%3A+0%2C+%22name%22%3A+%22%24pageview%22%2C+%22custom_name%22%3A+null%2C+%22math%22%3A+%22avg_count_per_actor%22%2C+%22math_property%22%3A+null%2C+%22math_group_type_index%22%3A+null%2C+%22properties%22%3A+%7B%7D%7D%5D&insight=TRENDS&interval=day&properties=%7B%22type%22%3A+%22AND%22%2C+%22values%22%3A+%5B%7B%22key%22%3A+%22%24feature%2Faloha%22%2C+%22operator%22%3A+%22exact%22%2C+%22type%22%3A+%22event%22%2C+%22value%22%3A+%5B%22control%22%2C+%22test%22%5D%7D%5D%7D&sampling_factor=&smoothing_intervals=1&entity_id=%24pageview&entity_type=events&entity_math=avg_count_per_actor&date_to=2023-05-19T00%3A00%3A00%2B00%3A00&breakdown_value=control&cache_invalidation_key=iaDd6ork',
- },
- ],
- filter: {
- breakdown: '$feature/aloha',
- breakdown_normalize_url: false,
- breakdown_type: 'event',
- date_from: '2023-02-11T10:37:17.634000Z',
- explicit_date: 'true',
- display: ChartDisplayType.ActionsLineGraph,
- events: [
- {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: null,
- math_group_type_index: null,
- properties: {},
- },
- ],
- insight: InsightType.TRENDS,
- interval: 'day',
- properties: [
- {
- key: '$feature/aloha',
- operator: PropertyOperator.Exact,
- type: PropertyFilterType.Event,
- value: ['control', 'test_1', 'test_2', 'test_3', 'test_4', 'test_5'],
- },
- ],
- sampling_factor: undefined,
- smoothing_intervals: 1,
- },
- },
- ],
- probability: {
- control: 0.407580005,
- test_1: 0.59242,
- test_2: 0.49242,
- test_3: 0.29242,
- test_4: 0.19242,
- test_5: 0.09242,
- },
- significant: false,
- filters: {
- breakdown: '$feature/aloha',
- breakdown_normalize_url: false,
- breakdown_type: 'event',
- date_from: '2023-02-11T10:37:17.634000Z',
- explicit_date: 'true',
- display: ChartDisplayType.ActionsLineGraph,
- events: [
- {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- custom_name: null,
- math: 'avg_count_per_actor',
- math_property: null,
- math_group_type_index: null,
- properties: {},
- },
- ],
- insight: InsightType.TRENDS,
- interval: 'day',
- properties: [
- {
- key: '$feature/aloha',
- operator: PropertyOperator.Exact,
- type: PropertyFilterType.Event,
- value: ['control', 'test_1', 'test_2', 'test_3', 'test_4', 'test_5'],
- },
- ],
- sampling_factor: undefined,
- smoothing_intervals: 1,
- },
- exposure_filters: {
- breakdown: '$feature/aloha',
- breakdown_normalize_url: false,
- breakdown_type: 'event',
- date_from: '2023-02-11T10:37:17.634000Z',
- explicit_date: 'true',
- display: ChartDisplayType.ActionsLineGraph,
- events: [
- {
- id: '$pageview',
- type: 'events',
- order: 0,
- name: '$pageview',
- math: 'dau',
- },
- ],
- insight: InsightType.TRENDS,
- interval: 'day',
- properties: [
- {
- key: '$feature/aloha',
- operator: PropertyOperator.Exact,
- type: PropertyFilterType.Event,
- value: ['control', 'test_1', 'test_2', 'test_3', 'test_4', 'test_5'],
- },
- ],
- },
- significance_code: SignificanceCode.NotEnoughExposure,
- p_value: 1,
- variants: [
- {
- key: 'control',
- count: 46,
- exposure: 1,
- absolute_exposure: 19,
- },
- {
- key: 'test_1',
- count: 63,
- exposure: 1.263157894736842,
- absolute_exposure: 24,
- },
- {
- key: 'test_2',
- count: 21,
- exposure: 5.463157894736842,
- absolute_exposure: 34,
- },
- {
- key: 'test_3',
- count: 31,
- exposure: 4.463157894736842,
- absolute_exposure: 44,
- },
- {
- key: 'test_4',
- count: 41,
- exposure: 3.463157894736842,
- absolute_exposure: 54,
- },
- {
- key: 'test_5',
- count: 51,
- exposure: 2.463157894736842,
- absolute_exposure: 64,
- },
- ],
- credible_intervals: {
- control: [1.5678, 3.8765],
- test_1: [1.2345, 3.4567],
- test_2: [1.3345, 3.5567],
- test_3: [1.4345, 3.5567],
- test_4: [1.5345, 3.5567],
- test_5: [1.6345, 3.6567],
- },
- },
- last_refresh: '2023-02-11T10:37:17.634000Z',
- is_cached: true,
-}
-
-const meta: Meta = {
- title: 'Scenes-App/Experiments',
- parameters: {
- layout: 'fullscreen',
- viewMode: 'story',
- mockDate: '2023-02-15', // To stabilize relative dates
- },
- decorators: [
- mswDecorator({
- get: {
- '/api/projects/:team_id/experiments/': toPaginatedResponse([
- MOCK_FUNNEL_EXPERIMENT,
- MOCK_TREND_EXPERIMENT,
- MOCK_TREND_EXPERIMENT_MANY_VARIANTS,
- MOCK_WEB_EXPERIMENT_MANY_VARIANTS,
- ]),
- '/api/projects/:team_id/experiments/1/': MOCK_FUNNEL_EXPERIMENT,
- '/api/projects/:team_id/experiments/1/results/': MOCK_EXPERIMENT_RESULTS,
- '/api/projects/:team_id/experiments/2/': MOCK_TREND_EXPERIMENT,
- '/api/projects/:team_id/experiments/2/results/': MOCK_TREND_EXPERIMENT_RESULTS,
- '/api/projects/:team_id/experiments/3/': MOCK_TREND_EXPERIMENT_MANY_VARIANTS,
- '/api/projects/:team_id/experiments/3/results/': MOCK_TREND_EXPERIMENT_MANY_VARIANTS_RESULTS,
- '/api/projects/:team_id/experiments/4/': MOCK_WEB_EXPERIMENT_MANY_VARIANTS,
- '/api/projects/:team_id/experiments/4/results/': MOCK_TREND_EXPERIMENT_MANY_VARIANTS_RESULTS,
- },
- }),
- ],
-}
-export default meta
-export const ExperimentsList: StoryFn = () => {
- useEffect(() => {
- router.actions.push(urls.experiments())
- }, [])
- return
-}
-
-export const CompleteFunnelExperiment: StoryFn = () => {
- useEffect(() => {
- router.actions.push(urls.experiment(MOCK_FUNNEL_EXPERIMENT.id))
- }, [])
- return
-}
-CompleteFunnelExperiment.parameters = {
- testOptions: {
- waitForSelector: '.card-secondary',
- },
-}
-
-export const RunningTrendExperiment: StoryFn = () => {
- useEffect(() => {
- router.actions.push(urls.experiment(MOCK_TREND_EXPERIMENT.id))
- }, [])
-
- return
-}
-RunningTrendExperiment.parameters = {
- testOptions: {
- waitForSelector: '.LemonBanner .LemonIcon',
- },
-}
-
-export const RunningTrendExperimentManyVariants: StoryFn = () => {
- useEffect(() => {
- router.actions.push(urls.experiment(MOCK_TREND_EXPERIMENT_MANY_VARIANTS.id))
- }, [])
-
- return
-}
-RunningTrendExperimentManyVariants.parameters = {
- testOptions: {
- waitForSelector: '.LemonBanner .LemonIcon',
- },
-}
-
-export const ExperimentNotFound: StoryFn = () => {
- useEffect(() => {
- router.actions.push(urls.experiment('1200000'))
- }, [])
- return
-}
diff --git a/frontend/src/scenes/experiments/ExperimentView/DistributionTable.tsx b/frontend/src/scenes/experiments/ExperimentView/DistributionTable.tsx
index caee718efb726..d34901f9716a1 100644
--- a/frontend/src/scenes/experiments/ExperimentView/DistributionTable.tsx
+++ b/frontend/src/scenes/experiments/ExperimentView/DistributionTable.tsx
@@ -23,12 +23,11 @@ import { VariantScreenshot } from './VariantScreenshot'
export function DistributionModal({ experimentId }: { experimentId: Experiment['id'] }): JSX.Element {
const { experiment, experimentLoading, isDistributionModalOpen } = useValues(experimentLogic({ experimentId }))
- const { closeDistributionModal, updateExperiment } = useActions(experimentLogic({ experimentId }))
+ const { closeDistributionModal, updateDistributionModal } = useActions(experimentLogic({ experimentId }))
const _featureFlagLogic = featureFlagLogic({ id: experiment.feature_flag?.id ?? null } as FeatureFlagLogicProps)
const { featureFlag, areVariantRolloutsValid, variantRolloutSum } = useValues(_featureFlagLogic)
- const { setFeatureFlagFilters, distributeVariantsEqually, saveSidebarExperimentFeatureFlag } =
- useActions(_featureFlagLogic)
+ const { setFeatureFlagFilters, distributeVariantsEqually } = useActions(_featureFlagLogic)
const handleRolloutPercentageChange = (index: number, value: number | undefined): void => {
if (!featureFlag?.filters?.multivariate || !value) {
@@ -61,13 +60,7 @@ export function DistributionModal({ experimentId }: { experimentId: Experiment['
{
- saveSidebarExperimentFeatureFlag(featureFlag)
- updateExperiment({
- holdout_id: experiment.holdout_id,
- parameters: {
- feature_flag_variants: featureFlag?.filters?.multivariate?.variants ?? [],
- },
- })
+ updateDistributionModal(featureFlag)
closeDistributionModal()
}}
type="primary"
diff --git a/frontend/src/scenes/experiments/experimentLogic.tsx b/frontend/src/scenes/experiments/experimentLogic.tsx
index 42f6b2cd37652..c8325ab3b7cf5 100644
--- a/frontend/src/scenes/experiments/experimentLogic.tsx
+++ b/frontend/src/scenes/experiments/experimentLogic.tsx
@@ -10,7 +10,12 @@ import { lemonToast } from 'lib/lemon-ui/LemonToast/LemonToast'
import { featureFlagLogic } from 'lib/logic/featureFlagLogic'
import { hasFormErrors, toParams } from 'lib/utils'
import { eventUsageLogic } from 'lib/utils/eventUsageLogic'
+import {
+ indexToVariantKeyFeatureFlagPayloads,
+ variantKeyToIndexFeatureFlagPayloads,
+} from 'scenes/feature-flags/featureFlagLogic'
import { validateFeatureFlagKey } from 'scenes/feature-flags/featureFlagLogic'
+import { featureFlagsLogic } from 'scenes/feature-flags/featureFlagsLogic'
import { funnelDataLogic } from 'scenes/funnels/funnelDataLogic'
import { insightDataLogic } from 'scenes/insights/insightDataLogic'
import { cleanFilters, getDefaultEvent } from 'scenes/insights/utils/cleanFilters'
@@ -165,6 +170,8 @@ export const experimentLogic = kea([
],
teamLogic,
['addProductIntent'],
+ featureFlagsLogic,
+ ['updateFlag'],
],
})),
actions({
@@ -262,6 +269,7 @@ export const experimentLogic = kea([
openPrimaryMetricModal: (index: number) => ({ index }),
closePrimaryMetricModal: true,
setPrimaryMetricsResultErrors: (errors: any[]) => ({ errors }),
+ updateDistributionModal: (featureFlag: FeatureFlagType) => ({ featureFlag }),
}),
reducers({
experiment: [
@@ -795,6 +803,23 @@ export const experimentLogic = kea([
lemonToast.error('Failed to update experiment variant images')
}
},
+ updateDistributionModal: async ({ featureFlag }) => {
+ const { created_at, id, ...flag } = featureFlag
+
+ const preparedFlag = indexToVariantKeyFeatureFlagPayloads(flag)
+
+ const savedFlag = await api.update(
+ `api/projects/${values.currentProjectId}/feature_flags/${id}`,
+ preparedFlag
+ )
+
+ const updatedFlag = variantKeyToIndexFeatureFlagPayloads(savedFlag)
+ actions.updateFlag(updatedFlag)
+
+ actions.updateExperiment({
+ holdout_id: values.experiment.holdout_id,
+ })
+ },
})),
loaders(({ actions, props, values }) => ({
experiment: {
@@ -1501,7 +1526,7 @@ export const experimentLogic = kea([
}
const variantsWithResults: TabularSecondaryMetricResults[] = []
- experiment?.parameters?.feature_flag_variants?.forEach((variant) => {
+ experiment?.feature_flag?.filters?.multivariate?.variants?.forEach((variant) => {
const metricResults: SecondaryMetricResult[] = []
experiment?.secondary_metrics?.forEach((metric, idx) => {
let result
diff --git a/frontend/src/scenes/feature-flags/featureFlagLogic.ts b/frontend/src/scenes/feature-flags/featureFlagLogic.ts
index 4a9fd05113d3e..41eac1ddc740b 100644
--- a/frontend/src/scenes/feature-flags/featureFlagLogic.ts
+++ b/frontend/src/scenes/feature-flags/featureFlagLogic.ts
@@ -154,7 +154,7 @@ export const variantKeyToIndexFeatureFlagPayloads = (flag: FeatureFlagType): Fea
}
}
-const indexToVariantKeyFeatureFlagPayloads = (flag: Partial): Partial => {
+export const indexToVariantKeyFeatureFlagPayloads = (flag: Partial): Partial => {
if (flag.filters?.multivariate) {
const newPayloads: Record = {}
flag.filters.multivariate.variants.forEach(({ key }, index) => {
diff --git a/frontend/src/scenes/surveys/SurveyCustomization.tsx b/frontend/src/scenes/surveys/SurveyCustomization.tsx
index c6fe0b0cbeb4f..ccbe34146a922 100644
--- a/frontend/src/scenes/surveys/SurveyCustomization.tsx
+++ b/frontend/src/scenes/surveys/SurveyCustomization.tsx
@@ -137,7 +137,11 @@ export function Customization({
<>
onAppearanceChange({ ...appearance, placeholder })}
disabled={!surveysStylingAvailable}
/>
diff --git a/frontend/src/scenes/surveys/SurveyEdit.tsx b/frontend/src/scenes/surveys/SurveyEdit.tsx
index b25fce787d71f..776a7e25c1409 100644
--- a/frontend/src/scenes/surveys/SurveyEdit.tsx
+++ b/frontend/src/scenes/surveys/SurveyEdit.tsx
@@ -2,8 +2,7 @@ import './EditSurvey.scss'
import { DndContext } from '@dnd-kit/core'
import { SortableContext, verticalListSortingStrategy } from '@dnd-kit/sortable'
-import { IconInfo } from '@posthog/icons'
-import { IconLock, IconPlus, IconTrash } from '@posthog/icons'
+import { IconInfo, IconLock, IconPlus, IconTrash } from '@posthog/icons'
import {
LemonButton,
LemonCalendarSelect,
@@ -538,12 +537,12 @@ export default function SurveyEdit(): JSX.Element {
appearance={value || defaultSurveyAppearance}
hasBranchingLogic={hasBranchingLogic}
deleteBranchingLogic={deleteBranchingLogic}
- customizeRatingButtons={
- survey.questions[0].type === SurveyQuestionType.Rating
- }
- customizePlaceholderText={
- survey.questions[0].type === SurveyQuestionType.Open
- }
+ customizeRatingButtons={survey.questions.some(
+ (question) => question.type === SurveyQuestionType.Rating
+ )}
+ customizePlaceholderText={survey.questions.some(
+ (question) => question.type === SurveyQuestionType.Open
+ )}
onAppearanceChange={(appearance) => {
onChange(appearance)
}}
diff --git a/posthog/session_recordings/queries/session_recording_list_from_query.py b/posthog/session_recordings/queries/session_recording_list_from_query.py
index d53c99682edad..b1819c063f383 100644
--- a/posthog/session_recordings/queries/session_recording_list_from_query.py
+++ b/posthog/session_recordings/queries/session_recording_list_from_query.py
@@ -182,7 +182,7 @@ def __init__(
def _test_account_filters(self) -> list[AnyPropertyFilter]:
prop_filters: list[AnyPropertyFilter] = []
for prop in self._team.test_account_filters:
- match prop["type"]:
+ match prop.get("type", None):
case "person":
prop_filters.append(PersonPropertyFilter(**prop))
case "event":
@@ -191,6 +191,9 @@ def _test_account_filters(self) -> list[AnyPropertyFilter]:
prop_filters.append(GroupPropertyFilter(**prop))
case "hogql":
prop_filters.append(HogQLPropertyFilter(**prop))
+ case None:
+ logger.warn("test account filter had no type", filter=prop)
+ prop_filters.append(EventPropertyFilter(**prop))
return prop_filters
diff --git a/posthog/session_recordings/queries/test/test_session_recording_list_from_query.py b/posthog/session_recordings/queries/test/test_session_recording_list_from_query.py
index 35116f4085e55..2acf2a47d5642 100644
--- a/posthog/session_recordings/queries/test/test_session_recording_list_from_query.py
+++ b/posthog/session_recordings/queries/test/test_session_recording_list_from_query.py
@@ -3316,7 +3316,9 @@ def test_event_filter_with_test_accounts_excluded(self):
"key": "is_internal_user",
"value": ["false"],
"operator": "exact",
- "type": "event",
+ # in production some test account filters don't include type
+ # we default to event in that case
+ # "type": "event",
},
{"key": "properties.$browser == 'Chrome'", "type": "hogql"},
]