@qilin-agent/client-product-analytics 3.1.6 → 3.1.7

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/README.i18n.yaml CHANGED
@@ -15,8 +15,11 @@
15
15
  en: 4e53164159b5ce41
16
16
  zh: adba5f78f4fe4801
17
17
  /qilin-agent-client-product-analytics/use-this-package:
18
- en: 43b4c57162dc9f6a
19
- zh: b87d9f39b133d9bd
18
+ en: 503c509109436d53
19
+ zh: 14bb613b0c5dfee9
20
+ /qilin-agent-client-product-analytics/use-this-package/navigation-preset-and-new-session-events:
21
+ en: c269d108e192046e
22
+ zh: 479fabd322c0f842
20
23
  /qilin-agent-client-product-analytics/dev-note:
21
24
  en: 3155a54154dfbdd4
22
25
  zh: a80fb690600452fd
package/README.md CHANGED
@@ -25,6 +25,14 @@ English | [中文](README.zh.md)
25
25
 
26
26
  Import the map where an event is declared and the event type where one is sent:
27
27
 
28
+ ### Navigation, preset, and new-session events
29
+
30
+ Official navigation reports New Session, Plugins, Automation tasks, and More clicks with their physical placement: `sidebar`, `sidebar_more`, or `titlebar`. Opening Automation tasks from the left sidebar More menu counts as `sidebar_more`, not as a direct sidebar click. Historical `sidebar_menu_click` records without `position` remain unattributed. More-menu actions distinguish the sidebar, conversation, and rightbar regions. Third-party entry identifiers and custom preset names are excluded.
31
+
32
+ Direct preset switches report accepted different choices in the mode picker: an unbound staged choice, or Host application for a blank Session. Custom source modes are `other`, and only built-in targets are reported. Default changes, automatic fallback, restoration, and Creator launchers are excluded. Each switch records the Coding Tools setting known at the action; an unknown setting reports nothing. `code_work_view_toggle` reports a successful change of that setting.
33
+
34
+ `send_button_click` carries `is_new_session`, which is true while the submitting Session is still blank, and `agent_preset`, the Session's preset as `creator`, `ptc`, `minimal`, `standard`, or `other` for a custom preset; `agent_preset` is omitted while the preset is unknown.
35
+
28
36
 
29
37
  <a id="dev-note"></a>
30
38
  ## Dev Note
package/README.zh.md CHANGED
@@ -25,6 +25,14 @@ kind: "package-reference"
25
25
 
26
26
  在声明事件处引用映射,在发送处引用事件类型:
27
27
 
28
+ ### 导航、预设与新会话事件
29
+
30
+ 官方导航上报 New Session、插件、自动化任务与「更多」点击,并携带其物理位置:`sidebar`、`sidebar_more` 或 `titlebar`。从左侧栏「更多」菜单打开自动化任务记为 `sidebar_more`,而非直接的侧栏点击。缺少 `position` 的历史 `sidebar_menu_click` 记录保持无归属。「更多」菜单的动作区分侧栏、会话与右侧栏三个区域。第三方入口标识与自定义预设名不采集。
31
+
32
+ 模式选择器中直接切换预设时,上报被接受且确实不同的选择:未绑定 Session 的暂存选择,或空白 Session 由 Host 应用的选择。自定义来源模式记为 `other`,只上报内置目标。默认值变更、自动回退、恢复与 Creator 入口不在此列。每次切换记录动作时已知的代码工作工具设置;设置未知时不上报。`code_work_view_toggle` 上报该设置的成功变更。
33
+
34
+ `send_button_click` 携带 `is_new_session`(提交的 Session 仍为空白时为 true)与 `agent_preset`(会话预设,内置值为 `creator`、`ptc`、`minimal`、`standard`,自定义预设为 `other`);预设未知时省略 `agent_preset`。
35
+
28
36
 
29
37
  <a id="dev-note"></a>
30
38
  ## 开发备注
@@ -10,7 +10,7 @@
10
10
  import { Service, type Context } from '@qilin-agent/kylin';
11
11
  import type { RemoteResult, RemoteStreamHandle } from '@qilin-agent/typert-protocol';
12
12
  import type { ProductEvent, ProductEventMap } from '../events.ts';
