<commit_before>package iiif

// FeatureSet represents all possible IIIF 2.0 features that can be encoded
// into a URL.  The fields are the same as the string to report features,
// except that the first character should be lowercased.
//
// Note that using this in a custom server only gets you so far.  As noted in
// the Supported() documentation below, verifying complete support is trickier
// than just checking a URL, and a server that doesn't support arbitrary
// resizing can still advertise specific sizes that will work.
type FeatureSet struct {
	// Region options: note that full isn't specified but must be supported
	RegionByPx  bool
	RegionByPct bool

	// Size options: note that full isn't specified but must be supported
	SizeByWhListed bool
	SizeByW        bool
	SizeByH        bool
	SizeByPct      bool
	SizeByForcedWh bool
	SizeByWh       bool
	SizeAboveFull  bool

	// Rotation and mirroring
	RotationBy90s     bool
	RotationArbitrary bool
	Mirroring         bool

	// "Quality", or as normal folk call it, "color depth"
	Default bool
	Color   bool
	Gray    bool
	Bitonal bool

	// Format
	Jpg  bool
	Png  bool
	Tif  bool
	Gif  bool
	Jp2  bool
	Pdf  bool
	Webp bool

	// HTTP features
	BaseUriRedirect     bool
	Cors                bool
	JsonldMediaType     bool
	ProfileLinkHeader   bool
	CanonicalLinkHeader bool
}

// FeaturesLevel0: the required features for a level-0-compliant IIIF server
var FeaturesLevel0 = &FeatureSet{
	SizeByWhListed: true,<commit_msg>Fix some featureset comments<commit_after>package iiif

// FeatureSet represents all possible IIIF 2.0 features that can be represented
// as a boolean value.  The fields are the same as the string to report
// features, except that the first character should be lowercased.
//
// Note that using this in a different server only gets you so far.  As noted
// in the Supported() documentation below, verifying complete support is
// trickier than just checking a URL, and a server that doesn't support
// arbitrary resizing can still advertise specific sizes that will work.
type FeatureSet struct {
	// Region options: note that full isn't specified but must be supported
	RegionByPx  bool
	RegionByPct bool

	// Size options: note that full isn't specified but must be supported
	SizeByWhListed bool
	SizeByW        bool
	SizeByH        bool
	SizeByPct      bool
	SizeByForcedWh bool
	SizeByWh       bool
	SizeAboveFull  bool

	// Rotation and mirroring
	RotationBy90s     bool
	RotationArbitrary bool
	Mirroring         bool

	// "Quality" (color depth / color space)
	Default bool
	Color   bool
	Gray    bool
	Bitonal bool

	// Format
	Jpg  bool
	Png  bool
	Tif  bool
	Gif  bool
	Jp2  bool
	Pdf  bool
	Webp bool

	// HTTP features
	BaseUriRedirect     bool
	Cors                bool
	JsonldMediaType     bool
	ProfileLinkHeader   bool
	CanonicalLinkHeader bool
}

// FeaturesLevel0: the required features for a level-0-compliant IIIF server
var FeaturesLevel0 = &FeatureSet{
	SizeByWhListed: true,
{'fraction_non_alphanumeric': 0.042560321715817695, 'fraction_numerical': 0.005361930294906166, 'mean_word_length': 3.0834473324213407, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4691659', 'n_tokens_mistral': 892, 'n_tokens_neox': 857, 'n_words': 381}