[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"doc-detail-118987-en":3,"doc-seo-118987-105":30,"detail-sidebar-cat-0-en-105":91},{"code":4,"msg":5,"data":6},0,"success",{"doc_id":7,"user_id":8,"nickname":9,"user_avatar":10,"doc_module":4,"category_id":11,"category_name":12,"doc_title":13,"doc_description":14,"doc_content":15,"file_id":16,"file_url":17,"file_type":18,"file_size":19,"view_count":4,"is_deleted":4,"is_public":20,"is_downloadable":20,"audit_status":20,"page_count":21,"language":22,"language_code":23,"site_id":24,"html_lang":23,"table_of_contents":25,"faqs":26,"seo_title":27,"seo_description":14,"update_tm":28,"read_time":29},118987,4398048949847,"Eliana","https://ap-avatar.wpscdn.com/avatar/400002536579ef2da7f?_k=1778318612642679267",8,"Research & Report","Bidirectional Reactive Programming for Machine Learning - arXiv 2311.16977v1","Bidirectional Reactive Programming targets machine-learning systems that operate over time as concurrent interactions and unbounded data streams. The work introduces a symmetric reactive construct that enables recurrences backward in time while preserving practical bounded-horizon execution. It shows that reverse-mode automatic differentiation, backpropagation, batch normalization, bidirectional recurrent neural networks, and training or reinforcement-learning loops are naturally captured as bidirectional reactive programs with deterministic formal semantics.","arXiv :2311 . 16977v1 [ cs .PL] 28 Nov 2023  \nBidirectional Reactive Programming for Machine Learning  \nDUMITRU POTOP BUTUCARU, Inria, France ALBERT COHEN, Google DeepMind, France GORDON PLOTKIN, Google DeepMind, USA HUGO POMPOUGNAC, Inria, France  \nReactive languages are dedicated to the programming of systems which interact continuously and concurrently with their environment. Values take the form of unbounded streams modeling the (discrete) passing of time or the sequence of concurrent interactions. While conventional reactivity models recurrences forward in time, we introduce a symmetric reactive construct enabling backward recurrences. Constraints on the latter allow to make the implementation practical. Machine Learning (ML) systems provide numerous motivations for all of this: we demonstrate that reverse-mode automatic diﬀerentiation, backpropagation, batch normalization, bidirectional recurrent neural networks, training and reinforcement learning algorithms, are all naturally captured as bidirectional reactive programs.  \n1 INTRODUCTION  \nConventional machine learning (ML) frameworks oﬀer a tensor-centric view of the design and implementation of deep neural networks. But ML models do not stand by themselves as pure tensor functions. ML applications typically interact with an environment and often operate on streams of data collected and processed over time. For instance, the reactive control of a self-driving car [27, 40] operates on streams of data coming from sensors and controlling actuators. Training algorithms themselves embed a model into a reactive loop: it is decomposed into epochs and (mini-)batches allowing the eﬃcient scheduling of computations and I/O, parameter updates, etc. The same applies to reinforcement learning (RL) agents [13] . Back to the automated driving example, stateful behavior is essential to taking into account previously-inferred facts such as speed limits, whether the current lane is a left turn etc., long after the acquisition of sensor inputs. Other examples of ML components embedded into stateful reactive feedback loops include model-predictive maintenance [37], control [8], and digital twins [21] . ML models themselves involve stateful constructs in the form of recurrent neural network (RNN) layers. When generating optimized code, even matrix products and convolutions in feedforward networks can be folded over time, using (stateful) buﬀering to reduce memory footprint [35] . In distributed settings, the eﬃcient implementation of large models involves pipelined communications and computations [7, 17, 22], which amounts to locally recovering a streaming execution pattern.  \nConsidering this broad range of scenarios, we observe that existing ML frameworks inadequately capture reactive aspects, raising barriers between diﬀerentiable models and the associated control, optimization, and input/output code. These barriers worsen the gap between ML research and system capabilities [3], particularly in the area of control automation where embedded ML engineering relies on undisclosed, ad-hoc implementations [40] . Our contributions are threefold:  \nDataﬂow reactive machine learning. We ﬁrst observe that conventional (dataﬂoworfold_left) reactive programming allows the natural speciﬁcation of a variety of ML inference models, optimization and RL algorithms. By indexing data and parameter streams along the logical time steps of computation and interaction, one may integrate the internal processing of ML models with data pre-/post-processing stages, and embed everything into a reactive control loop. Bidirectional reactive programming. We extend such a core reactive language with recurrences backward in time (fold_right). While classical reactive programs compute the values of cycle  \nAuthors’ addresses: Dumitru Potop Butucaru, Inria, France, [dumitru.potop@inria.fr](dumitru.potop@inria.fr); Albert Cohen, Google DeepMind, France; Gordon Plotkin, Google DeepMind, USA; Hugo Pompougnac, Inria, France.","cbCaimqzaY9bTjj8","https://ap.wps.com/l/cbCaimqzaY9bTjj8","pdf",534243,1,37,"English","en",105,"# Introduction\n## Dataflow reactive machine learning\n## Bidirectional reactive programming\n## Formal semantics\n# Related work","[{\"question\":\"What does bidirectional reactive programming add to conventional reactive models?\",\"answer\":\"It introduces recurrences backward in time, enabling a reactive value to depend on a future time step while keeping the execution practical under bounded-horizon constraints.\"},{\"question\":\"How does this approach relate to reverse-mode automatic differentiation and backpropagation?\",\"answer\":\"The paper demonstrates that reverse-mode automatic differentiation and backpropagation through recurrent layers are naturally expressed as bidirectional reactive programs, without requiring an explicit gradient tape.\"},{\"question\":\"What ensures that the backward dependencies can be executed without deadlocks?\",\"answer\":\"The semantics require that chains of backward dependences eventually terminate, allowing globally forward execution with locally backward computation and finite buffering.\"}]","Bidirectional Reactive Programming for Machine Learning - arXiv 2311.16977v1 | PDF",1785721426,93,{"code":4,"msg":31,"data":32},"ok",{"site_id":24,"language":23,"slug":33,"title":13,"keywords":34,"description":14,"schema_data":35,"social_meta":86,"head_meta":88,"extra_data":90,"updated_unix":28},"bidirectional-reactive-programming-for-machine-learning-arxiv-231116977v1","",{"@graph":36,"@context":85},[37,54,68],{"@type":38,"itemListElement":39},"BreadcrumbList",[40,44,48,51],{"item":41,"name":42,"@type":43,"position":20},"https://docshare.wps.com","Home","ListItem",{"item":45,"name":46,"@type":43,"position":47},"https://docshare.wps.com/document/","Document",2,{"item":49,"name":12,"@type":43,"position":50},"https://docshare.wps.com/document/research-report/",3,{"item":52,"name":13,"@type":43,"position":53},"https://docshare.wps.com/document/bidirectional-reactive-programming-for-machine-learning-arxiv-231116977v1/118987/",4,{"url":52,"name":13,"@type":55,"author":56,"headline":13,"publisher":58,"fileFormat":61,"inLanguage":23,"description":14,"dateModified":62,"datePublished":62,"encodingFormat":61,"isAccessibleForFree":63,"interactionStatistic":64},"DigitalDocument",{"name":9,"@type":57},"Person",{"url":41,"name":59,"@type":60},"DocShare","Organization","application/pdf","2026-08-03",true,{"@type":65,"interactionType":66,"userInteractionCount":4},"InteractionCounter",{"@type":67},"ViewAction",{"@type":69,"mainEntity":70},"FAQPage",[71,77,81],{"name":72,"@type":73,"acceptedAnswer":74},"What does bidirectional reactive programming add to conventional reactive models?","Question",{"text":75,"@type":76},"It introduces recurrences backward in time, enabling a reactive value to depend on a future time step while keeping the execution practical under bounded-horizon constraints.","Answer",{"name":78,"@type":73,"acceptedAnswer":79},"How does this approach relate to reverse-mode automatic differentiation and backpropagation?",{"text":80,"@type":76},"The paper demonstrates that reverse-mode automatic differentiation and backpropagation through recurrent layers are naturally expressed as bidirectional reactive programs, without requiring an explicit gradient tape.",{"name":82,"@type":73,"acceptedAnswer":83},"What ensures that the backward dependencies can be executed without deadlocks?",{"text":84,"@type":76},"The semantics require that chains of backward dependences eventually terminate, allowing globally forward execution with locally backward computation and finite buffering.","https://schema.org",{"og:url":52,"og:type":87,"og:title":13,"og:site_name":59,"og:description":14},"article",{"robots":89,"canonical":52},"index,follow",{"doc_id":7,"site_id":24},{"code":4,"msg":5,"data":92},[93,97,101,105,110,115,120,123,128,131,135],{"id":20,"doc_module":4,"doc_module_name":46,"category_name":94,"show_sort_weight":95,"slug":96},"Story & Novel",90,"story-novel",{"id":47,"doc_module":4,"doc_module_name":46,"category_name":98,"show_sort_weight":99,"slug":100},"Literature",80,"literature",{"id":53,"doc_module":4,"doc_module_name":46,"category_name":102,"show_sort_weight":103,"slug":104},"Exam",70,"exam",{"id":106,"doc_module":4,"doc_module_name":46,"category_name":107,"show_sort_weight":108,"slug":109},5,"Comic",60,"comic",{"id":111,"doc_module":4,"doc_module_name":46,"category_name":112,"show_sort_weight":113,"slug":114},6,"Technology",50,"technology",{"id":116,"doc_module":4,"doc_module_name":46,"category_name":117,"show_sort_weight":118,"slug":119},7,"Healthcare",40,"healthcare",{"id":11,"doc_module":4,"doc_module_name":46,"category_name":12,"show_sort_weight":121,"slug":122},30,"research-report",{"id":124,"doc_module":4,"doc_module_name":46,"category_name":125,"show_sort_weight":126,"slug":127},9,"Religion & Spirituality",20,"religion-spirituality",{"id":126,"doc_module":4,"doc_module_name":46,"category_name":129,"show_sort_weight":126,"slug":130},"World Cup","world-cup",{"id":132,"doc_module":4,"doc_module_name":46,"category_name":133,"show_sort_weight":132,"slug":134},10,"Lifestyle","lifestyle",{"id":136,"doc_module":4,"doc_module_name":46,"category_name":137,"show_sort_weight":106,"slug":138},19,"General","general"]