Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 41 additions & 0 deletions .changeset/analytics-landing-page-cube-vocabulary.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
---
'hotcrm': patch
---

Write the analytics landing page to source, and retire the "four built-in cubes"
vocabulary from the eight pages that still carried it.

`content/docs/analytics/index.mdx` is the first screen a reader of the analytics
docs sees, and every count on it named something else. It advertised **4 cubes**
(*Sales*, *Pipeline*, *Service*, *Marketing* — four names that exist nowhere in
the app; the semantic layer is the nine datasets in `src/datasets/`, which the
analytics service compiles into cubes internally, ADR-0021), **4 dashboards**
(there are five — *Sales Activity* was missing), **10+ reports across leads,
deals, cases, contracts** (there are exactly ten, and none of them is a contract
report: no dataset reads `crm_contract`, so none can be built), a report called
*Pipeline by Stage* (a shared dashboard tile and a chart title — the report is
**Opportunities by Stage**) and an **Analytics** navigation group (the group is
called **Insights**, and it holds CRM Overview, Forecasts, Pipeline Coverage,
Lead Inflow and SLA Performance — nothing in it is called *Dashboards*,
*Reports* or *Cubes*). The "AI Copilot reads directly from cubes" claim now says
what this app declares — no skill names a dataset, cube or measure, and the one
that answers data questions aggregates over records — and leaves the platform
side undecided rather than asserting it in either direction.

The same retired vocabulary is gone from eight further pages: `whats-new` now
lists the nine datasets it actually shipped, `getting-started/for-developers`
draws `datasets/` instead of the `src/cubes/` directory removed in #492, and
`reference/performance-and-limits` plus `reference/faq` state the refresh cadence
the app really declares — each dashboard's own `refreshInterval`, 60 s on
Customer Service, 180 s on Sales Performance, 300 s on the other three — in place
of an "every 5 min incremental / nightly full" figure nothing in `src/`
configures, and of a manual refresh button no dashboard declares.
`sales/pipeline-management`, `getting-started/introduction`,
`marketplace/fork-hotcrm` and `administration/sandbox-and-releases` were renames
only. The glossary's definition of the *cube* concept is deliberately untouched:
the concept is real, and only its misapplication to this app was not.

