Skip to main content

Parameterized Synthesis with Safety Properties

  • Conference paper
  • First Online:
Programming Languages and Systems (APLAS 2020)

Part of the book series: Lecture Notes in Computer Science ((LNPSE,volume 12470))

Included in the following conference series:

Abstract

Parameterized synthesis offers a solution to the problem of constructing correct and verified controllers for parameterized systems. Such systems occur naturally in practice (e.g., in the form of distributed protocols where the amount of processes is often unknown at design time and the protocol must work regardless of the number of processes). In this paper, we present a novel learning-based approach to the synthesis of reactive controllers for parameterized systems from safety specifications. We use the framework of regular model checking to model the synthesis problem as an infinite-duration two-player game and show how one can utilize Angluin’s well-known L\(^{*}\) algorithm to learn correct-by-design controllers. This approach results in a synthesis procedure that is conceptually simpler than existing synthesis methods with a completeness guarantee, whenever a winning strategy can be expressed by a regular set. We have implemented our algorithm in a tool called L\(^{*}\)-PSynth and have demonstrated its performance on a range of benchmarks, including robotic motion planning and distributed protocols. Despite the simplicity of L\(^{*}\)-PSynth  it competes well against (and in many cases even outperforms) the state-of-the-art tools for synthesizing parameterized systems.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Notes

  1. 1.

    The running time by definition accounts for the amount of time taken by the learner plus the maximum size of the counterexamples provided by the teacher. We assume the teacher is an oracle that can return an answer in constant time.

  2. 2.

    Code and benchmarks are available at https://github.com/lstarsynth/lstar-psynth.

  3. 3.

    The encoding in the benchmarks use a grid world of size \(2^n \times 2^n\) which can be easily reduced to \(n \times m \).

  4. 4.

    The original version of the evasion game is played in an infinite grid world, thus, making one valid strategy to always move into one direction, which resembles Player 0 moving out of bound.

  5. 5.

    This version of winning condition is called “misère play condition”, in which the last player making a move loses. Nim can also be played with “normal play condition”, i.e., the last player making a move wins.

  6. 6.

    Apart from DT-Synth, since instead of automata, it produces witnesses as decision trees.

  7. 7.

    Including one case (robot vacuum cleaner) in which the other two tools timed out.

  8. 8.

    In spite of the fact that Angluin’s algorithm computes the minimal DFA for a given target language, it is not necessarily encoded by a small automaton.

