XML Representation of Constraint Networks
Christophe Lecoutre · 2009
XML Representation of Constraint NetworksBefore being attacked by a constraint solver, instances of the constraint satisfaction problem must be represented and stored in computer data files 1 .The extensible markup language (XML) [WWW97] offers standardized representation of problem instances.XML is a simple and flexible text format that is increasingly important in the exchange of a wide variety of data on the web.The aim of the XML representation of CSP instances is to facilitate testing and comparison of constraint algorithms by providing a common test-bed.The CSP XML representation format, denoted by XCSP, has been introduced for international constraint solver competitions.Its current specification, XCSP 2.1 [ROU 09], is low-level, although introducing higher level constructs is envisioned.XCSP exhaustively describes domains, variables, relations (if any), predicates (if any) and constraints for each CSP instance.Interestingly, the proposed XML format offers two variants: a fully tagged representation and an abridged representation.The first is a full, completely structured XML representation that is suitable for use in generic XML tools, but is also relatively verbose.The second is a shorthand notation for the first representation, and is easier for a human to read and write.The two representations are equivalent: automatic translation tools allow us to use the shorthand notation to encode an instance while still being completely able to use available XML tools.The XML format XCSP is intended to be a good compromise between readability, verbosity and structuring.1. CSP instances can also be directly generated by programming, but this prevents broadcasting them.