How titanwings/colleague-skill works
1. What this repository is
- colleague.skill is not a conventional app; it is an AgentSkills/Claude Code skill package that generates other skills.
- The repository’s output is a per-person “colleague skill” made of two parts: Work Skill and Persona.
2. Primary entry point
- SKILL.md is the skill entry point consumed by Claude Code / AgentSkills.
- The repo is designed to be installed under .claude/skills/create-colleague, which makes the skill available as /create-colleague.
3. Core generation pipeline
- The flow is: collect source material → analyze work/persona → build skill files → write into colleagues/ → archive versions.
- The generated artifacts are the actual runtime output of the system; everything else supports producing and evolving them.
4. Source ingestion layer
- The repo supports multiple input boundaries:
- Feishu: API-based auto collection and browser/MCP-based collection
- DingTalk: browser-based collection
- Slack: API-based collection
- Email: .eml / .mbox parsing
- Manual inputs: PDF, images/screenshots, JSON export, Markdown, pasted text
- WeChat exports: parsed from external open-source export formats
- These are handled by the scripts in tools/, each targeting a different external source shape.
5. Normalization and parsing boundary
- Collectors and parsers convert heterogeneous source material into a common form suitable for prompting.
- This boundary is important because the system is explicitly designed to mix chat logs, docs, spreadsheets, screenshots, and subjective descriptions into one downstream synthesis process.
6. Analysis layer
- The prompts/ directory contains the system’s reasoning templates:
- intake.md for guided information gathering
- work_analyzer.md for extracting technical/work behavior
- persona_analyzer.md for extracting personality traits and translating tags
- correction_handler.md for applying conversational corrections
- This layer is where the system separates capability modeling from style/personality modeling.
7. Skill construction layer
- work_builder.md and persona_builder.md define how analyzed material becomes the final skill contents.
- The resulting skill is intentionally split into:
- Work Skill: knowledge, standards, workflows, and domain habits
- Persona: a five-layer behavioral model from hard rules to interpersonal tone
- This split is central to the architecture because execution is described as: persona decides attitude, work skill executes, output is in their voice.
8. Incremental update and merge logic
- merger.md defines how new evidence is appended without overwriting prior conclusions.
- The repo treats new inputs as deltas rather than full regenerations, which preserves accumulated knowledge and allows the skill to evolve over time.
9. Versioning and rollback
- tools/version_manager.py provides archive/rollback behavior.
- Every update can be versioned, and older versions can be restored, making the generated skills behave more like a maintained knowledge base than a one-shot export.
10. Generated skill storage
- colleagues/ contains example/generated colleague skill directories.
- Each skill directory follows the same internal shape: metadata plus separate persona.md and work.md content, which mirrors the two-part architecture described above.
11. Automation and service integration
- The tools/ directory is the operational layer:
- Feishu: feishu_auto_collector.py, feishu_browser.py, feishu_mcp_client.py, feishu_parser.py
- DingTalk: dingtalk_auto_collector.py
- Slack: slack_auto_collector.py
- Email: email_parser.py
- Skill output writing: skill_writer.py
- These scripts are the bridge between external collaboration systems and the generated skill repository.
12. Documentation and product surface
- docs/PRD.md, READMEs in multiple languages, INSTALL.md, and ROADMAP.md define the product boundaries and intended workflow, but they are not runtime components.
- The repo also includes CI (.github/workflows/ci.yml) and contribution templates, indicating a community-maintained generator rather than a closed internal tool.
13. Architecture summary for a diagram
- A clear diagram should show:
- External knowledge sources on the left
- Collectors/parsers in the middle
- Prompt-driven analyzers/builders as the synthesis core
- Skill writer + version manager as persistence/governance
- Generated colleague skills in colleagues/ as the output layer
- The key boundary is between raw human communication artifacts and structured, versioned skill artifacts.
Main entry points: intake.md Intake · merger.md Merger · skill_writer.py Skill writer · colleagues Colleagues
Components 22
External sources
Human communication and document inputs collected from collaboration systems and manual artifacts.
- Feishu · Chat and document source collected via API, browser, or MCP.
- DingTalk · Messaging source collected through browser automation.
- Slack · Workspace messages collected through API automation.
- Email · Mail inputs parsed from EML and MBOX archives.
- Manual inputs · PDFs, screenshots, JSON exports, markdown, and pasted text.
- WeChat exports · Imported chat exports from external open-source formats.
Ingestion
Collectors and parsers that normalize heterogeneous inputs into promptable material.
- Feishu tools · Auto collector, browser, MCP client, and parser for Feishu data.
tools/feishu_auto_collector.py - DingTalk collector · Browser-based DingTalk ingestion.
tools/dingtalk_auto_collector.py - Slack collector · Slack API ingestion pipeline.
tools/slack_auto_collector.py - Email parser · Parses mailbox and message files into normalized evidence.
tools/email_parser.py
Synthesis
Prompt-driven analysis and construction of the two-part colleague skill.
- Intake · Guided information gathering and evidence shaping.
prompts/intake.md - Work analyzer · Extracts technical ability, workflows, standards, and habits.
prompts/work_analyzer.md - Persona analyzer · Extracts personality traits and translates tags into a behavioral model.
prompts/persona_analyzer.md - Merger · Appends new evidence as deltas without overwriting prior conclusions.
prompts/merger.md - Work builder · Converts analyzed work evidence into the final work skill content.
prompts/work_builder.md - Persona builder · Converts persona analysis into the layered behavioral model.
prompts/persona_builder.md
Output
Generated colleague skill packages and versioned artifacts.
- Skill writer · Writes generated persona and work files into colleague skill folders.
tools/skill_writer.py - Version manager · Archives, restores, and rolls back generated skill versions.
tools/version_manager.py - Colleagues · Versioned colleague skill packages containing meta, persona, and work files.
colleagues
Ops
Documentation, workflow, and repository governance around the generator.
Connections 24
- Feishu → Feishu tools: ingest · Feishu data is collected and parsed into normalized evidence.
- DingTalk → DingTalk collector: ingest · DingTalk messages are captured through browser automation.
- Slack → Slack collector: ingest · Slack messages are fetched through API-based collection.
- Email → Email parser: parse · Mailbox artifacts are converted into structured evidence.
- Manual inputs → Intake: prompt · Manual materials are guided into the intake flow.
- WeChat exports → Intake: prompt · WeChat exports are normalized through the intake path.
- Feishu tools → Intake: normalize · Collected Feishu evidence is prepared for prompting.
- DingTalk collector → Intake: normalize · Collected DingTalk evidence is prepared for prompting.
- Slack collector → Intake: normalize · Collected Slack evidence is prepared for prompting.
- Email parser → Intake: normalize · Parsed email evidence enters the shared intake boundary.
- Intake → Work analyzer: analyze · Guided intake feeds work extraction.
- Intake → Persona analyzer: analyze · Guided intake feeds persona extraction.
- Work analyzer → Merger: delta · Work conclusions are merged with prior evidence.
- Persona analyzer → Merger: delta · Persona conclusions are merged with prior evidence.
- Merger → Work builder: build · Merged evidence is shaped into the work skill.
- Merger → Persona builder: build · Merged evidence is shaped into the persona model.
- Work builder → Skill writer: write · Final work content is emitted to skill files.
- Persona builder → Skill writer: write · Final persona content is emitted to skill files.
- Skill writer → Colleagues: persist · Generated colleague skill directories are written to storage.
- Colleagues → Version manager: archive · Generated skills are versioned for rollback and restoration.
- Version manager → Colleagues: restore · Older versions can be recovered into the live output set.
- SKILL.md → Intake: entry · The skill entry point launches the generation workflow.
- Docs → SKILL.md: describe · Product docs define usage, workflow, and boundaries.
- CI → Skill writer: validate · CI checks the generator and emitted artifacts.