# US 2024/0202452 A1 · Prompt generation simulating fine-tuning for a machine learning model

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2024/0202452 A1
- Document ID: US20240202452A1
- Status: Published application
- Kind: A1
- Application number: 18/129,772
- Filed: 2023-03-31
- Published: 2024-06-20
- Earliest claimed: 2022-12-19
- Assignees: Microsoft Technology Licensing, LLC
- Applicants: Microsoft Technology Licensing, LLC
- Inventors: Samuel Edward SCHILLACE; Umesh MADAN; Devis LUCATO
- Web page: https://patentgrep.com/patent/US20240202452A1

## CPC

- G06F 40/30: Semantic analysis
- G06N 3/045: Combinations of networks
- G06N 3/0475: Generative networks
- G06F 16/35: Clustering; Classification
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS

## Abstract

Aspects of the present disclosure relate to systems and methods for generating one or more prompts based on an input and the semantic context associated with the input. In examples, the prompts may be provided as input to one or more general ML models to provide a semantic context around the input and/or output of the model. The prompt simulates training and fine-tuned specialization of the general ML model without the need to use a fine-tuning process to actually train the general ML model into a fine-tuned state. Additionally, the model output may be evaluated for responsiveness to the input prior to being returned to the user. An advantage of the present disclosure is that it allows a general ML model to be applied to a plurality of applications without the need for expensive and time-consuming training to fine-tune the ML model.

## Claims

### Claim 1

A system comprising:
at least one processor; and
memory storing instructions that, when executed by the at least one processor, cause the system to perform a set of operations, the set of operations comprising:
receive an input;
generate a task request based on the received input;
determine a task objective based on the input and task request;
generate one or more prompts based upon the task objective and task request, wherein the one or more prompts include additional context relating to the input for a machine learning model;
process the one or more prompts with the machine learning model to generate a model output; and
provide the model output to an application of a computing device.

### Claim 2 (depends on 1)

The system of claim 1, further comprising:
store one or more of the input, task request, task objective, prompt, and model output.

### Claim 3 (depends on 1)

The system of claim 1, further comprising:
embed one or more questions for the machine learning model in the one or more prompts;
receive from the machine learning model one or more requests for additional context, information, or prompt templates in response to the one or more questions;
generate one or more updated prompts with the requested context, information, or prompt templates; and
process the one or more updated prompts with the machine learning model to generate a model output.

### Claim 4 (depends on 1)

The system of claim 1, wherein generate one or more prompts further comprising:
generate one or more embeddings for one or more of the input, task request, and task objective;
insert the one or more embeddings in an embedding object memory;
determine one or more prompt templates that are semantically associated to the one or more embeddings; and
populate the one or more prompt templates into a prompt.

### Claim 5 (depends on 1)

The system of claim 1, further comprising:
evaluating if the model output for responsive to the input.

### Claim 6 (depends on 5)

The system of claim 5, further comprising:
receive the model output;
generate a score for the model output;
determine if the score is below a threshold value; and
when the score is below a threshold value, generate an updated prompt.

### Claim 7 (depends on 6)

The system of claim 6, further comprising:
when the score meets or exceeds the threshold value, provide the model output to an application of the computing device.

### Claim 8 (depends on 1)

The system of claim 1, wherein the machine learning model is a large language generative transformer model.

### Claim 9

A method comprising:
receiving a input;
generating a task request based on the received input;
determining a task objective based on the input and task request;
generating one or more prompts based upon the task objective and task request, wherein the one or more prompts include additional context relating to the input for a machine learning model;
processing the one or more prompts with a machine learning model to generate a model output;
providing, if the model output is responsive to the input, the model output to an application of a computing device.

### Claim 10 (depends on 9)

The method of claim 9, further comprising:
store one or more of the input, task request, task objective, prompt, and model output.

### Claim 11 (depends on 9)

The method of claim 9, further comprising:
embed one or more questions for the machine learning model in the one or more prompts;
receive from the machine learning model one or more requests for additional context, information, or prompt templates in response to the one or more questions;
generate one or more updated prompts with the requested context, information, or prompt templates; and
process the one or more updated prompts with the machine learning model to generate a model output.

### Claim 12 (depends on 9)

The method of claim 9, wherein generate one or more prompts further comprising:
generate one or more embeddings for one or more of the input, task request, and task objective;
insert the one or more embeddings in an embedding object memory;
determine one or more prompt templates that are semantically associated to the one or more embeddings; and
populate the one or more prompt templates into a prompt.

### Claim 13 (depends on 9)

The method of claim 9, further comprising:
evaluating if the model output for responsive to the input.

### Claim 14 (depends on 13)

The method of claim 13, further comprising:
receive the model output;
generate a score for the model output;
determine if the score is below a threshold value; and
when the score is below a threshold value, generate an updated prompt.

### Claim 15 (depends on 14)

The method of claim 14, further comprising:
when the score meets or exceeds the threshold value, provide the model output to an application of the computing device.

### Claim 16 (depends on 1)

The system of claim 1, wherein the machine learning model is a large language generative transformer model.

### Claim 17

A computer storage media including instructions, which when executed by a processor, cause the processor to:
receive an input;
generate a task request based on the received input;
determine a task objective based on the input and task request;
generate one or more prompts based upon the task objective and task request, wherein the one or more prompts include additional context relating to the input for a machine learning model;
process the one or more prompts with the machine learning model to generate a model output; and
provide the model output to an application of a computing device.

### Claim 18 (depends on 17)

The computer storage media of claim 17, further comprising:
embed one or more questions for the machine learning model in the one or more prompts;
receive from the machine learning model one or more requests for additional context, information, or prompt templates in response to the one or more questions;
generate one or more updated prompts with the requested context, information, or prompt templates; and
process the one or more updated prompts with the machine learning model to generate a model output.

### Claim 19 (depends on 17)

The computer storage media of claim 17, wherein generate one or more prompts further comprising:
generate one or more embeddings for one or more of the input, task request, and task objective;
insert the one or more embeddings in an embedding object memory;
determine one or more prompt templates that are semantically associated to the one or more embeddings; and
populate the one or more prompt templates into a prompt.

### Claim 20 (depends on 17)

The computer storage media of claim 17, wherein the machine learning model is a large language generative transformer model.
