cencon-generate
Skill96 starsChanged 16 days agoMITView on GitHub
Analyze .NET source code and generate CenCon documentation (architecture_manifest.yaml, security_profile.yaml, INDEX.md). Triggers on "/cencon-generate".
We split this skill into the rules it gives an agent
18 rules. About 0 are common, 14 are distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈14
Distinctive · estimate
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 18
All files are created in docs/cencon/:
- Distinctive: line 27
Use Glob to find *.sln files in the repository root
- Distinctive: line 28
Use Glob to find all *.csproj files
- Distinctive: line 29
Read existing documentation for context:
- Distinctive: line 33
Read existing CenCon files (if any) for comparison:
- Distinctive: line 42
Read the .csproj file
- Distinctive: line 69
Read the primary class file in each directory
- Distinctive: line 86
Search for patterns indicating external system interactions:
- Distinctive: line 107
Search for security-relevant patterns in all .cs files:
- Very specific: line 262
If --diff flag was provided:
- Very specific: line 267
If --dry-run flag was provided:
- Distinctive: line 277
Only after user approval:
- Very specific: line 279
Create docs/cencon/ directory if it doesn't exist
- Distinctive: line 299
Never hallucinate components - only include what you actually find
- Distinctive: line 301
Use consistent ID formats (snake_case for IDs)
- Distinctive: line 306
If no .sln file found:
- Distinctive: line 310
If no .csproj files found:
- Distinctive: line 314
If reading a file fails:
≈ “Common” is an estimate: at least 1 in 5 of the 308,232 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
CenCon Generate Skill
Automatically analyze .NET source code (the ground truth) and generate CenCon documentation files.
Triggers
/cencon-generate- Full generation/cencon-generate --diff- Show changes since last generation/cencon-generate --dry-run- Preview without writing files
Output Files
All files are created in docs/cencon/:
architecture_manifest.yaml- C4 Level 1 & 2 model (machine-readable)security_profile.yaml- OWASP Desktop + custom security rulesINDEX.md- Human-readable summary with data flow diagrams
Workflow
STEP 1: Discover Repository Context
- Use Glob to find *.sln files in the repository root
- Use Glob to find all *.csproj files
- Read existing documentation for context:
- README.md (if exists)
- docs/CodingStyle.md (if exists)
- CLAUDE.md (if exists)
- Read existing CenCon files (if any) for comparison:
- docs/cencon/architecture_manifest.yaml
- docs/cencon/security_profile.yaml
- docs/cencon/INDEX.md
STEP 2: Discover Containers (Projects)
For each .csproj file found:
- Read the .csproj file
- Extract key properties:
- TargetFramework (e.g., net10.0, net8.0)
- OutputType (WinExe, Library, Exe)
- UseWPF (true/false)
- UseWindowsForms (true/false)
- ImplicitUsings
- Extract ProjectReferences to build dependency graph
- Extract PackageReferences for external dependencies
Classify each project into container types:
wpf_ui- OutputType=WinExe + UseWPF=truecore_services- OutputType=Library, no UIcli- OutputType=Exe, no UItests- Project name ends with .Tests or contains test packages
Build a dependency graph from ProjectReferences.
STEP 3: Discover Components (Classes/Namespaces)
For each non-test container:
- List all directories under the project folder (excluding bin, obj, Properties)
- Each top-level directory represents a component group
- For each directory, use Grep to find:
- Public classes:
public (class|interface|enum|record|struct) \w+ - With attributes:
\[.*\]before class declarations
- Public classes:
- Read the primary class file in each directory
- Extract XML documentation summaries (
/// <summary>) - Identify design patterns by looking for:
- Strategy: Interface with multiple implementations (ISessionBackend)
- Observer: Events and event handlers
- State Machine: Enum + switch/state transitions
- Producer-Consumer: BlockingCollection, ConcurrentQueue
- Repository: Load/Save/Get methods
Record component information:
- name: Class/interface name
- description: From XML doc or inferred from code
- file: Primary file path
- files: List of related files if multiple
STEP 4: Identify External Systems
Search for patterns indicating external system interactions:
- HttpClient usage -> External API
- Process.Start("git") or Process.StartInfo containing "git" -> Git VCS
- Process.Start("claude") -> Claude Code CLI
- Process.Start with other executables -> External tool
- NamedPipeServerStream -> IPC (this is a boundary, not an actor)
- [DllImport] attributes -> Native Windows APIs
- HttpClient with OpenAI/Anthropic patterns -> AI APIs
For each external system found:
- id: snake_case identifier
- name: Human-readable name
- description: What it does
- type: external_system or person
- relationship: How the main system uses it
Developer (person) is always added as the primary actor.
STEP 5: Extract Security Information
Search for security-relevant patterns in all .cs files:
- Credential patterns:
password\s*=,apikey,secret,token\s*=- ConnectionStrings with sensitive data
- User input handling:
- Console.ReadLine, TextBox.Text
- Command line args (args[])
- Process execution:
- Process.Start, ProcessStartInfo
- Arguments construction
- File path construction:
- Path.Combine with user input
- String concatenation for paths
- Network access:
- HttpClient, TcpClient, WebSocket
- NamedPipeServerStream (IPC)
- Crypto and secrets:
- Encryption/decryption patterns
- DPAPI usage
For each pattern found, determine:
- Is this a potential vulnerability?
- Is there proper validation/sanitization?
- What mitigation is in place?
Generate custom security rules based on findings.
STEP 6: Generate YAML/MD Files
Generate three files with today's date as last_updated/last_verified.
architecture_manifest.yaml:
schema_version: "1.0.0"
project:
name: [from solution name]
description: [from README.md or inferred]
version: [from .csproj VersionPrefix or "1.0.0"]
framework: [from TargetFramework]
platform: [inferred from UseWPF, UseWindowsForms, etc.]
last_updated: [today's date YYYY-MM-DD]
context:
system:
name: [project name]
description: [from README or inferred]
technology: [from framework analysis]
actors:
- [list of actors from STEP 4]
containers:
- [list of containers from STEP 2 with components from STEP 3]
data_flows:
- [inferred from component interactions]
security_boundaries:
- [from STEP 5 analysis]
patterns:
- [from STEP 3 pattern detection]security_profile.yaml:
schema_version: "1.0.0"
project:
name: [project name]
version: [version]
last_verified: [today's date YYYY-MM-DD]
drift:
threshold_days: 30
action_on_drift: FAIL_REVIEW
owasp_desktop:
- [OWASP Desktop checks based on STEP 5]
soc2_alignment:
- [SOC 2 controls applicable]
custom_rules:
- [project-specific grep patterns from STEP 5]
review_checklist:
- [human-readable checklist items]INDEX.md:
# [Project Name] - CenCon Documentation Index
**Version:** [version]
**Last Updated:** [date]
**Schema:** CenCon Method v1.0
## Overview
[Project description]
## Architecture Diagrams
[Links to context.png and container.png with generation instructions]
## System Components
[Tables of components by container]
## Data Flows
[ASCII diagrams of key flows]
## Security Profile Summary
[Key security controls and compliance alignment]
## Related Documentation
[Links to other docs]
## Maintenance
[How to update this documentation]STEP 7: Present Results and Get Approval
Display to the user:
CenCon Generation Summary
Repository: [repo name]
Solution: [solution file]
Containers Discovered: [count]
[list each container with technology]
Components Discovered: [count]
[list count by container]
External Systems: [count]
[list each external system]
Security Rules Generated: [count]
[list rule names]
Files to Create/Update:
docs/cencon/architecture_manifest.yaml
docs/cencon/security_profile.yaml
docs/cencon/INDEX.mdIf --diff flag was provided:
- Show additions (lines starting with +)
- Show removals (lines starting with -)
- Show unchanged count
If --dry-run flag was provided:
- Display the generated content
- Say: "Dry run complete. No files were written."
- STOP here
Otherwise ask: Approve writing these files? Reply "yes" to write.
STEP 8: Write Files
Only after user approval:
- Create docs/cencon/ directory if it doesn't exist
- Write architecture_manifest.yaml
- Write security_profile.yaml
- Write INDEX.md
Report completion:
CenCon documentation generated successfully.
Files created:
docs/cencon/architecture_manifest.yaml
docs/cencon/security_profile.yaml
docs/cencon/INDEX.md
To generate diagrams, run: cc-docgen generateNotes
- Source code is the ground truth - always analyze actual .cs/.csproj files
- Never hallucinate components - only include what you actually find
- Preserve existing structure when updating (don't remove valid sections)
- Use consistent ID formats (snake_case for IDs)
- Today's date format: YYYY-MM-DD
Error Handling
If no .sln file found:
- Show error: "No solution file found in repository root"
- STOP
If no .csproj files found:
- Show error: "No project files found"
- STOP
If reading a file fails:
- Note the error and continue with other files
- Include a comment in output about the skipped file
Skill Version: 1.0 Last Updated: 2026-02-21 Created for: CenCon Method v1.0
Other versions1 project uses a version of this.
Word for word · 1
- thefrederiksen/devthrottle★ 96100% same
Edited · 0
None found.
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository30 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- agent-expertSkill
- cc-settings-apiSkill
- code-maintenanceSkill
- commitSkill
- dead-code-finderSkill
- deploy-hosted-gatewaySkill
- developer-agentSkill
- dev-throttleSkill
- document-featuresSkill
- enter-issueSkill
- fleet-commsSkill
- implementation-loopSkill
- move-sessionSkill
- playwright-cliSkill
- product-agentSkill
- qa-agentSkill
- read-issuesSkill
- release-managerSkill
- review-codeSkill
- shipSkill
- skill-managerSkill
- support-agentSkill
- terminologySkill
- test-managerSkill
- ui-testSkill
- update-docsSkill
- voice-reviewSkill
- warning-fixerSkill
- wingman-brief-reviewerSkill
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

