/inno-code-survey
Acquires missing code repositories for the selected idea (Phase A) and conducts comprehensive code survey mapping academic concepts to implementations (Phase B). Outputs acquired_code_repos, updated_prepare_res, and model_survey for downstream use by inno-implementation-plan.
$ npx -y skills add OpenLAIR/dr-claw --skill inno-code-survey --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
- Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
- You can call itInvoke it directly when you want it.
- Slash command
/inno-code-survey
Context preview
The summary Claude sees to decide when to auto-load this skill.
Acquires missing code repositories for the selected idea (Phase A) and conducts comprehensive code survey mapping academic concepts to implementations (Phase B). Outputs acquired_code_repos, updated_prepare_res, and model_survey for downstream use by inno-implementation-plan.
SKILL.md
inno-code-survey.SKILL.mdname: inno-code-survey
description: Acquires missing code repositories for the selected idea (Phase A) and conducts comprehensive code survey mapping academic concepts to implementations (Phase B). Outputs acquired_code_repos, updated_prepare_res, and model_survey for downstream use by inno-implementation-plan.
Inno Code Survey (Repo Acquisition + Code Survey)
Merges `_acquire_missing_repos`, `_update_prepare_res_with_new_repos`, and `_conduct_code_survey` from [run_infer_idea_ours.py](workspace/medical/Medical_ai_scientist_idea/research_agent/run_infer_idea_ours.py) (lines 639–828, 1038–1052) into a single two-phase skill.
Directory structure
skills/inno-code-survey/
├── SKILL.md ← this file
├── prompts/
│ ├── build_repo_acquisition_query.md ← Phase A query template
│ └── build_code_survey_query.md ← Phase B query template
├── references/
│ ├── repo_acquisition_agent.md ← Phase A agent system prompt & tools
│ └── code_survey_agent.md ← Phase B agent system prompt & tools
└── scripts/
└── github_search_clone.py ← GitHub search + clone helperPath conventions
All file paths use semantic directory names under the project root:
| Path | Contents | |------|----------| | `Ideation/references/papers/` | Downloaded arXiv LaTeX sources (`.tex`, `.txt`, `.md`) | | `Experiment/code_references/<repo_name>/` | Cloned GitHub repositories | | `Experiment/code_references/model_survey.md` | Code survey implementation report | | `Experiment/code_references/logs/` | Phase A & B agent cache files |
Inputs
These are aligned with outputs from **inno-idea-generation** and **inno-prepare-resources**:
| Input | Source | Description | |-------|--------|-------------| | `selected_idea` | `Ideation/ideas/selected_idea.txt` or `final_selected_idea_data` | The finalized selected idea (full markdown) | | `download_res` | `inno-prepare-resources` output | Result log from downloading arXiv paper sources | | `prepare_res` | `inno-prepare-resources` output (JSON) | Contains `reference_codebases` and `reference_paths` | | `context_variables` | Shared context dict | Accumulated pipeline context | | `instance.json` | `<project_path>/instance.json` | Paths are **absolute** when created by Dr. Claw (`Experiment.code_references`, `Ideation.references`); use as-is or resolve with `path.join(project_path, value)` if relative. Also `date_limit` from context. |
Outputs
| Output | Description | Consumer | |--------|-------------|----------| | `acquired_code_repos` | Dict of `{name: path}` for newly cloned repos | Phase B, cache | | `updated_prepare_res` | `prepare_res` JSON with new repos merged into `reference_codebases` / `reference_paths` | Downstream pipeline | | `extra_repo_info` | Formatted string listing acquired repos | Phase B query | | `model_survey` | Comprehensive code survey implementation report | `inno-experiment-dev` |
---
Phase A — Repo Acquisition
> Full template & parameter docs: [prompts/build_repo_acquisition_query.md](prompts/build_repo_acquisition_query.md) > Agent system prompt & tools: [references/repo_acquisition_agent.md](references/repo_acquisition_agent.md)
Maps to `_acquire_missing_repos` (lines 745–792) + `_update_prepare_res_with_new_repos` (lines 639–686).
Step A1: Analyze the selected idea and identify gaps
Read `selected_idea` and identify 2–3 **missing technical components** — novel or specialized parts that are likely NOT in the standard repos already present in `Experiment/code_references/`.
Step A2: Search GitHub using the "Cascade" strategy
For each missing component, perform **6 distinct queries** using progressive decomposition:
1. **Level 1 (Specific)**: Search for the exact mechanism name 2. **Level 2 (Broad)**: Strip context adjectives, search core technique 3. **Level 3 (Atomic)**: Search for 3 base mathematical operators
Use the helper script or GitHub API directly:
# Option 1: Helper script
python scripts/github_search_clone.py --query "sinkhorn attention pytorch" --limit 5 --date-limit 2025-12-31
# Option 2: Direct GitHub API via curl
curl -s "https://api.github.com/search/repositories?q=sinkhorn+attention&per_page=5" \
-H "Accept: application/vnd.github.v3+json"
Step A3: Clone selected repos
Clone the best candidate for each gap into `Experiment/code_references/`:
GIT_TERMINAL_PROMPT=0 git clone --depth 1 <clone_url> Experiment/code_references/<repo_name>
Step A4: Verify each clone
For each cloned repo: 1. Read `README.md`: `cat Experiment/code_references/<repo_name>/README.md` 2. Check language and domain relevance 3. Reject repos that don't match (wrong domain, empty, HTML-only)
Step A5: Build `acquired_code_repos` and update `prepare_res`
1. Build `acquired_code_repos` dict from verified clones:
{
"repo_name_1": "Experiment/code_references/repo_name_1",
"repo_name_2": "Experiment/code_references/repo_name_2"
}2. Set `context_variables["acquired_code_repos"] = acquired_code_repos` 3. Parse `prepare_res` JSON, ensure `reference_codebases` and `reference_paths` arrays exist 4. For each entry in `acquired_code_repos`, if `path` not already in `reference_paths`:
- Append repo name to `reference_codebases`
- Append repo path to `reference_paths`
5. Serialize back to JSON as `updated_prepare_res`
Step A6: Save Phase A cache
1. Build `extra_repo_info` string:
- Name: <name1> | Path: <path1>
- Name: <name2> | Path: <path2>
(Empty string if no repos acquired)
2. Write `Experiment/code_references/logs/repo_acquisition_agent.json`:
{
"context_variables": {
"code_references_path": "<instance.Experiment.code_references if absolute (Dr. Claw), else path.join(project_path, ...)>",
"references_path": "<instance.Ideation.references if aRead more
name: inno-code-survey description: Acquires missing code repositories for the selected idea (Phase A) and conducts comprehensive code survey mapping academic concepts to implementations (Phase B). Outputs acquired_code_repos, updated_prepare_res, and model_survey for downstream use by inno-implementation-plan.
Inno Code Survey (Repo Acquisition + Code Survey)
Merges `_acquire_missing_repos`, `_update_prepare_res_with_new_repos`, and `_conduct_code_survey` from [run_infer_idea_ours.py](workspace/medical/Medical_ai_scientist_idea/research_agent/run_infer_idea_ours.py) (lines 639–828, 1038–1052) into a single two-phase skill.
Directory structure
skills/inno-code-survey/
├── SKILL.md ← this file
├── prompts/
│ ├── build_repo_acquisition_query.md ← Phase A query template
│ └── build_code_survey_query.md ← Phase B query template
├── references/
│ ├── repo_acquisition_agent.md ← Phase A agent system prompt & tools
│ └── code_survey_agent.md ← Phase B agent system prompt & tools
└── scripts/
└── github_search_clone.py ← GitHub search + clone helperPath conventions
All file paths use semantic directory names under the project root:
| Path | Contents | |------|----------| | `Ideation/references/papers/` | Downloaded arXiv LaTeX sources (`.tex`, `.txt`, `.md`) | | `Experiment/code_references/<repo_name>/` | Cloned GitHub repositories | | `Experiment/code_references/model_survey.md` | Code survey implementation report | | `Experiment/code_references/logs/` | Phase A & B agent cache files |
Inputs
These are aligned with outputs from **inno-idea-generation** and **inno-prepare-resources**:
| Input | Source | Description | |-------|--------|-------------| | `selected_idea` | `Ideation/ideas/selected_idea.txt` or `final_selected_idea_data` | The finalized selected idea (full markdown) | | `download_res` | `inno-prepare-resources` output | Result log from downloading arXiv paper sources | | `prepare_res` | `inno-prepare-resources` output (JSON) | Contains `reference_codebases` and `reference_paths` | | `context_variables` | Shared context dict | Accumulated pipeline context | | `instance.json` | `<project_path>/instance.json` | Paths are **absolute** when created by Dr. Claw (`Experiment.code_references`, `Ideation.references`); use as-is or resolve with `path.join(project_path, value)` if relative. Also `date_limit` from context. |
Outputs
| Output | Description | Consumer | |--------|-------------|----------| | `acquired_code_repos` | Dict of `{name: path}` for newly cloned repos | Phase B, cache | | `updated_prepare_res` | `prepare_res` JSON with new repos merged into `reference_codebases` / `reference_paths` | Downstream pipeline | | `extra_repo_info` | Formatted string listing acquired repos | Phase B query | | `model_survey` | Comprehensive code survey implementation report | `inno-experiment-dev` |
---
Phase A — Repo Acquisition
> Full template & parameter docs: [prompts/build_repo_acquisition_query.md](prompts/build_repo_acquisition_query.md) > Agent system prompt & tools: [references/repo_acquisition_agent.md](references/repo_acquisition_agent.md)
Maps to `_acquire_missing_repos` (lines 745–792) + `_update_prepare_res_with_new_repos` (lines 639–686).
Step A1: Analyze the selected idea and identify gaps
Read `selected_idea` and identify 2–3 **missing technical components** — novel or specialized parts that are likely NOT in the standard repos already present in `Experiment/code_references/`.
Step A2: Search GitHub using the "Cascade" strategy
For each missing component, perform **6 distinct queries** using progressive decomposition:
1. **Level 1 (Specific)**: Search for the exact mechanism name 2. **Level 2 (Broad)**: Strip context adjectives, search core technique 3. **Level 3 (Atomic)**: Search for 3 base mathematical operators
Use the helper script or GitHub API directly:
# Option 1: Helper script python scripts/github_search_clone.py --query "sinkhorn attention pytorch" --limit 5 --date-limit 2025-12-31 # Option 2: Direct GitHub API via curl curl -s "https://api.github.com/search/repositories?q=sinkhorn+attention&per_page=5" \ -H "Accept: application/vnd.github.v3+json"
Step A3: Clone selected repos
Clone the best candidate for each gap into `Experiment/code_references/`:
GIT_TERMINAL_PROMPT=0 git clone --depth 1 <clone_url> Experiment/code_references/<repo_name>
Step A4: Verify each clone
For each cloned repo: 1. Read `README.md`: `cat Experiment/code_references/<repo_name>/README.md` 2. Check language and domain relevance 3. Reject repos that don't match (wrong domain, empty, HTML-only)
Step A5: Build `acquired_code_repos` and update `prepare_res`
1. Build `acquired_code_repos` dict from verified clones:
{
"repo_name_1": "Experiment/code_references/repo_name_1",
"repo_name_2": "Experiment/code_references/repo_name_2"
}2. Set `context_variables["acquired_code_repos"] = acquired_code_repos` 3. Parse `prepare_res` JSON, ensure `reference_codebases` and `reference_paths` arrays exist 4. For each entry in `acquired_code_repos`, if `path` not already in `reference_paths`:
- Append repo name to `reference_codebases`
- Append repo path to `reference_paths`
5. Serialize back to JSON as `updated_prepare_res`
Step A6: Save Phase A cache
1. Build `extra_repo_info` string:
- Name: <name1> | Path: <path1> - Name: <name2> | Path: <path2>
(Empty string if no repos acquired)
2. Write `Experiment/code_references/logs/repo_acquisition_agent.json`:
{
"context_variables": {
"code_references_path": "<instance.Experiment.code_references if absolute (Dr. Claw), else path.join(project_path, ...)>",
"references_path": "<instance.Ideation.references if aA Super AI Lab with massive AI Doctors as Assistants. Best IDE for Research via AI Power.
Repo: OpenLAIR/dr-claw
Other skills on dr-claw.
- /dr-claw
Dr. Claw skill for OpenClaw project discovery, idea intake, waiting-session triage, structured session control, event-driven notifications, and mobile reporting through the local drclaw CLI.
Open skill - /academic-researcher
Academic research assistant for literature reviews, paper analysis, and scholarly writing. Use when: reviewing academic papers, conducting literature reviews, writing research summaries, analyzing methodologies, formatting citations, or when user mentions academic research,
Open skill - /autogpt
Autonomous AI agent platform for building and deploying continuous agents. Use when creating visual workflow agents, deploying persistent autonomous agents, or building complex multi-step AI automation systems.
Open skill - /crewai
Multi-agent orchestration framework for autonomous AI collaboration. Use when building teams of specialized agents working together on complex tasks, when you need role-based agent collaboration with memory, or for production workflows requiring sequential/hierarchical
Open skill - /langchain
Framework for building LLM-powered applications with agents, chains, and RAG. Supports multiple providers (OpenAI, Anthropic, Google), 500+ integrations, ReAct agents, tool calling, memory management, and vector store retrieval. Use for building chatbots, question-answering
Open skill - /llamaindex
Data framework for building LLM applications with RAG. Specializes in document ingestion (300+ connectors), indexing, and querying. Features vector indices, query engines, agents, and multi-modal support. Use for document Q&A, chatbots, knowledge retrieval, or building RAG
Open skill

