# US 2025/0095638 A1 · Zero-shot intent classification using a semantic similarity aware contrastive loss and large language model

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

- Number: US 2025/0095638 A1
- Document ID: US20250095638A1
- Status: Published application
- Kind: A1
- Application number: 18/891,686
- Filed: 2024-09-20
- Published: 2025-03-20
- Earliest claimed: 2023-09-20
- Assignees: Samsung Electronics Co., Ltd.
- Applicants: Samsung Electronics Co., Ltd.
- Inventors: Jaejin CHO; Rakshith Sharma Srinivasa; Chou-chang Yang; Yashas Malur Saidutta; Ching-Hua Lee; Yilin Shen; Hongxia Jin
- Web page: https://patentgrep.com/patent/US20250095638A1

## CPC

- G10L 15/063: {Training}
- G06F 40/30: Semantic analysis
- G06N 3/045: Combinations of networks
- G06N 3/08: Learning methods
- G06N 20/00: Machine learning
- G10L 15/16: using artificial neural networks
- G10L 15/1815: {Semantic context, e.g. disambiguation of the recognition hypotheses based on word meaning}
- G10L 15/1822: {Parsing for meaning understanding}
- G10L 15/183: using context dependencies, e.g. language models
- G10L 2015/0635: {updating or merging of old and new templates; Mean values; Weighting}
- G10L: SPEECH ANALYSIS TECHNIQUES OR SPEECH SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING TECHNIQUES; SPEECH OR AUDIO CODING OR DECODING
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS

## Abstract

A method includes: receiving one or more training text sentences; generating one or more training vectors based on inputting the one or more training sentences input into a text encoder, the one or more training vectors corresponding to one or more operations that an electronic device is configured to perform; generating one or more speech vectors based on one or more speech utterances input into a speech encoder; generating a similarity matrix that compares each of the one or more training vectors with each of the one or more speech vectors; and updating at least one of the text encoder and the speech encoder based on the similarity matrix.

## Claims

### Claim 1

A method performed by at least one processor, the method comprising:
receiving one or more training text sentences;
generating one or more training vectors based on inputting the one or more training sentences input into a text encoder, the one or more training vectors corresponding to one or more operations that an electronic device is configured to perform;
generating one or more speech vectors based on one or more speech utterances input into a speech encoder;
generating a similarity matrix that compares each of the one or more training vectors with each of the one or more speech vectors; and
updating at least one of the text encoder and the speech encoder based on the similarity matrix.

### Claim 2 (depends on 1)

The method according to claim 1, wherein the one or more training text sentences are received from a supervised dataset that labels each text sentence from the one or more text sentences with a label corresponding to an operation from the one or more operations.

### Claim 3 (depends on 1)

The method according to claim 1, wherein the similarity matrix comprises comparing each training vector from the one or more training vectors with each speech vector from the one or more speech vectors by determining a similarity score between a respective training vector and a respective speech vector that indicates a degree of similarity between the respective training vector and the respective speech vector.

### Claim 4 (depends on 1)

The method according to claim 1, wherein a sum of each of the similarity scores in each column of the similarity matrix is 1.

### Claim 5 (depends on 1)

The method according to claim 1, wherein each diagonal entry in the similarity matrix has a higher similarity score than a non-diagonal entry.

### Claim 6 (depends on 5)

The method according to claim 5, wherein at least one non-diagonal entry in the similarity matrix has a value between −1 and 1.

### Claim 7 (depends on 1)

The method according to claim 1, wherein the updating comprises updating at least one of the text encoder and the speech encoder such that a first pair of a speech vector and a training vector in the similarity matrix that has a higher degree of similarity than a second pair of a speech vector and a training vector has a higher similarity score.

### Claim 8

A method performed by at least one processor, the method comprising:
receiving, from a large language model, one or more text sentences based on one or more text prompts input into the LLM;
generating one or more class vectors based on the one or more text sentences input into a pre-trained text encoder, the one or more class vectors corresponding to one or more operations that an electronic device is configured to perform;
generating a speech vector based on a speech utterance input into a pre-trained speech encoder;
generating a similarity score between each class vector and the speech vector; and
selecting a class vector from the one or more class vectors having a highest similarity score,
wherein the electronic device is configured to perform an operation associated with the selected class vector.

### Claim 9 (depends on 8)

The method according to claim 8, wherein the one or more text prompts comprise an instruction that instructs the LLM to generate N different sentences corresponding to the one or more operations of the electronic device.

### Claim 10 (depends on 9)

The method according to claim 9, wherein each of the N different sentences is associated with a scenario label corresponding to a respective operation of the one or more operations of the electronic device.

### Claim 11 (depends on 10)

The method according to claim 10, wherein the text encoder performs an averaging of sentences having a same scenario label to generate a respective class vector.

### Claim 12 (depends on 8)

The method according to claim 8, wherein the one on or more class vectors includes at least one class vector corresponding to an operation that was not used in the training of the pre-trained text encoder or the pre-trained speech encoder.

### Claim 13 (depends on 9)

The method according to claim 9, wherein at least one of the pre-trained text encoder and the pre-trained speech encoder is trained with a supervised dataset.

### Claim 14

An apparatus comprising:
a memory storing one or more instructions; and
a processor operatively coupled to the memory and configured to execute the one or more instructions stored in the memory,
wherein the one or more instructions, when executed by the processor, cause the apparatus to:
receive one or more training text sentences;
generate one or more training vectors based on inputting the one or more training sentences input into a text encoder, the one or more training vectors corresponding to one or more operations that an electronic device is configured to perform;
generate one or more speech vectors based on one or more speech utterances input into a speech encoder;
generate a similarity matrix that compares each of the one or more training vectors with each of the one or more speech vectors; and
update at least one of the text encoder and the speech encoder based on the similarity matrix.

### Claim 15 (depends on 14)

The apparatus according to claim 14, wherein the one or more training text sentences are received from a supervised dataset that labels each text sentence from the one or more text sentences with a label corresponding to an operation from the one or more operations.

### Claim 16 (depends on 14)

The apparatus according to claim 14, wherein the similarity matrix comprises comparing each training vector from the one or more training vectors with each speech vector from the one or more speech vectors by determining a similarity score between a respective training vector and a respective speech vector that indicates a degree of similarity between the respective training vector and the respective speech vector.

### Claim 17 (depends on 14)

The apparatus according to claim 14, wherein a sum of each of the similarity scores in each column of the similarity matrix is 1.

### Claim 18 (depends on 14)

The apparatus according to claim 14, wherein each diagonal entry in the similarity matrix has a higher similarity score than a non-diagonal entry.

### Claim 19 (depends on 18)

The apparatus according to claim 18, wherein at least one non-diagonal entry in the similarity matrix has a value between −1 and 1.

### Claim 20 (depends on 14)

The apparatus according to claim 14, wherein the one or more instructions, when executed by the processor, cause the apparatus to:
update of the at least one text encoder and the speech encoder comprises updating at least one of the text encoder and the speech encoder such that a first pair of a speech vector and a training vector in the similarity matrix that has a higher degree of similarity than a second pair of a speech vector and a training vector has a higher similarity score.
