ae-kb-discovery

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Knowledge Base Discovery

知识库发现

Treat knowledge bases as an optional source of internal facts and business context. Keep the user's original goal unchanged; knowledge base retrieval is a supporting workflow, not the task itself.
This skill decides whether to use a knowledge base and which knowledge base is worth searching. The retrieval procedure itself — inspecting the index, grep, reading sections, and optional LLM synthesis — lives in the
ae-kb
skill (
references/query-workflow.md
). Discover here, then hand off to
ae-kb
to execute.
将知识库视为内部事实与业务上下文的可选来源。保持用户的原始目标不变;知识库检索是辅助工作流,而非任务本身。
本技能用于决定是否使用知识库,以及哪些知识库值得搜索。检索流程本身——查看索引、grep、读取章节以及可选的LLM合成——由
ae-kb
技能负责(详见
references/query-workflow.md
)。在此完成发现后,移交至
ae-kb
执行检索。

Decide Whether to Use This Skill

判断是否使用本技能

Use this skill when:
  • The user explicitly asks to search a knowledge base, internal documentation, or company materials.
  • The task requires organization-specific facts or context, such as product design and rules, events, campaign or operations calendars, release and iteration records, workflows, policies, or terminology.
  • Internal context is needed to explain data analysis results, anomalies, or trends and form evidence-backed conclusions.
  • The knowledge base context currently available does not cover the question, and discovering other accessible sources has clear value.
Do not use this skill when:
  • The user explicitly asks not to use knowledge bases.
  • The task only requires querying real-time state or performing an operation and does not need document context.
  • General knowledge is sufficient for a reliable answer and internal evidence would not materially improve it.
在以下场景使用本技能:
  • 用户明确要求搜索知识库、内部文档或公司资料。
  • 任务需要组织特定的事实或上下文,例如产品设计与规则、活动、营销或运营日历、发布与迭代记录、工作流程、政策或术语。
  • 需要内部上下文来解释数据分析结果、异常或趋势,并形成有证据支持的结论。
  • 当前可用的知识库上下文无法覆盖问题,发现其他可访问来源具有明确价值。
在以下场景请勿使用本技能:
  • 用户明确要求不使用知识库。
  • 任务仅需查询实时状态或执行操作,无需文档上下文。
  • 通用知识足以给出可靠答案,内部证据无法实质性提升答案质量。

Discovery Workflow

发现工作流

1. Get the List of Accessible Knowledge Bases

1. 获取可访问知识库列表

First, get the lightweight list of knowledge bases accessible to the current user:
bash
ae-cli kb +list
Use the exact
scope
and knowledge base name returned by the command, together with available metadata such as description, tags, language, and
bindings
. A binding identifies an associated context through
targetType
,
targetId
, and optional
targetName
. Do not guess a name, scope, or binding. Treat metadata returned by
+list
only as input for candidate selection, not as evidence from knowledge base content.
If
+list
is unavailable or fails, do not guess which knowledge bases exist. If the user explicitly requested a knowledge base search, explain that discovery cannot currently be completed. Otherwise, return to the original task and reassess the capabilities currently available.
首先,获取当前用户可访问的轻量化知识库列表:
bash
ae-cli kb +list
使用命令返回的精确
scope
和知识库名称,以及可用元数据(如描述、标签、语言和
bindings
)。绑定通过
targetType
targetId
和可选的
targetName
标识关联上下文。请勿猜测名称、范围或绑定。仅将
+list
返回的元数据作为候选筛选的输入,而非知识库内容的证据。
如果
+list
不可用或执行失败,请勿猜测存在哪些知识库。如果用户明确要求搜索知识库,请说明当前无法完成发现操作。否则,回到原始任务并重新评估当前可用的能力。

2. Rank Candidate Knowledge Bases

2. 对候选知识库排序

Rank candidates in this order:
  1. Prefer a knowledge base explicitly named by the user. Use the exact name and scope returned by
    +list
    , regardless of whether it has a matching binding.
  2. Prefer candidates whose bindings exactly match the current session context. Match
    targetType: project
    against the current analysis project ID,
    targetType: space
    against the current community space ID, and
    targetType: dwSpace
    against the current digital workspace code.
  3. For the remaining candidates, compare the user's request with the knowledge base name, description, and tags. Use language only as a preference between candidates with similar relevance; language alone does not establish relevance.
