Aspects and implementations of the present disclosure relate to data processing, and more specifically, to generating adaptive code based on resource availability.
Executable code running on a web browser imparts a burden on a webpage which impacts a website's overall performance and an experience of an end user. For example, the code executing on a website within a web browser can interact with the webpage's Hypertext Markup Language (HTML) document object model (DOM) to perform activities that consume the web browser resources including processing resources (e.g., CPU resources) and network resources (e.g., bandwidth resources). Example activities performed by the code executing via a web browser include the initiation and completion of network requests and the transmission of data and therefore consumes browser resources (e.g. CPU, network).
In some conventional systems, code executing on a website, either by the website itself or by a third party or fourth party service running on the website, is configured to execute the same on all user devices and all network environments. In such systems, the code is designed to run as a one-size-fits all manner, which ignores conditions relating to the user device accessing the webpage.
Other conventional systems deploy code that is pre-configured to run specifically for each individual device type (e.g., code is set up one way for desktop devices, and another way for mobile devices) or web browser type (e.g., code is configured one way for a Google® Chrome web browser and another way for a Microsoft® Internet Explorer web browser). However, segmentation of environments by device type (e.g., desktop, tablet, and mobile) and web browser fails to account for complexities involved with the device and its associated operating environment.
Aspects and implementations of the present disclosure will be understood more fully from the detailed description given below and from the accompanying drawings of various aspects and implementations of the disclosure, which, however, should not be taken to limit the disclosure to the specific aspects or implementations, but are for explanation and understanding only.
Aspects and implementations of the present disclosure address the above-identified problems by generating and provisioning computer-executable code that is adapted in view of resource availability associated with a user device. In an embodiment, a system (also referred to as an “adaptive code management system”) is configured to identify or detect various resources that are available to the user device on which a web browser is executing code. In an embodiment, the adaptive code management system identifies a web or network environment by measuring available resources provided by or available to the web browser (e.g., processing device availability, network parameters including network type, bandwidth, etc.) at any selected time. According to embodiments, the adaptive code management system generates adaptive code configured to adjust a level of one or more code activities (e.g., capabilities, functions, operations, etc. performed by the code) based on the identified resource availability or operating environment of the user device.
The adaptive code management system performs one or more processes configured to perform measurements (e.g., iterative measurements associated with one or more user devices), learning, and adjustments to monitor and measure the resource availability of the one or more user devices. In an embodiment, the adaptive code is adjusted for execution by a user device in any suitable network environment, on any device type (e.g., desktop, mobile, tablet, etc.). Advantageously, the adaptive code management system can provide on-going monitoring and measuring of the resource availability (e.g., processing resources including available processing power and network availability resources including available bandwidth and transmission rates) associated with the one or more user devices, without the need for prior knowledge of the web environment of the user device or the implementation of static pre-configured settings.
In another embodiment, one or more portions or components of the adaptive code management system 100 including the adaptive code 50A-50N can be installed (e.g., via a plug-in to a web browser of a user device) on and executed by one or more of the user devices 22A-22N. The user devices can include any suitable computing system such as a personal computer (e.g., a desktop computer, laptop computer, server, a tablet computer), a workstation, a handheld device, a web-enabled appliance, a gaming device, a mobile phone (e.g., a Smartphone), an eBook reader, a camera, a watch, an in-vehicle computer/system, or any computing device enable with one or more web browsers (e.g., web browser 26A, 26B . . . 26N).
Various applications or sets of code (e.g., the adaptive code) may run or execute on the user device (e.g., on the operating system (OS) of the user device). In certain implementations, user device 22A-22N can also include and/or incorporate various sensors and/or communications interfaces (not shown). Examples of such sensors include but are not limited to: accelerometer, gyroscope, compass, GPS, haptic sensors (e.g., touchscreen, buttons, etc.), microphone, camera, etc. Examples of such communication interfaces include but are not limited to cellular (e.g., 3G, 4G, etc.) interface(s), Bluetooth interface, WiFi interface, USB interface, NFC interface, etc. The set of user devices can also include or incorporate one or more third-party or fourth-party services.
In an embodiment, the user devices of the set of user devices 20 operate in a respective computing environment. In the example shown in
In an embodiment, each user device 22A-22N includes a set of one or more user device resources 24A-24N. The user device resources 28A-28N can be defined by a set data relating to the user device (herein also referred to as the “device data”). Example device data can include one or more of a model type associated with the user device, an operating system (e.g., Microsoft® Windows, Apple® IOS, the Android operating system (OS), Google® Chrome OS, etc.), a web browser type (e.g., Microsoft® Internet Explorer, Apple® Safari, Google® Chrome, etc.), processing device types, and any other information relating to the performance, capabilities, functions, and operation of the user device.
In an embodiment, the adaptive code management system 100 is configured to perform various functions, operations, and activities relating to the management of code that is adapted for execution by the respective user devices 22A-22N of the set of user devices 20. In an embodiment, the adaptive code management system 100 can include one or more programs or components configured to perform the functions and operations described in detail herein, including a resource availability management component 110, an adaptive code generator 120, a memory 130 including a data store 132 and one or sets of instructions or programs corresponding to functions, operations, activities, etc. of the adaptive code management system 100. The adaptive code management system 100 also includes one or more processing devices 140 configured to execute the instructions stored in the memory 130 to implement the processes executed by the adaptive code management system 100, as described in greater detail herein.
In an embodiment, the adaptive resource availability management component 110 is configured to provide a user device (e.g., user device 22A) with adaptive code (e.g., adaptive code 50A) for execution via a web browser (e.g., web browser 16A). In an embodiment, the adaptive code is adapted in accordance with the device data, environment data, or a combination thereof.
In an embodiment, the adaptive code supplements other executable code that is native to a web asset (e.g., a web page, web application, etc.) or provided by another party (e.g., third-party web services, fourth-party web services, etc. In an embodiment, the adaptive code collects the device and environment data and adjusts code activities of the adaptive code and other code executing on the web asset (e.g., native code, third-party code, fourth-party code, etc.)
In an embodiment, the adaptive code runs on a user device and collects the device data relating to parameters of the device (e.g., model type, operating system, browser type, etc.) and the environment data (e.g., a network type, a connection strength, a number of tabs open within the web browser, etc.). In an embodiment, the adaptive code evaluates the device data and the environment data and calculates one or more resource availability functions based on the collected resource availability data (e.g., the device data and the environment data). The adaptive code manages a set of the resource availability functions to determine values representing a level of availability of the one or resources of the user device. The one or more resource availability functions can include one or more operations, functions, programs, etc. that are configured to determine a value measuring a level of one or more resources available to a particular user device (i.e., the user device executing the adaptive code and the corresponding resource availability function) at a particular time (e.g., at a time of execution of the resource availability function).
In an embodiment, the resource availability functions can be numeric continuous (e.g., provide value for any computing environment), deterministic (e.g., configured to return the same result any time they are called with a specific set of input values), and can require no prior knowledge or information relating to the user device or computing environment, and may not require any special access to the user device or computing environment be granted to the adaptive code. An example resource availability function includes, but is not limited to, a measurement estimating CPU capabilities of a user device based on a time (e.g., measured in milliseconds) it takes for a function running in a loop with X cycles to execute to completion. In an another example, the resource availability function includes, but is not limited to, a measurement estimating a network strength of a user device based on a time (e.g., measured in milliseconds) it takes for a network to send a request to a remote computing device (e.g., a server/destination) and receive a response.
In an embodiment, the resource availability management component 110 can collect and evaluates the device data, the environment data, and the one or more resource availability function values generated by the adaptive code. In an embodiment, the resource availability management component 110 is configured to employ one or more learning algorithms using the aforementioned data identified by the adaptive code. For example, the resource availability management component 110 can analyze the resource availability function values and generate a segmentation histogram (e.g., based on relative values of a first user device (e.g., user device 22A)) as compared to corresponding resource availability function values of one or more other user devices in the set of user devices 20 (also referred to as the “user device population”)). In an embodiment, the segmentation histogram segments the user device population into classifications (e.g., groups, categories, or types) based on their relative resource availability function values (e.g., groups such as “Extremely Strong”, “Strong”, “Normal”, “Weak”, “Extremely Weak”, or the like).
In an embodiment, the resource availability management component 110 receives the device data and the environment data including the resource availability function values, and, in some instances, information relating to previous parameter adjustments and corresponding measurements relating to impact on the user device (also referred to as “user device impact”). In an embodiment, the resource availability management component 110 stores information relating to the resource availability (device data, environment data), parameters and user device impact in data store 132.
In an embodiment, the resource availability management component 110 is configured to perform a process (e.g., a resource-based analysis process) including a set of instructions to analyze the one or more resource availability function values received from the set of multiple user devices (e.g., user devices 22A-22N), compare the one or resource availability function values of the multiple user devices and classify the respective user device into a corresponding class, group or segment (e.g., a strong resource classification, a medium resource classification, a weak resource classification, etc.) for each of the resource availability functions, as described in greater detail below with reference to
In an embodiment, the code generator 120 is configured to generate the adaptive code 50A-50N including calculated value ranges using one or more code adjustment rules 125 defining how to adjust the adaptive code's activity based on the provided values. In an embodiment, one or more code adjustment rules 125 can be associated with or mapped to a particular classification, such that the corresponding code adjustment rules are applied to generate the adaptive code for user devices having that particular classification, as described in greater detail with respect to
In an embodiment, the adaptive code 50A-50N adjusts a code activity level based on one or more value ranges embedded in the adaptive code 50A-50N as provided by the code generator 120. In an embodiment, the ranges established by the code generator 120 represent the relativity of the resource availability function values based on the comparison to the overall device population and corresponding classification (e.g., segmentation) performed by the resource availability management component 110. In an embodiment, the adaptive code 50A-50N transmits resource availability functions values to the resource availability management component 110 on an iterative basis to enable on-going analysis and classification (e.g., re-classification) of the user devices in the set of user devices 20 that are executing the adaptive code 50A-50N.
In an embodiment, the adaptive code can be adjusted to a web environment's network and CPU capabilities. For example, the adaptive code can be deployed more aggressively (e.g., in terms of an amount of resources allocated and used in connection with execution of the adaptive code) within an environment classified as strong (e.g., a higher resource utilization), and can run in a lightweight mode (e.g., a lower resource utilization) if the availability and capabilities for a given environment are low.
For simplicity of explanation, methods are depicted and described as a series of operations. However, the operations in accordance with this disclosure can occur in various orders and/or concurrently, and with other operations not presented and described herein. Furthermore, not all illustrated operations may be required to implement the methods in accordance with the disclosed subject matter. In addition, those skilled in the art will understand and appreciate that the methods could alternatively be represented as a series of interrelated states via a state diagram or events. Additionally, it should be appreciated that the methods disclosed in this specification are capable of being stored on an article of manufacture to facilitate transporting and transferring such methods to computing devices. The term article of manufacture, as used herein, is intended to encompass a computer program accessible from any computer-readable device or storage media.
In operation 210, the processing logic measures, by a code set executed by a processing device, a first set of data associated with a first user device of set of multiple user devices (e.g., a device population). In an embodiment, the first set of data (e.g., the device data) can include one or more measured values associated with one or more parameters of the first user device, such as, for example a model type, an operating system, a web browser type, etc. For example, the code set is the adaptive code 50A executed by web browser 26A of user device 22A of
In operation 220, the processing logic measures, by the code set, a second set of data associated with a computing environment of the first user device. In an embodiment, the second set of data (e.g., the environment data) includes one or more measured values for one or more parameters associated with a computing environment of the first user device. For example, the second set of data can include data relating to the operation, strength, capabilities, functions, etc. of the computing environment, such as a signal strength, transmission (e.g., upload and/or download speed) rate, bandwidth, processing speed, etc.
In operation 230, the processing logic calculates a first value for a resource availability function in view of the first set of data and the second set of data. In an embodiment, the resource availability function can include a process or set of operations configured to measure or determine a value representing a level of resource availability of the first user device. For example, the resource availability function includes, but is not limited to, a measurement estimating a user device's CPU capabilities based on a time (e.g., measured in milliseconds) it takes for a function executing in a loop with a number of cycles to run to completion. In an another example, the resource availability function can be a measurement of the first user device's network strength based on a time it takes for the first user device to send, via a connected network, a request to a remote system and receive a return transmission (e.g., a response to the request).
In operation 240, the processing logic compares the first value to a set of values for the resource availability function associated with a set of one or more other user devices to determine a classification for the first user device. In an embodiment, the processing logic can classify each of the user devices in a set of user devices into a particular class or category based on a comparison of the respective values of the resource availability function.
For example, as shown in
As shown in
With reference to
In an embodiment, the code set having the adjusted level of activity (e.g. a reduced level of activity for a user device having a low level of resource availability or an increased level of activity for a user device having a high level of resource availability) can be executed by the first user device. Advantageously, the code set can be adapted based on on-going and iterative measurements and determinations based on a resource availability level associated with a user device.
As shown in
In an embodiment, as illustrated in
In an embodiment, the various operations of method 200 can be performed iteratively with respect to multiple different user devices of the device population. In this regard, at multiple different times (e.g., T=2, T=3, T=4, etc. in the example shown in
In an embodiment, in addition to adjusting the code activity level, the adaptive code continues to identify and collect resource availability function values for the execution of one or more learning processes (e.g., machine learning, modeling, etc.). In an embodiment, information associated with the adaptive code, device data and environment data associated with the device population can be stored in a data store and processed via one or more learning models to generate improvements, changes, updates, or adjustments to the one or more resource availability functions, segments or classifications, or other parameters of the adaptive code management system.
The exemplary computer system 400 includes a processing system (processor) 402, a main memory 404 (e.g., read-only memory (ROM), flash memory, dynamic random access memory (DRAM) such as synchronous DRAM (SDRAM)), a static memory 406 (e.g., flash memory, static random access memory (SRAM)), and a data storage device 416, which communicate with each other via a bus 408.
Processor 402 represents one or more general-purpose processing devices such as a microprocessor, central processing unit, or the like. More particularly, the processor 402 may be a complex instruction set computing (CISC) microprocessor, reduced instruction set computing (RISC) microprocessor, very long instruction word (VLIW) microprocessor, or a processor implementing other instruction sets or processors implementing a combination of instruction sets. The processor 402 may also be one or more special-purpose processing devices such as an application specific integrated circuit (ASIC), a field programmable gate array (FPGA), a digital signal processor (DSP), network processor, or the like. The processor 402 is configured to execute instructions of an adaptive code generation system 100 for performing the operations discussed herein.
The computer system 400 may further include a network interface device 422. The computer system 400 also may include a video display unit 410 (e.g., a liquid crystal display (LCD) or a cathode ray tube (CRT)), an alphanumeric input device 412 (e.g., a keyboard), a cursor control device 414 (e.g., a mouse), and a signal generation device 420 (e.g., a speaker).
The data storage device 416 may include a computer-readable medium 424 on which is stored one or more sets of instructions (e.g., instructions executed by the adaptive code generation system 100) embodying any one or more of the methodologies or functions described herein. The instructions of the adaptive code generation system 100 may also reside, completely or at least partially, within the main memory 404 and/or within the processor 402 during execution thereof by the computer system 400, the main memory 404 and the processor 402 also constituting computer-readable media. The instructions of the adaptive code generation system 100 may further be transmitted or received over a network via the network interface device 422.
While the computer-readable storage medium 424 is shown in an exemplary embodiment to be a single medium, the term “computer-readable storage medium” should be taken to include a single medium or multiple media (e.g., a centralized or distributed database, and/or associated caches and servers) that store the one or more sets of instructions. The term “computer-readable storage medium” shall also be taken to include any medium that is capable of storing, encoding or carrying a set of instructions for execution by the machine and that cause the machine to perform any one or more of the methodologies of the present disclosure. The term “computer-readable storage medium” shall accordingly be taken to include, but not be limited to, solid-state memories, optical media, and magnetic media.
In the above description, numerous details are set forth. It will be apparent, however, to one of ordinary skill in the art having the benefit of this disclosure, that embodiments may be practiced without these specific details. In some instances, well-known structures and devices are shown in block diagram form, rather than in detail, in order to avoid obscuring the description.
Some portions of the detailed description are presented in terms of algorithms and symbolic representations of operations on data bits within a computer memory. These algorithmic descriptions and representations are the means used by those skilled in the data processing arts to most effectively convey the substance of their work to others skilled in the art. An algorithm is here, and generally, conceived to be a self-consistent sequence of steps leading to a desired result. The steps are those requiring physical manipulations of physical quantities. Usually, though not necessarily, these quantities take the form of electrical or magnetic signals capable of being stored, transferred, combined, compared, and otherwise manipulated. It has proven convenient at times, principally for reasons of common usage, to refer to these signals as bits, values, elements, symbols, characters, terms, numbers, or the like.
It should be borne in mind, however, that all of these and similar terms are to be associated with the appropriate physical quantities and are merely convenient labels applied to these quantities. Unless specifically stated otherwise as apparent from the above discussion, it is appreciated that throughout the description, discussions utilizing terms such as “measuring,” “processing,” “comparing,” “adjusting,” or the like, refer to the actions and processes of a computer system, or similar electronic computing device, that manipulates and transforms data represented as physical (e.g., electronic) quantities within the computer system's registers and memories into other data similarly represented as physical quantities within the computer system memories or registers or other such information storage, transmission or display devices.
Aspects and implementations of the disclosure also relate to an apparatus for performing the operations herein. This apparatus may be specially constructed for the required purposes, or it may comprise a general purpose computer selectively activated or reconfigured by a computer program stored in the computer. Such a computer program may be stored in a computer readable storage medium, such as, but not limited to, any type of disk including floppy disks, optical disks, CD-ROMs, and magnetic-optical disks, read-only memories (ROMs), random access memories (RAMs), EPROMs, EEPROMs, magnetic or optical cards, or any type of media suitable for storing electronic instructions.
The algorithms and displays presented herein are not inherently related to any particular computer or other apparatus. Various general purpose systems may be used with programs in accordance with the teachings herein, or it may prove convenient to construct a more specialized apparatus to perform certain operations. In addition, the present disclosure is not described with reference to any particular programming language. It will be appreciated that a variety of programming languages may be used to implement the teachings of the disclosure as described herein.
It is to be understood that the above description is intended to be illustrative, and not restrictive. Many other embodiments will be apparent to those of skill in the art upon reading and understanding the above description. Moreover, the techniques described above could be applied to practically any type of data. The scope of the disclosure should, therefore, be determined with reference to the appended claims, along with the full scope of equivalents to which such claims are entitled.
Filing Document | Filing Date | Country | Kind |
---|---|---|---|
PCT/IB20/00522 | 6/24/2020 | WO | 00 |
Number | Date | Country | |
---|---|---|---|
62865717 | Jun 2019 | US |