Loading...
Loading...
Compare original and translation side by side
| Method | Recommended Language | Rationale |
|---|---|---|
| Topic Models (LDA, STM) | R | |
| Dictionary/Sentiment | R | tidytext workflow is elegant; great lexicon support |
| Visualization | R | ggplot2 produces publication-ready figures |
| Transformers/BERT | Python | HuggingFace ecosystem, GPU support |
| BERTopic | Python | Neural topic modeling, only in Python |
| Named Entity Recognition | Python | spaCy is industry standard |
| Supervised Classification | Either | sklearn and tidymodels both excellent |
| Word Embeddings | Python | gensim more mature; sentence-transformers |
| 方法 | 推荐语言 | 理由 |
|---|---|---|
| 主题模型(LDA、STM) | R | |
| 词典/情感分析 | R | tidytext工作流简洁优雅,支持丰富的词库 |
| 可视化 | R | ggplot2可生成符合发表标准的图表 |
| Transformer/BERT | Python | HuggingFace生态完善,支持GPU加速 |
| BERTopic | Python | 神经主题建模工具,仅支持Python |
| 命名实体识别 | Python | spaCy是行业标准工具 |
| 监督式分类 | 两者均可 | sklearn与tidymodels表现同样出色 |
| 词嵌入 | Python | gensim更为成熟,sentence-transformers易用性强 |
Pause: Confirm design with user before corpus preparation.
暂停:在开始语料库准备前,与用户确认设计方案。
Pause: Review corpus characteristics and confirm preprocessing.
暂停:审核语料库特征并确认预处理方案。
Pause: User approves specification before analysis.
暂停:在开始分析前需获得用户对规范方案的认可。
Pause: User reviews results before validation.
暂停:在进入验证阶段前需由用户审核结果。
Pause: User assesses validity before final outputs.
暂停:在生成最终产出前需由用户确认有效性。
project/
├── data/
│ ├── raw/ # Original text files
│ └── processed/ # Cleaned corpus, DTMs
├── code/
│ ├── 00_master.R # or 00_master.py
│ ├── 01_preprocess.R
│ ├── 02_analysis.R
│ └── 03_validation.R
├── output/
│ ├── tables/
│ └── figures/
├── dictionaries/ # Custom lexicons if used
└── memos/ # Phase outputsproject/
├── data/
│ ├── raw/ # 原始文本文件
│ └── processed/ # 清洗后的语料库、文档-词项矩阵
├── code/
│ ├── 00_master.R # 或00_master.py
│ ├── 01_preprocess.R
│ ├── 02_analysis.R
│ └── 03_validation.R
├── output/
│ ├── tables/
│ └── figures/
├── dictionaries/ # 自定义词库(若使用)
└── memos/ # 各阶段产出物concepts/| Guide | Topics |
|---|---|
| Lexicons, custom dictionaries, validation |
| LDA, STM, BERTopic theory and selection |
| Training data, features, evaluation |
| Word2Vec, GloVe, BERT concepts |
| Dictionary vs ML approaches |
| Human coding, diagnostics, robustness |
concepts/| 指南 | 主题 |
|---|---|
| 词库、自定义词典、验证 |
| LDA、STM、BERTopic的理论与选择 |
| 训练数据、特征、评估 |
| Word2Vec、GloVe、BERT概念 |
| 词典法与机器学习法对比 |
| 人工编码、诊断、鲁棒性 |
r-techniques/| Guide | Topics |
|---|---|
| tidytext, quanteda |
| tidytext lexicons, TF-IDF |
| topicmodels, stm |
| tidymodels for text |
| text2vec |
| ggplot2 for text |
r-techniques/| 指南 | 主题 |
|---|---|
| tidytext、quanteda |
| tidytext词库、TF-IDF |
| topicmodels、stm |
| 面向文本的tidymodels |
| text2vec |
| 面向文本的ggplot2 |
python-techniques/| Guide | Topics |
|---|---|
| nltk, spaCy, sklearn |
| VADER, TextBlob |
| gensim, BERTopic |
| sklearn, transformers |
| gensim, sentence-transformers |
| matplotlib, pyLDAvis |
python-techniques/| 指南 | 主题 |
|---|---|
| nltk、spaCy、sklearn |
| VADER、TextBlob |
| gensim、BERTopic |
| sklearn、transformers |
| gensim、sentence-transformers |
| matplotlib、pyLDAvis |
Task: Phase 0 Research Design
subagent_type: general-purpose
model: opus
prompt: Read phases/phase0-design.md and execute for [user's project]Task: Phase 0 Research Design
subagent_type: general-purpose
model: opus
prompt: Read phases/phase0-design.md and execute for [user's project]| Phase | Model | Rationale |
|---|---|---|
| Phase 0: Research Design | Opus | Method selection requires judgment |
| Phase 1: Corpus Preparation | Sonnet | Data processing, descriptives |
| Phase 2: Specification | Opus | Design decisions, parameters |
| Phase 3: Main Analysis | Sonnet | Running models |
| Phase 4: Validation | Sonnet | Systematic diagnostics |
| Phase 5: Output | Opus | Interpretation, writing |
| 阶段 | 模型 | 理由 |
|---|---|---|
| 阶段0:研究设计 | Opus | 方法选择需要专业判断 |
| 阶段1:语料库准备 | Sonnet | 擅长数据处理与描述性统计 |
| 阶段2:方法规范 | Opus | 擅长设计决策与参数制定 |
| 阶段3:主分析 | Sonnet | 擅长模型运行与结果提取 |
| 阶段4:验证 | Sonnet | 擅长系统化诊断分析 |
| 阶段5:产出 | Opus | 擅长结果解读与写作 |
"What are you trying to learn from the text? Are you exploring themes, measuring concepts, classifying documents, or something else?"
"What text data do you have? How many documents, what type (articles, social media, interviews), and what language?"
"Do you have specific methods in mind (topic models, sentiment, classification), or would you like help selecting based on your question?"
"你希望从文本中获取什么信息?是探索主题、测量概念、分类文档,还是其他需求?"
"你拥有什么样的文本数据?文档数量、类型(文章、社交媒体、访谈)以及语言分别是什么?"
"你是否有特定的方法意向(主题模型、情感分析、分类),还是需要根据你的问题协助选择?"