Compare
targetId
with the corresponding current ID or code first. Use
targetName
only as a secondary signal when an ID or code is unavailable; do not replace a conflicting ID match with a name match. A candidate with no bindings or no current-context match remains eligible for semantic ranking. A binding to another project or space lowers implicit priority but does not exclude the candidate, and an explicit user choice still takes precedence.
Select one preferred knowledge base by default. When several candidates are highly relevant, retain no more than three and try them one at a time in priority order. Do not read the indexes of all candidates in advance. A binding, name, description, tag, or language match only indicates that a knowledge base is worth searching; it does not prove a content match, grant access, or count as knowledge base evidence.
按以下顺序对候选知识库排序:
  1. 优先选择用户明确指定的知识库。使用
    +list
    返回的精确名称和范围,无论其是否有匹配的绑定。
  2. 优先选择绑定与当前会话上下文完全匹配的候选。将
    targetType: project
    与当前分析项目ID匹配,
    targetType: space
    与当前社区空间ID匹配,
    targetType: dwSpace
    与当前数字工作区代码匹配。
  3. 对于剩余候选,将用户请求与知识库名称、描述和标签进行对比。仅在相关性相似的候选之间将语言作为偏好因素;语言本身无法确立相关性。
首先将
targetId
与对应的当前ID或代码匹配。仅当ID或代码不可用时,才将
targetName
作为次要信号;请勿用名称匹配替代冲突的ID匹配。无绑定或无当前上下文匹配的候选仍可参与语义排序。绑定到其他项目或空间会降低隐含优先级,但不会排除该候选,且用户的明确选择仍具有最高优先级。
默认选择一个首选知识库。当多个候选高度相关时,最多保留三个,并按优先级顺序依次尝试。请勿提前读取所有候选的索引。绑定、名称、描述、标签或语言匹配仅表明知识库值得搜索;并不证明内容匹配、授予访问权限或可作为知识库证据。

3. Hand Off to Retrieval

3. 移交至检索流程

Once a preferred knowledge base is selected, hand off to the
ae-kb
skill and follow its
references/query-workflow.md
for the entire retrieval procedure — including when
+ask
is appropriate.
一旦选定首选知识库,移交至
ae-kb
技能,并遵循其
references/query-workflow.md
完成整个检索流程——包括判断何时适合使用
+ask

Assess Coverage

评估覆盖范围

  • Full coverage: The page content read supports the key conclusions required for the information request or analysis.
  • Partial coverage: The page content read provides only background, definitions, or partially relevant facts and cannot independently support the required conclusions.
  • No coverage: No suitable candidate knowledge base exists, or
    +grep
    and
    +read
    return no content that can support the conclusions.
A candidate returned by
+list
, navigation returned by
+index
, a successful command, a tool call, or a metadata match does not count as a knowledge base hit. Only relevant page content that has actually been read can serve as knowledge base evidence.
  • 完全覆盖:读取的页面内容支持信息请求或分析所需的关键结论。
  • 部分覆盖:读取的页面内容仅提供背景、定义或部分相关事实,无法独立支持所需结论。
  • 无覆盖:不存在合适的候选知识库,或
    +grep
    +read
    未返回可支持结论的内容。
+list
返回的候选、
+index
返回的导航、成功执行的命令、工具调用或元数据匹配均不算作知识库命中。只有实际读取的相关页面内容才能作为知识库证据。

Use Knowledge Base Evidence in Analysis

在分析中使用知识库证据

When using internal context to explain data analysis results, anomalies, or trends:
  1. First state what the analysis itself demonstrates, including the metric change, time range, affected entity, and magnitude.
  2. Search using the affected entity, metric, time range, campaign or event name, product area, and release or version name.
  3. Verify that the retrieved evidence:
    • Applies to the same entity, product area, or business scope.
    • Overlaps with the time range covered by the analysis.
    • Records an event, rule, release, or change that actually took effect.
    • Uses a version and effective date that remained valid during the analysis period.
  4. Distinguish planned activities from completed events. A calendar or roadmap does not prove that an activity or release occurred unless the retrieved content confirms execution.
  5. Combine analytical facts with retrieved internal evidence and state directly what the evidence supports. Do not list possible causes that lack evidence.
  6. Use causal language such as "caused" or "led to" only when the available evidence establishes causality. Otherwise, say that the evidence supports a factor as a key explanation or that the factor is consistent with the observed change.
  7. If the evidence is insufficient, state clearly that the cause cannot be determined from the available evidence. Do not fill evidence gaps with speculation.
  8. When appropriate, organize the final answer in this order:
    • Conclusion.
    • Analytical evidence.
    • Knowledge base evidence and relevant page paths.
    • Necessary limitations of the evidence.
