@atlaskit/rovo-agent-analytics 1.10.0 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,37 @@
1
1
  # @atlaskit/rovo-agent-analytics
2
2
 
3
+ ## 2.0.0
4
+
5
+ ### Major Changes
6
+
7
+ - [`b0222d13caefe`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/b0222d13caefe) -
8
+ Replace `@typescript-eslint/no-explicit-any` suppressions with real types across
9
+ rovo-content-bridge and rovo-platform packages (TREX-1392).
10
+
11
+ Key changes:
12
+ - `rovo-content-bridge-api`: Replace `any` in `CommandConstructor`, type guards, handlers,
13
+ debugger, and desktop transport with `unknown`, typed event interfaces, and a new `WebContents`
14
+ interface.
15
+ - `rovo-content-bridge-api-commands`: Replace `any` fields with `SerializableValue` in chart,
16
+ Jira, and content commands.
17
+ - `rovo-playground`: Replace `any` in plugin config, settings store, and ADF utilities with
18
+ `unknown` and recursive typed nodes.
19
+ - `rovo-platform-ui-components`, `rovo-navigation`, `rovo-spaces`, `rovo-triggers`,
20
+ `rovo-agent-analytics`, `rovo-agent-components`, `rovo-chat-side-by-side-evaluation`,
21
+ `rovo-agent-debug-modal`: Replace remaining `any` occurrences with `unknown`, typed interfaces,
22
+ or properly inferred types.
23
+
24
+ ## 1.11.0
25
+
26
+ ### Minor Changes
27
+
28
+ - [`5922ce1f90616`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/5922ce1f90616) -
29
+ RAGE-3548: Type `EditingEventPayload['attributes']` as a discriminated union by `field`, so
30
+ field-specific data (e.g. `newValue: boolean` for toggle fields, `skillCount: number` for
31
+ `agenticSkills`) is required at call sites and discoverable to analytics consumers. A
32
+ `{ field: string }` catch-all is kept for backwards compatibility; prefer adding a typed variant
33
+ for new fields.
34
+
3
35
  ## 1.10.0
4
36
 
5
37
  ### Minor Changes
@@ -14,8 +14,6 @@ var getDefaultTrackEventConfig = exports.getDefaultTrackEventConfig = function g
14
14
  tags: ['atlaskit']
15
15
  };
16
16
  };
17
-
18
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
19
17
  var getAttributesFromContexts = exports.getAttributesFromContexts = function getAttributesFromContexts(context) {
20
18
  if (!context || !Array.isArray(context)) {
21
19
  return {};
@@ -2,8 +2,6 @@ export const getDefaultTrackEventConfig = () => ({
2
2
  eventType: 'track',
3
3
  tags: ['atlaskit']
4
4
  });
5
-
6
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
7
5
  export const getAttributesFromContexts = context => {
8
6
  if (!context || !Array.isArray(context)) {
9
7
  return {};
@@ -7,8 +7,6 @@ export var getDefaultTrackEventConfig = function getDefaultTrackEventConfig() {
7
7
  tags: ['atlaskit']
8
8
  };
9
9
  };
10
-
11
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
12
10
  export var getAttributesFromContexts = function getAttributesFromContexts(context) {
13
11
  if (!context || !Array.isArray(context)) {
14
12
  return {};
@@ -10,12 +10,59 @@
10
10
  * (see other files in this directory for the template)
11
11
  */
12
12
  import type { VersionedAgentAttributes } from '../../common/types';
13
+ type FieldAttributes = {
14
+ field: 'deepResearch';
15
+ isDeepResearchEnabled: boolean;
16
+ } | {
17
+ field: 'webSearch';
18
+ isWebSearchEnabled: boolean;
19
+ } | {
20
+ field: 'agenticSkills';
21
+ skillCount: number;
22
+ } | {
23
+ field: 'tools' | 'actions';
24
+ toolsCount: number;
25
+ } | {
26
+ field: 'actionsAndMcpServers';
27
+ toolsCount: number;
28
+ mcpServersCount: number;
29
+ mcpToolsCount: number;
30
+ } | {
31
+ field: 'knowledgeSources';
32
+ knowledgeSourcesCount: number;
33
+ } | {
34
+ field: 'knowledgeScope';
35
+ isKnowledgeEnabled: boolean;
36
+ } | {
37
+ field: 'name';
38
+ } | {
39
+ field: 'description';
40
+ } | {
41
+ field: 'instructions';
42
+ } | {
43
+ field: 'behaviour';
44
+ } | {
45
+ field: 'invocationDescription';
46
+ } | {
47
+ field: 'authoringTeam';
48
+ } | {
49
+ field: 'authoringTeamId';
50
+ } | {
51
+ field: 'creatorId';
52
+ } | {
53
+ field: 'isActive';
54
+ } | {
55
+ field: 'isDefault';
56
+ } | {
57
+ field: 'responseStrategy';
58
+ } | {
59
+ field: 'executionConfig';
60
+ };
13
61
  export type EditingEventPayload = {
14
62
  actionSubject: 'rovoAgent';
15
63
  action: 'updated';
16
64
  attributes: VersionedAgentAttributes & {
17
65
  agentType?: string;
18
- field: string;
19
66
  /**
20
67
  * Identifies the subagent (formerly "scenario") whose configuration was updated.
21
68
  * Pass the scenario/subagent id when the analytics event is fired at the
@@ -23,5 +70,6 @@ export type EditingEventPayload = {
23
70
  * level (i.e. not scoped to any specific subagent).
24
71
  */
25
72
  subagentId: string | null;
26
- };
73
+ } & FieldAttributes;
27
74
  };
75
+ export {};
@@ -2,4 +2,4 @@ export declare const getDefaultTrackEventConfig: () => {
2
2
  eventType: string;
3
3
  tags: string[];
4
4
  };
5
- export declare const getAttributesFromContexts: (context: unknown) => Record<string, any>;
5
+ export declare const getAttributesFromContexts: (context: unknown) => Record<string, unknown>;
@@ -8,7 +8,7 @@ import type { CreateFlowEventPayload } from '../actions/groups/create-flow';
8
8
  type AgentCreateAction = CreateFlowEventPayload['action'] | AddToolsPromptEventPayload['action'];
9
9
  type CommonAnalyticsAttributes = {
10
10
  touchPoint?: string;
11
- } & Record<string, any>;
11
+ } & Record<string, unknown>;
12
12
  export declare const useRovoAgentCreateAnalytics: (commonAttributes: CommonAnalyticsAttributes) => readonly [string | null, {
13
13
  readonly trackCreateSession: (action: AgentCreateAction, attributes?: CommonAnalyticsAttributes) => void;
14
14
  readonly trackCreateSessionStart: (attributes?: CommonAnalyticsAttributes) => void;
@@ -10,12 +10,59 @@
10
10
  * (see other files in this directory for the template)
11
11
  */
12
12
  import type { VersionedAgentAttributes } from '../../common/types';
13
+ type FieldAttributes = {
14
+ field: 'deepResearch';
15
+ isDeepResearchEnabled: boolean;
16
+ } | {
17
+ field: 'webSearch';
18
+ isWebSearchEnabled: boolean;
19
+ } | {
20
+ field: 'agenticSkills';
21
+ skillCount: number;
22
+ } | {
23
+ field: 'tools' | 'actions';
24
+ toolsCount: number;
25
+ } | {
26
+ field: 'actionsAndMcpServers';
27
+ toolsCount: number;
28
+ mcpServersCount: number;
29
+ mcpToolsCount: number;
30
+ } | {
31
+ field: 'knowledgeSources';
32
+ knowledgeSourcesCount: number;
33
+ } | {
34
+ field: 'knowledgeScope';
35
+ isKnowledgeEnabled: boolean;
36
+ } | {
37
+ field: 'name';
38
+ } | {
39
+ field: 'description';
40
+ } | {
41
+ field: 'instructions';
42
+ } | {
43
+ field: 'behaviour';
44
+ } | {
45
+ field: 'invocationDescription';
46
+ } | {
47
+ field: 'authoringTeam';
48
+ } | {
49
+ field: 'authoringTeamId';
50
+ } | {
51
+ field: 'creatorId';
52
+ } | {
53
+ field: 'isActive';
54
+ } | {
55
+ field: 'isDefault';
56
+ } | {
57
+ field: 'responseStrategy';
58
+ } | {
59
+ field: 'executionConfig';
60
+ };
13
61
  export type EditingEventPayload = {
14
62
  actionSubject: 'rovoAgent';
15
63
  action: 'updated';
16
64
  attributes: VersionedAgentAttributes & {
17
65
  agentType?: string;
18
- field: string;
19
66
  /**
20
67
  * Identifies the subagent (formerly "scenario") whose configuration was updated.
21
68
  * Pass the scenario/subagent id when the analytics event is fired at the
@@ -23,5 +70,6 @@ export type EditingEventPayload = {
23
70
  * level (i.e. not scoped to any specific subagent).
24
71
  */
25
72
  subagentId: string | null;
26
- };
73
+ } & FieldAttributes;
27
74
  };
75
+ export {};
@@ -2,4 +2,4 @@ export declare const getDefaultTrackEventConfig: () => {
2
2
  eventType: string;
3
3
  tags: string[];
4
4
  };
5
- export declare const getAttributesFromContexts: (context: unknown) => Record<string, any>;
5
+ export declare const getAttributesFromContexts: (context: unknown) => Record<string, unknown>;
@@ -8,7 +8,7 @@ import type { CreateFlowEventPayload } from '../actions/groups/create-flow';
8
8
  type AgentCreateAction = CreateFlowEventPayload['action'] | AddToolsPromptEventPayload['action'];
9
9
  type CommonAnalyticsAttributes = {
10
10
  touchPoint?: string;
11
- } & Record<string, any>;
11
+ } & Record<string, unknown>;
12
12
  export declare const useRovoAgentCreateAnalytics: (commonAttributes: CommonAnalyticsAttributes) => readonly [
13
13
  string | null,
14
14
  {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/rovo-agent-analytics",
3
- "version": "1.10.0",
3
+ "version": "2.0.0",
4
4
  "description": "Rovo Agents analytics",
5
5
  "repository": "https://bitbucket.org/atlassian/atlassian-frontend-monorepo",
6
6
  "atlassian": {