microsoft/teams.net

Public

mirrored fromhttps://github.com/microsoft/teams.netAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
8e11e5e231765b6fbeae91b4033a354e2340d0af

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

Libraries/Microsoft.Teams.AI/Annotations/Prompt.InstructionsAttribute.cs

23lines · modecode

1// Copyright (c) Microsoft Corporation. All rights reserved.
2// Licensed under the MIT License.
3
4using Microsoft.Teams.AI.Templates;
5
6namespace Microsoft.Teams.AI.Annotations;
7
8public static partial class Prompt
9{
10 [AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct, Inherited = true)]
11 public class InstructionsAttribute : Attribute
12 {
13 /// <summary>
14 /// the prompts instructions
15 /// </summary>
16 public ITemplate Instructions { get; private set; }
17
18 public InstructionsAttribute(params string[] Instructions)
19 {
20 this.Instructions = new StringTemplate(string.Join("\n", Instructions));
21 }
22 }
23}