# How the AI Investment Team Coordinates Parallel Research Across Multiple Perspectives

> Learn how the AI investment team coordinates parallel research using a declarative four-role framework with specialized agents. Discover how they synthesize outputs into auditable investment reports.

- Repository: [Xbt Lin/ai-berkshire](https://github.com/xbtlin/ai-berkshire)
- Tags: how-to-guide
- Published: 2026-07-26

---

**The AI-Berkshire repository implements a declarative four-role framework where a team-lead agent orchestrates specialized sub-agents to execute simultaneous background tasks, synthesizing their outputs into an auditable seven-module investment report.**

The xbtlin/ai-berkshire repository solves the coordination challenge of deep investment research by treating analysis as a parallel computing problem. By implementing a multi-agent architecture defined in [`skills/investment-team.md`](https://github.com/xbtlin/ai-berkshire/blob/main/skills/investment-team.md) and [`skills/investment-research.md`](https://github.com/xbtlin/ai-berkshire/blob/main/skills/investment-research.md), the system enables an AI investment team to coordinate parallel research across multiple perspectives. This approach reduces total research time from serial minutes to the duration of the longest single sub-task while maintaining rigorous data integrity through automated verification.

## The Four-Role Parallel Research Framework

The architecture assigns distinct analytical responsibilities to five specialized agents, each embodying the investment philosophy of a specific master investor. This parallel structure ensures comprehensive coverage without the latency of sequential processing.

### Specialized Agent Roles and Investment Master Lenses

According to the team-framework table on lines 11‑17 of [`skills/investment-team.md`](https://github.com/xbtlin/ai-berkshire/blob/main/skills/investment-team.md), the roles break down as follows:

- **team-lead** (the caller): Orchestrates overall coordination, synthesis, and final report generation using a four-master synthesis lens.
- **business-analyst**: Focuses on business model and moat analysis through the lens of **段永平 (Dan Yong-ping)**.
- **financial-analyst**: Handles financial statements and valuation using **巴菲特 (Warren Buffett)** principles.
- **industry-researcher**: Analyzes industry landscape and competitive dynamics through **芒格 (Charlie Munger)**'s multidisciplinary approach.
- **risk-assessor**: Profiles risks and management team quality following **李录 (Li Lu)** methodology.

## Coordination Flow and Execution Pipeline

The workflow follows seven distinct phases encoded as declarative skill commands that the Claude-Code runtime interprets, eliminating manual scripting requirements.

### Pre-Check and Bias Assessment

Before launching any sub-agent, the team-lead evaluates the target's "AI researchability" through an information-richness rating (A/B/C) and verifies that the `WebSearch` permission is enabled. This validation occurs on lines 21‑48 of [`investment-team.md`](https://github.com/xbtlin/ai-berkshire/blob/main/investment-team.md), preventing silent degradation of agent capabilities due to missing data sources.

### Declarative Team Creation and Task Distribution

The coordination begins with a `TeamCreate` call:

```bash
TeamCreate \
  team_name="<company>-research" \
  agent_type="team-lead"

```

This command, referenced on line 52 of [`investment-team.md`](https://github.com/xbtlin/ai-berkshire/blob/main/investment-team.md), instantiates the coordination namespace. Following team creation, four `TaskCreate` calls generate parallel jobs for business-model analysis, financial valuation, industry analysis, and risk assessment (lines 55‑98).

### Parallel Execution with Background Agents

Each sub-agent launches with `run_in_background:true` set in the same message (lines 14‑16), enabling true concurrency rather than sequential execution. The agents receive role-specific prompt templates (lines 21‑34) that mandate:

- Use of `WebSearch` for latest data retrieval.
- Pulling two independent data sources as specified in [`skills/financial-data.md`](https://github.com/xbtlin/ai-berkshire/blob/main/skills/financial-data.md).
- Aborting or flagging the task if web search fails (lines 34‑35).

### Real-Time Monitoring and Aggregation

The team-lead monitors completion status through progress tables and extracts the top 3‑5 insights from each interim report (lines 48‑50). Once all four analyses complete, the system sends a `shutdown_request` to each sub-agent (line 54) and synthesizes results into the **seven-module structure** defined in [`investment-research.md`](https://github.com/xbtlin/ai-berkshire/blob/main/investment-research.md) (lines 7‑15).

### Data Auditing and Verification

Every numeric claim undergoes cross-validation through [`tools/financial_rigor.py`](https://github.com/xbtlin/ai-berkshire/blob/main/tools/financial_rigor.py) (see verification commands on lines 79‑84 of [`investment-team.md`](https://github.com/xbtlin/ai-berkshire/blob/main/investment-team.md) and lines 68‑73 of [`investment-research.md`](https://github.com/xbtlin/ai-berkshire/blob/main/investment-research.md)). The final report then passes through [`tools/report_audit.py`](https://github.com/xbtlin/ai-berkshire/blob/main/tools/report_audit.py) for a 15 % random-sample audit (lines 99‑108), ensuring programmatic verification of all quantitative assertions before publication.

## Practical Implementation: Code Examples

The following examples demonstrate how to invoke the parallel research framework from the command line or via the Claude-Code API.

### Creating the Team and Launching Parallel Tasks

Execute these commands to establish a research team for a target company (example: Meituan):

```bash

# Create the research team

TeamCreate \
  team_name="meituan-research" \
  agent_type="team-lead"

# Launch four parallel background tasks

TaskCreate \
  team_name="meituan-research" \
  subagent_type="general-purpose" \
  name="business-analyst" \
  subject="分析Meituan商业模式、护城河与用户价值" \
  description="..." \
  activeForm="..." \
  run_in_background=true

TaskCreate \
  team_name="meituan-research" \
  subagent_type="general-purpose" \
  name="financial-analyst" \
  subject="分析Meituan财务数据、盈利能力与估值" \
  description="..." \
  activeForm="..." \
  run_in_background=true

TaskCreate \
  team_name="meituan-research" \
  subagent_type="general-purpose" \
  name="industry-researcher" \
  subject="分析餐饮外卖行业格局与Meituan竞争态势" \
  description="..." \
  activeForm="..." \
  run_in_background=true

TaskCreate \
  team_name="meituan-research" \
  subagent_type="general-purpose" \
  name="risk-assessor" \
  subject="评估Meituan投资风险与管理层质量" \
  description="..." \
  activeForm="..." \
  run_in_background=true

```

*Note: All four `TaskCreate` calls must be sent in a single message to trigger concurrent execution, as specified on lines 11‑13 of [`investment-team.md`](https://github.com/xbtlin/ai-berkshire/blob/main/investment-team.md).*

### Sub-Agent Prompt Templates

Each sub-agent receives a templated prompt forcing role-specific behavior. The business analyst template (excerpt from lines 21‑34) appears as:

```

你是Meituan投研团队中的"商业分析师"，负责从段永平投资视角分析Meituan。
请完成任务 #1：分析Meituan商业模式、护城河与用户价值
...
使用 WebSearch 搜索最新公开信息（财报、行业报告、新闻）
...

```

### Aggregation and Final Reporting

Once sub-agents return results, the team-lead synthesizes and transmits the final output:

```bash

# Mark task completion

TaskUpdate \
  team_name="meituan-research" \
  task_id=1 \
  status="completed"

# Transmit consolidated report

SendMessage \
  type="message" \
  recipient="team-lead" \
  content="$(cat ~/meituan-investment-report_20260726.md)"

```

### Report Auditing Workflow

Validate numeric integrity using the audit toolchain:

```bash

# Extract 15% random sample for verification

python3 tools/report_audit.py extract \
  --report ~/meituan-investment-report_20260726.md

# Generate verdict after populating verification JSON

python3 tools/report_audit.py verdict \
  --results '<filled-json>' \
  --report ~/meituan-investment-report_20260726.md

```

## Key Source Files and Architecture

| File | Function in Parallel Research |
|------|------------------------------|
| [`skills/investment-team.md`](https://github.com/xbtlin/ai-berkshire/blob/main/skills/investment-team.md) | Defines the four-role team structure, bias-rating pre-check, and exact command sequences for team creation, task launching, and aggregation (lines 11‑108). |
| [`skills/investment-research.md`](https://github.com/xbtlin/ai-berkshire/blob/main/skills/investment-research.md) | Provides the seven-module analysis framework (business, moat, risk, etc.) that structures the final aggregated report (lines 7‑15). |
| [`tools/financial_rigor.py`](https://github.com/xbtlin/ai-berkshire/blob/main/tools/financial_rigor.py) | Command-line utility enforcing programmatic verification of market-cap, valuation metrics, and cross-source data consistency (referenced lines 79‑84). |
| [`tools/report_audit.py`](https://github.com/xbtlin/ai-berkshire/blob/main/tools/report_audit.py) | Implements the 15 % random-sample audit for final report numeric integrity (lines 99‑108). |
| [`codex-skills/investment-team/SKILL.md`](https://github.com/xbtlin/ai-berkshire/blob/main/codex-skills/investment-team/SKILL.md) | Codex-compatible wrapper ensuring runtime compatibility with Claude-Code and Codex environments. |

## Summary

- The AI investment team coordinates parallel research through a **declarative multi-agent framework** using `TeamCreate` and `TaskCreate` commands defined in [`skills/investment-team.md`](https://github.com/xbtlin/ai-berkshire/blob/main/skills/investment-team.md).
- **Four specialized sub-agents** operate simultaneously via `run_in_background:true`, each applying distinct investment master lenses (Dan Yong-ping, Warren Buffett, Charlie Munger, Li Lu) to different analytical dimensions.
- **Pre-execution bias assessment** (lines 21‑48) ensures data availability before resource allocation, while `WebSearch` requirements enforce real-time information retrieval.
- **Automated verification chains** using [`tools/financial_rigor.py`](https://github.com/xbtlin/ai-berkshire/blob/main/tools/financial_rigor.py) and [`tools/report_audit.py`](https://github.com/xbtlin/ai-berkshire/blob/main/tools/report_audit.py) guarantee that all numeric claims in the final seven-module report undergo cross-validation and random-sample auditing.
- The architecture reduces research latency to the duration of the longest single sub-task while maintaining strict reproducibility and auditability standards.

## Frequently Asked Questions

### How does the team-lead ensure all sub-agents complete before generating the final report?

The team-lead monitors a real-time progress table (lines 48‑50 of [`investment-team.md`](https://github.com/xbtlin/ai-berkshire/blob/main/investment-team.md)) tracking the completion status of each background task. Only after receiving confirmation messages from all four sub-agents via `SendMessage` does the team-lead trigger the `shutdown_request` commands (line 54) and begin synthesis of the seven-module final report.

### What prevents the parallel agents from returning conflicting data or hallucinations?

Each sub-agent must pull **two independent data sources** and pass outputs through [`tools/financial_rigor.py`](https://github.com/xbtlin/ai-berkshire/blob/main/tools/financial_rigor.py) for programmatic verification (lines 79‑84). Additionally, the final report undergoes a 15 % random-sample audit via [`tools/report_audit.py`](https://github.com/xbtlin/ai-berkshire/blob/main/tools/report_audit.py) (lines 99‑108), which cross-validates numeric claims against fresh source data, ensuring hallucination-free output.

### Can the parallel research framework handle targets with limited public data?

The **pre-check and bias assessment** phase (lines 21‑48) assigns an information-richness rating (A/B/C) before execution. If the target receives a poor rating or lacks `WebSearch` accessibility, the team-lead aborts or flags the task immediately, preventing resource waste on data-scarce targets that cannot support rigorous parallel analysis.

### What is the performance benefit of running agents in parallel rather than sequentially?

By setting `run_in_background:true` (lines 14‑16) and launching all four `TaskCreate` calls in a single message, the system achieves **true concurrency**. This architecture reduces total research time from the sum of all analytical tasks (sequential) to approximately the duration of the longest single sub-task, typically cutting research time by 60‑75 % while maintaining analytical depth.