Park: An Open Platform for Learning-Augmented Computer Systems

Hongzi Mao, Parimarjan Negi, Akshay Narayan, Hanrui Wang, Jiacheng Yang, Haonan Wang, Ryan Marcus, Ravichandra Addanki, Mehrdad Khani Shirkoohi, Songtao He, Vikram Nathan, Frank Cangialosi, Shaileshh Bojja Venkatakrishnan, Wei-Hung Weng, Song Han, Tim Kraska, Mohammad AlizadehNeurIPS 2019

Overview

Park is an open-source platform that provides a standardized interface—similar to OpenAI Gym—for applying Reinforcement Learning (RL) to diverse computer system optimization problems. By decoupling the complexity of systems engineering from the machine learning logic, Park allows researchers to benchmark RL agents on real-world tasks like database indexing, network congestion control, and cluster scheduling.

The Challenge: RL in Computer Systems

While Deep RL has seen massive success in games and robotics, its application to computer systems has been comparatively slow. The authors identify a significant "barrier to entry": ML researchers often lack the systems expertise required to set up complex environments (like a Spark cluster or a SQL engine), while systems researchers may not have the tools to rigorously evaluate modern RL algorithms.

Furthermore, computer systems present unique challenges not typically found in standard RL benchmarks like Atari games or MuJoCo:

  • Stochasticity: System performance is often driven by exogenous "input processes" (like a sudden burst of web traffic) that create high variance in rewards.
  • Structured Spaces: States and actions are often represented as graphs (e.g., dataflows) or have exponentially large, time-varying dimensions.
  • The Simulation-Reality Gap: Simple simulators often fail to capture the nuances of actual hardware, causing agents trained in "the lab" to fail in production.

Park's Architecture: RL-as-a-Service

To bridge the gap between systems and machine learning, the authors propose an "RL-as-a-service" architecture. Park uses a request-response design pattern where the backend system (which could be written in C++, Java, Rust, etc.) communicates with a Python-based RL agent via Remote Procedure Calls (RPCs).

Park's RL-as-a-service architecture using RPCs to bridge system environments and Python-based agents.

Key technical features include:

  • Common Interface: A unified API hides system-level implementation details, allowing researchers to focus purely on the Markov Decision Process (MDP) formulation.
  • Hybrid Backends: Park includes 7 environments powered by real-world systems and 5 powered by high-fidelity simulators.
  • Scalability: The platform supports multiple concurrent environment instances. This enables distributed RL training (e.g., IMPALA-style) to overcome the slow interaction times inherent to real hardware.

The Park Environments

Park introduces a suite of 12 environments across five major domains:

  1. Networking: Adaptive video streaming, congestion control, and active queue management.
  2. Databases: SQL query optimization and multi-dimensional indexing.
  3. Distributed Systems: Spark job scheduling, load balancing, and account region assignment.
  4. Operating Systems: CDN memory caching.
  5. Hardware/Circuits: TensorFlow device placement, circuit design, and switch scheduling.

These environments are grounded in reality, utilizing real-world traces such as a dataset of 500 million requests from a major CDN and network throughput measurements from video streaming services.

Key Insights for Systems RL

Through benchmarking, the authors highlight several critical insights for applying RL to systems:

  • Input-Driven Variance: In systems, the "reward" is often more dependent on the workload than the agent's action. Standard RL needs "input-dependent baselines" to reduce this variance effectively.
Illustration of input-driven variance: the same action in the same state yields vastly different rewards depending on the job sequence.
  • Graph Representations Matter: For tasks like job scheduling or circuit design, the state is naturally a graph. The paper demonstrates that Graph Convolutional Networks (GCNs) generalize significantly better than LSTMs or MLPs in these domains.
  • The Needle-in-the-Haystack Problem: In environments like congestion control, the vast majority of the action space results in terrible performance (e.g., crashing the queue). Random exploration is ineffective here; agents often require domain-specific constraints or "warm-starting" from existing heuristics.
  • Infinite Horizons: Unlike games with a clear "Game Over," computer systems run indefinitely. This makes traditional episodic discounting tricky and suggests that average-reward RL might be a better fit.

Performance and Results

The authors benchmarked standard RL algorithms (DQN, A2C, PPO, DDPG) against state-of-the-art human-engineered heuristics:

  • Successes: RL agents successfully outperformed traditional heuristics in Spark scheduling and video bitrate adaptation.
  • Mixed Results: In database query optimization, standard RL struggled to converge to a stable policy, suggesting that "one-shot" decision-making is insufficient without being combined with explicit search mechanisms.
  • Encoding Gains: In the TensorFlow device placement task, using GCNs allowed the agent to learn 5x faster than using an LSTM-based state encoding.

Limitations and Future Directions

  • Simplification: To make RL feasible, some environments were simplified (e.g., using a 1MB cache for CDN testing instead of a typical multi-GB production cache).
  • Safety and Interpretability: "Black-box" RL is notoriously hard to debug compared to a simple FIFO scheduler. Future work must focus on hybrid solutions that combine the safety and predictability of heuristics with the optimization power of RL.
  • Robustness: Many agents overfit to specific training workloads. Developing agents that can handle "distribution shift" in system traffic remains a major open challenge for the community.

Summary updated

BibTeX
@inproceedings{mao2019park,
  author = {Hongzi Mao and Parimarjan Negi and Akshay Narayan and Hanrui Wang and Jiacheng Yang and Haonan Wang and Ryan Marcus and Ravichandra Addanki and Mehrdad Khani Shirkoohi and Songtao He and Vikram Nathan and Frank Cangialosi and Shaileshh Bojja Venkatakrishnan and Wei-Hung Weng and Song Han and Tim Kraska and Mohammad Alizadeh},
  title = {{Park: An Open Platform for Learning-Augmented Computer Systems}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2019},
  url = {https://openreview.net/forum?id=NqdXrBla1PS},
}
Figure