resolve-before-asking
它能做什么
这项技能阻止你的智能体询问那些它本可以从你自己的笔记中找到答案的问题。它会先检查你的知识库和已连接的来源。
适用场景
- ✓当你的智能体准备询问某人是谁或担任什么角色的时候。
- ✓当智能体在笔记中发现一个名字,但不确定指的是哪个人时。
- ✓当你希望智能体避免询问笔记中已经记录过的事情时。
技能链接
https://github.com/garrytan/gbrain/blob/master/plugin-variants/gbrain-coding/skills/resolve-before-asking/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“在你问我 Dana 是谁之前,请先在我的知识库中查找她,只有找不到时才问我。”
每周 5 个新技能,1 分钟读完。
工作原理
智能体会按固定顺序搜索你的笔记和过往记录,然后尝试外部来源。如果仍然没有答案,它会问你一个问题,并附上它的最佳猜测。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
Resolve Before Asking — Exhaust the Brain Before Bothering the User
Convention: see conventions/brain-first.md for the base lookup chain (search → query → get_page → external APIs). This skill extends that chain one hop further, to the human boundary: asking the user is the LAST resort, after the brain AND external escalation, not a shortcut around them.
Convention: see _brain-filing-rules.md — pages touched by the ingest-resolution section file by primary subject (
people/,companies/).
Purpose
Never ask the user "who is X?" when the answer already exists in the brain.
The memory answers before the human is bothered — that is the product promise. This skill defines the lookup chain that runs before any entity-identification question is sent to the user, and the escalation format when asking really is justified.
The Bug This Kills
The pattern: the agent encounters an entity with a rich brain page — timeline entries, meeting history, an imported message archive — and instead of reading them, asks the user "who is X?". This is lazy escalation. It spends the user's attention on questions the system can answer itself.
Examples of the bug (anonymized):
- alice-example — her brain page already carried a role line ("Chief of Staff at acme-example") and a long meeting history → the agent still asked.
- charlie-example — a thick imported email thread whose subject lines all pointed at one shared project → the agent still asked.
When This Fires
This is a harness-routing convention, not a mechanical guarantee: route here whenever ANY of these are true —
- A reply draft contains "who is [name]?" or equivalent.
- A draft asks about someone's role, relationship, or identity.
- You are about to present an entity as "unknown" or "unidentified".
- A brain page has
[To be filled by content analysis]or similar placeholder text. - You are composing a list of people and leaving any as "unknown relationship".
The Lookup Chain (run in order; STOP at the first clear answer)
Step 1: think — cross-brain synthesis (solves most cases)
gbrain think "Who is {entity}? What is their relationship to the user? What role do they play? Use all available context — meetings, timeline, imported archives, facts."
think synthesizes across ALL brain data. If the entity has a page with
imported-activity stats, timeline entries, and meeting history, think will
connect the dots. Over MCP, entity("{entity}") first gives a zero-LLM card
(aliases, last-touched, top edges); synthesize is the heavy cross-page
answer when the card isn't enough.
If this returns a clear answer → STOP. Use the answer. Do not ask the user.
Step 2: search + full page read
gbrain search "{entity}" --limit 5
gbrain get {entity-slug}
What to look for:
relationshipfield in frontmatter — filled means resolved.- Role signals repeated in timeline entries ("advisor", "colleague at acme-example", "chief of staff").
- Facts table — any role/relationship facts.
- Meeting history — what did they attend? With whom?
If timeline entries repeat a consistent role → STOP. The role is obvious. Do not ask the user.
Step 3: Query each mounted source the brain actually has
Don't hardcode channels. Check what the brain holds, then query it:
gbrain sources list
gbrain query "emails with {entity}" --limit 10
gbrain query "meetings with {entity}" --limit 5
Whatever is mounted — an email archive, calendar imports, chat transcripts, meeting notes — a handful of subject lines or meeting titles usually reveals the relationship:
- Invoice / scheduling / billing subjects → professional services.
- Recurring 1:1 titles with consistent co-attendees → colleague.
- Dinner / weekend-plan messages → personal friend.
Step 4: Timeline + graph walk
gbrain timeline {entity-slug} --limit 20
gbrain backlinks {entity-slug}
gbrain graph {entity-slug} --depth 2
Dated events, who references this entity, and what it connects to. A person who back-links from a company page and three meeting pages is not an unknown.
Step 5: Web search (external escalation, per brain-first)
Only after steps 1–4 return nothing useful. Run a generic web search on
"{entity name} {company/domain hints accumulated in steps 1-4}". Fold
anything found back into the brain page before using it (the brain-op
常见问题
如果答案仍然不清楚怎么办?
智能体只会问你一次,并附上一个可能的答案,这样你只需确认或更正即可。
批量导入时它会创建占位页面吗?
不会。它的规则会避免在批量摄入时产生空白的占位页面。
允许询问你吗?
允许,但只有在已经尝试过知识库和外部查找之后。
详情
作者的原始描述
Gate on identity questions to the user. Before any "who is X?" (or role / relationship question) reaches the user, exhaust the brain's lookup chain: think → search + page read → mounted sources → timeline/graph → web. If escalation survives the chain, ask WITH a hypothesis, never a bare unknown. Also owns the no-placeholders-at-ingest rule: pages created during bulk ingestion get their relationship/role resolved immediately.
repo: garrytan/gbrain
热度
- GitHub 星标
- 31k
- 排名
- #9267
- 许可证
- MIT
- 更新时间
- 2026/11/2
评论
- …