AGENT SKILL
add-source-parser
Step-by-step scaffold for adding a new coding-agent source to the gateway.
- License 许可
- MIT
- 最近更新
- 2026-07-02
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- add-source-parser
- description
- Step-by-step scaffold for adding a new coding-agent source to the gateway.
03 SKILL.md 正文
Add Source Parser
When to use
Use any time a new agent source (e.g., a new CLI tool) needs to be captured. Triggered by requests like "add support for X CLI", "capture Y's session files".
Key files
src/sources/<agent>/discover.ts,collect.ts,index.ts,<agent>.constants.tssrc/services/contract/contract.constants.ts(SOURCE_VARIANTS)src/services/polling/default-sources.ts,poll-worker.ts
Common pitfalls
- Using
**/*.jsonlinstead of a pinned-depth glob. - Forgetting to add the
SOURCE_VARIANTSentry —validateRawRecordDTOwill reject the DTO silently at runtime. - Not implementing
consecutive_errorstracking in the catch block. - Not handling VACUUM detection if the source is sqlite-based.
- Opening a live sqlite directly instead of using
snapshotSqlite(for sources the agent writes to concurrently). - Using
anyin the type signatures — prohibited across the codebase.
04 同仓库更多 Skills
redaction-validator
Test that a new or modified redaction rule fires on the target pattern without matching any preserved token.
★ 0
audit-sqlite-usage
Audit all bun:sqlite call sites for correctness against the rules in bun-sqlite.md and cross-platform.md.
★ 0
sample-skill
Example skill
★ 0