IP Library › Granted Patent US 10,698,664
Granted Patent B2
US 10,698,664 · App. 15/851,734 · Granted Jun 30, 2020

API mashup generation

Inventors: Mehdi Bahrami (Santa Clara, CA); Lei Liu (San Jose, CA); Wei-Peng Chen (Fremont, CA)
Assignee: FUJITSU LIMITED
G06F8/36G06F8/30G06F8/38G06F8/74G06F9/54G06F16/90344
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 10,698,664
App. No.
15/851,734
Granted
Jun 30, 2020
Kind
B2
Abstract

A method may include extracting information regarding a software project based on source code of the software project, where the information includes a description of the source code and computer-readable source code. The method may also include identifying at least two application programming interface (API) calls within the information, and extracting metadata regarding at least one of the APIs from the information. The method may additionally include, using the metadata, analyzing the computer-readable source code to determine a correlation between the two API calls. The method may also include, based on the correlation and using a first of the two API calls, generating computer source code that combines the first API call and an additional API call in an API mashup.

Claims (81)

1. A method, comprising:

extracting information regarding a first software project based on source code of the first software project, the information including at least a description of the source code and computer-readable source code;

identifying at least two application programming interface (API) calls invoking respective APIs within the information;

extracting metadata regarding at least one of the APIs from the information;

using the metadata, analyzing the computer-readable source code to determine a correlation between the at least two API calls, comprising:

determining a first output of a first API of the at least two APIs; and

determining a first set of processing of the first software project that occurs on the first output to yield a second input for a second API of the at least two APIs;

determining a third output of a third API in a second software project;

determining a second set of processing that occurs on the third output in the second software project to yield the second input for the second API;

determining a third set of processing of a third software project that occurs on the first output to yield a fourth input for a fourth API;

deriving a fourth set of processing by:

observing differences between the first set of processing and the third set of processing; and

applying the differences to the second set of processing to yield the fourth set of processing; and

based on the correlation, generating computer source code that combines the third API call invoking the third API, the fourth set of processing, and the fourth API call invoking the fourth API in an API mashup.

2. The method of claim 1 , wherein generating computer source code includes:

detecting that the third API call is in a different programming language than the fourth API call; and

converting the fourth API call into computer source code consistent with a programming language of the source code of the second software project.

3. The method of claim 1 , wherein analyzing the computer-readable source code includes:

determining a third input of the third API;

determining that a fifth output of a fifth API in a fourth software project includes the third input; and

wherein generating computer source code includes combining code from calling the fifth API and code from calling the third API into the API mashup.

4. The method of claim 1 , wherein extracting metadata includes:

searching the description to identify any strings of characters that include API or synonyms of API;

determining whether the identified string of characters are associated with introducing new APIs or using existing APIs; and

extracting at least one of an API title, an API uniform resource locator (URL), an API host, an example usage, an installation guide, or an API dependency from the description to facilitate the determination of the correlation.

5. The method of claim 4 , wherein determining whether the identified string of characters are associated with introducing new APIs or using existing APIs includes one of searching a list of known APIs for a given API associated with the string of characters, or processing the description for terms identifying that the first software project source code is introducing the given API as source code of a new API.

6. The method of claim 1 , wherein analyzing the computer-readable source code includes:

extracting variables from the source code;

determining types and relationships of the extracted variables; and

identifying any API calls in the source code; and

identifying usages for each of the identified API calls based on the types and relationships between variables used in the identified API calls; and

wherein generating computer source code is based on the identified usages.

7. One or more non-transitory computer-readable media containing instructions, which, when executed by one or more processors, cause a system to perform operations, the operations comprising:

extracting information regarding a first software project based on source code of the first software project, the information including at least a description of the source code and computer-readable source code;

identifying at least two application programming interface (API) calls invoking respective APIs within the information;

extracting metadata regarding at least one of the APIs from the information;

using the metadata, analyzing the computer-readable source code to determine a correlation between the at least two API calls, comprising:

determining a first output of a first API of the at least two APIs; and

determining a first set of processing of the first software project that occurs on the first output to yield a second input for a second API of the at least two APIs;

determining a third output of a third API in a second software project;

determining a second set of processing that occurs on the third output in the second software project to yield the second input for the second API;

determining a third set of processing of a third software project that occurs on the first output to yield a fourth input for a fourth API;

deriving a fourth set of processing by:

observing differences between the first set of processing and the third set of processing; and

applying the differences to the second set of processing to yield the fourth set of processing; and

based on the correlation, generating computer source code that combines the third API call invoking the third API, the fourth set of processing, and the fourth API call invoking the fourth API in an API mashup.

8. The computer-readable media of claim 7 , wherein generating the computer source code includes:

detecting that the third API call is in a different programming language than the fourth API call; and

converting the fourth API call into computer source code consistent with a programming language of the source code of the second software project.

9. The computer-readable media of claim 7 , wherein analyzing the computer-readable source code includes:

determining a third input of the third API;

determining that a fifth output of a fifth API in a fourth software project includes the third input; and

wherein generating computer source code includes combining code from calling the fifth API and code from calling the third API into the API mashup.

10. The computer-readable media of claim 7 , wherein extracting metadata includes:

searching the description to identify any strings of characters that include API or synonyms of API;

determining whether the identified string of characters are associated with introducing new APIs or using existing APIs; and

extracting at least one of an API title, an API uniform resource locator (URL), an API host, an example usage, an installation guide, or an API dependency from the description.

11. The computer-readable media of claim 10 , wherein determining whether the identified string of characters are associated with introducing new APIs or using existing APIs includes one of searching a list of known APIs for a given API associated with the string of characters, or processing the description for terms identifying that the first software project source code is introducing the given API as source code of a new API.

12. A system comprising:

one or more processors; and

one or more non-transitory computer-readable media containing instructions, which, when executed by the one or more processors, cause the system to perform operations, the operations comprising:

extracting information regarding a first software project based on source code of the first software project, the information including at least a description of the source code and computer-readable source code;

identifying at least two application programming interface (API) calls invoking respective APIs within the information;

extracting metadata regarding at least one of the APIs from the information;

using the metadata, analyzing the computer-readable source code to determine a correlation between the at least two API calls, comprising:

determining a first output of a first API of the at least two APIs; and

determining a first set of processing of the first software project that occurs on the first output to yield a second input for a second API of the at least two APIs;

determining a third output of a third API in a second software project;

determining a second set of processing that occurs on the third output in the second software project to yield the second input for the second API;

determining a third set of processing of a third software project that occurs on the first output to yield a fourth input for a fourth API;

deriving a fourth set of processing by:

observing differences between the first set of processing and the third set of processing; and

applying the differences to the second set of processing to yield the fourth set of processing; and

based on the correlation, generating computer source code that combines the third API call invoking the third API, the fourth set of processing, and the fourth API call invoking the fourth API in an API mashup.

13. The system of claim 12 , wherein generating the computer source code includes:

detecting that the third API call is in a different programming language than the fourth API call; and

converting the fourth API call into computer source code consistent with a programming language of the source code of the second software project.

14. The system of claim 12 , wherein analyzing the computer-readable source code includes:

determining a third input of the third API;

determining that a fifth output of a fifth API in a fourth software project includes the third input; and

wherein generating computer source code includes combining code from calling the fifth API and code from calling the third API into the API mashup.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jan 11, 2018
From: BAHRAMI, MEHDI; LIU, LEI; CHEN, WEI-PENG
To: FUJITSU LIMITED
Reel/Frame 044599/0586 →
Continuity (1)
Related Publication 20190196796A1 · Jun 27, 2019