13
- export type { ProductEvent, ProductEventMap, TrackProductEvent } from '../events.ts';
13
+ export type { AnalyticsPreset, EntryAnalyticsRegion, ProductEvent, ProductEventMap, SidebarAnalyticsEntry, SidebarAnalyticsPosition, TrackProductEvent, } from '../events.ts';
14
14
  /** The authenticated analytics namespace mounted by the desktop Client assembly. */
15
15
  declare module '@qilin-agent/typert-protocol' {
16
16
  interface TypertRemoteNamespaceMap {
@@ -36,6 +36,10 @@ export interface ProductEventMap {
36
36
  thinking_effort?: string;
37
37
  run_mode: 'plan' | 'goal' | 'default';
38
38
  msg_type: 'default' | 'steer' | 'queue';
39
+ /** Whether the message is the first one of a blank Session. */
40
+ is_new_session: boolean;
41
+ /** Fixed category of the Session's Agent preset, when known. */
42
+ agent_preset?: AnalyticsPreset | 'other';
39
43
  };
40
44
  model_switch: {
41
45
  session_id?: SessionId;
@@ -59,7 +63,20 @@ export interface ProductEventMap {
59
63
  click_position: 'footer' | 'sidebar';
60
64
  };
61
65
  sidebar_menu_click: {
62
- menu_name: 'plugin' | 'cron';
66
+ menu_name: SidebarAnalyticsEntry;
67
+ position?: SidebarAnalyticsPosition;
68
+ };
69
+ more_menu_item_click: {
70
+ region: EntryAnalyticsRegion;
71
+ action: 'browse_plugins' | 'create_plugin';
72
+ };
73
+ agent_preset_switch: {
74
+ switch_from: AnalyticsPreset | 'other';
75
+ switch_to: AnalyticsPreset;
76
+ code_work_view_enabled: boolean;
77
+ };
78
+ code_work_view_toggle: {
79
+ is_enabled: boolean;
63
80
  };
64
81
  plugin_toggle: {
65
82
  plugin_name: string;
@@ -82,6 +99,14 @@ export interface ProductEventMap {
82
99
  plugin_name: string;
83
100
  };
84
101
  }
102
+ /** Official navigation entries; third-party identifiers are never analytics dimensions. */
103
+ export type SidebarAnalyticsEntry = 'new_session' | 'plugin' | 'cron' | 'more';
104
+ /** Physical navigation placement, independent of the selected destination. */
105
+ export type SidebarAnalyticsPosition = 'sidebar' | 'sidebar_more' | 'titlebar';
106
+ /** Entry-customization menu regions. */
107
+ export type EntryAnalyticsRegion = 'sidebar' | 'conversation' | 'rightbar';
108
+ /** Built-in presets, independent of localized names and custom preset identifiers. */
109
+ export type AnalyticsPreset = 'creator' | 'ptc' | 'minimal' | 'standard';
85
110
  /** Public page names independent of internal onboarding state names. */
86
111
  export type OnboardingPage = 'onboarding_welcome' | 'onboarding_recharge' | 'onboarding_use_case' | 'onboarding_process';
87
112
  /** Correlated event name and attributes for the authenticated analytics RPC. */
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@qilin-agent/client-product-analytics",
3
3
  "description": "Desktop product event collection and authenticated Host reporting",
4
- "version": "3.1.6",
4
+ "version": "3.1.7",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -33,13 +33,13 @@
33
33
  "@qilin-agent/kylin": "~4.0.5"
34
34
  },
35
35
  "devDependencies": {
36
+ "@qilin-agent/api-gateway": "3.1.7",
37
+ "@qilin-agent/app-boot": "3.1.7",
36
38
  "@qilin-agent/kylin": "~4.0.5",
39
+ "@qilin-agent/llm": "3.1.7",
37
40
  "@qilin-agent/kylin-plugin-loader": "~1.0.6",
38
- "@qilin-agent/app-boot": "3.1.6",
39
- "@qilin-agent/session": "3.1.6",
40
- "@qilin-agent/llm": "3.1.6",
41
- "@qilin-agent/api-gateway": "3.1.6",
42
- "@qilin-agent/typert-protocol": "3.1.6"
41
+ "@qilin-agent/session": "3.1.7",
42
+ "@qilin-agent/typert-protocol": "3.1.7"
43
43
  },
44
44
  "dependencies": {},
45
45
  "optionalDependencies": {},