Documentation only in all three locales; no metadata changed.
`test/docs-analytics-vocabulary.test.ts` now derives every count and product name
on these pages from `src/` and fails the build when the app and the page disagree.
Refs #976 #977.
2 changes: 1 addition & 1 deletion content/docs/administration/sandbox-and-releases.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ A **change package** captures a set of metadata changes (objects, fields, valida
| Flows | ✅ |
| Sharing rules, profiles, permission sets | ✅ |
| Pages, list views, dashboards | ✅ |
| Reports, cubes | ✅ |
| Reports, datasets | ✅ |
| AI skills, knowledge base configs | ✅ |
| Approval processes | ✅ |
| Email templates | ✅ |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ description: 安全地进行配置变更 —— 沙箱租户、变更包、提
| 流程 | ✅ |
| 共享规则、权限档案、权限集 | ✅ |
| 页面、列表视图、仪表板 | ✅ |
| 报表、立方体 | ✅ |
| 报表、dataset | ✅ |
| AI 技能、知识库配置 | ✅ |
| 审批流程 | ✅ |
| 电子邮件模板 | ✅ |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ description: 安全地進行設定變更 —— 沙箱租戶、變更包、提
| 流程 | ✅ |
| 共用規則、權限設定檔、權限集 | ✅ |
| 頁面、清單檢視、儀表板 | ✅ |
| 報表、立方體 | ✅ |
| 報表、dataset | ✅ |
| AI 技能、知識庫設定 | ✅ |
| 審批流程 | ✅ |
| 電子郵件範本 | ✅ |
Expand Down
40 changes: 22 additions & 18 deletions content/docs/analytics/index.mdx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
title: Analytics
description: Dashboards, reports, and the data cubes that power them — how HotCRM turns daily activity into insight.
description: Dashboards, reports, and the semantic layer under them — how HotCRM turns daily activity into insight.
---

# Analytics
Expand All @@ -9,15 +9,17 @@ HotCRM Analytics turns your CRM activity into **decisions**. Three layers work t

- **Dashboards** — visual at-a-glance views for execs, managers, and reps.
- **Reports** — detailed list-and-summary reports anyone can filter and export.
- **Cubes** — the data layer underneath, ready for self-service slice-and-dice.
- **Cubes** — the semantic layer underneath. In this app that layer is a set of **datasets**: HotCRM declares no cube of its own, and the analytics service compiles each dataset into its cube internally (ADR-0021).

## What's included

| Layer | What it does |
| --- | --- |
| [**Dashboards**](/docs/analytics/dashboards) | 4 ready-made dashboards (CRM, Sales, Service, Executive) |
| [**Reports**](/docs/analytics/reports) | 10+ standard reports across leads, deals, cases, contracts |
| [**Cubes**](/docs/analytics/cubes) | 4 cubes (sales, pipeline, service, marketing) for self-service analysis |
| [**Dashboards**](/docs/analytics/dashboards) | **Five** ready-made dashboards — CRM Overview, Sales Performance, Sales Activity, Customer Service, Executive Overview |
| [**Reports**](/docs/analytics/reports) | **Ten** standard reports — four on deals, three on cases, one each on leads, accounts and churn |
| [**Cubes**](/docs/analytics/cubes) | **Nine** datasets in `src/datasets/`, the layer both of the above bind by name |

Two counts on that table used to read differently, and the difference is worth knowing before you go looking. **There is no contract report** — and none can be built, because `src/datasets/` reads nine objects and `crm_contract` is not one of them, so nothing in analytics counts, sums or groups a contract. And **no cube is named** *Sales*, *Pipeline*, *Service* or *Marketing* — those four names exist nowhere in the app. [Cubes](/docs/analytics/cubes) says which datasets answer the first three and why the fourth has no data source at all.

## What you get out of the box

Expand All @@ -33,32 +35,34 @@ The moment you have data in HotCRM, you have analytics. No setup required.

The same sharing rules that govern records also govern dashboards and reports:

- A rep running *Pipeline by Stage* sees only their pipeline.
- A rep running **Opportunities by Stage** sees only their own deals.
- A manager sees the rollup for their team.
- An exec sees company-wide.

This means **one dashboard** works for the whole org — what each person sees depends on who they are.

*Pipeline by Stage* is not a report you can run, though the name is real twice over: it is the open-pipeline funnel **tile** that CRM Overview, Sales Performance and Executive Overview share (`src/dashboards/shared-widgets.ts`), and it is the title of the bar chart on the **Opportunities by Stage** report. Search the report library for it and you find nothing — see [Reports](/docs/analytics/reports).

## Where to find things

In the Enterprise CRM app, the **Analytics** group contains:
In the Enterprise CRM app the group is called **Insights**, and it holds five entries:

- **CRM Overview** — the cross-functional dashboard.
- **Forecasts** — the forecast records themselves.
- **Pipeline Coverage**, **Lead Inflow**, **SLA Performance** — three reports pinned to the sidebar by name.

- **Dashboards** — the visual hub.
- **Reports** — the report library.
- **Cubes** — the data-modeling layer (admins).
There is no *Analytics* group, and nothing in the sidebar is called *Dashboards*, *Reports* or *Cubes*. The other dashboards are pinned to the group that owns them — **Sales Performance** under Sales, **Sales Activity** under Activity, **Service Overview** under Service — and the rest of the report library is reached from the reports screen rather than from the nav. [Quick tour](/docs/getting-started/quick-tour) lists the whole sidebar, group by group.

## AI-powered insights

The AI Copilot can read directly from cubes — ask questions like:
**On this app's side, nothing connects the Copilot to a dataset.** The six skills under `src/skills/` name no dataset, no cube and no measure. The one that answers data questions, **Live Data Access**, is wired to the platform's object tools and is instructed to re-read the object's schema and aggregate over records — so a Copilot answer is computed from the objects, not read off a compiled cube.

- *"What's driving the gap between commit and forecast?"*
- *"Why did East close 3 fewer deals than West last quarter?"*
- *"Show me which products correlate with longer sales cycles."*
That also sets what it can be asked. *"What's driving the gap between commit and forecast?"* has data behind it: **Commit**, **Quota**, **Closed Won** and **Pipeline** are all real figures on the forecast record, published as **Commit**, **Quota**, **Closed** and **Pipeline** on the **Forecast Metrics** dataset. *"Why did East close 3 fewer deals than West last quarter?"* and *"Show me which products correlate with longer sales cycles"* do not — no region is stored on a deal, no dataset reads line items, and the one duration the opportunity carries (**Days in Current Stage**) is a formula evaluated after the query, so nothing can aggregate it. [Cubes](/docs/analytics/cubes) lists the gaps one by one.

See [Sales Skills](/docs/ai-copilot/sales-copilot) for more.
Whether the platform's own agent additionally reads the compiled cubes is a question about the runtime rather than about this app, so this page makes no claim about it in either direction; check it against your deployment. See [Sales Skills](/docs/ai-copilot/sales-copilot) for what the sales-side skills do.

## Start here

- [Dashboards](/docs/analytics/dashboards) — the four built-in dashboards.
- [Reports](/docs/analytics/reports) — the standard report library.
- [Cubes](/docs/analytics/cubes) — for analysts who want to build their own.
- [Dashboards](/docs/analytics/dashboards) — the five built-in dashboards.
- [Reports](/docs/analytics/reports) — the ten standard reports.
- [Cubes](/docs/analytics/cubes) — the nine datasets underneath, and what each can and cannot answer.
40 changes: 22 additions & 18 deletions content/docs/analytics/index.zh-Hans.mdx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
title: 分析
description: 仪表盘、报表,以及为它们提供支持的多维数据集——HotCRM 如何将日常活动转化为洞察。
description: 仪表盘、报表,以及它们底下的语义层——HotCRM 如何将日常活动转化为洞察。
---

# 分析
Expand All @@ -9,15 +9,17 @@ HotCRM 分析将你的 CRM 活动转化为**决策**。三个层次协同工作

- **仪表盘** — 面向高管、经理和销售代表的可视化一览视图。
- **报表** — 任何人都可以筛选和导出的详细列表与汇总报表。
- **多维数据集** — 底层数据层,可用于自助式切片分析
- **多维数据集** — 底下的语义层。在本应用里,这一层是一组 **dataset**:HotCRM 自己不声明任何 cube,由分析服务在内部把每个 dataset 编译成它的 cube(ADR-0021)

## 包含内容

| 层次 | 作用 |
| --- | --- |
| [**仪表盘**](/zh-Hans/docs/analytics/dashboards) | 4 个开箱即用的仪表盘(CRM、销售、服务、高管) |
| [**报表**](/zh-Hans/docs/analytics/reports) | 涵盖线索、交易、工单、合同的 10+ 个标准报表 |
| [**多维数据集**](/zh-Hans/docs/analytics/cubes) | 4 个多维数据集(销售、管道、服务、市场营销),用于自助分析 |
| [**仪表盘**](/zh-Hans/docs/analytics/dashboards) | **五个**开箱即用的仪表盘 —— CRM Overview、Sales Performance、Sales Activity、Customer Service、Executive Overview |
| [**报表**](/zh-Hans/docs/analytics/reports) | **十份**标准报表 —— 交易 4 份、工单 3 份,线索、客户、流失各 1 份 |
| [**多维数据集**](/zh-Hans/docs/analytics/cubes) | `src/datasets/` 下的**九个** dataset,也就是上面两层按名字绑定的那一层 |

上表有两个数字过去写的是别的样子,去找东西之前值得先知道。**这里没有合同报表** —— 也建不出来:`src/datasets/` 只读九个对象,`crm_contract` 不在其中,所以分析里没有任何东西能对合同做计数、求和或分组。另外,**没有任何 cube 叫这四个名字** —— *Sales*、*Pipeline*、*Service*、*Marketing* 在应用里零命中。前三个由哪些 dataset 回答、第四个为什么连数据源都没有,见 [多维数据集](/zh-Hans/docs/analytics/cubes)。

## 开箱即用的能力

Expand All @@ -33,32 +35,34 @@ HotCRM 分析将你的 CRM 活动转化为**决策**。三个层次协同工作

管理记录的共享规则同样管理仪表盘和报表:

- 运行 *Pipeline by Stage* 的销售代表只能看到自己的管道
- 运行 **Opportunities by Stage** 的销售代表只能看到自己的交易
- 经理看到其团队的汇总。
- 高管看到全公司范围。

这意味着**一个仪表盘**适用于整个组织——每个人看到的内容取决于他们的身份。

*Pipeline by Stage* 不是一张可以运行的报表,但这个名字有两个真身:它是 CRM Overview、Sales Performance 与 Executive Overview 共用的那块未结管道漏斗**磁贴**(`src/dashboards/shared-widgets.ts`),也是 **Opportunities by Stage** 报表上那张柱状图的标题。在报表库里按这个名字搜索,什么也搜不到 —— 见 [报表](/zh-Hans/docs/analytics/reports)。

## 在哪里可以找到

在 Enterprise CRM 应用中,**分析**组包含:
在 Enterprise CRM 应用里,这个分组叫 **Insights**,下面有五个条目:

- **CRM Overview** —— 跨职能的那块仪表盘。
- **Forecasts** —— 预测记录本身。
- **Pipeline Coverage**、**Lead Inflow**、**SLA Performance** —— 三张按名字钉在侧边栏上的报表。

- **仪表盘** — 可视化中枢。
- **报表** — 报表库。
- **多维数据集** — 数据建模层(管理员)。
没有 *Analytics* 分组,侧边栏上也没有任何条目叫 *Dashboards*、*Reports* 或 *Cubes*。其余仪表盘各自钉在负责它的分组下 —— **Sales Performance** 在 Sales、**Sales Activity** 在 Activity、**Service Overview** 在 Service —— 报表库里剩下的报表则从报表界面进入,而不是从导航进入。整条侧边栏逐组的列法,见 [快速导览](/zh-Hans/docs/getting-started/quick-tour)。

## AI 驱动的洞察

AI Copilot 可以直接从多维数据集读取数据——可以提出如下问题:
**在本应用这一侧,没有任何东西把 Copilot 连到某个 dataset 上。** `src/skills/` 下的六个技能,没有一个点名任何 dataset、cube 或度量。其中负责回答数据问题的那个 —— **Live Data Access** —— 接的是平台的对象工具,而它的指令要求先重新读一遍对象的 schema,再在记录上做聚合。所以 Copilot 的回答是从对象上算出来的,而不是从编译好的 cube 上读出来的。

- *"是什么造成了承诺额与预测额之间的差距?"*
- *"为什么上季度东区比西区少成交了 3 笔交易?"*
- *"告诉我哪些产品与更长的销售周期相关。"*
这也决定了能问它什么。*"是什么造成了承诺额与预测额之间的差距?"* 背后是有数据的:预测记录上真实带着 **Commit**、**Quota**、**Closed Won**、**Pipeline** 四个数字,在 **Forecast Metrics** dataset 上发布为 **Commit**、**Quota**、**Closed**、**Pipeline** 四个度量。*"为什么上季度东区比西区少成交了 3 笔交易?"* 与 *"告诉我哪些产品与更长的销售周期相关。"* 则没有 —— 交易上不存区域,没有任何 dataset 读行项目,而商机唯一带着的那个时长(**Days in Current Stage**)是查询之后才算的公式,什么都聚合不了。这些缺口逐条列在 [多维数据集](/zh-Hans/docs/analytics/cubes)。

更多内容请参阅 [销售技能](/zh-Hans/docs/ai-copilot/sales-copilot)。
平台自带的 agent 是否另外也读编译后的 cube,是关于运行时而不是关于本应用的问题 —— 所以本页对它不做任何方向上的断言,请对着你自己的部署去核。销售侧的技能各自做什么,见 [销售技能](/zh-Hans/docs/ai-copilot/sales-copilot)。

## 从这里开始

- [仪表盘](/zh-Hans/docs/analytics/dashboards) — 四个内置仪表盘
- [报表](/zh-Hans/docs/analytics/reports) — 标准报表库
- [多维数据集](/zh-Hans/docs/analytics/cubes) — 适合想要自行构建的分析师
- [仪表盘](/zh-Hans/docs/analytics/dashboards) —— 五个内置仪表盘
- [报表](/zh-Hans/docs/analytics/reports) —— 十份标准报表
- [多维数据集](/zh-Hans/docs/analytics/cubes) —— 底下的九个 dataset,以及每个能回答什么、不能回答什么
Loading
Loading