-
公开(公告)号:US20240176604A1
公开(公告)日:2024-05-30
申请号:US18070015
申请日:2022-11-28
Applicant: Google LLC
Inventor: Joey Hong , Rishabh Singh , Joel Galenson , Jonathan Malmaud , Manzil Zaheer
IPC: G06F8/51
CPC classification number: G06F8/51
Abstract: Implementations are described herein for predicting symbolic transformation templates to automate source code transformations. In various implementations, pair(s) of predecessor and successor source code snippets may be processed using a symbolic transformation template prediction (STTP) model to predict a symbolic transformation template that includes a predecessor portion that matches the predecessor source code snippet(s) of the pair(s) and a successor portion that matches the successor source code snippet(s) of the pair(s). At least one additional predecessor source code snippet may be identified that matches the predecessor portion of the predicted symbolic transformation template. Placeholders of the predecessor portion of the predicted symbolic transformation template may be bound to one or more tokens of the at least one additional predecessor source code snippet to create binding(s). The successor portion of the predicted symbolic transformation template may be applied to the bindings to generate additional successor source code snippet(s).
-
公开(公告)号:US12147794B2
公开(公告)日:2024-11-19
申请号:US18070015
申请日:2022-11-28
Applicant: Google LLC
Inventor: Joey Hong , Rishabh Singh , Joel Galenson , Jonathan Malmaud , Manzil Zaheer
IPC: G06F8/51
Abstract: Implementations are described herein for predicting symbolic transformation templates to automate source code transformations. In various implementations, pair(s) of predecessor and successor source code snippets may be processed using a symbolic transformation template prediction (STTP) model to predict a symbolic transformation template that includes a predecessor portion that matches the predecessor source code snippet(s) of the pair(s) and a successor portion that matches the successor source code snippet(s) of the pair(s). At least one additional predecessor source code snippet may be identified that matches the predecessor portion of the predicted symbolic transformation template. Placeholders of the predecessor portion of the predicted symbolic transformation template may be bound to one or more tokens of the at least one additional predecessor source code snippet to create binding(s). The successor portion of the predicted symbolic transformation template may be applied to the bindings to generate additional successor source code snippet(s).
-