Hi - I answer from the OpenSmartRoute documentation: routing, the API, plans and quotas, self-hosting. Ask away, or open a support ticket if you need a person.
Grounded in the docs - follow a source before acting on it.
infrastructure-efcore - Skill - OpenSmartRoute
Skillv1.0.0
infrastructure-efcore
These instructions apply to the layer using EF Core.
Instruction file imported from Nadine-Mousa/StyleHub (.github/instructions/infrastructure-efcore.instructions.md). Copyright stays with the author.
These instructions apply to the layer using EF Core.
EF Core Guidelines:
Use AsNoTracking() for read-only queries.
Prefer async methods (e.g., ToListAsync(), FirstOrDefaultAsync()) with CancellationToken.
Do not expose DbContext directly to the Presentation layer; use repositories or query services.
Avoid N+1 queries; use Include / ThenInclude judiciously.
For transactional operations, prefer IDbContextTransaction or application-level units of work.
Avoid putting domain logic in the Infrastructure layer; keep it in Domain/Application.
Use ValueConverter<T> for complex value objects when mapping to DB.
Never call .SaveChanges() inside a repository without explicit transaction control.
Use it
Copy one of these into your project. Installing also returns the manifest and these snippets.
yaml
targets:
- https://api.opensmartroute.ai/api/v1/registry/nadine-mousa-stylehub-infrastructure-efcore-instructions/manifest # or paste the manifest below
Manifest
An Open Capability Manifest: the router reads it to know what this does, what it costs and when to pick it.
{
"ocm": "1",
"id": "nadine-mousa-stylehub-infrastructure-efcore-instructions",
"kind": "skill",
"name": "infrastructure-efcore",
"description": "These instructions apply to the layer using EF Core.",
"publisher": "Nadine-Mousa",
"version": "1.0.0",
"capabilities": {
"domains": [
"general"
],
"tags": [
"skill-md",
"github-instructions"
],
"languages": [
"en"
]
},
"quality_prior": 0.6,
"examples": [
"These instructions apply to the layer using EF Core."
],
"primary": false,
"metadata": {
"source": {
"provider": "github-instructions",
"repository": "https://github.com/Nadine-Mousa/StyleHub",
"path": ".github/instructions/infrastructure-efcore.instructions.md",
"ref": "5acd3b3e6912f25f96bf35e587fe5af971ac00ab",
"url": "https://github.com/Nadine-Mousa/StyleHub/blob/5acd3b3e6912f25f96bf35e587fe5af971ac00ab/.github/instructions/infrastructure-efcore.instructions.md",
"key": "Nadine-Mousa/StyleHub/.github/instructions/infrastructure-efcore.instructions.md"
},
"applies_to": "src/Infrastructure/**/*.cs"
},
"instructions": "These instructions apply to the layer using EF Core.\n\n### EF Core Guidelines:\n- Use `AsNoTracking()` for read-only queries.\n- Prefer async methods (e.g., `ToListAsync()`, `FirstOrDefaultAsync()`) with `CancellationToken`.\n- Do not expose `DbContext` directly to the Presentation layer; use repositories or query services.\n- Avoid N+1 queries; use `Include` / `ThenInclude` judiciously.\n- For transactional operations, prefer `IDbContextTransaction` or application-level units of work.\n- Avoid putting domain logic in the Infrastructure layer; keep it in Domain/Application.\n- Use `ValueConverter<T>` ",
"cost": {
"context_tokens": 183
}
}
Fetch it by URL: GET /api/v1/registry/nadine-mousa-stylehub-infrastructure-efcore-instructions/manifest?version=1.0.0
Reviews
Star ratings from people who tried it. One review per account; edit yours any time.
No reviews yet. Install it, try it, and be the first to rate it.