# US 2025/0166647 A1 · Adaptive Codebook for Neural Network-Based Audio Codec

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

- Number: US 2025/0166647 A1
- Document ID: US20250166647A1
- Status: Published application
- Kind: A1
- Application number: 18/902,309
- Filed: 2024-09-30
- Published: 2025-05-22
- Earliest claimed: 2023-11-20
- Assignees: Tencent America LLC
- Applicants: Tencent America LLC
- Inventors: Sheng LIN; Xin ZHAO; Shan LIU
- Web page: https://patentgrep.com/patent/US20250166647A1

## CPC

- G10L 19/032: Quantisation or dequantisation of spectral components
- G10L 19/038: Vector quantisation, e.g. TwinVQ audio
- G10L 2019/0002: {Codebook adaptations}
- G10L: SPEECH ANALYSIS TECHNIQUES OR SPEECH SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING TECHNIQUES; SPEECH OR AUDIO CODING OR DECODING

## Abstract

This disclosure relates generally to audio coding and particularly to methods and systems for audio coding based on neural networks. In particular, feature vectors generated by a neural network audio encoder may be quantized using adaptive codebooks and/or grouped codebooks. Correspondingly, the encoded bitstream may be processed via a dequantization process using the adaptive codebooks and/or grouped codebooks. The adaptive codebooks or grouped code books may be selected to preserve a maximum bitrate and potentially increase coding efficiency

## Claims

### Claim 1

A method for encoding an audio segment, comprising:
generating a set of feature vectors by processing the audio segment using a pretrained neural-network audio encoder; and
quantizing the set of feature vectors using at least one codebook to generate, for the set of feature vectors, a set of codebook indexes to feature vector entries in the at least one codebook as part of an encoded bitstream for the audio segment,
wherein the at least one codebook is adaptively selected and the adaptive selection is indicated in the encoded bitstream by explicit signaling or implicitly.

### Claim 2 (depends on 1)

The method of claim 1, wherein the at least one codebook comprises two or more adaptively selected codebooks, each of the two or more adaptively selected codebooks is used to quantize a different feature vectors of the set of the feature vectors of the audio segment.

### Claim 3 (depends on 1)

The method of claim 1, wherein:
the set of feature vectors are split into N groups of feature vectors corresponding to N group indexes, N being a positive integer;
the at least one codebook comprises N adaptively selected codebooks respectively corresponding to the N groups of feature vectors; and
the set of codebook indexes for the set of feature vectors are generated within indexing spaces of corresponding N adaptively selected codebooks.

### Claim 4 (depends on 3)

The method of claim 3, wherein sizes of each of the N adaptively selected codebooks are powers of 2.

### Claim 5 (depends on 3)

The method of claim 3, where a total size of the N adaptively selected codebooks is bounded by a predefined upper limit.

### Claim 6 (depends on 3)

The method of claim 3, wherein the N group indexes are determined by a relative encoding order of the N groups of feature vectors.

### Claim 7 (depends on 1)

The method of claim 1, further comprising:
prior to quantizing the set of feature vectors, determining a quantization mode for the set of feature vectors as an adaptive codebook mode among at least two quantization modes comprising the adaptive codebook mode and a fixed codebook mode; and
indicating the quantization mode for the set of feature vectors by an explicit signaling in the encoded bitstream or implicitly.

### Claim 8 (depends on 7)

The method of claim 7, wherein the quantization mode for the set of feature vectors is implicitly derived coded information.

### Claim 9 (depends on 1)

The method of claim 1, wherein the at least one codebook for quantizing the audio segment differs from codebooks adaptively selected for another audio segment.

### Claim 10 (depends on 1)

The method of claim 1, wherein the at least one codebook is adaptively selected or updated based on reconstructed samples of another audio segment.

### Claim 11 (depends on 1)

The method of claim 1, wherein quantization of audio segments associated with a same time duration for different channels share same codebooks.

### Claim 12 (depends on 1)

The method of claim 1, wherein the at least one codebook is adaptively selected based on a type of the audio segment.

### Claim 13 (depends on 12)

The method of claim 12, wherein the type of the audio segment is one of a music type, a speech type, and a general audio type, a mono audio type, and a stereo audio type.

### Claim 14 (depends on 12)

The method of claim 12, wherein the type of the audio segment is explicitly signaled in the encoded bitstream or implicitly derivable.

### Claim 15

An electronic device comprising a memory for storing instructions and at least one processor configured to execute the instructions to:
receive an encoded bitstream of an audio segment;
determine at least one codebook;
decode from the encoded bitstream a set of codebook indexes to entries in the at least one codebook;
generate a set of feature vectors of the audio segment according to the at least one codebook and the set of codebook indexes; and
process the set of feature vectors to generate a decoded audio segment using a neural-network audio decoder,
wherein the at least one codebook is adaptively selected based on explicit signaling or implicit derivation from the encoded bitstream.

### Claim 16 (depends on 15)

The electronic device of claim 15, wherein:
the at least one codebook comprises N
the at least one codebook comprises N adaptively selected codebooks respectively corresponding to N groups of the set of feature vectors corresponding to N group indexes, N being a positive integer; and
the set of codebook indexes are within indexing spaces of corresponding N adaptively selected codebooks.

### Claim 17 (depends on 15)

The electronic device of claim 15, the at least one processor is configured to execute the instructions to:
prior to determining the at least one codebook, determine a codebook mode for encoding the audio segment as an adaptive codebook mode among at least two codebook modes comprising the adaptive codebook mode and a fixed codebook mode by an explicit signaling in or implicit derivation from the encoded bitstream.

### Claim 18 (depends on 15)

The electronic device of claim 15, wherein the at least one codebook for the audio segment differs from codebooks adaptively selected for another audio segment.

### Claim 19 (depends on 15)

The electronic device of claim 15, wherein:
the at least one codebook is adaptively selected based on a type of the audio segment;
the type of the audio segment is one of a music type, a speech type, and a general audio type, a mono audio type, and a stereo audio type; and
the type of the audio segment is explicitly signaled in the encoded bitstream or implicitly derivable.

### Claim 20

A method for processing an audio segment, comprising converting the audio segment to an encoded audio bitstream, wherein the encoded audio bitstream comprises:
an indication that the audio segment is encoded based on N adaptively selected codebooks each containing entries of audio feature vectors, N being a positive integer; and
N groups of encoded indexes corresponding to the N adaptively selected codebooks, the N groups of encoded indexes being associated with a set of feature vectors of the audio segment.
