Skip to content

Latest commit

 

History

History
54 lines (39 loc) · 5.73 KB

File metadata and controls

54 lines (39 loc) · 5.73 KB

Office File API – Integrate DevExpress AI-powered Extensions

The following project integrates AI capabilities into a DevExpress-powered Office File API Web API application. This project uses the DevExpress AI-powered extension to complete the following tasks:

  • DevExpress AI-powered extensions generate descriptions for images, charts, and hyperlinks in Microsoft Word and Excel files.
  • DevExpress document-processing AI-powered extensions summarize, translate, and proofread Word, PDF, and Presentation files.

Note

DevExpress AI-powered extensions operate on a “bring your own key” (BYOK) model. We do not provide a proprietary REST API or bundled language models (LLMs/SLMs).

You can either deploy a self-hosted model or connect to a cloud AI provider and obtain necessary connection parameters (endpoint, API key, language model identifier, and so on). These parameters must be configured at application startup to register an AI client and enable extension functionality.

Implementation Details

This project uses both common and document-processing AI-powered extension methods. The IChatClient interface serves as the central mechanism for language model interaction. DevExpress AI-powered extensions run inside an AIExtensionsContainerDefault container that manages registered AI clients. Call the AddDevExpressAIConsole method to register a chat client in a Web API application.

Call the RegisterAIDocProcessingService(AIExtensionsContainerSettings) method to register document-processing AI extensions in your dependency injection container.

The table below lists controllers that use DevExpress AI-powered extensions and corresponding registration methods.

Controller Description API
AccessibilityController Endpoints to generate image, chart, and hyperlink and descriptions.
For Excel files, charts are converted to images to obtain relevant descriptions.
GenerateImageDescriptionAsync
CustomPromptAsync
SummarizeController Endpoints to produce a concise summary for an entire document/presentation or selected parts (slides, pages, sections). SummarizeAsync
ProofreadController Endpoints to review entire document/presentation or selected parts (slides, pages, sections) for grammar, spelling, and style in real-time. ProofreadAsync
TranslateController Includes endpoints to translate full document/presentation content or selected parts (slides, pages, sections). TranslateAsync

Files to Review

Documentation

Does this example address your development requirements/objectives?

(you will be redirected to DevExpress.com to submit your response)