{"skill":{"slug":"nm-tome-research","displayName":"Nm Tome Research","summary":"Multi-source research across code, discourse, and academic channels","description":"---\nname: research\ndescription: Multi-source research across code, discourse, and academic channels\nversion: 1.9.5\ntriggers:\n  - research\n  - synthesis\n  - multi-source\nmetadata: {\"openclaw\": {\"homepage\": \"https://github.com/athola/claude-night-market/tree/master/plugins/tome\", \"emoji\": \"\\ud83e\\udd9e\"}}\nsource: claude-night-market\nsource_plugin: tome\n---\n\n> **Night Market Skill** — ported from [claude-night-market/tome](https://github.com/athola/claude-night-market/tree/master/plugins/tome). For the full experience with agents, hooks, and commands, install the Claude Code plugin.\n\n\n# Research Session Orchestrator\n\nRun a full multi-source research session: classify the\ndomain, dispatch parallel agents, synthesize findings,\nand output a formatted report.\n\n## Workflow\n\n### Step 1: Classify Domain\n\nRun the domain classifier on the topic:\n\n```python\nfrom tome.scripts.domain_classifier import classify\nresult = classify(topic)\n# result.domain, result.triz_depth, result.channel_weights\n```\n\nIf confidence < 0.6, ask the user to confirm or override\nthe domain classification before proceeding.\n\n### Step 2: Plan Research\n\n```python\nfrom tome.scripts.research_planner import plan\nresearch_plan = plan(result)\n# research_plan.channels, research_plan.weights, research_plan.triz_depth\n```\n\n### Step 3: Create Session\n\n```python\nfrom tome.session import SessionManager\nmgr = SessionManager(Path.cwd())\nsession = mgr.create(topic, result.domain, result.triz_depth, research_plan.channels)\n```\n\n### Step 4: Dispatch Agents\n\nLaunch research agents in parallel using the Agent tool.\nUse this mapping:\n\n| Channel | Agent Type | Prompt Includes |\n|---------|-----------|-----------------|\n| code | `tome:code-searcher` | topic |\n| discourse | `tome:discourse-scanner` | topic, domain, subreddits |\n| academic | `tome:literature-reviewer` | topic, domain |\n| triz | `tome:triz-analyst` | topic, domain, triz_depth |\n\n**Rules:**\n- Always dispatch code and discourse agents\n- Dispatch academic agent only if \"academic\" is in\n  research_plan.channels\n- Dispatch triz agent only if \"triz\" is in\n  research_plan.channels AND triz_depth != \"light\"\n- Dispatch all eligible agents in a SINGLE message\n  (parallel, not sequential)\n\nEach agent prompt must include:\n1. The topic string\n2. The domain classification\n3. Any channel-specific context (subreddits for discourse,\n   triz_depth for triz)\n4. Instruction to return findings as JSON\n\n### Step 5: Collect and Synthesize\n\nAfter all agents return:\n\n1. Parse each agent's findings into Finding objects\n2. Merge using `tome.synthesis.merger.merge_findings()`\n3. Rank using `tome.synthesis.ranker.rank_findings()`\n\n### Step 6: Generate Output\n\n```python\nfrom tome.output.report import format_report, format_brief, format_transcript\n\n# Default to report format\noutput = format_report(session)\n\n# Save to docs/research/\noutput_path = f\"docs/research/{session.id}-{slug}.md\"\n```\n\nSave the session state:\n```python\nmgr.save(session)\n```\n\n### Step 7: Present Results\n\nDisplay a brief summary to the user:\n- Number of findings per channel\n- Top 3 findings by relevance\n- Path to saved report\n\nThen offer interactive refinement:\n\"Use `/tome:dig \\\"subtopic\\\"` to explore specific areas.\"\n\n## Error Handling\n\n- If an agent fails, continue with remaining agents\n- If all agents fail, report the error and suggest\n  manual research approaches\n- If synthesis produces 0 findings, state this clearly\n  rather than generating an empty report\n- Save session state even on partial failure\n\n## Output Format Selection\n\n| Flag | Format | Function |\n|------|--------|----------|\n| (default) | report | `format_report()` |\n| `--format brief` | brief | `format_brief()` |\n| `--format transcript` | transcript | `format_transcript()` |\n","tags":{"latest":"1.0.2"},"stats":{"comments":0,"downloads":475,"installsAllTime":1,"installsCurrent":1,"stars":0,"versions":3},"createdAt":1776776504055,"updatedAt":1778492695381},"latestVersion":{"version":"1.0.2","createdAt":1778293257322,"changelog":"Release v1.9.5","license":"MIT-0"},"metadata":{"setup":[],"os":null,"systems":null},"owner":{"handle":"athola","userId":"s17emme0e2m3cpf7k2jvp3a84984b8z9","displayName":"athola","image":"https://avatars.githubusercontent.com/u/9769290?v=4"},"moderation":null}