Running from the command line java weka.classifiers.bayes.net.BayesNetGenerator -B -N 10 -A 9 -C 2 will print a Bayes net with 10 nodes, 9 arcs and binary variables in XML BIF format to standard output.