IP Library Granted Patent US 11,487,533
Granted Patent B2
US 11,487,533 · App. 17/205,455 · Granted Nov 1, 2022

Method and system for inferencing logic out of an application source

Inventors: Yogananda Ravindranath (Chennai, IN); Tamildurai Mehalingam (Chennai, IN); Aditya Thuruvas Senthil (Chennai, IN); Reshinth Gnana Adithyan (Chennai, IN); Shrayan Banerjee (Chennai, IN); Balakrishnan Venkatanarayanan (Chennai, IN)
Assignee: TATA CONSULTANCY SERVICES LIMITED
G06F8/73G06F8/75G06N5/04G06N20/00
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 11,487,533
App. No.
17/205,455
Granted
Nov 1, 2022
Kind
B2
Abstract

The application source code generally does not have any uniformity, defined executional sequence or documented information on the underlying complexity. It varies based on the requirement, domain and from each developer to developer. The slightest mistake in analyzing/modifying it will have a huge impact for the existing functionalities and interfacing applications. A method and system for inferencing code logic out of an application source code has been provided. This starts with the conversion of the raw form of code into logically linked blocks. These logical blocks in-turn represent standard meaningful representation of the code logic and are processed into vectors. Further, the processed vectors are fed into pre-trained machine learning models from which the code logic is predicted. Further the system and method can also be extended to various other applications in application maintenance, aiding the SME, inducting a new resource, documentation etc.

Claims (34)

1. A processor implemented method for inferencing logic out of an application source code, the method comprising:

providing, via a user interface, the application source code as an input; parsing, via one or more hardware processors, the application source code using parsers, wherein the parsing results in generation of a code language independent repository, and wherein the code language independent repository comprises information about the application source code;

linking, via the one or more hardware processors, the information related to each other present in the repository to extract a plurality of logical blocks of the application source code, wherein the plurality of logical blocks comprises a plurality of leaf nodes and sequential distances between each of the plurality of leaf nodes;

creating, via the one or more hardware processors, a plurality of capsules for each pair of the plurality of leaf nodes from the plurality of logical blocks based on a scope of the leaf nodes and sequential distance between the leaf nodes of each leaf node pair;

calculating, via the one or more hardware processors, an optimized set of hyper parameters of a machine learning model using an optimizer model;

training, via the one or more hardware processors, the machine learning model using the calculated hyper parameters;

predicting, via the one or more hardware processors, a functionality of the plurality of logical blocks by vectorizing the plurality of logical blocks using the plurality of capsules and the trained machine learning model; and

merging, via the one or more hardware processors, the predicted functionality with a plurality of external inputs to determine code logic inference of the application source code, wherein the plurality of external inputs is taken from one or more external learning models.

2. The method of claim 1 , wherein the plurality of capsules further comprises one or more of a plurality of leaf node sub-capsules, a plurality of scope sub-capsules, and a plurality of sequential distance sub-capsules.

3. The method of claim 1 , wherein the plurality of logical blocks comprises one or more of a plurality of logically linked statements resulting in data blocks, control blocks and condition blocks, wherein a size of the plurality of logical block is determined through a set of optimum threshold.

4. The method of claim 1 , wherein the parsing is performed using a plurality of technology specific parsers to understand a syntax of the application source code.

5. The method of claim 1 , wherein the hyper parameters of the machine learning model are decided based on a desired accuracy, desired loss and base model architecture using the optimizer model.

6. The method of claim 1 further comprising retraining the machine learning model with additional input using the optimizer model.

7. A system for inferencing logic out of an application source code, the system comprising:

a user interface for providing, the application source code as an input;

one or more hardware processors; a memory in communication with the one or more hardware processors, wherein the one or more hardware processors are configured to execute programmed instructions stored in the memory, to:

parse the application source code using parsers, wherein the parsing results in generation of a code language independent repository, wherein the code language independent repository comprises information about the application source code;

link the information related to each other present in the repository to extract a plurality of logical blocks of the application source code, wherein the plurality of logical blocks comprising a plurality of leaf nodes and sequential distances between each of the plurality of leaf nodes;

create a plurality of capsules for each pair of the plurality of leaf nodes from the plurality of logical blocks based on a scope of the leaf nodes and sequential distance between the leaf nodes of each leaf node pair;

calculate an optimized set of hyper parameters of a machine learning model using an optimizer model;

train the machine learning model using the calculated hyper parameters;

predict a functionality of the plurality of logical blocks by vectorizing the plurality of logical blocks using the plurality of capsules and the trained machine learning model; and

merge the predicted functionality with a plurality of external inputs to determine code logic inference of the application source code, wherein the plurality of external inputs is taken from one or more external learning models.

8. The system of claim 7 , wherein the plurality of capsules further comprises one or more of a plurality of leaf node sub-capsules, a plurality of scope sub-capsules, and a plurality of sequential distance sub-capsules.

9. The system of claim 7 , wherein the plurality of logical blocks comprises one or more of a plurality of logically linked statements resulting in data blocks, control blocks and condition blocks, wherein a size of the plurality of logical block is determined through a set of optimum threshold.

10. The system of claim 7 , wherein the hyper parameters of the machine learning model are decided based on a desired accuracy, desired loss and base model architecture using the optimizer model.

11. A computer program product comprising a non-transitory computer-readable medium having a computer readable program embodied therein, wherein the computer readable program, when executed on a computing device, causes the computing device to:

parse the application source code using parsers, wherein the parsing results in generation of a code language independent repository, wherein the code language independent repository comprises information about the application source code;

link the information related to each other present in the repository to extract a plurality of logical blocks of the application source code, wherein the plurality of logical blocks comprising a plurality of leaf nodes and sequential distances between each of the plurality of leaf nodes;

create a plurality of capsules for each pair of the plurality of leaf nodes from the plurality of logical blocks based on a scope of the leaf nodes and sequential distance between the leaf nodes of each leaf node pair;

calculate an optimized set of hyper parameters of a machine learning model using an optimizer model;

train the machine learning model using the calculated hyper parameters;

predict a functionality of the plurality of logical blocks by vectorizing the plurality of logical blocks using the plurality of capsules and the trained machine learning model; and

merge the predicted functionality with a plurality of external inputs to determine code logic inference of the application source code, wherein the plurality of external inputs is taken from one or more external learning models.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Mar 18, 2021
From: RAVINDRANATH, YOGANANDA; MEHALINGAM, TAMILDURAI; THURUVAS SENTHIL, ADITYA; ADITHYAN, RESHINTH GNANA; BANERJEE, SHRAYAN; VENKATANARAYANAN, BALAKRISHNAN
To: TATA CONSULTANCY SERVICES LIMITED
Reel/Frame 055639/0326 →
Priority Claims (1)
IN 202121001729 · Jan 13, 2021 · national
Continuity (1)
Related Publication 20220222069A1 · Jul 14, 2022