Skip to content

feat(autoresearch): add Dr. Claw research pack#150

Merged
bbsngg merged 2 commits intomainfrom
feat/dr-claw-research-pack
Apr 9, 2026
Merged

feat(autoresearch): add Dr. Claw research pack#150
bbsngg merged 2 commits intomainfrom
feat/dr-claw-research-pack

Conversation

@bbsngg
Copy link
Copy Markdown
Contributor

@bbsngg bbsngg commented Apr 9, 2026

Summary

  • Add Dr. Claw as the first pack in AutoResearch Hub, featuring 16 in-house inno- skills covering the full research lifecycle (planning → survey → ideation → experiment → paper writing → review → rebuttal)
  • Add GEMINI_API_KEY environment configuration for image generation (Figure Gen skill), with Hub UI adapted to show env-only config instead of MCP reviewer labels
  • Backend: support inno- prefix in skills symlinking; gracefully skip MCP registration for env-only packs

Changes

  • src/constants/autoResearchPacks.ts — new Dr. Claw PackDef (first in array), add optional configLabel field to PackDef type
  • src/components/AutoResearchHub.tsx — use configLabel for per-pack config section title/desc; hide MCP selector when single option; hide register command when empty
  • server/routes/community-tools.js — skip MCP registration for unknown backends (env-only); add inno- to skills symlink filter

Test plan

  • Open AutoResearch Hub, verify Dr. Claw card appears first with correct description
  • Expand config section, verify it shows "环境变量" / "Environment" (not "MCP 审稿服务")
  • Verify only GEMINI_API_KEY input is shown (no MCP selector buttons, no register command)
  • Enter a key and click "一键配置", verify key is saved to ~/.openclaw/community-tools.json
  • Check chat dropdown shows Dr. Claw workflows
  • Verify ARIS/Autoresearch/DeepScientist packs still work as before

🤖 Generated with Claude Code

Add Dr. Claw as the first pack in AutoResearch Hub, featuring 16 inno-
prefixed skills covering the full research lifecycle. Includes GEMINI_API_KEY
env config for figure generation, with Hub UI adapted to support env-only
configuration (no MCP server registration needed).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@bbsngg bbsngg requested a review from Zhang-Henry April 9, 2026 01:16
Copy link
Copy Markdown
Collaborator

@Zhang-Henry Zhang-Henry left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review: feat(autoresearch): add Dr. Claw research pack

Overall a clean, well-scoped feature addition. A couple of minor concerns.

👍 Highlights

  1. Data-driven approach — Dr. Claw is added purely as a PackDef entry in autoResearchPacks.ts with no special-case logic. The pack system is well designed.
  2. Graceful env-only handling — The backend correctly skips MCP registration for packs that only need env vars (like gemini-figure). The frontend hides the MCP selector when there is only one option and hides the register command when it is empty. Logical.
  3. configLabel extension — The optional configLabel field on PackDef is a clean extension. Other packs can use it too without breaking changes.
  4. inno- prefix in symlink filter — Necessary for Dr. Claw skills to be discovered. One-line change, correct.

🔴 Must Fix

1. Unknown backend errors are silently swallowed (medium severity)

Old code:

if (!args) {
  results.errors.push({ step: 'mcp', error: `Unknown backend: ${mcpBackend}` });
}

New code:

if (!args) {
  results.steps.push({ step: 'mcp', status: 'skipped', message: `No MCP server needed for ${mcpBackend}` });
}

This is correct for gemini-figure, but if someone misconfigures a pack with a typo (e.g., mcpBackend: "codxe"), the old code would report an error while the new code silently skips with "No MCP server needed."

Suggestion: maintain an explicit allowlist of env-only backends (e.g., const envOnlyBackends = new Set(['gemini-figure'])) and only skip for those. Unknown backends should still error.


🟡 Suggestions

2. register: '' relies on JS falsy semantics (nit)

{ key: 'gemini-figure', label: 'Gemini (Figure Gen)', register: '', envVars: [...] }

The UI checks {mcpOpt.register && (...)}, so empty string works as falsy. But register: string in the PackDef type does not convey the intent. Consider either:

  • Making the type register?: string (optional), or
  • Adding a comment explaining that empty string means "no register command"

3. Korean translations are copy-pasted English (nit)

All ko strings are identical to en. If Korean localization is planned, these should be translated. If not, consider omitting ko and falling back to en at the consumer level to avoid maintaining duplicate strings.


Verdict

Approve with one fix — Address #1 (silent error swallowing for unknown backends), then good to merge. The rest are cosmetic improvements.

- Add ENV_ONLY_BACKENDS allowlist so unknown backends still error
  while known env-only backends (gemini-figure) skip gracefully
- Make PackConfigOption.register optional instead of using empty string
- Add register guard in SkillsDashboard to match AutoResearchHub

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@bbsngg
Copy link
Copy Markdown
Contributor Author

bbsngg commented Apr 9, 2026

Pushed fixes per review feedback (4dd5c21):

✅ Addressed

1. Unknown backend errors no longer silently swallowed (must fix)

  • Added ENV_ONLY_BACKENDS allowlist — only known env-only backends like gemini-figure skip MCP registration gracefully
  • Unknown backends (e.g. typo codxe) still produce an error, preserving the original safety check

2. register: '' falsy semantics (suggestion)

  • Changed PackConfigOption.register type from register: string to register?: string (optional) for clearer intent
  • gemini-figure entry now omits the register field entirely instead of using empty string
  • Added missing {mcpOpt.register && ...} guard in SkillsDashboard.tsx (was already present in AutoResearchHub.tsx)

⏭️ Deferred

3. Korean translations copy-pasted from English (nit)

  • This is a pre-existing pattern across all packs (ARIS, Autoresearch, DeepScientist), not specific to Dr. Claw
  • A proper fix would require making ko optional in Record<LocaleKey, string> or adding fallback logic at every consumer site — too invasive for this PR
  • Suggest addressing in a separate PR with a unified locale fallback mechanism

@bbsngg bbsngg merged commit 7cfc883 into main Apr 9, 2026
1 check passed
@bbsngg bbsngg deleted the feat/dr-claw-research-pack branch April 9, 2026 16:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants