src/autoskillit/skills_extended/arch-lens-repository-access/SKILL.md
Create Repository/Data Access architecture diagram showing the repository pattern, entity relationships, and data access patterns. Data-centric lens answering "How is data accessed?"
npx skillsauth add talont-org/autoskillit arch-lens-repository-accessInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Cognitive Mode: Data-Centric Primary Question: "How is data accessed?" Focus: Repository Pattern, Entity Relationships, Query Patterns, Format Conversion
/autoskillit:arch-lens-repository-access or /autoskillit:make-arch-diag repositoryNEVER:
run_in_background: true is prohibited)ALWAYS:
/autoskillit:mermaid skill using the Skill tool - this is MANDATORYtemp/arch-lens-repository-access/...
save path to absolute by prepending the full CWD:
diagram_path = /absolute/cwd/temp/arch-lens-repository-access/{filename}.md
This token is MANDATORY — the pipeline cannot proceed without it./autoskillit:arch-lens-repository-access [context_path]
If a context_path positional argument is present:
context_pathIf no context_path is provided, skip this step and explore the full CWD in Step 1.
Spawn Explore subagents to investigate:
Repository Classes
Entity Models
CRUD Operations
Query Patterns
Factory/Scoping
Format Conversion
Document:
CRITICAL - Analyze Read/Write Direction: For EVERY repository method and data access:
get_*, find_*, query_* - data flows OUT of storagesave_*, create_*, update_*, delete_* - data flows INTO storageFor EVERY caller-to-repository relationship:
Label connections accordingly (reads, writes, reads/writes)
| Pattern | Repository Method | Use Case | |---------|------------------|----------| | By ID | get_by_id() | Single entity lookup | | By Business Key | get_by_* | Domain-specific lookup | | List | get_all(), get_for_* | Collection queries | | Bulk | save_many() | Batch operations |
Use flowchart with:
Direction: LR (left-to-right) for caller-to-storage flow
Subgraphs:
Node Styling:
cli class: Callers (nodes, handlers)phase class: Factory, scopingnewComponent class: Repositories (green to highlight)handler class: Conversion adaptersintegration class: Database storageShow Relationships:
Write the diagram to: {{AUTOSKILLIT_TEMP}}/arch-lens-repository-access/arch_diag_repository_access_{YYYY-MM-DD_HHMMSS}.md (relative to the current working directory)
After writing the diagram file, emit a structured output line:
IMPORTANT: Emit the structured output tokens as literal plain text with no markdown formatting on the token names. Do not wrap token names in
**bold**,*italic*, or any other markdown. The adjudicator performs a regex match on the exact token name — decorators cause match failure.
diagram_path = {absolute_path_to_diagram_file}
# Repository/Data Access Diagram: {System Name}
**Lens:** Repository/Data Access (Data-Centric)
**Question:** How is data accessed?
**Date:** {YYYY-MM-DD}
**Scope:** {What was analyzed}
## Repository Overview
| Category | Count | Key Repositories |
|----------|-------|------------------|
| {category} | {N} | {names} |
## Data Access Diagram
```mermaid
%%{init: {'flowchart': {'nodeSpacing': 50, 'rankSpacing': 60, 'curve': 'basis'}}}%%
flowchart LR
%% CLASS DEFINITIONS %%
classDef cli fill:#1a237e,stroke:#7986cb,stroke-width:2px,color:#fff;
classDef stateNode fill:#004d40,stroke:#4db6ac,stroke-width:2px,color:#fff;
classDef handler fill:#e65100,stroke:#ffb74d,stroke-width:2px,color:#fff;
classDef phase fill:#6a1b9a,stroke:#ba68c8,stroke-width:2px,color:#fff;
classDef output fill:#00695c,stroke:#4db6ac,stroke-width:2px,color:#fff;
classDef integration fill:#c62828,stroke:#ef9a9a,stroke-width:2px,color:#fff;
classDef newComponent fill:#2e7d32,stroke:#81c784,stroke-width:2px,color:#fff;
subgraph Callers ["CALLERS"]
CALLER1["Handler/Service<br/>━━━━━━━━━━<br/>Business logic"]
end
subgraph Factory ["REPOSITORY FACTORY"]
direction TB
FAC["RepositoryFactory<br/>━━━━━━━━━━<br/>Dependency injection"]
SCOPE["Scoping<br/>━━━━━━━━━━<br/>Context management"]
end
subgraph Repositories ["REPOSITORIES"]
direction TB
REPO1["EntityRepository<br/>━━━━━━━━━━<br/>CRUD methods"]
BASE["BaseRepository<T><br/>━━━━━━━━━━<br/>Generic CRUD"]
end
subgraph Conversion ["FORMAT CONVERSION"]
direction TB
ADAPTER["Adapters/DTOs<br/>━━━━━━━━━━<br/>Serialization"]
end
subgraph Storage ["DATABASE"]
direction TB
DB[("Table/Collection<br/>━━━━━━━━━━<br/>Persistent storage")]
end
%% FLOW %%
CALLER1 --> FAC
FAC --> SCOPE
SCOPE --> REPO1
BASE --> REPO1
REPO1 --> ADAPTER
ADAPTER --> DB
%% CLASS ASSIGNMENTS %%
class CALLER1 cli;
class FAC,SCOPE phase;
class REPO1 newComponent;
class BASE stateNode;
class ADAPTER handler;
class DB integration;
Color Legend: | Color | Category | Description | |-------|----------|-------------| | Dark Blue | Callers | Services/handlers that use repositories | | Purple | Factory | Repository construction and scoping | | Green | Repositories | Repository implementations | | Teal | Base | Generic base repository | | Orange | Conversion | Format adapters/DTOs | | Red | Storage | Database tables/collections |
| Category | Count | Key Repositories | |----------|-------|------------------| | {category} | {N} | {list} |
| Pattern | Repository Method | Use Case | |---------|------------------|----------| | {pattern} | {method} | {use case} |
| Parent | Child | Cardinality | FK | |--------|-------|-------------|-----| | {parent} | {child} | {1:N/1:1} | {fk field} |
---
## Pre-Diagram Checklist
Before creating the diagram, verify:
- [ ] LOADED `/autoskillit:mermaid` skill using the Skill tool
- [ ] Using ONLY classDef styles from the mermaid skill (no invented colors)
- [ ] Diagram will include a color legend table
---
## Related Skills
- `/autoskillit:make-arch-diag` - Parent skill for lens selection
- `/autoskillit:mermaid` - MUST BE LOADED before creating diagram
- `/autoskillit:arch-lens-data-lineage` - For data flow view
- `/autoskillit:arch-lens-c4-container` - For storage container view
development
Generate YAML recipes for .autoskillit/recipes/. Use when user says "make script skill", "generate script", "script a workflow", "write a script", "create a script", "new recipe", "write a pipeline", or when loaded by other skills for script formatting.
data-ai
Create Uncertainty Representation visualization planning spec showing error bar definitions, distribution-aware alternatives, and multi-seed variance protocols. Statistical lens answering "How is uncertainty honestly represented?"
data-ai
Create Temporal Dynamics visualization planning spec showing axis scaling (linear vs log), smoothing disclosure, epoch/step alignment, run aggregation (mean + variance bands), early-stopping markers, and wall-clock vs step-count x-axis. Temporal lens answering "Are training dynamics shown clearly and honestly?"
data-ai
Create Narrative Story Arc visualization planning spec showing visual consistency across the report (same color = same model everywhere), logical figure progression, redundant figure detection, and narrative dependency between figures. Narrative lens answering "Do the figures tell a coherent story across the report?"