# US 10,871,949 B2 · Integration of learning models into a software development system

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

- Number: US 10,871,949 B2
- Document ID: US10871949B2
- Status: Granted
- Kind: B2
- Application number: 16/430,351
- Filed: 2019-06-03
- Published: 2019-09-19
- Granted: 2020-12-22
- Earliest claimed: 2017-06-03
- Assignees: Apple Inc.
- Applicants: Apple Inc.
- Inventors: Alexander B. Brown; Michael R. Siracusa; Gaurav Kapoor; Elizabeth Ottens; Christopher M. Hanson; Zachary A. Nation; Vrushali Mundhe; Srikrishna Sridhar
- Web page: https://patentgrep.com/patent/US10871949B2

## CPC

- G06F 8/315: {Object-oriented languages}
- G06F 8/35: model driven
- G06N 20/00: Machine learning
- G06F 8/10: Requirements analysis; Specification techniques
- G06F 8/30: Creation or generation of source code
- G06F 8/36: Software reuse
- G06F 8/60: Software deployment
- G06F 8/71: Version control (security arrangements therefor G06F21/57); Configuration management
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS

## Abstract

The subject technology transforms a machine learning model into a transformed machine learning model in accordance with a particular model specification when the machine learning model does not conform to the particular model specification, the particular model specification being compatible with an integrated development environment (IDE). The subject technology generates a code interface and code for the transformed machine learning model, the code interface including code statements in the object oriented programming language, the code statements corresponding to an object representing the transformed machine learning model. Further, the subject technology provides the generated code interface and the code for display in the IDE, the IDE enabling modifying of the generated code interface and the code.

## Claims

### Claim 1

A method comprising:
transforming a machine learning model into a transformed machine learning model in accordance with a particular model specification when the machine learning model does not conform to the particular model specification, the particular model specification being compatible with an integrated development environment (IDE);
generating a code interface and code for the transformed machine learning model, the code interface including code statements in an object oriented programming language, the code statements corresponding to an object representing the transformed machine learning model; and
providing the generated code interface and the generated code for display in the IDE, the IDE enabling modifying of the generated code interface and the code.

### Claim 2 (depends on 1)

The method of claim 1, further comprising:
receiving additional code corresponding to calling a function provided by the code for the transformed machine learning model.

### Claim 3 (depends on 2)

The method of claim 2, further comprising:
compiling the code interface, the code for the transformed machine learning model, and the additional code into a compiled machine learning model, wherein compiling includes generating object code for the object oriented programming language; and
sending the compiled machine learning model as part of a software package to a runtime environment of a target computing device for execution.

### Claim 4 (depends on 3)

The method of claim 3, wherein compiling the code interface, the code for the transformed machine learning model, and the additional code for the transformed machine learning model into the compiled machine learning model further comprises:
combining object code corresponding to the code interface, the code, and the additional code for the transformed machine learning model.

### Claim 5 (depends on 3)

The method of claim 3, further comprising:
performing preprocessing on the code interface, the code for the transformed machine learning model, and the additional code, wherein the preprocessing further comprises:
indexing the code interface, the code for the transformed machine learning model, and the additional code.

### Claim 6 (depends on 1)

The method of claim 1, wherein generating the code interface and code for the transformed machine learning model further comprises:
generating a function for performing an operation of the transformed machine learning model, the function including code written in an object oriented programming language.

### Claim 7 (depends on 6)

The method of claim 6, wherein the function further comprises an input variable that corresponds to machine learning data associated with the transformed machine learning model.

### Claim 8 (depends on 1)

The method of claim 1, wherein generating the code interface and code for the transformed machine learning model further comprises:
determining an input data type used by the machine learning model; and
determining a target data type for transformed machine learning model based on the input data type, wherein the input data type is different than the target data type.

### Claim 9 (depends on 1)

The method of claim 1, wherein generating the code interface and code for the transformed machine learning model further comprises:
determining hardware or processing requirements for the machine learning model, the hardware or processing requirements including information indicating a GPU, a CPU, an ASIC, or a cloud computing service.

### Claim 10 (depends on 1)

The method of claim 1, wherein generating the code interface and code for the transformed machine learning model further comprises:
generating data objects corresponding to machine learning primitives included in the machine learning model.

### Claim 11 (depends on 1)

The method of claim 1, wherein generating the code interface and code for the transformed machine learning model further comprises:
mapping a function call to an input data type required by the transformed machine learning model, the input data type comprising an input vector or a matrix.

### Claim 12 (depends on 1)

The method of claim 1, further comprising:
tagging the transformed machine learning model to indicate that the machine learning model has been transformed into the particular model specification, wherein tagging includes assigning an identifier to the transformed machine learning model.

### Claim 13

A system comprising;
a processor;
a memory device containing instructions, which when executed by the processor cause the processor to:
obtain a machine learning model corresponding to a particular model specification that is compatible with an integrated development environment (IDE);
generate a code interface and code for the machine learning model, the code interface including code statements in an object oriented programming language, the code statements corresponding to an object representing the machine learning model; and
provide the generated code interface and the generated code for display in the IDE, the IDE enabling modifying of the generated code interface and the code.

### Claim 14 (depends on 13)

The system of claim 13, wherein the memory device contains further instructions, which when executed by the processor, further cause the processor to:
receive additional code corresponding to calling a function provided by the code for the machine learning model.

### Claim 15 (depends on 14)

The system of claim 14, wherein the memory device contains further instructions, which when executed by the processor, further cause the processor to:
compile the code interface, the code for the machine learning model, and the additional code into a compiled machine learning model, wherein compiling includes generating object code for the object oriented programming language; and
send the compiled machine learning model as part of a software package to a runtime environment of a target computing device for execution.

### Claim 16 (depends on 15)

The system of claim 15, wherein to compile the code interface, the code for the machine learning model, and the additional code for the machine learning model into the compiled machine learning model further comprises:
combining object code corresponding to the code interface, the code, and the additional code for the machine learning model.

### Claim 17 (depends on 15)

The system of claim 15, wherein the memory device contains further instructions, which when executed by the processor, further cause the processor to:
perform preprocessing on the code interface, the code for the machine learning model, and the additional code, wherein the preprocessing further comprises:
indexing the code interface, the code for the machine learning model, and the additional code.

### Claim 18

A non-transitory computer-readable medium comprising instructions, which when executed by a computing device, cause the computing device to perform operations comprising:
generating a code interface and code for a machine learning model, the code interface including code statements in an object oriented programming language, the code statements corresponding to an object representing the machine learning model; and
providing the generated code interface and the generated code for display in an integrated development environment (IDE), the IDE enabling modifying of the generated code interface and the code.

### Claim 19 (depends on 18)

The non-transitory computer-readable medium of claim 18, wherein the operations further comprise:
verifying that the machine learning model is compliant with a particular model specification that is compatible with the IDE prior to generating the code interface and the code.

### Claim 20 (depends on 18)

The non-transitory computer-readable medium of claim 18, wherein generating the code interface and code for the machine learning model further comprises:
generating a function for performing an operation of the machine learning model, the function including code written in an object oriented programming language.
