HEX-Programs with Nested Program Calls

  • Thomas Eiter
  • Thomas Krennwallner
  • Christoph Redl
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 7773)

Abstract

Answer-Set Programming (ASP) is an established declarative programming paradigm. However, classical ASP lacks subprogram calls as in procedural programming, and access to external computations (akin to remote procedure calls) in general. This feature is desired for increasing modularity and—assuming proper access in place—(meta-)reasoning over subprogram results. While hex-programs extend classical ASP with external source access, they do not support calls of (sub-)programs upfront. We present nested hex-programs, which extend hex-programs to serve the desired feature in a user-friendly manner. Notably, the answer sets of called sub-programs can be individually accessed. This is particularly useful for applications that need to reason over answer sets like belief set merging, user-defined aggregate functions, or preferences of answer sets. We will further present a novel method for rapid prototyping of external sources by the use of nested programs.

References

  1. 1.
    Analyti, A., Antoniou, G., Damásio, C.V.: Mweb: a principled framework for modular web rule bases and its semantics. ACM Trans. Comput. Log. 12(2), 17:1–17:46 (2011)CrossRefGoogle Scholar
  2. 2.
    Baral, C., Dzifcak, J., Takahashi, H.: Macros, macro calls and use of ensembles in modular answer set programming. In: Etalle, S., Truszczyński, M. (eds.) ICLP 2006. LNCS, vol. 4079, pp. 376–390. Springer, Heidelberg (2006)Google Scholar
  3. 3.
    Brewka, G., Eiter, T., Truszczyński, M.: Answer set programming at a glance. Commun. ACM 54(12), 92–103 (2011)CrossRefGoogle Scholar
  4. 4.
    Delgrande, J.P., Schaub, T., Tompits, H., Wang, K.: A classification and survey of preference handling approaches in nonmonotonic reasoning. Comput. Intell. 20(2), 308–334 (2004)MathSciNetCrossRefGoogle Scholar
  5. 5.
    Eiter, T., Gottlob, G., Veith, H.: Modular logic programming and generalized quantifiers. In: Dix, J., Furbach, U., Nerode, A. (eds.) LPNMR 1997. LNCS, vol. 1265, pp. 289–308. Springer, Heidelberg (1997)Google Scholar
  6. 6.
    Eiter, T., Ianni, G., Schindlauer, R., Tompits, H.: A uniform integration of higher-order reasoning and external evaluations in answer set programming. In: IJCAI’05, pp. 90–96. Professional Book Center (2005)Google Scholar
  7. 7.
    Faber, W., Leone, N., Pfeifer, G.: Semantics and complexity of recursive aggregates in answer set programming. Artif. Intell. 175(1), 278–298 (2011)MathSciNetCrossRefMATHGoogle Scholar
  8. 8.
    Gelfond, M., Lifschitz, V.: Classical negation in logic programs and deductive databases. New Generat. Comput. 9, 365–385 (1991)CrossRefGoogle Scholar
  9. 9.
    Janhunen, T., Oikarinen, E., Tompits, H., Woltran, S.: Modularity aspects of disjunctive stable models. J. Artif. Intell. Res. 35, 813–857 (2009)MathSciNetMATHGoogle Scholar
  10. 10.
    Redl, C., Eiter, T., Krennwallner, T.: Declarative belief set merging using merging plans. In: Rocha, R., Launchbury, J. (eds.) PADL 2011. LNCS, vol. 6539, pp. 99–114. Springer, Heidelberg (2011)Google Scholar
  11. 11.
    Swift, T., Warren, D.S.: XSB: Extending prolog with tabled logic programming. Theor. Pract. Log. Program 12(1–2), 157–187 (2012)MathSciNetCrossRefMATHGoogle Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2013

Authors and Affiliations

  • Thomas Eiter
    • 1
  • Thomas Krennwallner
    • 1
  • Christoph Redl
    • 1
  1. 1.Institut für InformationssystemeTechnische Universität WienViennaAustria

Personalised recommendations