Skip to content

Commit 5f58ea6

Browse files
authored
Merge pull request #781 from telerik/dkrastev/m-ai-assistant
Add AI Assistant Code
2 parents fd958e6 + 6559fe8 commit 5f58ea6

File tree

7 files changed

+549
-0
lines changed

7 files changed

+549
-0
lines changed
Lines changed: 86 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
1+
---
2+
title: Copilot Extension
3+
page_title: Telerik WinForms GitHub Copilot Extension
4+
description: Learn how to add and use the Telerik WinForms GitHub Copilot extension as a WinForms AI coding assistant and code generator for better developer productivity. The Telerik WinForms GitHub Copilot extension provides proprietary context about Telerik UI for WinForms to AI-powered software.
5+
slug: ai-copilot-extension
6+
tags: telerik, WinForms, ai, coding assistant, ai server
7+
position: 1
8+
---
9+
10+
# Telerik WinForms GitHub Copilot Extension
11+
12+
The Telerik WinForms [GitHub Copilot](https://github.com/features/copilot) extension is an AI-powered coding assistant that provides specialized knowledge about [Telerik UI for WinForms components](https://www.telerik.com/products/winforms.aspx).
13+
14+
This extension enhances GitHub Copilot with proprietary context about Telerik WinForms controls, helping you:
15+
16+
* Generate code snippets using Telerik WinForms components.
17+
* Get contextual suggestions for component properties and methods.
18+
* Access best practices and implementation patterns.
19+
* Speed up development with AI-powered code completion.
20+
21+
## Prerequisites
22+
23+
Before using the Telerik WinForms GitHub Copilot extension, ensure you have:
24+
25+
* An active [GitHub Copilot](https://github.com/features/copilot) subscription. You can enable or configure GitHub Copilot on the [Copilot Settings page in your GitHub account](https://github.com/settings/copilot).
26+
* A [Telerik user account](https://www.telerik.com/account/?_gl=1*rbcezh*_gcl_au*NzA0NDU3NzU1LjE3NTA2NTk3NDY.*_ga*ODUxNTg5NDI5LjE2OTU2NDQ2ODI.*_ga_9JSNBCSF54*czE3NTQ1NDQ5MTQkbzE0NSRnMSR0MTc1NDU3MjMxMiRqMzAkbDAkaDA.).
27+
* An active [DevCraft or Telerik UI for WinForms license](https://www.telerik.com/purchase/individual/winforms.aspx) or a [Telerik UI for WinForms trial](https://www.telerik.com/try/ui-for-winforms).
28+
* A [WinForms application that includes Telerik UI for WinForms](https://docs.telerik.com/devtools/winforms/getting-started/first-steps).
29+
* The latest version of your [Copilot-enabled app](https://docs.github.com/en/copilot/building-copilot-extensions/about-building-copilot-extensions#supported-clients-and-ides) (for example, Visual Studio or Visual Studio Code).
30+
31+
## Installation
32+
33+
Follow these steps to install and configure the Telerik WinForms Copilot extension:
34+
35+
1. Go to the [Telerik WinForms GitHub App](https://github.com/apps/telerikwinforms) page and click the **Install** button.
36+
1. You will see a list that includes your GitHub account and all GitHub organizations that you are part of. Select your GitHub account.
37+
1. Click the **Install & Allow** button. This will allow the GitHub Copilot extension to integrate with your GitHub account.
38+
1. Enter your GitHub password when prompted.
39+
1. You will be redirected to telerik.com. Enter your Telerik account credentials if prompted. This step links the GitHub Copilot extension with your Telerik account.
40+
1. Upon successful Telerik authentication, you will be redirected to a confirmation page that indicates successful Copilot extension installation.
41+
1. Restart your [Copilot-enabled app](https://docs.github.com/en/copilot/building-copilot-extensions/about-building-copilot-extensions#supported-clients-and-ides) (for example, Visual Studio and Visual Studio Code).
42+
1. Start a new chat session in Copilot.
43+
44+
## Usage
45+
46+
To use the Telerik WinForms Copilot extension:
47+
48+
1. Open the GitHub Copilot chat window in your [Copilot-enabled app](https://docs.github.com/en/copilot/building-copilot-extensions/about-building-copilot-extensions#supported-clients-and-ides) (for example, Visual Studio or VS Code).
49+
1. Ensure you are in **Chat** mode and not in **Edit** or **Agent** mode. The Edit and Agent modes do not use the Telerik Copilot extension. However, the Agent mode can use the [Telerik WinForms MCP server]({%slug ai-mcp-server%}).
50+
1. Start your prompt with `@telerikwinforms` and type your request. Verify that `@telerikwinforms` is recognized and highlighted; otherwise, the extension may not be properly installed.
51+
1. Look for a status label such as **Telerik WinForms working...** or **Telerik WinForms generating response...** in the output to confirm the extension is active.
52+
1. Grant permission to the Telerik WinForms extension to read your workspace files when prompted.
53+
1. For unrelated queries, start a new chat session in a new window to avoid context pollution from previous conversations.
54+
55+
### Sample Prompts
56+
57+
The following examples demonstrate useful prompts for the Telerik WinForms extension:
58+
59+
* "`@telerikwinforms` Create a RadGridView with 100 records each having Id, Name and Company. Group the data by Company. Sort by name. Add aggregate count function for the company column."
60+
* "`@telerikwinforms` Create a RadGridView with 100 employees records with two columns for name and company name. Include paging in the RadGridView with 20 records per page."
61+
* "`@telerikwinforms` Create a line RadChartView with 100 records of sample data. Each record should have Value plotted on the vertical axis and Date on the horizontal axis."
62+
* "`@telerikwinforms` Show me how to size all columns in GridView to take all the available space."
63+
64+
![WinForms AI Assistance Sample Prompt](images/copilot-extension001.png)
65+
66+
>tip Visit the Telerik UI for WinForms Prompt Library for more sample prompts.
67+
68+
## Number of Requests
69+
70+
A Telerik [Subscription license](https://www.telerik.com/purchase/faq/licensing-purchasing) is recommended in order to use the Telerik WinForms AI Coding Assistant without restrictions. Perpetual license holders and trial users can make a limited [number of requests per year]({%slug ai-overview%}#number-of-requests).
71+
72+
## Troubleshooting
73+
74+
If you encounter issues:
75+
76+
* Ensure the `@telerikwinforms` mention is properly highlighted in your prompt.
77+
* Verify that you have an active GitHub Copilot subscription.
78+
* Restart your IDE after installation.
79+
* Check that you're in Chat mode, not Edit or Agent mode.
80+
81+
## See Also
82+
83+
* [GitHub Copilot Documentation](https://docs.github.com/en/copilot)
84+
* [GitHub Copilot Tutorials](https://github.com/features/copilot/tutorials)
85+
* [Telerik WinForms MCP Server]({%slug ai-mcp-server%})
86+
* [Telerik UI for WinForms Documentation](https://docs.telerik.com/devtools/winforms/introduction)
23.4 KB
Loading
17.5 KB
Loading
12.4 KB
Loading

ai-coding-assistant/mcp-server.md

Lines changed: 160 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,160 @@
1+
---
2+
title: MCP Server
3+
page_title: Telerik WinForms MCP Server
4+
description: Learn how to add and use the Telerik WinForms MCP Server as a WinForms AI coding assistant and code generator for better developer productivity. The Telerik WinForms MCP server provides proprietary context about Telerik UI for WinForms to AI-powered software.
5+
slug: ai-mcp-server
6+
tags: telerik,winforms,ai,ai server,coding assistant
7+
position: 2
8+
---
9+
10+
# Telerik WinForms MCP Server
11+
12+
The Telerik WinForms [MCP (Model Context Protocol) Server](https://modelcontextprotocol.io/introduction) enhances your AI-powered development experience by providing specialized context about Telerik UI for WinForms components.
13+
14+
This MCP server enables AI-powered IDEs and tools to generate more accurate, tailored code that leverages [Telerik UI for WinForms components](https://docs.telerik.com/devtools/winforms/introduction) and APIs. You can ask complex questions about Telerik components, request specific implementations, and generate comprehensive code solutions.
15+
16+
## Prerequisites
17+
18+
To use the Telerik WinForms MCP server, you need:
19+
20+
* [Node.js](https://nodejs.org/en) 18 or newer.
21+
* An [MCP-compatible client](https://modelcontextprotocol.io/clients) that supports **MCP tools** (latest version recommended).
22+
* A [Telerik user account](https://www.telerik.com/account/?_gl=1*rbcezh*_gcl_au*NzA0NDU3NzU1LjE3NTA2NTk3NDY.*_ga*ODUxNTg5NDI5LjE2OTU2NDQ2ODI.*_ga_9JSNBCSF54*czE3NTQ1NDQ5MTQkbzE0NSRnMSR0MTc1NDU3MjMxMiRqMzAkbDAkaDA.).
23+
* An active [DevCraft or Telerik UI for WinForms license](https://www.telerik.com/purchase/individual/winforms.aspx) or a [Telerik UI for WinForms trial](https://www.telerik.com/try/ui-for-winforms).
24+
* A [WinForms application that includes Telerik UI for WinForms](https://docs.telerik.com/devtools/winforms/getting-started/first-steps).
25+
26+
## Installation
27+
28+
Install the Telerik WinForms MCP server using npm:
29+
30+
```bash
31+
npm i @progress/telerik-winforms-mcp@latest
32+
```
33+
34+
### Configuration
35+
36+
Use these settings when configuring the server in your MCP client:
37+
38+
| Setting | Value |
39+
|---------|-------|
40+
| Package Name | `@progress/telerik-winforms-mcp` |
41+
| Type | `stdio` (standard input/output transport) |
42+
| Command | `npx` |
43+
| Arguments | `-y` |
44+
| Server Name | `telerik-winforms-mcp` (customizable) |
45+
46+
### License Configuration
47+
48+
Add your [Telerik license key]({%slug license-key%}) as an environment parameter in your `mcp.json` file using one of these options:
49+
50+
Option 1: License File Path (Recommended)
51+
52+
```json
53+
"env": {
54+
"TELERIK_LICENSE_PATH": "THE_PATH_TO_YOUR_LICENSE_FILE"
55+
}
56+
```
57+
58+
The THE_PATH_TO_YOUR_LICENSE_FILE should point to the telerik-license.txt file, which is usually located in the AppData folder. So, the field often will look like this: "TELERIK_LICENSE_PATH": "%appdata%/Telerik/telerik-license.txt"
59+
60+
Option 2: Direct License Key
61+
62+
```json
63+
"env": {
64+
"TELERIK_LICENSE": "YOUR_LICENSE_KEY_HERE"
65+
}
66+
```
67+
68+
> Option 1 is recommended unless you're sharing settings across different systems. Remember to [update your license key]({%slug license-key%}#updating-your-license-key) when necessary.
69+
70+
## Visual Studio
71+
72+
For complete setup instructions, see [Use MCP servers in Visual Studio](https://learn.microsoft.com/en-us/visualstudio/ide/mcp-servers).
73+
74+
> Early Visual Studio 17.14 versions require the Copilot Chat window to be open when opening a solution for the MCP server to work properly.
75+
76+
### Workspace-Specific Setup:
77+
78+
1. Add `.mcp.json` to your solution folder:
79+
80+
```json
81+
{
82+
"inputs": [],
83+
"servers": {
84+
"telerik-winforms-mcp": {
85+
"type": "stdio",
86+
"command": "npx",
87+
"args": ["-y", "@progress/telerik-winforms-mcp@latest"],
88+
"env": {
89+
"TELERIK_LICENSE_PATH": "THE_PATH_TO_YOUR_LICENSE_FILE",
90+
// or
91+
"TELERIK_LICENSE": "YOUR_LICENSE_KEY"
92+
}
93+
}
94+
}
95+
}
96+
```
97+
98+
2. Restart Visual Studio.
99+
3. Enable the `telerik-winforms-mcp` tool in the [Copilot Chat window's tool selection dropdown](https://learn.microsoft.com/en-us/visualstudio/ide/mcp-servers?view=vs-2022#configuration-example-with-github-mcp-server).
100+
101+
![WinForms AI Assistance MCP Server](images/ai-mcp-server001.png)
102+
103+
### Global Setup:
104+
105+
Add the `.mcp.json` file to your user directory (`%USERPROFILE%`, e.g., `C:\Users\YourName\.mcp.json`).
106+
107+
## Usage
108+
109+
To use the Telerik MCP Server:
110+
111+
1. Start your prompt with one of these triggers:
112+
- `/telerik` / `@telerik` / `#telerik`
113+
- `/telerikwinforms` / `@telerikwinforms` / `#telerikwinforms`
114+
- `#telerik-winforms-mcp`
115+
116+
2. Verify server activation by looking for these messages:
117+
- Visual Studio: `Running telerik-winforms-mcp`
118+
- Visual Studio Code: `Running telerik-winforms-assistant`
119+
- Cursor: `Calling MCP tool telerik-winforms-mcp`
120+
121+
3. Grant permissions when prompted (per session, workspace, or always).
122+
123+
4. Start fresh sessions for unrelated prompts to avoid context pollution.
124+
125+
You can check the Output pane of Visual Studio for diagnostics information related to Copilot. To display the relevant information, select to show output from GitHub Copilot.
126+
127+
![WinForms AI Assistance MCP Server](images/ai-mcp-server002.png)
128+
129+
### Improving Server Usage
130+
131+
To increase the likelihood of the Telerik MCP server being used, add custom instructions to your AI tool:
132+
- [GitHub Copilot custom instructions](https://docs.github.com/en/copilot/customizing-copilot/adding-repository-custom-instructions-for-github-copilot#about-repository-custom-instructions-for-github-copilot-chat)
133+
- [Cursor rules](https://docs.cursor.com/context/rules)
134+
135+
### Sample Prompts
136+
137+
The following examples demonstrate useful prompts for the Telerik WinForms MCP Server:
138+
139+
* "`/telerik` Generate a RadGridView with sorting and paging. Bind it to a Person model with a sample ViewModel."
140+
* "`/telerikwinforms` Create a RadDropDownList showing a product list of 20 items. Include Product class and sample data."
141+
* "`/telerik` Build a RadListView with sorting and filtering capabilities."
142+
143+
## Number of Requests
144+
145+
A Telerik [Subscription license](https://www.telerik.com/purchase/faq/licensing-purchasing) is recommended in order to use the Telerik WinForms AI Coding Assistant without restrictions. Perpetual license holders and trial users can make a limited [number of requests per year]({%slug ai-overview%}#number-of-requests).
146+
147+
## Local AI Model Integration
148+
149+
You can use the Telerik WinForms MCP server with local large language models (LLMs):
150+
151+
1. Run a local model, for example, through [Ollama](https://ollama.com).
152+
2. Use a bridge package like [MCP-LLM Bridge](https://github.com/patruff/ollama-mcp-bridge).
153+
3. Connect your local model to the Telerik MCP server.
154+
155+
This setup allows you to use the Telerik AI Coding Assistant without cloud-based AI models.
156+
157+
## See Also
158+
159+
* [Telerik WinForms GitHub Copilot Extension]({%slug ai-copilot-extension%})
160+
* [AI Coding Assistant Overview]({%slug ai-overview%})

0 commit comments

Comments
 (0)