From ai-analyst
Browses organization's knowledge system: glossary terms, products, metrics, OKRs, teams. Crawls Notion workspaces to ingest context. Invoke via /business subcommands or /notion-ingest.
How this skill is triggered — by the user, by Claude, or both
Slash command
/ai-analyst:business-contextThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
> Interactive browser for your organization's knowledge system. Explore terms,
Interactive browser for your organization's knowledge system. Explore terms, products, metrics, objectives, and team structure. Also optionally crawl Notion workspaces to extract and populate business context.
Invoked as /business or /business {subcommand} or /notion-ingest
<workspace>/knowledge/organizations/{org}/<workspace>/knowledge/setup-state.yaml to find active organization/setup Phase 3 to configure business context, or create one manually at <workspace>/knowledge/organizations/{name}/."/business (no args) — OverviewDisplay a summary of available business context:
Business Context: {org_name}
Glossary: {n} terms defined
Products: {n} products cataloged
Metrics: {n} metrics specified
Objectives: {n} OKRs/goals tracked
Teams: {n} teams mapped
Type /business {category} for details.
Implementation:
<workspace>/knowledge/organizations/{org}/manifest.yaml for org namehelpers/business_context.py → load_business_context(org_path)/business glossary — Browse TermsDisplay all business term definitions:
Glossary ({n} terms)
Term | Definition | Category
──────────────────|─────────────────────────────────────|──────────
Active User | User with ≥1 session in last 30d | Engagement
Churn | No activity for 60+ days | Retention
...
Implementation:
business/glossary/terms.yaml<workspace>/knowledge/organizations/{org}/business/glossary/terms.yaml."/business products — View Product CatalogDisplay product hierarchy:
Products ({n} total)
Product | Category | Status | Key Metrics
──────────────────|─────────────|───────────|────────────
Core Platform | SaaS | Active | MAU, Revenue
Mobile App | Mobile | Active | DAU, Retention
...
Implementation:
business/products/index.yaml<workspace>/knowledge/organizations/{org}/business/products/index.yaml."/business metrics — Inspect Metric DefinitionsDisplay metric dictionary:
Metrics ({n} defined)
Metric | Type | Formula/Definition | Owner
──────────────────|─────────────|───────────────────────────|──────
Conversion Rate | Ratio | signups / visitors | Growth
MRR | Currency | SUM(active_subscriptions) | Finance
...
Implementation:
business/metrics/index.yaml<workspace>/knowledge/datasets/{active}/metrics/ if available/metrics add to define metrics, or add to <workspace>/knowledge/organizations/{org}/business/metrics/index.yaml."/business objectives — Review OKRs/GoalsDisplay current objectives:
Objectives ({n} active)
Objective | Key Results | Status
───────────────────────────────|──────────────────────────|────────
Increase activation rate | +15% by Q2 | On Track
Reduce churn | <5% monthly by Q3 | At Risk
...
Implementation:
business/objectives/index.yaml<workspace>/knowledge/organizations/{org}/business/objectives/index.yaml."/business teams — Show Team StructureDisplay team organization:
Teams ({n} mapped)
Team | Lead | Focus Area | Analysts
──────────────────|─────────────|───────────────────|──────────
Growth | Jane D. | Acquisition | 2
Product | John S. | Core Experience | 3
...
Implementation:
business/teams/index.yaml<workspace>/knowledge/organizations/{org}/business/teams/index.yaml."/business lookup {term} — SearchSearch across all categories for a term:
If no match: "No results for '{term}'. Try a different search term or browse categories with /business."
Implementation:
helpers/business_context.py → get_glossary(), get_products(), etc./notion-ingest)This skill uses a breadth-first crawl strategy to systematically traverse a Notion workspace, converting pages to structured knowledge entries. It does NOT require external Python packages — all Notion API calls use inline HTTP requests.
import yaml, os
# Load integration config
integrations_path = "<workspace>/knowledge/user/integrations.yaml"
with open(integrations_path) as f:
config = yaml.safe_load(f)
notion_token = config.get("notion", {}).get("token")
if not notion_token:
print("No Notion token found. Add to <workspace>/knowledge/user/integrations.yaml")
# HALT
Verify token works with a simple API call:
GET https://api.notion.com/v1/users/me
Authorization: Bearer {token}
Notion-Version: 2022-06-28
Ask the user for crawl scope:
Notion workspace connected. How would you like to crawl?
1. **Full workspace** — Crawl all accessible pages (may be slow for large workspaces)
2. **Specific database** — Provide a database URL to crawl
3. **Specific page tree** — Provide a root page URL to crawl its children
4. **Search by keyword** — Search for pages matching specific terms
Algorithm: Breadth-First Search (BFS)
Queue ← [root_page_id]
Visited ← {}
Results ← []
WHILE Queue is not empty:
page_id ← Queue.dequeue()
IF page_id IN Visited: CONTINUE
Visited.add(page_id)
page ← fetch_page(page_id) # GET /v1/pages/{id}
children ← fetch_children(page_id) # GET /v1/blocks/{id}/children
result ← convert_to_knowledge(page, children)
Results.append(result)
# Enqueue child pages and linked databases
FOR child IN children:
IF child.type == "child_page" OR child.type == "child_database":
Queue.enqueue(child.id)
rate_limit_pause() # See Step 4
Notion API limits: 3 requests per second for integration tokens.
Backoff strategy:
Retry-After header seconds, minimum 1sConvert Notion block types to markdown:
| Notion Block Type | Markdown Output |
|---|---|
| paragraph | Plain text |
| heading_1 | # Title |
| heading_2 | ## Title |
| heading_3 | ### Title |
| bulleted_list_item | - Item |
| numbered_list_item | 1. Item |
| code | ```lang\ncode\n``` |
| quote | > Quote |
| callout | > ℹ️ Callout |
| table | Markdown table |
| divider | --- |
| toggle | Treat as heading + nested content |
| child_page | [Page Title](notion://page_id) |
| child_database | [Database Title](notion://db_id) |
For each crawled page, attempt to classify and extract structured knowledge:
| Page Contains | Classification | Target File |
|---|---|---|
| Term definitions, glossary entries | Glossary term | business/glossary/terms.yaml |
| KPI, metric, formula | Metric definition | business/metrics/index.yaml |
| Product name, feature list | Product entry | business/products/index.yaml |
| OKR, objective, key result | Objective | business/objectives/index.yaml |
| Team name, org chart | Team entry | business/teams/index.yaml |
| SQL query, data pattern | Query archaeology | <workspace>/knowledge/query-archaeology/raw/ |
During crawl, show progress:
Crawling Notion workspace...
Pages crawled: 45/~120 (estimated)
Terms extracted: 12
Metrics found: 5
Products found: 3
Errors: 1 (skipped)
Current: "Q4 2025 OKR Tracker"
After crawl completes:
Notion ingest complete!
Pages crawled: 127
Pages skipped: 3 (errors logged)
Knowledge extracted:
Glossary terms: 23 → business/glossary/terms.yaml
Metrics: 8 → business/metrics/index.yaml
Products: 5 → business/products/index.yaml
Objectives: 12 → business/objectives/index.yaml
Teams: 4 → business/teams/index.yaml
Raw pages saved: 127 → <workspace>/knowledge/query-archaeology/raw/
Review extracted knowledge with `/business` to verify accuracy.
/setup Phase 3<workspace>/knowledge/user/integrations.yaml."/business, detail for subcommandsnpx claudepluginhub ai-analyst-lab/ai-analyst-plugin --plugin ai-analystSearches Notion workspaces for topics, fetches and synthesizes multi-page content, then creates structured research reports or summaries as new pages with citations and insights.
Provides Notion API architecture patterns for headless CMS (blog), task tracker, knowledge base, form handler, and data pipeline. Includes TypeScript/JavaScript and Python code examples with schemas.
Discovers team structure, terminology, goals, performance frameworks, values, and ways of working by crawling Slack, Notion, Google Drive, Gmail, Calendar; validates with manager before persisting.