From 89374cb35f4586190ea93496df18cf7fb98b7226 Mon Sep 17 00:00:00 2001 From: Research Assistant Date: Wed, 22 Apr 2026 23:20:49 +0800 Subject: [PATCH] =?UTF-8?q?remove:=20all=20=E7=A7=91=E7=A0=94=E8=AF=BB?= =?UTF-8?q?=E5=9B=BE=E6=8C=87=E5=8D=97=20and=20Template=20references=20fro?= =?UTF-8?q?m=20project?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- AGENTS.md | 2 - README.md | 1 - docs/INSTALLATION.md | 3 - paperforge.json | 1 - .../worker/scripts/literature_pipeline.py | 2 +- scripts/setup.py | 30 +------ scripts/validate_setup.py | 4 +- setup_wizard.py | 1 - templates/科研读图指南.md | 81 ------------------- update.py | 2 +- 10 files changed, 5 insertions(+), 122 deletions(-) delete mode 100644 templates/科研读图指南.md diff --git a/AGENTS.md b/AGENTS.md index ce71dfb9..b67e9142 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -92,8 +92,6 @@ Zotero 添加文献 │ │ │ └── figure-map.json ← 图表索引(自动创建) │ │ └── worker/scripts/ │ │ └── literature_pipeline.py ← 核心脚本 -│ ├── Template/ -│ │ └── 科研读图指南.md ← 图表阅读参考 │ └── Zotero/ ← Junction/Symlink 到 Zotero 数据目录 │ ├── .opencode/ ← OpenCode Agent 配置(自动创建) diff --git a/README.md b/README.md index baa32684..0d965eec 100644 --- a/README.md +++ b/README.md @@ -48,7 +48,6 @@ python setup.py - [安装指南](docs/INSTALLATION.md) - [使用指南](docs/USAGE.md) -- [读图指南](99_System/Template/科研读图指南.md) ## License diff --git a/docs/INSTALLATION.md b/docs/INSTALLATION.md index 679354cc..0ad607d3 100644 --- a/docs/INSTALLATION.md +++ b/docs/INSTALLATION.md @@ -115,9 +115,6 @@ Copy the following files from the repository to your vault: # Copy scripts cp -r scripts/* "{vault_path}/99_System/PaperForge/worker/scripts/" -# Copy templates -cp -r templates/* "{vault_path}/99_System/Template/" - # Copy AGENTS.md cp AGENTS.md "{vault_path}/AGENTS.md" ``` diff --git a/paperforge.json b/paperforge.json index f02335e7..e629278c 100644 --- a/paperforge.json +++ b/paperforge.json @@ -21,7 +21,6 @@ "updateable_paths": [ "skills/", "pipeline/", - "templates/", "command/", "scripts/" ], diff --git a/pipeline/worker/scripts/literature_pipeline.py b/pipeline/worker/scripts/literature_pipeline.py index 8d00d774..45e8fe03 100644 --- a/pipeline/worker/scripts/literature_pipeline.py +++ b/pipeline/worker/scripts/literature_pipeline.py @@ -2391,7 +2391,7 @@ PROTECTED_PATHS = { "99_System/PaperForge/candidates", ".env", "AGENTS.md", } -UPDATEABLE_PATHS = ["skills", "pipeline", "templates", "command", "scripts"] +UPDATEABLE_PATHS = ["skills", "pipeline", "command", "scripts"] def _color(text: str, c: str = "") -> str: diff --git a/scripts/setup.py b/scripts/setup.py index c1c1dd47..52b5004f 100644 --- a/scripts/setup.py +++ b/scripts/setup.py @@ -116,8 +116,7 @@ def configure_vault_paths(vault_path: Path) -> dict: # Build derived paths paths["pipeline_path"] = f"{paths['system_dir']}/PaperForge" - paths["template_path"] = f"{paths['system_dir']}/Template" - paths["literature_path"] = f"{paths['resources_dir']}/{paths['literature_dir']}" + paths["literature_path"] = f"{paths['resources_dir']}/{paths['literature_dir']}" return paths @@ -257,9 +256,6 @@ def create_directory_structure(vault_path: Path, paths: dict) -> None: f"{paths['pipeline_path']}/indexes", f"{paths['pipeline_path']}/exports", - # Template directories - f"{paths['template_path']}", - # Zotero junction point f"{paths['system_dir']}/Zotero", @@ -293,7 +289,7 @@ def create_env_file(vault_path: Path, config: dict, paths: dict) -> None: "# Path Configuration", f"PAPERFORGE_SYSTEM_DIR={paths['system_dir']}", f"PAPERFORGE_PIPELINE_PATH={paths['pipeline_path']}", - f"PAPERFORGE_TEMPLATE_PATH={paths['template_path']}", + f"PAPERFORGE_RESOURCES_PATH={paths['literature_path']}", f"PAPERFORGE_VAULT_PATH={vault_path}", ] @@ -412,8 +408,6 @@ Zotero 添加文献 │ │ │ └── figure-map.json ← 图表索引(自动创建) │ │ └── worker/scripts/ │ │ └── literature_pipeline.py ← 核心脚本 -│ ├── Template/ -│ │ └── 科研读图指南.md ← 图表阅读参考 │ └── Zotero/ ← Junction/Symlink 到 Zotero 数据目录 │ ├── {agent_config['skill_dir']}/ ← {agent_config['name']} Skill 目录 @@ -831,26 +825,6 @@ def deploy_workflow_scripts(vault_path: Path, agent_key: str, agent_config: dict fail_count += 1 print_success(f"Deployed {len(chart_files)} chart reading guides") - # Deploy template files - template_files = [ - ("templates/科研读图指南.md", - f"{paths['template_path']}/科研读图指南.md"), - ] - - for src_rel, dst_rel in template_files: - src_path = repo_root / src_rel - dst_path = vault_path / dst_rel - - if src_path.exists(): - if safe_copy(src_path, dst_path): - print_success(f"Deployed template: {src_rel}") - success_count += 1 - else: - fail_count += 1 - else: - print_warning(f"Template not found (skipping): {src_rel}") - fail_count += 1 - # Deploy agent commands command_src = repo_root / "command" command_dst = vault_path / ".opencode/command" diff --git a/scripts/validate_setup.py b/scripts/validate_setup.py index 2d3a2985..77aecfb9 100644 --- a/scripts/validate_setup.py +++ b/scripts/validate_setup.py @@ -125,9 +125,7 @@ def validate_ld_deep(vault_path: str) -> list[tuple[bool, str]]: results.append((ok, msg)) # Check chart reading guides - chart_guide_dir = vault_dir / "99_System" / "Template" / "读图指南" - ok, msg = check_path("Chart reading guides directory", chart_guide_dir, "dir") - results.append((ok, msg)) + if ok: # Count guide files diff --git a/setup_wizard.py b/setup_wizard.py index 59cd3a3e..3ca43411 100644 --- a/setup_wizard.py +++ b/setup_wizard.py @@ -985,7 +985,6 @@ python pipeline/worker/scripts/literature_pipeline.py --vault . ### 详细文档 - 安装后指南:`AGENTS.md` -- 图表阅读指南:`99_System/Template/科研读图指南.md` - GitHub: https://github.com/LLLin000/PaperForge """) yield Horizontal( diff --git a/templates/科研读图指南.md b/templates/科研读图指南.md deleted file mode 100644 index 1c11e86d..00000000 --- a/templates/科研读图指南.md +++ /dev/null @@ -1,81 +0,0 @@ -# 科研读图指南 - -## 使用方式 - -在精读 **Figure-by-Figure** 时,识别图表类型,然后加载对应子指南。 - -**识别方法**: -1. 看标题/caption中的关键词 -2. 看图像本身的视觉特征(坐标轴、颜色、几何图形) -3. 如果不确定,参考下方的「图表类型索引」 - ---- - -## 通用检查清单(适用于所有图表) - -在深入类型-specific分析前,先回答这6个问题: - -- [ ] **类型匹配**:图表类型是否匹配作者声称的分析方法?(例如:说做差异分析却用散点图而非箱式图) -- [ ] **样本量**:n值是否标注?每个点/柱/箱代表多少样本? -- [ ] **统计方法**:p值、检验方法、置信区间是否明确? -- [ ] **颜色图例**:是否自解释?色盲友好吗? -- [ ] **坐标轴**:单位、刻度、截断是否合理?(警惕Y轴截断造成的视觉放大) -- [ ] **视觉误导**:是否存在不连续刻度、面积误导、三维透视扭曲等? - ---- - -## 图表类型索引 - -| 图表类型 | 识别关键词 | 子指南文件 | -|---------|-----------|-----------| -| 箱式图 / 小提琴图 | boxplot, violin, quartile, median, IQR | 箱式图与小提琴图 | -| 热图 / 聚类图 | heatmap, clustering, dendrogram, z-score | 热图与聚类图 | -| PCA / t-SNE / UMAP | principal component, embedding, dimensionality reduction | 降维图(PCA-tSNE-UMAP) | -| ROC / PR 曲线 | ROC, AUC, sensitivity, specificity, precision-recall | ROC与PR曲线 | -| 生存曲线 | Kaplan-Meier, survival, hazard ratio, log-rank | 生存曲线 | -| 火山图 / 曼哈顿图 | volcano plot, log2 fold change, -log10 p, GWAS | 火山图与曼哈顿图 | -| 散点图 / 气泡图 | scatter plot, bubble, correlation, regression | 散点图与气泡图 | -| 条形图 / 误差棒 | bar chart, SEM, SD, confidence interval | 条形图与误差棒 | -| GSEA 富集图 | enrichment plot, ES, NES, leading edge | GSEA富集图 | -| 森林图 / Meta 分析 | forest plot, meta-analysis, odds ratio, I2 | 森林图与Meta分析 | -| 雷达图 / 漏斗图 | radar chart, funnel plot, publication bias | 雷达图与漏斗图 | -| 网络图 / 通路图 | network, pathway, PPI, interaction | 网络图与通路图 | -| 桑基图 / 弦图 | Sankey, chord, alluvial, flow | 桑基图与弦图 | -| 蛋白质结构图 | protein structure, PDB, Cryo-EM, X-ray | 蛋白质结构图 | - ---- - -## 进阶:什么时候需要子指南? - -**所有 14 类图表均有子指南**。根据复杂度选择阅读深度: - -**复杂图表**(强烈建议读子指南): -- 热图(聚类、标准化、注释层) -- PCA/t-SNE/UMAP(方差解释、批次效应) -- ROC/PR曲线(截断点、置信区间) -- 生存曲线(删失、比例风险假设) -- GSEA 富集图(ES曲线、Leading Edge、FDR阈值) -- 森林图(异质性、权重、发表偏倚) -- 蛋白质结构图(分辨率、界面、动态性) - -**中等复杂度**(建议读子指南): -- 箱式图/小提琴图(统计检验选择、异常值处理) -- 火山图(多重检验校正、效应量阈值) -- 散点图/气泡图(过绘、假相关、气泡大小误导) -- 条形图/误差棒(SEM vs SD、Y轴截断、多重比较) -- 网络图/通路图(hairball、预测边、Hub偏倚) - -**相对简单但仍建议参考**: -- 雷达图/漏斗图(维度标准化、发表偏倚判断) -- 桑基图/弦图(流量守恒、路径追踪、方向性) - -**通用清单足够**(基础检查): -- 简单的饼图、面积图、折线图 - ---- - -## References - -- Weissgerber et al. (2015). *Beyond bar and line graphs*. PLOS Biology. [DOI:10.1371/journal.pbio.1002128](https://doi.org/10.1371/journal.pbio.1002128) -- Weissgerber et al. (2019). *Reveal, don't conceal*. Circulation. [DOI:10.1161/CIRCULATIONAHA.118.037777](https://doi.org/10.1161/CIRCULATIONAHA.118.037777) -- Krzywinski & Altman (2013). *Visualizing samples with box plots*. Nature Methods. [DOI:10.1038/nmeth.2813](https://doi.org/10.1038/nmeth.2813) diff --git a/update.py b/update.py index b7d084a3..e2c85e6f 100644 --- a/update.py +++ b/update.py @@ -58,7 +58,7 @@ PROTECTED_PATHS = { } # 可更新路径(代码文件) -UPDATEABLE_PATHS = ["skills", "pipeline", "templates", "command", "scripts"] +UPDATEABLE_PATHS = ["skills", "pipeline", "command", "scripts"] # =============================================================================