diff --git a/automation/add_md_separators.py b/automation/add_md_separators.py index e2c8059..677fd17 100644 --- a/automation/add_md_separators.py +++ b/automation/add_md_separators.py @@ -3,7 +3,7 @@ 在 Markdown 的 H2 标题前插入分隔线,第一个除外 """ -MD_PATH = "/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年/final-article.md" +MD_PATH = "/root/openclaw-workspace/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年/final-article.md" with open(MD_PATH, "r", encoding="utf-8") as f: lines = f.readlines() diff --git a/automation/add_separators.py b/automation/add_separators.py index 36800ae..4a6e594 100644 --- a/automation/add_separators.py +++ b/automation/add_separators.py @@ -5,7 +5,7 @@ import re -HTML_PATH = "/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年/article-optimized.html" +HTML_PATH = "/root/openclaw-workspace/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年/article-optimized.html" with open(HTML_PATH, "r", encoding="utf-8") as f: html = f.read() diff --git a/automation/compress_images.py b/automation/compress_images.py index 30be55d..58482d3 100644 --- a/automation/compress_images.py +++ b/automation/compress_images.py @@ -7,8 +7,8 @@ import os from PIL import Image -IMAGES_DIR = "/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/content/publishing/images" -OUTPUT_DIR = "/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/content/publishing/images_compressed" +IMAGES_DIR = "/root/openclaw-workspace/projects/yu-zhi-ran/content/publishing/images" +OUTPUT_DIR = "/root/openclaw-workspace/projects/yu-zhi-ran/content/publishing/images_compressed" os.makedirs(OUTPUT_DIR, exist_ok=True) diff --git a/automation/generate_docx.py b/automation/generate_docx.py index 973e3f6..bd2acc5 100644 --- a/automation/generate_docx.py +++ b/automation/generate_docx.py @@ -10,9 +10,9 @@ from docx.shared import Inches, Pt, RGBColor from docx.enum.text import WD_ALIGN_PARAGRAPH # 路径配置 -MARKDOWN_FILE = "/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年/final-article.md" -IMAGES_DIR = "/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/content/publishing/images" -OUTPUT_DOCX = "/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年/上海阳台种菜一年_最终版.docx" +MARKDOWN_FILE = "/root/openclaw-workspace/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年/final-article.md" +IMAGES_DIR = "/root/openclaw-workspace/projects/yu-zhi-ran/content/publishing/images" +OUTPUT_DOCX = "/root/openclaw-workspace/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年/上海阳台种菜一年_最终版.docx" # 读取 Markdown with open(MARKDOWN_FILE, "r", encoding="utf-8") as f: diff --git a/automation/generate_docx_fixed.py b/automation/generate_docx_fixed.py index 2a05882..e1272f0 100644 --- a/automation/generate_docx_fixed.py +++ b/automation/generate_docx_fixed.py @@ -8,7 +8,7 @@ from docx import Document from docx.shared import Inches, Pt from docx.enum.text import WD_ALIGN_PARAGRAPH -BASE_DIR = "/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年" +BASE_DIR = "/root/openclaw-workspace/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年" MD_FILE = os.path.join(BASE_DIR, "final-article.md") IMAGES_DIR = os.path.join(BASE_DIR, "images") # 已复制的图片 OUTPUT_DOCX = os.path.join(BASE_DIR, "上海阳台种菜一年_最终版.docx") diff --git a/automation/generate_html_fixed.py b/automation/generate_html_fixed.py index 914d3e8..99976e5 100644 --- a/automation/generate_html_fixed.py +++ b/automation/generate_html_fixed.py @@ -6,7 +6,7 @@ import os import re -BASE_DIR = "/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年" +BASE_DIR = "/root/openclaw-workspace/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年" MD_FILE = os.path.join(BASE_DIR, "final-article.md") OUT_HTML = os.path.join(BASE_DIR, "上海阳台种菜一年_可复制.html") diff --git a/automation/generate_html_inline.py b/automation/generate_html_inline.py index f7c8f60..c6d6bd9 100644 --- a/automation/generate_html_inline.py +++ b/automation/generate_html_inline.py @@ -7,7 +7,7 @@ import os import re import base64 -BASE_DIR = "/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年" +BASE_DIR = "/root/openclaw-workspace/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年" MD_FILE = os.path.join(BASE_DIR, "final-article.md") IMAGES_DIR = os.path.join(BASE_DIR, "images") # 使用发布目录内的 images OUT_HTML = os.path.join(BASE_DIR, "上海阳台种菜一年_内联.html") diff --git a/automation/generate_optimized_md.py b/automation/generate_optimized_md.py index 9ae57ca..1e83d75 100644 --- a/automation/generate_optimized_md.py +++ b/automation/generate_optimized_md.py @@ -10,7 +10,7 @@ import os import re -BASE_DIR = "/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年" +BASE_DIR = "/root/openclaw-workspace/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年" MD_FILE = os.path.join(BASE_DIR, "final-article.md") OUT_MD = os.path.join(BASE_DIR, "final-article-optimized.md") diff --git a/automation/make_final_docx.sh b/automation/make_final_docx.sh index 3055c5c..cc1015d 100755 --- a/automation/make_final_docx.sh +++ b/automation/make_final_docx.sh @@ -6,7 +6,7 @@ from docx import Document from docx.shared import Inches, Pt from docx.enum.text import WD_ALIGN_PARAGRAPH -BASE_DIR = "/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年" +BASE_DIR = "/root/openclaw-workspace/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年" MD_FILE = os.path.join(BASE_DIR, "final-article-optimized.md") IMAGES_DIR = os.path.join(BASE_DIR, "images") OUTPUT_DOCX = os.path.join(BASE_DIR, "上海阳台种菜一年_发布版.docx") diff --git a/automation/make_final_html.sh b/automation/make_final_html.sh index d2fc376..0abf2bd 100644 --- a/automation/make_final_html.sh +++ b/automation/make_final_html.sh @@ -3,7 +3,7 @@ python3 - << 'PYEOF' import os, re, base64 -BASE_DIR = "/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年" +BASE_DIR = "/root/openclaw-workspace/projects/yu-zhi-ran/content/published/2026-04-14-上海阳台种菜一年" MD_FILE = os.path.join(BASE_DIR, "final-article-optimized.md") IMAGES_DIR = os.path.join(BASE_DIR, "images") OUT_HTML = os.path.join(BASE_DIR, "上海阳台种菜一年_发布版.html") diff --git a/automation/publish_to_wechat_mp.sh b/automation/publish_to_wechat_mp.sh index 7f6f904..d1e8675 100755 --- a/automation/publish_to_wechat_mp.sh +++ b/automation/publish_to_wechat_mp.sh @@ -6,7 +6,7 @@ set -e PROJECT_ROOT="/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran" -SESSION_STATE="/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/automation/wechat_state.json" +SESSION_STATE="/root/openclaw-workspace/projects/yu-zhi-ran/automation/wechat_state.json" if [ $# -ne 2 ]; then echo "用法: $0 " diff --git a/automation/wechat_fill.js b/automation/wechat_fill.js index a10e85c..c5b1204 100644 --- a/automation/wechat_fill.js +++ b/automation/wechat_fill.js @@ -58,7 +58,7 @@ if (!editor) { } // 上传封面图(如需自动上传) -const coverPath = "/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/content/publishing/images/05-封面图.png"; +const coverPath = "/root/openclaw-workspace/projects/yu-zhi-ran/content/publishing/images/05-封面图.png"; console.log("📸 封面上传:请手动点击编辑器图片按钮,选择封面图文件"); console.log(" 文件路径:", coverPath); diff --git a/automation/wechat_fill_ready.js b/automation/wechat_fill_ready.js index 8d68562..29132af 100644 --- a/automation/wechat_fill_ready.js +++ b/automation/wechat_fill_ready.js @@ -313,7 +313,7 @@ if (!editor) { } // 提示封面上传 -const coverPath = "/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/content/publishing/images/05-封面图.png"; +const coverPath = "/root/openclaw-workspace/projects/yu-zhi-ran/content/publishing/images/05-封面图.png"; console.log("\n📸 封面上传:"); console.log(" 1. 点击编辑器工具栏的图片按钮(🖼️)"); console.log(" 2. 选择 '上传图片'"); diff --git a/platform/backend/run.sh b/platform/backend/run.sh old mode 100644 new mode 100755 diff --git a/scripts/fix_collector.py b/scripts/fix_collector.py index 4644d3c..84757d0 100644 --- a/scripts/fix_collector.py +++ b/scripts/fix_collector.py @@ -6,7 +6,7 @@ Collector 修复脚本 import sys import os -sys.path.insert(0, '/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/platform/backend') +sys.path.insert(0, '/root/openclaw-workspace/projects/yu-zhi-ran/platform/backend') from app.models import Topic from datetime import datetime diff --git a/scripts/strategy_topics_to_json.py b/scripts/strategy_topics_to_json.py index 2502622..6c3ff1f 100644 --- a/scripts/strategy_topics_to_json.py +++ b/scripts/strategy_topics_to_json.py @@ -24,7 +24,7 @@ topics = [ {"id":"D05","title":"科技与自然共生:如何用AI让阳台农场更'自然'","field":"科技人文交叉","format":"理念 + 实操方案","core_concept":"对比荷兰智能温室与中国人'回归原始'误区,实现技术隐形化(传感器+提醒)+ 自然反馈闭环 + 人工仪式感","audience_pain":"想用科技但又怕失去'自然感',追求矛盾","unique_angle":"技术与情感连接的平衡方案,AI只做幕后,人工保留仪式","priority":"高","priority_score":10,"total_score":48,"status":"待处理","cases":[],"source_file":"strategy/全球-本土比较研究与全新内容战略规划-2026-04-15.md","created_at":datetime.datetime.now().isoformat()} ] -with open(OUTPUT_FILE:= '/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/automation/data/sustainability_topics.json', 'w', encoding='utf-8') as f: +with open(OUTPUT_FILE:= '/root/openclaw-workspace/projects/yu-zhi-ran/automation/data/sustainability_topics.json', 'w', encoding='utf-8') as f: json.dump(topics, f, ensure_ascii=False, indent=2) print(f"✅ 已创建全新选题库:{len(topics)} 个选题") diff --git a/tests/test_run_creator.py b/tests/test_run_creator.py index c065453..71f4498 100644 --- a/tests/test_run_creator.py +++ b/tests/test_run_creator.py @@ -1,6 +1,6 @@ #!/usr/bin/env python3 import sys -sys.path.insert(0, '/root/.openclaw/workspaces/yzr-yxl/projects/yu-zhi-ran/platform/backend') +sys.path.insert(0, '/root/openclaw-workspace/projects/yu-zhi-ran/platform/backend') from app.core.generator import run_creator result = run_creator('A05') print('RESULT:', result)