Skip to content

Commit 1ec7aa2

Browse files
authored
Fix YesSql Concurrency Issue (#459)
1 parent 522adff commit 1ec7aa2

5 files changed

Lines changed: 151 additions & 2 deletions

File tree

.github/copilot-instructions.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -295,6 +295,7 @@ tests/
295295
- **AI Agents**: `CrestApps.OrchardCore.AI.Agent` - defines reusable AI agents/tools
296296
- **Provider modules**: `CrestApps.OrchardCore.OpenAI`, `CrestApps.OrchardCore.OpenAI.Azure`, `CrestApps.OrchardCore.Ollama`, `CrestApps.OrchardCore.AzureAIInference`
297297
- **AI Prompt Templates**: Never hardcode AI system prompts or prompt-style recovery instructions in C# code. Store them in `Templates/Prompts/*.md`, add a constant in `AITemplateIds`, and render them through `ITemplateService`.
298+
- **AI function catalog docs**: Whenever you add, remove, rename, re-categorize, or change the description or feature requirements of an AI function/tool, update `src\CrestApps.Docs\docs\ai\tools.md` and any related feature doc (for example `ai\memory.md`) in the same change so the documented function lists stay synchronized with the codebase.
298299

299300
### Working with Omnichannel Modules
300301
- **Base Module**: `CrestApps.OrchardCore.Omnichannel` - unified communication layer

Directory.Packages.props

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
<PropertyGroup>
33
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
44
<CentralPackageTransitivePinningEnabled>true</CentralPackageTransitivePinningEnabled>
5-
<OrchardCoreVersion>[3.0.0-preview-19021, )</OrchardCoreVersion>
6-
<CrestAppsCoreVersion>1.0.0-preview.105</CrestAppsCoreVersion>
5+
<OrchardCoreVersion>[3.0.0-preview-19022, )</OrchardCoreVersion>
6+
<CrestAppsCoreVersion>1.0.0-preview.108</CrestAppsCoreVersion>
77
<ModelContextProtocolVersion>1.3.0</ModelContextProtocolVersion>
88
</PropertyGroup>
99
<ItemGroup>

src/CrestApps.Docs/docs/ai/agent.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ The Orchard agent module surfaces agent profiles inside Orchard Core so they can
2929

3030
The exact tool set available to agents depends on which Orchard modules are enabled. For example, tenant-management tools only light up when Orchard tenants support is enabled, and recipe tools depend on Orchard recipes support.
3131

32+
For the complete Orchard-specific AI function catalog, including the feature that enables each function and its description, see [AI Tools](tools).
33+
3234
## Orchard-specific role of agent profiles
3335

3436
In Orchard Core, agent profiles are useful when you want:

src/CrestApps.Docs/docs/ai/tools.md

Lines changed: 145 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ The shared tool system is documented primarily in **CrestApps.Core**:
1212
- [MCP](https://core.crestapps.com/docs/mcp/index)
1313
- [A2A](https://core.crestapps.com/docs/a2a/index)
1414

15+
This page is the Orchard-specific catalog for the AI functions registered or documented in this repository. Shared framework utilities that are not registered by Orchard features in this repo, along with external MCP and A2A tools, continue to be documented in the shared Core docs.
16+
1517
Within Orchard Core, tools become useful through the modules that register or expose them:
1618

1719
- [AI Services](overview)
@@ -21,6 +23,149 @@ Within Orchard Core, tools become useful through the modules that register or ex
2123
- [MCP](./mcp/)
2224
- [A2A](./a2a/)
2325

26+
## Orchard-specific AI function catalog
27+
28+
Use this catalog to see which Orchard feature makes each AI function available and what it does. When the codebase adds, removes, renames, or re-describes an AI function, update this page together with the related feature docs so the catalog stays synchronized with the current registrations.
29+
30+
### System tools
31+
32+
**Available when:** `CrestApps.OrchardCore.AI.Agent`
33+
34+
| Function | Description |
35+
| --- | --- |
36+
| `listTimeZones` | Retrieves a list of the available time zones in the system. |
37+
| `listAIProfiles` | Lists AI profiles with optional filters for type, analytics, data extraction, and post-session processing. |
38+
| `viewAIProfile` | Retrieves detailed configuration for a specific AI profile by ID or name. |
39+
40+
### Recipe tools
41+
42+
**Available when:** `CrestApps.OrchardCore.AI.Agent` + `OrchardCore.Recipes.Core`
43+
44+
| Function | Description |
45+
| --- | --- |
46+
| `applySiteSettings` | Applies predefined system configurations and settings using AI assistance. |
47+
| `getOrchardCoreRecipeJsonSchema` | Returns a JSON Schema definition for Orchard Core recipes or a specific recipe step. |
48+
| `listOrchardCoreRecipeStepsAndSchemas` | Lists all available Orchard Core recipe steps and returns their JSON schema definitions. |
49+
| `importOrchardCoreRecipe` | Imports and runs Orchard Core recipes within your site. |
50+
| `listNonStartupRecipes` | Retrieves all available Orchard Core recipes that are not executed during startup. |
51+
| `executeNonStartupRecipe` | Executes Orchard Core recipes that are not configured to run at application startup. |
52+
53+
### Tenant tools
54+
55+
**Available when:** `CrestApps.OrchardCore.AI.Agent` + `OrchardCore.Tenants`
56+
57+
| Function | Description |
58+
| --- | --- |
59+
| `listStartupRecipes` | Retrieves a list of Orchard Core recipes configured to run at application startup. |
60+
| `createTenant` | Creates a new tenant in the Orchard Core application. |
61+
| `getTenant` | Retrieves detailed information about a specific tenant. |
62+
| `listTenant` | Returns information about all tenants in the system. |
63+
| `enableTenant` | Enables a tenant that is currently disabled. |
64+
| `disableTenant` | Disables a tenant that is currently active. |
65+
| `removeTenant` | Removes an existing tenant that can be safely deleted. |
66+
| `reloadTenant` | Reloads the configuration and state of an existing tenant. |
67+
| `setupTenant` | Sets up new tenants. |
68+
69+
### Content tools
70+
71+
**Available when:** `CrestApps.OrchardCore.AI.Agent` + `OrchardCore.Contents`
72+
73+
| Function | Description |
74+
| --- | --- |
75+
| `searchForContentItems` | Searches for content items. |
76+
| `getSampleContentItemForContentType` | Generates a structured sample content item for a specified content type. |
77+
| `publishContentItem` | Publishes a draft or previously unpublished content item. |
78+
| `unpublishContentItem` | Unpublishes a currently published content item. |
79+
| `getContentItemById` | Retrieves a specific content item by its ID or type. |
80+
| `deleteContentItem` | Deletes a content item from the system. |
81+
| `cloneContentItem` | Creates a duplicate of an existing content item. |
82+
| `createOrUpdateContentItem` | Creates a new content item or updates an existing one. |
83+
| `getLinkForContentItem` | Retrieves a link for a content item. |
84+
85+
### Content definition tools
86+
87+
**Available when:** `CrestApps.OrchardCore.AI.Agent` + `OrchardCore.ContentTypes`
88+
89+
| Function | Description |
90+
| --- | --- |
91+
| `getContentTypeDefinition` | Retrieves the definitions of all available content types. |
92+
| `getContentPartDefinition` | Retrieves the definitions of all available content parts. |
93+
| `listContentTypesDefinitions` | Provides a list of available content type definitions. |
94+
| `listContentPartsDefinitions` | Provides a list of available content part definitions. |
95+
| `listContentFieldDefinitions` | Provides a list of available content fields. |
96+
97+
### Content definition recipe tools
98+
99+
**Available when:** `CrestApps.OrchardCore.AI.Agent` + `OrchardCore.ContentTypes` + `OrchardCore.Recipes.Core`
100+
101+
| Function | Description |
102+
| --- | --- |
103+
| `removeContentTypeDefinition` | Removes the content type definition. |
104+
| `removeContentPartDefinition` | Removes the content part definition. |
105+
| `applyContentTypeDefinitionFromRecipe` | Creates a new content type definition or updates an existing one. |
106+
107+
### Feature management tools
108+
109+
**Available when:** `CrestApps.OrchardCore.AI.Agent` + `OrchardCore.Features`
110+
111+
| Function | Description |
112+
| --- | --- |
113+
| `disableSiteFeature` | Disables site features. |
114+
| `enableSiteFeature` | Enables site features. |
115+
| `searchSiteFeature` | Searches available features for a match. |
116+
| `listSiteFeature` | Retrieves available site features. |
117+
| `getSiteFeature` | Retrieves info about a feature. |
118+
119+
### Communication tools
120+
121+
**Available when:** `CrestApps.OrchardCore.AI.Agent` + one or more communication features
122+
123+
| Function | Required feature | Description |
124+
| --- | --- | --- |
125+
| `sendNotification` | `OrchardCore.Notifications` | Sends a notification message to a user. |
126+
| `sendEmail` | `OrchardCore.Email` | Sends an email message on behalf of the logged-in user. |
127+
| `sendSmsMessage` | `OrchardCore.Sms` | Sends an SMS message to a user. |
128+
129+
### User and role tools
130+
131+
**Available when:** `CrestApps.OrchardCore.AI.Agent` + the matching user-management feature
132+
133+
| Function | Required feature | Description |
134+
| --- | --- | --- |
135+
| `getUserInfo` | `OrchardCore.Users` | Gets information about a user. |
136+
| `searchForUsers` | `OrchardCore.Users` | Searches the system for users. |
137+
| `getRoleInfo` | `OrchardCore.Roles` | Gets information about a role. |
138+
139+
### Workflow tools
140+
141+
**Available when:** `CrestApps.OrchardCore.AI.Agent` + the matching workflow feature set
142+
143+
| Function | Required feature(s) | Description |
144+
| --- | --- | --- |
145+
| `getWorkflowType` | `OrchardCore.Workflows` | Gets information about a workflow type. |
146+
| `listWorkflowTypes` | `OrchardCore.Workflows` | Lists information about workflow types. |
147+
| `createOrUpdateWorkflow` | `OrchardCore.Workflows` + `OrchardCore.Recipes.Core` | Creates or updates a workflow. |
148+
| `listWorkflowActivities` | `OrchardCore.Workflows` + `OrchardCore.Recipes.Core` | Lists all available tasks and activities for workflows. |
149+
150+
### Analytics tools
151+
152+
**Available when:** `CrestApps.OrchardCore.AI.Agent` + `CrestApps.OrchardCore.AI.Chat.Analytics`
153+
154+
| Function | Description |
155+
| --- | --- |
156+
| `queryChatSessionMetrics` | Queries aggregated chat session analytics metrics with optional date range and profile filters, returning statistics for charts and reports. |
157+
158+
### Memory tools
159+
160+
**Available when:** `CrestApps.OrchardCore.AI.Memory` is enabled and user memory is enabled for the current authenticated user
161+
162+
| Function | Description |
163+
| --- | --- |
164+
| Search User Memories | Semantic search across the current user's saved memories. |
165+
| List User Memories | Enumerates the current user's existing memories. |
166+
| Save User Memory | Creates or updates a named memory entry for the current user. |
167+
| Remove User Memory | Removes a saved memory entry when it should be forgotten. |
168+
24169
## Invocation Context (AIInvocationScope)
25170

26171
`AIInvocationScope` is the shared per-request context for references, tool state, and other invocation-scoped data. For the framework-level explanation, see the shared Core documentation:

src/CrestApps.Docs/docs/changelog/v2.0.0.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -288,6 +288,7 @@ This included:
288288
- adding dedicated Docusaurus pages for the `CrestApps.OrchardCore.AI.Memory.AzureAI` and `CrestApps.OrchardCore.AI.Memory.Elasticsearch` feature modules
289289
- adding a manifest-backed feature-ID reference page and missing Azure Communication Services coverage
290290
- expanding AI recipe schema guidance for provider-connection authentication fields and contained Azure Speech deployments
291+
- adding a centralized Orchard-specific AI function catalog that maps each documented function to the feature that makes it available
291292
- refreshing provider setup wording and the docs contributor guidance
292293

293294
### Orchard data-source sync background resolution fix

0 commit comments

Comments
 (0)