Drain kraut slightly. Cook onion in butter or drippings until transparent. Add sauerkraut and stir; cook slowly. Wash, peel, and core apples; dice fruit and add to sauerkraut. Add wine and enough stock or bouillon to cover. Cook slowly, uncovered, for 30 minutes. Add sugar and celery seeds; cover and finish cooking in moderate 325° oven 30 minutes longer.