How to Use the /investment-team Skill for Rapid Investment Analysis
The /investment-team skill orchestrates four parallel AI agents to transform a single company name into a fully sourced investment research report in minutes.
The xbtlin/ai-berkshire repository implements this skill as a structured multi-agent workflow defined in skills/investment-team.md. By leveraging parallel background execution and automated data validation, the /investment-team skill eliminates the sequential bottlenecks of traditional investment analysis while maintaining rigorous source verification.
How the Multi-Agent Workflow Works
The skill implements a full-stack research framework through coordinated agent orchestration. According to the source code in skills/investment-team.md, the workflow proceeds through seven distinct phases:
Team Orchestration and Structure
The skill initializes a team-lead agent that coordinates four specialized sub-agents: business-analyst, financial-analyst, industry-researcher, and risk-assessor. Each agent receives distinct mandates covering financial trends, valuation metrics, industry dynamics, and risk assessment respectively.
Pre-Check Validation
Before launching background agents, the skill verifies that the WebSearch permission is enabled (lines 34-48 of skills/investment-team.md). This prevents silent degradation to training-data-only answers and ensures real-time data accessibility.
Parallel Task Creation
The team-lead creates four simultaneous tasks using the TaskCreate tool with run_in_background:true (lines 55-84 and 109-118). Each task prompt includes:
- A localized subject line (e.g., "分析{公司名}财务数据、盈利能力与估值")
- Structured deliverable descriptions
- Mandatory
WebSearchrequirements - Dual-source financial data verification protocols
Execution and Monitoring
Agents execute simultaneously, reporting progress via SendMessage. The team-lead displays a live progress table and waits for all four analyses to complete before proceeding.
Report Synthesis
Once all sub-agents return, the team-lead merges outputs into a single markdown document (lines 158-188) containing:
- A one-sentence investment thesis
- A 4-dimension star rating table
- Core data tables with source citations
- Bull vs. Bear arguments
- A Buffett-style investment checklist
- Suggested price ranges
Final Audit and Cleanup
The completed report passes through tools/report_audit.py for random-sample data validation (lines 199-215). After audit completion, the skill executes TeamDelete to tear down the agent workspace.
Invoking the /investment-team Skill
You can trigger this rapid analysis pipeline through multiple interfaces depending on your environment.
Claude Code Slash Command
For quick interactive use within Claude Code:
/investment-team Apple
Replace Apple with your target company name or ticker symbol. The skill prompts for confirmation, runs the pre-check, and automatically initiates the full research workflow.
Direct API Integration
Send a JSON payload to the skill endpoint:
{
"skill": "investment-team",
"arguments": "Tesla"
}
The response stream delivers real-time progress updates and concludes with the assembled markdown report.
Command-Line Orchestration
For automation or scripting environments:
# Synchronize Codex artefacts
python3 scripts/sync-codex-skills.py
# Trigger via Claude-CLI wrapper
claude --skill investment-team "Alibaba"
CLI execution outputs progress messages to stdout and saves the final report to ~/Alibaba投资研究报告_YYYYMMDD.md as defined in the skill configuration.
Direct Tool Access for Debugging
To reproduce individual sub-tasks or verify calculations manually:
# Verify valuation metrics directly
python3 tools/financial_rigor.py verify-valuation \
--price 150 --eps 5.2 --bvps 30
# Audit an existing report
python3 tools/report_audit.py extract \
--report ~/Alibaba投资研究报告_20260729.md
# Generate audit verdict
python3 tools/report_audit.py verdict \
--results audit_results.json \
--report ~/Alibaba投资研究报告_20260729.md
Key Source Files
The /investment-team skill relies on the following components in the xbtlin/ai-berkshire repository:
skills/investment-team.md– Complete skill definition including team structure, task prompts, and synthesis logic.codex-prompts/investment-team.md– Entry-point prompt enabling the slash command interface for Codex users.tools/financial_rigor.py– Quantitative verification utilities referenced by the financial analyst agent.tools/report_audit.py– Random-sample validation system for final report verification.scripts/sync-codex-skills.py– Build script that regenerates Codex artefacts when source markdown changes.
Summary
- The
/investment-teamskill deploys four specialized agents (business-analyst, financial-analyst, industry-researcher, risk-assessor) in parallel usingTaskCreatewithrun_in_background:true. - A pre-check validates
WebSearchavailability (lines 34-48) before execution to ensure data freshness. - The workflow synthesizes sub-agent outputs into a comprehensive markdown report including star ratings, thesis statements, and valuation ranges (lines 158-188).
- Automated auditing via
tools/report_audit.py(lines 199-215) validates random data samples before workspace cleanup. - Reports can be generated via slash commands, API calls, or CLI scripts, with outputs automatically saved to the filesystem.
Frequently Asked Questions
How long does the /investment-team skill take to generate a report?
Because the four sub-agents execute in parallel rather than sequentially, the entire workflow typically completes in minutes rather than hours. The exact duration depends on WebSearch latency and the complexity of the company's financial disclosures, but the parallel architecture eliminates the linear time accumulation of traditional research processes.
What happens if WebSearch is disabled when running the skill?
The skill implements a hard pre-check (lines 34-48 of skills/investment-team.md) that halts execution if WebSearch permissions are unavailable. This prevents the agents from generating reports based solely on training data, ensuring all outputs contain current, sourced financial information.
Can I customize the analysis prompts or agent roles in the investment-team skill?
The agent definitions and task prompts are hardcoded in skills/investment-team.md (lines 55-84). To modify the research framework, you must edit this source file and regenerate the Codex artefacts using scripts/sync-codex-skills.py. The skill does not expose runtime prompt overrides through the standard slash-command interface.
Where is the final report saved when using CLI invocation?
When triggered via claude --skill investment-team, the skill writes the markdown output to ~/[CompanyName]投资研究报告_YYYYMMDD.md by default. You can inspect this file directly after the TeamDelete operation completes, or use tools/report_audit.py to perform additional validation on the saved document.
Have a question about this repo?
These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:
curl -s "https://instagit.com/install.md" Maintain an open-source project? Get it listed too →