当使用内部上下文解释数据分析结果、异常或趋势时:
  1. 首先说明分析本身展示的内容,包括指标变化、时间范围、受影响实体及幅度。
  2. 使用受影响实体、指标、时间范围、营销活动或事件名称、产品领域、发布或版本名称进行搜索。
  3. 验证检索到的证据:
    • 适用于相同的实体、产品领域或业务范围。
    • 与分析覆盖的时间范围重叠。
    • 记录了实际生效的事件、规则、发布或变更。
    • 使用的版本和生效日期在分析期间保持有效。
  4. 区分计划活动与已完成事件。日历或路线图不能证明活动或发布已发生,除非检索到的内容确认已执行。
  5. 将分析事实与检索到的内部证据相结合,直接说明证据支持的内容。请勿列出缺乏证据的可能原因。
  6. 仅当现有证据确立因果关系时,使用“导致”或“引发”等因果性语言。否则,说明证据支持某一因素作为关键解释,或该因素与观察到的变化一致。
  7. 如果证据不足,明确说明无法从现有证据中确定原因。请勿用猜测填补证据空白。
  8. 适当时,按以下顺序组织最终答案:
    • 结论。
    • 分析证据。
    • 知识库证据及相关页面路径。
    • 证据的必要局限性。

Handle Partial or No Coverage

处理部分覆盖或无覆盖情况

When knowledge base evidence provides only partial coverage, is entirely absent, or retrieval fails:
  1. Stop repeating searches against the same candidate knowledge base.
  2. If ranked candidates remain, switch to the next candidate. Search no more than three knowledge bases in one task.
  3. When all candidates provide no coverage, return to the user's original request instead of remaining in the knowledge base retrieval subtask.
  4. Reassess the capabilities currently available and choose the next path that best serves the original task. Do not hard-code a fixed fallback.
  5. Retain verified background evidence when useful, but never attribute conclusions drawn from other sources to a knowledge base.
  6. Do not report an unsuccessful knowledge base search unless the retrieval failure itself affects the user's decision.
Knowledge base information must not replace required business operations. If the original task also requires real-time data or an action, complete that part through the appropriate available capability.
当知识库证据仅提供部分覆盖、完全缺失或检索失败时:
  1. 停止对同一候选知识库重复搜索。
  2. 如果仍有已排序的候选,切换至下一个候选。单次任务中搜索的知识库不超过三个。
  3. 当所有候选均无覆盖时,回到用户的原始请求,而非停留在知识库检索子任务中。
  4. 重新评估当前可用的能力,选择最适合原始任务的下一步路径。请勿硬编码固定的回退方案。
  5. 保留有用的已验证背景证据,但切勿将其他来源得出的结论归因于知识库。
  6. 除非检索失败本身影响用户决策,否则无需报告未成功的知识库搜索。
知识库信息不得替代必要的业务操作。如果原始任务还需要实时数据或执行操作,请通过相应的可用能力完成该部分。

Safety Boundaries

安全边界

  • Limit knowledge base access to the read-only retrieval primitives (
    +list
    ,
    +index
    ,
    +grep
    ,
    +read
    , and
    +ask
    when the question requires multi-page synthesis or multi-hop reasoning). Do not create, upload, compile, or delete knowledge bases.
  • Respect existing scope, tenant, and membership permissions. Do not attempt to bypass an inaccessible knowledge base.
  • Do not expose internal root paths, access tokens, or raw permission metadata.
  • For protected knowledge bases, provide only summaries and synthesized conclusions allowed by the current permissions. Do not export complete source text or extensive verbatim excerpts.
  • 知识库访问仅限只读检索原语(
    +list
    +index
    +grep
    +read
    ,以及当问题需要多页合成或多跳推理时的
    +ask
    )。请勿创建、上传、编译或删除知识库。
  • 遵守现有的范围、租户和成员权限。请勿尝试绕过无法访问的知识库。
  • 请勿暴露内部根路径、访问令牌或原始权限元数据。
  • 对于受保护的知识库,仅提供当前权限允许的摘要和合成结论。请勿导出完整源文本或大量逐字摘录。