References

  1. Griesmayer, A., Staber, S., Bloem, R.: Automated fault localization for C programs. Electron. Notes Theoret. Comput. Sci. 174(4), 95–111 (2007)

    Article  Google Scholar 

  2. Abdulla, P.A., Jonsson, B., Mahata, P., d’Orso, J.: Regular tree model checking. In: Brinksma, E., Larsen, K.G. (eds.) CAV 2002. LNCS, vol. 2404, pp. 555–568. Springer, Heidelberg (2002). https://doi.org/10.1007/3-540-45657-0_47

    Chapter  Google Scholar 

  3. Abdulla, P.A.: Regular model checking. STTT 14(2), 109–118 (2012). https://doi.org/10.1007/s10009-011-0216-8

    Article  Google Scholar 

  4. Abdulla, P.A., Haziza, F., Holík, L.: Parameterized verification through view abstraction. STTT 18(5), 495–516 (2016). https://doi.org/10.1007/s10009-015-0406-x

    Article  MATH  Google Scholar 

  5. Angluin, D.: Learning regular sets from queries and counterexamples. Inf. Comput. 75(2), 87–106 (1987)

    Article  MathSciNet  Google Scholar 

  6. Angluin, D., Fisman, D.: Learning regular omega languages. Theor. Comput. Sci. 650, 57–72 (2016)

    Article  MathSciNet  Google Scholar 

  7. Apt, K.R., Kozen, D.: Limits for automatic verification of finite-state concurrent systems. Inf. Process. Lett. 22(6), 307–309 (1986)

    Article  MathSciNet  Google Scholar 

  8. Beyene, T.A., Chaudhuri, S., Popeea, C., Rybalchenko, A.: A constraint-based approach to solving games on infinite graphs. In: Jagannathan, S., Sewell, P. (eds.) The 41st Annual ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, POPL 2014, San Diego, CA, USA, 20–21 January 2014 (2014)

    Google Scholar 

  9. Bloem, R., et al.: Decidability of Parameterized Verification. Synthesis Lectures on Distributed Computing Theory. Morgan & Claypool Publishers, San Rafael (2015)

    Book  Google Scholar 

  10. Bollig, B., Habermehl, P., Kern, C., Leucker, M.: Angluin-style learning of NFA. In: IJCAI, pp. 1004–1009

    Google Scholar 

  11. Bouajjani, A., Habermehl, P., Rogalewicz, A., Vojnar, T.: Abstract regular (tree) model checking. STTT 14(2), 167–191 (2012). https://doi.org/10.1007/s10009-011-0205-y

    Article  MATH  Google Scholar 

  12. Bouton, C.L.: Nim, a game with a complete mathematical theory. Ann. Math. 3(1/4), 35–39 (1901). http://www.jstor.org/stable/1967631

  13. Camacho, A., Muise, C.J., Baier, J.A., McIlraith, S.A.: LTL realizability via safety and reachability games. In: Proceedings of the Twenty-Seventh International Joint Conference on Artificial Intelligence, IJCAI 2018, Stockholm, Sweden, 13–19 July 2018, pp. 4683–4691 (2018)

    Google Scholar 

  14. Chatain, T., David, A., Larsen, K.G.: Playing games with timed games. In: 3rd IFAC Conference on Analysis and Design of Hybrid Systems, ADHS 2009, Zaragoza, Spain, 16–18 September 2009, pp. 238–243 (2009)

    Google Scholar 

  15. Chen, Y.-F., Clarke, E.M., Farzan, A., Tsai, M.-H., Tsay, Y.-K., Wang, B.-Y.: Automated assume-guarantee reasoning through implicit learning. In: Touili, T., Cook, B., Jackson, P. (eds.) CAV 2010. LNCS, vol. 6174, pp. 511–526. Springer, Heidelberg (2010). https://doi.org/10.1007/978-3-642-14295-6_44

    Chapter  Google Scholar 

  16. Chen, Y., Hong, C., Lin, A.W., Rümmer, P.: Learning to prove safety over parameterised concurrent systems. In: Formal Methods in Computer Aided Design, FMCAD 2017, Vienna, Austria, 2–6 October 2017, pp. 76–83 (2017)

    Google Scholar 

  17. Doyen, L.: Games and automata: from boolean to quantitative verification. habilitation, ENS de Cachan, LSV (2011)

    Google Scholar 

  18. Ehlers, R., Seshia, S.A., Kress-Gazit, H.: Synthesis with identifiers. In: McMillan, K.L., Rival, X. (eds.) VMCAI 2014. LNCS, vol. 8318, pp. 415–433. Springer, Heidelberg (2014). https://doi.org/10.1007/978-3-642-54013-4_23

    Chapter  Google Scholar 

  19. Fang, Y., Piterman, N., Pnueli, A., Zuck, L.: Liveness with incomprehensible ranking. In: Jensen, K., Podelski, A. (eds.) TACAS 2004. LNCS, vol. 2988, pp. 482–496. Springer, Heidelberg (2004). https://doi.org/10.1007/978-3-540-24730-2_36

    Chapter  Google Scholar 

  20. Fang, Y., Piterman, N., Pnueli, A., Zuck, L.: Liveness with invisible ranking. In: Steffen, B., Levi, G. (eds.) VMCAI 2004. LNCS, vol. 2937, pp. 223–238. Springer, Heidelberg (2004). https://doi.org/10.1007/978-3-540-24622-0_19

    Chapter  Google Scholar 

  21. Ferguson, T.S.: Game theory (2014). https://www.math.ucla.edu/~tom/Game_Theory/Contents.html

  22. Fey, G., Staber, S., Bloem, R., Drechsler, R.: Automatic fault localization for property checking. IEEE Trans. Comput. Aided Des. Integr. Circ. Syst. 27, 1138–1149 (2008)

    Article  Google Scholar 

  23. Grädel, E., Thomas, W., Wilke, T. (eds.): Automata Logics, and Infinite Games. LNCS, vol. 2500. Springer, Heidelberg (2002). https://doi.org/10.1007/3-540-36387-4

    Book  MATH  Google Scholar 

  24. Habermehl, P., Vojnar, T.: Regular model checking using inference of regular languages. In: Bradfield, J.C., Moller, F. (eds.) Proceedings of the 6th International Workshop on Verification of Infinite-State Systems, INFINITY 2004 (2004)

    Google Scholar 

  25. Jobstmann, B., Griesmayer, A., Bloem, R.: Program repair as a game. In: Etessami, K., Rajamani, S.K. (eds.) CAV 2005. LNCS, vol. 3576, pp. 226–238. Springer, Heidelberg (2005). https://doi.org/10.1007/11513988_23

    Chapter  Google Scholar 

  26. Katis, A., et al.: Validity-guided synthesis of reactive systems from assume-guarantee contracts. In: Beyer, D., Huisman, M. (eds.) TACAS 2018. LNCS, vol. 10806, pp. 176–193. Springer, Cham (2018). https://doi.org/10.1007/978-3-319-89963-3_10

    Chapter  Google Scholar 

  27. Kearns, M.J., Vazirani, U.: An Introduction to Computational Learning Theory. MIT Press, Cambridge (2014)

    Google Scholar 

  28. Kesten, Y., Maler, O., Marcus, M., Pnueli, A., Shahar, E.: Symbolic model checking with rich assertional languages. TCS 256(1–2), 93–112 (2001)

    Article  MathSciNet  Google Scholar 

  29. Lin, A.W., Rümmer, P.: Liveness of randomised parameterised systems under arbitrary schedulers. In: Chaudhuri, S., Farzan, A. (eds.) CAV 2016. LNCS, vol. 9780, pp. 112–133. Springer, Cham (2016). https://doi.org/10.1007/978-3-319-41540-6_7

    Chapter  Google Scholar 

  30. McNaughton, R.: Infinite games played on finite graphs. Ann. Pure Appl. Logic 65(2), 149–184 (1993)

    Article  MathSciNet  Google Scholar 

  31. de Moura, L., Bjørner, N.: Z3: an efficient SMT solver. In: Ramakrishnan, C.R., Rehof, J. (eds.) TACAS 2008. LNCS, vol. 4963, pp. 337–340. Springer, Heidelberg (2008). https://doi.org/10.1007/978-3-540-78800-3_24

    Chapter  Google Scholar 

  32. Neider, D.: Small strategies for safety games. In: Bultan, T., Hsiung, P.-A. (eds.) ATVA 2011. LNCS, vol. 6996, pp. 306–320. Springer, Heidelberg (2011). https://doi.org/10.1007/978-3-642-24372-1_22

    Chapter  MATH  Google Scholar 

  33. Neider, D., Jansen, N.: Regular model checking using solver technologies and automata learning. In: Brat, G., Rungta, N., Venet, A. (eds.) NFM 2013. LNCS, vol. 7871, pp. 16–31. Springer, Heidelberg (2013). https://doi.org/10.1007/978-3-642-38088-4_2

    Chapter  Google Scholar 

  34. Neider, D., Markgraf, O.: Learning-based synthesis of safety controllers. In: Formal Methods in Computer Aided Design, FMCAD 2019, San Jose, CA, USA, 22–25 October 2019. pp. 120–128 (2019)

    Google Scholar 

  35. Neider, D., Topcu, U.: An automaton learning approach to solving safety games over infinite graphs. In: Chechik, M., Raskin, J.-F. (eds.) TACAS 2016. LNCS, vol. 9636, pp. 204–221. Springer, Heidelberg (2016). https://doi.org/10.1007/978-3-662-49674-9_12

    Chapter  Google Scholar 

  36. Nerode, A.: Linear automaton transformations. Proc. Am. Math. Soc. 9(4), 541–544 (1958)

    Article  MathSciNet  Google Scholar 

  37. Oncina, J., Garcia, P.: Inferring regular languages in polynomial updated time. In: Pattern Recognition and Image Analysis: Selected Papers from the IVth Spanish Symposium, pp. 49–61. World Scientific (1992)

    Google Scholar 

  38. Pnueli, A., Shahar, E.: Liveness and acceleration in parameterized verification. In: Emerson, E.A., Sistla, A.P. (eds.) CAV 2000. LNCS, vol. 1855, pp. 328–343. Springer, Heidelberg (2000). https://doi.org/10.1007/10722167_26

    Chapter  MATH  Google Scholar 

  39. Rivest, R.L., Schapire, R.E.: Inference of finite automata using homing sequences. Inf. Comput. 103(2), 299–347 (1993)

    Article  MathSciNet  Google Scholar 

  40. Solar-Lezama, A.: The sketching approach to program synthesis. In: Hu, Z. (ed.) APLAS 2009. LNCS, vol. 5904, pp. 4–13. Springer, Heidelberg (2009). https://doi.org/10.1007/978-3-642-10672-9_3

    Chapter  Google Scholar 

  41. Solar-Lezama, A., Arnold, G., Tancau, L., Bodík, R., Saraswat, V.A., Seshia, S.A.: Sketching stencils. ACM (2007)

    Google Scholar 

  42. Solar-Lezama, A., Tancau, L., Bodík, R., Seshia, S.A., Saraswat, V.A.: Combinatorial sketching for finite programs (2006)

    Google Scholar 

  43. Staber, S., Bloem, R.: Fault localization and correction with QBF. In: Marques-Silva, J., Sakallah, K.A. (eds.) SAT 2007. LNCS, vol. 4501, pp. 355–368. Springer, Heidelberg (2007). https://doi.org/10.1007/978-3-540-72788-0_34

    Chapter  MATH  Google Scholar 

  44. Tomlin, C.J., Lygeros, J., Sastry, S.S.: A game theoretic approach to controller design for hybrid systems. Proc. IEEE 88, 949–970 (2000)

    Article  Google Scholar 

  45. Vardhan, A., Sen, K., Viswanathan, M., Agha, G.: Using language inference to verify omega-regular properties. In: Halbwachs, N., Zuck, L.D. (eds.) TACAS 2005. LNCS, vol. 3440, pp. 45–60. Springer, Heidelberg (2005). https://doi.org/10.1007/978-3-540-31980-1_4

    Chapter  Google Scholar 

  46. Vardhan, A., Viswanathan, M.: LEVER: a tool for learning based verification. In: Ball, T., Jones, R.B. (eds.) CAV 2006. LNCS, vol. 4144, pp. 471–474. Springer, Heidelberg (2006). https://doi.org/10.1007/11817963_43

    Chapter  Google Scholar 

  47. Vojnar, T.: Cut-offs and automata in formal verification of infinite-state systems, : habilitation Thesis. Brno University of Technology, Faculty of Information Technology (2007)

    Google Scholar 

  48. Vojnar, T.: Cut-offs and Automata in Formal Verification of Infinite-State Systems. FIT Monograph 1, Faculty of Information Technology BUT (2007)

    Google Scholar 

  49. Zuck, L.D., Pnueli, A.: Model checking and abstraction to the aid of parameterized systems (a survey). Comput. Lang. Syst. Struct. 30, 139–169 (2004)

    MATH  Google Scholar 

Download references

Acknowledgement

This work was partially funded by the ERC Starting Grant AV-SMP (grant agreement no. 759969) and MPI-Fellowship as well as the DFG grant no. 434592664.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Oliver Markgraf .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2020 Springer Nature Switzerland AG

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Markgraf, O., Hong, CD., Lin, A.W., Najib, M., Neider, D. (2020). Parameterized Synthesis with Safety Properties. In: Oliveira, B.C.d.S. (eds) Programming Languages and Systems. APLAS 2020. Lecture Notes in Computer Science(), vol 12470. Springer, Cham. https://doi.org/10.1007/978-3-030-64437-6_14

Download citation

  • DOI: https://doi.org/10.1007/978-3-030-64437-6_14

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-030-64436-9

  • Online ISBN: 978-3-030-64437-6

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics