# Crestapps Core Data Sources

> Skill for search-backed RAG, index profiles, and vector data source integration in CrestApps.Core.

- Skill: `crestapps/crestapps-core-data-sources` (Agent Skill)
- Install (CLI): `npx skillmds@latest add crestapps/crestapps-core-data-sources`
- Raw SKILL.md: https://api.skillmd.com/api/skills/crestapps/crestapps-core-data-sources/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: CrestApps (https://skillmd.com/u/crestapps)
- Updated: 2026-09-10
- Page: https://skillmd.com/skills/crestapps/crestapps-core-data-sources

---


# CrestApps.Core Data Sources - Prompt Templates

## Add Search-Backed RAG

You are a CrestApps.Core expert. Generate code and guidance for index-backed data sources in CrestApps.Core.

### Guidelines

- Use data sources when knowledge should come from durable search indexes instead of only attached documents.
- Pair data sources with the AI runtime and orchestration.
- Provide an indexing store through Entity Framework Core or YesSql when index profiles are persisted.
- Use Azure AI Search or Elasticsearch based on the chosen backend.
- Keep provider-specific search wiring behind the shared data-source abstractions.

### Feature Goals

- semantic retrieval from durable indexes
- index profile selection
- preemptive RAG and retrieval tuning
- backend-specific registration without rewriting business logic

### Common Composition Pattern

```csharp
builder.Services.AddCrestAppsCore(crestApps => crestApps
    .AddAISuite(ai => ai
        .AddOpenAI()
        .AddChatInteractions()
    )
    .AddIndexingServices(indexing => indexing
        .AddEntityCoreStores()
        .AddAzureAISearch(
            builder.Configuration.GetSection("CrestApps:AzureAISearch"),
            search => search
                .AddAIDataSources())
    )
);
```

### Design Guidance

- Use documents for uploaded file workflows.
- Use data sources for durable business indexes.
- Combine data sources with AI Profiles when retrieval boundaries should be reusable.
- A metadata store alone does not provide a data-source backend. Register a real backend such as Azure AI Search, Elasticsearch, or PostgreSQL and call that backend's `AddAIDataSources()` extension.

