sync-context
- Repo stars 0
- Author updated Live
- Author repo skills-registry
- Domain
- AI
- Compatible agents
-
- Claude Code
- Cursor
- Cline
- Codex
- Windsurf
- Gemini CLI
- +20
- Trust score
- 88 / 100 · community maintained
- Author / version / license
- @tomevault-io · no license declared
- Token usage
- Lean
- Setup complexity
- Manual integration
- External API key
- Not required
- Operating systems
- Docker
- Runtime requirements
- Node.js · Python · Docker
- Permissions
-
- Read-only
- Write / modify
- Shell exec
- Env read
- Network behavior
- Local-only
- Install commands
- 26 variants
Profile is derived at build time from SKILL.md and install vectors. Subject to drift from author intent.
Heads up: 未限定 allowed-tools,默认拥有全部工具权限。
---
name: sync-context
description: | Use when this capability is needed. Analyzes codebase and intelligently updates .github/copilo…
category: ai
runtime: Node.js / Python / Docker
---
# sync-context output preview
## PART A: Task fit
- Use case: | Use when this capability is needed. Analyzes codebase and intelligently updates .github/copilot-instructions.md with current project context. /sync-context # Full analysis and update runs entirely locally; runs on Node.js. Works with Claude Code, Cursor, Cline and 23 more..
- Inputs: target material, constraints, expected output, and acceptance criteria.
- Evidence boundary: follow “Usage / What It Does / Analysis Process” and do not present inference as author intent.
## PART B: Execution result
- **01** The card summarizes the use case; runtime output centers on “| Use when this capability is needed. Analyzes codebase and intelligently updates .github/copilot-instructions.md with current project context. /sync-context # Full analysis and update runs entirely locally; runs on Node.js. Works with Claude Code, Cursor, Cline and 23 more.”.
- **02** When the source has headings, the agent prioritizes “Usage / What It Does / Analysis Process” so the result follows the author’s structure.
- **03** Typical output includes task judgment, concrete steps, required commands or file edits, validation, and follow-up options.
- **04** Risk context follows the fingerprint: read files, write/modify files, run shell commands, read environment variables; mostly runs locally; usually needs no extra API key.
## Running Rules
- read files, write/modify files, run shell commands, read environment variables; mostly runs locally; usually needs no extra API key.
- Validate with a small sample before expanding scope.
- Return the result, validation criteria, and next iteration options. The source mentions slash commands such as `/sync-context`, `/build-feature`, `/memory`, `/help`; use them first when your agent supports command triggers.
Name target files or source material, expected output, forbidden changes, and whether network or shell access is allowed. Permission fingerprint: read files, write/modify files, run shell commands, read environment variables.
Start with a small task and check whether the result follows “Usage / What It Does / Analysis Process”. Inspect diffs, logs, previews, or tests before expanding scope.
Confirm the final output includes a concrete result, evidence, and next action. If it stays generic, tighten inputs, boundaries, and acceptance criteria.
---
name: sync-context
description: | Use when this capability is needed. Analyzes codebase and intelligently updates .github/copilo…
category: ai
source: tomevault-io/skills-registry
---
# sync-context
## When to use
- | Use when this capability is needed. Analyzes codebase and intelligently updates .github/copilot-instructions.md with…
- Use it when the task has clear inputs, repeatable steps, and validation criteria.
## What to provide
- Target material, scope, expected result, and forbidden changes.
- Whether network, commands, file writes, or external services are allowed.
## Execution rules
- Organize steps around “Usage / What It Does / Analysis Process” and keep inference separate from source facts.
- read files, write/modify files, run shell commands, read environment variables; mostly runs locally; usually needs no extra API key.
- Validate with a small sample before expanding the task.
## Output requirements
- Return the deliverable, key evidence, validation method, and next action.
- Mark missing information as unknown; do not invent commands, platforms, or dependencies. The author source anchors workflow facts; repository files anchor sources and commands; Fluxly only adds fit, limitations, and quality judgment.
skill "sync-context" {
input -> user goal + target files + boundaries + acceptance criteria
context -> Usage / What It Does / Analysis Process
rules -> SKILL.md triggers / order / output contract
runtime -> Node.js / Python / Docker | read files, write/modify files, run shell commands, read environment variables | mostly runs locally
guardrails -> usually needs no extra API key + small-sample validation + diff/log review
output -> copyable result + checklist + next iteration
} Sync Context Command
Analyzes codebase and intelligently updates .github/copilot-instructions.md with current project context.
Usage
/sync-context # Full analysis and update
/sync-context --section agents # Update specific section
/sync-context --dry-run # Preview changes without saving
What It Does
- Analyzes current codebase structure
- Extracts patterns, conventions, and architecture
- Merges with existing copilot-instructions.md content
- Preserves manual customizations
- Updates sections that need refresh
Analysis Process
Step 1: Scan Codebase Structure
# Discover project structure
Glob("**/*.py") # Python files
Glob("**/*.ts") # TypeScript files
Glob("**/package.json") # Node projects
Glob("**/pyproject.toml") # Python projects
Glob("**/Dockerfile") # Container configs
Glob("**/*.tf") # Terraform
Step 2: Extract Patterns
# Code patterns
Grep("@dataclass") # Dataclass usage
Grep("class.*Parser") # Parser patterns
Grep("def test_") # Test patterns
Grep("async def") # Async patterns
# Architecture patterns
Grep("from src") # Import structure
Grep("@router") # API patterns
Grep("@lambda_handler") # Lambda patterns
Step 3: Analyze Agents
# List available agents
Glob(".github/agents/*.agent.md")
# Categorize by name prefix
- workflow-* → SDD pipeline agents (brainstorm, define, design, build, ship, iterate)
- architect-* → System design (schema, pipeline, lakehouse, genai, the-planner)
- cloud-* → AWS, GCP, CI/CD, deployment agents
- fabric-* → Microsoft Fabric specialists
- python-* → Code review, clean, document, prompt engineering
- test-* → Testing, data quality, data contracts
- de-* → Data engineering: Spark, dbt, Airflow, Lakeflow, streaming, SQL
- dev-* → Codebase explorer, meeting analyst, prompt crafter
Step 4: Merge Updates
# Sections to update
- Project Structure (from scan)
- Coding Standards (from patterns)
- Agent Usage (from agent analysis)
- Commands (from commands/)
- Environment (from config files)
# Sections to preserve
- Project Context (manual)
- Core Mission (manual)
- Important Dates (manual)
- Getting Help (manual)
copilot-instructions.md Template
Generated .github/copilot-instructions.md follows this structure:
# {Project Name}
## Project Context
{Manual: What this project does and why}
---
## Architecture Overview
{Auto-generated from codebase scan}
```text
{Data flow diagram}
| Stage | Technology | Purpose |
|---|---|---|
| {stage} | {tech} | {purpose} |
Project Structure
{Auto-generated from Glob scans}
{project}/
├── src/
│ ├── {folders discovered}
├── tests/
├── .github/
│ ├── agents/
│ ├── kb/
│ ├── sdd/
│ ├── skills/
│ └── storage/
Agent Usage Guidelines
{Auto-generated from agents/ folder}
Available Agents by Category
| Category | Agents | Use When |
|---|---|---|
| Workflow | brainstorm-agent, define-agent, ... | Building features with SDD |
| Code Quality | python-code-reviewer, test-generator, ... | Improving code |
| {category} | {agents} | {trigger} |
Coding Standards
{Auto-generated from detected patterns}
Language: {Python/TypeScript/etc}
- Version: {detected from config}
- Style: {detected patterns}
- Testing: {detected framework}
Detected Patterns
| Pattern | Usage | Example File |
|---|---|---|
| {pattern} | {where used} | {file path} |
Commands
{Auto-generated from commands/ folder}
| Command | Purpose |
|---|---|
| /build-feature | Full SDD pipeline |
| /memory | Save session insights |
| {command} | {purpose} |
Environment Variables
{Auto-generated from .env.example, config files}
| Variable | Purpose |
|---|---|
| {var} | {purpose} |
MCP Tools Available
{Auto-generated from settings}
| MCP Server | Purpose |
|---|---|
| context7-mcp | Library documentation |
| exa | Code context search |
| {mcp} | {purpose} |
Important Dates
{Manual: Project-specific dates}
Getting Help
{Auto-generated from structure}
- Documentation: Start with relevant docs
- Agents: Review .github/agents/
- Commands: Use /help for available commands
---
## Section Update Rules
| Section | Source | Update Mode |
| ------- | ------ | ----------- |
| Project Context | Manual | Preserve |
| Architecture | Codebase scan | Replace |
| Project Structure | Glob patterns | Replace |
| Agent Usage | agents/ folder | Replace |
| Coding Standards | Pattern detection | Merge |
| Commands | commands/ folder | Replace |
| Environment | Config files | Merge |
| MCP Tools | settings.json | Replace |
| Important Dates | Manual | Preserve |
| Getting Help | Structure | Replace |
**Replace**: Fully regenerate from source
**Merge**: Add new, preserve custom
**Preserve**: Never auto-modify
---
## Execution Flow
```text
1. Read existing .github/copilot-instructions.md
│
▼
2. Parse into sections
│
▼
3. Analyze codebase (parallel)
├── Glob for structure
├── Grep for patterns
├── Read config files
└── List agents/commands
│
▼
4. Generate new sections
│
▼
5. Apply update rules
├── Replace auto sections
├── Merge semi-auto sections
└── Preserve manual sections
│
▼
6. Validate (dry-run or save)
│
▼
7. Write updated .github/copilot-instructions.md
Example Output
UPDATE .github/copilot-instructions.md
━━━━━━━━━━━━━━━━
Analyzing codebase...
✓ Found 47 Python files
✓ Found 12 test files
✓ Found 28 agents
✓ Found 8 commands
Detected patterns:
✓ Dataclass pattern (15 usages)
✓ Parser pattern (4 files)
✓ Generator pattern (8 usages)
Section updates:
• Architecture: UPDATED (new components detected)
• Project Structure: UPDATED (3 new folders)
• Agent Usage: UPDATED (2 new agents)
• Coding Standards: MERGED (1 new pattern)
• Commands: UPDATED (1 new command)
• Project Context: PRESERVED (manual content)
━━━━━━━━━━━━━━━━
.github/copilot-instructions.md updated successfully
Flags
| Flag | Description |
|---|---|
--dry-run |
Preview changes without saving |
--section {name} |
Update only specific section |
--force |
Replace all sections (ignores preserve rules) |
--verbose |
Show detailed analysis |
Best Practices
When to Run
- After adding new agents or commands
- After significant architecture changes
- After adding new file types
- When onboarding new team members
What to Customize
After running, manually update:
- Project Context - Add business context
- Important Dates - Add milestone dates
- Architecture - Add business-specific details
- Coding Standards - Add team conventions
Version Control
# Review changes before committing
git diff .github/copilot-instructions.md
# Commit with context
git add .github/copilot-instructions.md
git commit -m "chore: update copilot-instructions.md with latest project structure"
Source: Arthur1511/agentspec-copilot — distributed by TomeVault.
Decide Fit First
Design Intent
How To Use It
Boundaries And Review