schema.xml 49 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <!--
  3. Licensed to the Apache Software Foundation (ASF) under one or more
  4. contributor license agreements. See the NOTICE file distributed with
  5. this work for additional information regarding copyright ownership.
  6. The ASF licenses this file to You under the Apache License, Version 2.0
  7. (the "License"); you may not use this file except in compliance with
  8. the License. You may obtain a copy of the License at
  9. http://www.apache.org/licenses/LICENSE-2.0
  10. Unless required by applicable law or agreed to in writing, software
  11. distributed under the License is distributed on an "AS IS" BASIS,
  12. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. See the License for the specific language governing permissions and
  14. limitations under the License.
  15. -->
  16. <!--
  17. This is the Solr schema file. This file should be named "schema.xml" and
  18. should be in the conf directory under the solr home
  19. (i.e. ./solr/conf/schema.xml by default)
  20. or located where the classloader for the Solr webapp can find it.
  21. This example schema is the recommended starting point for users.
  22. It should be kept correct and concise, usable out-of-the-box.
  23. For more information, on how to customize this file, please see
  24. http://wiki.apache.org/solr/SchemaXml
  25. PERFORMANCE NOTE: this schema includes many optional features and should not
  26. be used for benchmarking. To improve performance one could
  27. - set stored="false" for all fields possible (esp large fields) when you
  28. only need to search on the field but don't need to return the original
  29. value.
  30. - set indexed="false" if you don't need to search on the field, but only
  31. return the field as a result of searching on other indexed fields.
  32. - remove all unneeded copyField statements
  33. - for best index size and searching performance, set "index" to false
  34. for all general text fields, use copyField to copy them to the
  35. catchall "text" field, and use that for searching.
  36. - For maximum indexing performance, use the StreamingUpdateSolrServer
  37. java client.
  38. - Remember to run the JVM in server mode, and use a higher logging level
  39. that avoids logging every request
  40. -->
  41. <schema name="example" version="1.5">
  42. <!-- attribute "name" is the name of this schema and is only used for display purposes.
  43. version="x.y" is Solr's version number for the schema syntax and
  44. semantics. It should not normally be changed by applications.
  45. 1.0: multiValued attribute did not exist, all fields are multiValued
  46. by nature
  47. 1.1: multiValued attribute introduced, false by default
  48. 1.2: omitTermFreqAndPositions attribute introduced, true by default
  49. except for text fields.
  50. 1.3: removed optional field compress feature
  51. 1.4: autoGeneratePhraseQueries attribute introduced to drive QueryParser
  52. behavior when a single string produces multiple tokens. Defaults
  53. to off for version >= 1.4
  54. 1.5: omitNorms defaults to true for primitive field types
  55. (int, float, boolean, string...)
  56. -->
  57. <fields>
  58. <!-- Valid attributes for fields:
  59. name: mandatory - the name for the field
  60. type: mandatory - the name of a field type from the
  61. <types> fieldType section
  62. indexed: true if this field should be indexed (searchable or sortable)
  63. stored: true if this field should be retrievable
  64. docValues: true if this field should have doc values. Doc values are
  65. useful for faceting, grouping, sorting and function queries. Although not
  66. required, doc values will make the index faster to load, more
  67. NRT-friendly and more memory-efficient. They however come with some
  68. limitations: they are currently only supported by StrField, UUIDField
  69. and all Trie*Fields, and depending on the field type, they might
  70. require the field to be single-valued, be required or have a default
  71. value (check the documentation of the field type you're interested in
  72. for more information)
  73. multiValued: true if this field may contain multiple values per document
  74. omitNorms: (expert) set to true to omit the norms associated with
  75. this field (this disables length normalization and index-time
  76. boosting for the field, and saves some memory). Only full-text
  77. fields or fields that need an index-time boost need norms.
  78. Norms are omitted for primitive (non-analyzed) types by default.
  79. termVectors: [false] set to true to store the term vector for a
  80. given field.
  81. When using MoreLikeThis, fields used for similarity should be
  82. stored for best performance.
  83. termPositions: Store position information with the term vector.
  84. This will increase storage costs.
  85. termOffsets: Store offset information with the term vector. This
  86. will increase storage costs.
  87. required: The field is required. It will throw an error if the
  88. value does not exist
  89. default: a value that should be used if no value is specified
  90. when adding a document.
  91. -->
  92. <!-- field names should consist of alphanumeric or underscore characters only and
  93. not start with a digit. This is not currently strictly enforced,
  94. but other field names will not have first class support from all components
  95. and back compatibility is not guaranteed. Names with both leading and
  96. trailing underscores (e.g. _version_) are reserved.
  97. -->
  98. <field name="id" type="string" indexed="true" stored="true" required="true" multiValued="false" />
  99. <field name="user_friends_count" type="tint" indexed="true" stored="true" />
  100. <field name="user_location" type="lowercase" indexed="true" stored="true" />
  101. <field name="user_description" type="text_en" indexed="true" stored="false"/>
  102. <field name="user_statuses_count" type="tint" indexed="true" stored="true" />
  103. <field name="user_followers_count" type="tint" indexed="true" stored="true"/>
  104. <field name="user_name" type="text_en" indexed="true" stored="true" />
  105. <field name="user_screen_name" type="text_en" indexed="true" stored="true" />
  106. <field name="created_at" type="tdate" indexed="true" stored="true" />
  107. <field name="text" type="text_en" indexed="true" stored="true" />
  108. <field name="retweet_count" type="tint" indexed="true" stored="true" />
  109. <field name="retweeted" type="boolean" indexed="true" stored="false" />
  110. <field name="in_reply_to_user_id" type="long" indexed="true" stored="true" />
  111. <field name="source" type="lowercase" indexed="true" stored="true" />
  112. <field name="in_reply_to_status_id" type="long" indexed="true" stored="true" multiValued="true"/>
  113. <field name="media_url_https" type="string" indexed="false" stored="true" />
  114. <field name="expanded_url" type="string" indexed="false" stored="true" />
  115. <!-- file metadata -->
  116. <!--
  117. <field name="file_download_url" type="string" indexed="false" stored="true" />
  118. <field name="file_upload_url" type="string" indexed="false" stored="true" />
  119. <field name="file_scheme" type="string" indexed="true" stored="true" />
  120. <field name="file_host" type="string" indexed="true" stored="true" />
  121. <field name="file_port" type="int" indexed="true" stored="true" />
  122. <field name="file_path" type="string" indexed="true" stored="true" />
  123. <field name="file_name" type="string" indexed="true" stored="true" />
  124. <field name="file_length" type="tlong" indexed="true" stored="true" />
  125. <field name="file_last_modified" type="tlong" indexed="true" stored="true" />
  126. <field name="file_owner" type="string" indexed="true" stored="true" />
  127. <field name="file_group" type="string" indexed="true" stored="true" />
  128. <field name="file_permissions_user" type="string" indexed="true" stored="true" />
  129. <field name="file_permissions_group" type="string" indexed="true" stored="true" />
  130. <field name="file_permissions_other" type="string" indexed="true" stored="true" />
  131. <field name="file_permissions_stickybit" type="boolean" indexed="true" stored="true" />
  132. -->
  133. <!-- tika metadata -->
  134. <!--
  135. <field name="content_type" type="lowercase" indexed="true" stored="true" />
  136. -->
  137. <field name="_version_" type="long" indexed="true" stored="true"/>
  138. <dynamicField name="ignored_*" type="ignored"/>
  139. </fields>
  140. <!-- Field to use to determine and enforce document uniqueness.
  141. Unless this field is marked with required="false", it will be a required field
  142. -->
  143. <uniqueKey>id</uniqueKey>
  144. <!-- DEPRECATED: The defaultSearchField is consulted by various query parsers when
  145. parsing a query string that isn't explicit about the field. Machine (non-user)
  146. generated queries are best made explicit, or they can use the "df" request parameter
  147. which takes precedence over this.
  148. Note: Un-commenting defaultSearchField will be insufficient if your request handler
  149. in solrconfig.xml defines "df", which takes precedence. That would need to be removed.
  150. <defaultSearchField>text</defaultSearchField> -->
  151. <!-- DEPRECATED: The defaultOperator (AND|OR) is consulted by various query parsers
  152. when parsing a query string to determine if a clause of the query should be marked as
  153. required or optional, assuming the clause isn't already marked by some operator.
  154. The default is OR, which is generally assumed so it is not a good idea to change it
  155. globally here. The "q.op" request parameter takes precedence over this.
  156. <solrQueryParser defaultOperator="OR"/> -->
  157. <!-- copyField commands copy one field to another at the time a document
  158. is added to the index. It's used either to index the same field differently,
  159. or to add multiple fields to the same field for easier/faster searching. -->
  160. <types>
  161. <!-- field type definitions. The "name" attribute is
  162. just a label to be used by field definitions. The "class"
  163. attribute and any other attributes determine the real
  164. behavior of the fieldType.
  165. Class names starting with "solr" refer to java classes in a
  166. standard package such as org.apache.solr.analysis
  167. -->
  168. <!-- The StrField type is not analyzed, but indexed/stored verbatim.
  169. It supports doc values but in that case the field needs to be
  170. single-valued and either required or have a default value.
  171. -->
  172. <fieldType name="string" class="solr.StrField" sortMissingLast="true" />
  173. <!-- boolean type: "true" or "false" -->
  174. <fieldType name="boolean" class="solr.BoolField" sortMissingLast="true"/>
  175. <!-- sortMissingLast and sortMissingFirst attributes are optional attributes are
  176. currently supported on types that are sorted internally as strings
  177. and on numeric types.
  178. This includes "string","boolean", and, as of 3.5 (and 4.x),
  179. int, float, long, date, double, including the "Trie" variants.
  180. - If sortMissingLast="true", then a sort on this field will cause documents
  181. without the field to come after documents with the field,
  182. regardless of the requested sort order (asc or desc).
  183. - If sortMissingFirst="true", then a sort on this field will cause documents
  184. without the field to come before documents with the field,
  185. regardless of the requested sort order.
  186. - If sortMissingLast="false" and sortMissingFirst="false" (the default),
  187. then default lucene sorting will be used which places docs without the
  188. field first in an ascending sort and last in a descending sort.
  189. -->
  190. <!--
  191. Default numeric field types. For faster range queries, consider the tint/tfloat/tlong/tdouble types.
  192. These fields support doc values, but they require the field to be
  193. single-valued and either be required or have a default value.
  194. -->
  195. <fieldType name="int" class="solr.TrieIntField" precisionStep="0" positionIncrementGap="0"/>
  196. <fieldType name="float" class="solr.TrieFloatField" precisionStep="0" positionIncrementGap="0"/>
  197. <fieldType name="long" class="solr.TrieLongField" precisionStep="0" positionIncrementGap="0"/>
  198. <fieldType name="double" class="solr.TrieDoubleField" precisionStep="0" positionIncrementGap="0"/>
  199. <!--
  200. Numeric field types that index each value at various levels of precision
  201. to accelerate range queries when the number of values between the range
  202. endpoints is large. See the javadoc for NumericRangeQuery for internal
  203. implementation details.
  204. Smaller precisionStep values (specified in bits) will lead to more tokens
  205. indexed per value, slightly larger index size, and faster range queries.
  206. A precisionStep of 0 disables indexing at different precision levels.
  207. -->
  208. <fieldType name="tint" class="solr.TrieIntField" precisionStep="8" positionIncrementGap="0"/>
  209. <fieldType name="tfloat" class="solr.TrieFloatField" precisionStep="8" positionIncrementGap="0"/>
  210. <fieldType name="tlong" class="solr.TrieLongField" precisionStep="8" positionIncrementGap="0"/>
  211. <fieldType name="tdouble" class="solr.TrieDoubleField" precisionStep="8" positionIncrementGap="0"/>
  212. <!-- The format for this date field is of the form 1995-12-31T23:59:59Z, and
  213. is a more restricted form of the canonical representation of dateTime
  214. http://www.w3.org/TR/xmlschema-2/#dateTime
  215. The trailing "Z" designates UTC time and is mandatory.
  216. Optional fractional seconds are allowed: 1995-12-31T23:59:59.999Z
  217. All other components are mandatory.
  218. Expressions can also be used to denote calculations that should be
  219. performed relative to "NOW" to determine the value, ie...
  220. NOW/HOUR
  221. ... Round to the start of the current hour
  222. NOW-1DAY
  223. ... Exactly 1 day prior to now
  224. NOW/DAY+6MONTHS+3DAYS
  225. ... 6 months and 3 days in the future from the start of
  226. the current day
  227. Consult the DateField javadocs for more information.
  228. Note: For faster range queries, consider the tdate type
  229. -->
  230. <fieldType name="date" class="solr.TrieDateField" precisionStep="0" positionIncrementGap="0"/>
  231. <!-- A Trie based date field for faster date range queries and date faceting. -->
  232. <fieldType name="tdate" class="solr.TrieDateField" precisionStep="6" positionIncrementGap="0"/>
  233. <!--Binary data type. The data should be sent/retrieved in as Base64 encoded Strings -->
  234. <fieldtype name="binary" class="solr.BinaryField"/>
  235. <!--
  236. Note:
  237. These should only be used for compatibility with existing indexes (created with lucene or older Solr versions).
  238. Use Trie based fields instead. As of Solr 3.5 and 4.x, Trie based fields support sortMissingFirst/Last
  239. Plain numeric field types that store and index the text
  240. value verbatim (and hence don't correctly support range queries, since the
  241. lexicographic ordering isn't equal to the numeric ordering)
  242. -->
  243. <fieldType name="pint" class="solr.IntField"/>
  244. <fieldType name="plong" class="solr.LongField"/>
  245. <fieldType name="pfloat" class="solr.FloatField"/>
  246. <fieldType name="pdouble" class="solr.DoubleField"/>
  247. <fieldType name="pdate" class="solr.DateField" sortMissingLast="true"/>
  248. <!-- The "RandomSortField" is not used to store or search any
  249. data. You can declare fields of this type it in your schema
  250. to generate pseudo-random orderings of your docs for sorting
  251. or function purposes. The ordering is generated based on the field
  252. name and the version of the index. As long as the index version
  253. remains unchanged, and the same field name is reused,
  254. the ordering of the docs will be consistent.
  255. If you want different psuedo-random orderings of documents,
  256. for the same version of the index, use a dynamicField and
  257. change the field name in the request.
  258. -->
  259. <fieldType name="random" class="solr.RandomSortField" indexed="true" />
  260. <!-- solr.TextField allows the specification of custom text analyzers
  261. specified as a tokenizer and a list of token filters. Different
  262. analyzers may be specified for indexing and querying.
  263. The optional positionIncrementGap puts space between multiple fields of
  264. this type on the same document, with the purpose of preventing false phrase
  265. matching across fields.
  266. For more info on customizing your analyzer chain, please see
  267. http://wiki.apache.org/solr/AnalyzersTokenizersTokenFilters
  268. -->
  269. <!-- One can also specify an existing Analyzer class that has a
  270. default constructor via the class attribute on the analyzer element.
  271. Example:
  272. <fieldType name="text_greek" class="solr.TextField">
  273. <analyzer class="org.apache.lucene.analysis.el.GreekAnalyzer"/>
  274. </fieldType>
  275. -->
  276. <!-- A text field that only splits on whitespace for exact matching of words -->
  277. <fieldType name="text_ws" class="solr.TextField" positionIncrementGap="100">
  278. <analyzer>
  279. <tokenizer class="solr.WhitespaceTokenizerFactory"/>
  280. </analyzer>
  281. </fieldType>
  282. <!-- A general text field that has reasonable, generic
  283. cross-language defaults: it tokenizes with StandardTokenizer,
  284. removes stop words from case-insensitive "stopwords.txt"
  285. (empty by default), and down cases. At query time only, it
  286. also applies synonyms. -->
  287. <fieldType name="text_general" class="solr.TextField" positionIncrementGap="100">
  288. <analyzer type="index">
  289. <tokenizer class="solr.StandardTokenizerFactory"/>
  290. <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt" enablePositionIncrements="true" />
  291. <!-- in this example, we will only use synonyms at query time
  292. <filter class="solr.SynonymFilterFactory" synonyms="index_synonyms.txt" ignoreCase="true" expand="false"/>
  293. -->
  294. <filter class="solr.LowerCaseFilterFactory"/>
  295. </analyzer>
  296. <analyzer type="query">
  297. <tokenizer class="solr.StandardTokenizerFactory"/>
  298. <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt" enablePositionIncrements="true" />
  299. <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="true"/>
  300. <filter class="solr.LowerCaseFilterFactory"/>
  301. </analyzer>
  302. </fieldType>
  303. <!-- A text field with defaults appropriate for English: it
  304. tokenizes with StandardTokenizer, removes English stop words
  305. (lang/stopwords_en.txt), down cases, protects words from protwords.txt, and
  306. finally applies Porter's stemming. The query time analyzer
  307. also applies synonyms from synonyms.txt. -->
  308. <fieldType name="text_en" class="solr.TextField" positionIncrementGap="100">
  309. <analyzer type="index">
  310. <tokenizer class="solr.StandardTokenizerFactory"/>
  311. <!-- in this example, we will only use synonyms at query time
  312. <filter class="solr.SynonymFilterFactory" synonyms="index_synonyms.txt" ignoreCase="true" expand="false"/>
  313. -->
  314. <!-- Case insensitive stop word removal.
  315. add enablePositionIncrements=true in both the index and query
  316. analyzers to leave a 'gap' for more accurate phrase queries.
  317. -->
  318. <filter class="solr.StopFilterFactory"
  319. ignoreCase="true"
  320. words="lang/stopwords_en.txt"
  321. enablePositionIncrements="true"
  322. />
  323. <filter class="solr.LowerCaseFilterFactory"/>
  324. <filter class="solr.EnglishPossessiveFilterFactory"/>
  325. <filter class="solr.KeywordMarkerFilterFactory" protected="protwords.txt"/>
  326. <!-- Optionally you may want to use this less aggressive stemmer instead of PorterStemFilterFactory:
  327. <filter class="solr.EnglishMinimalStemFilterFactory"/>
  328. -->
  329. <filter class="solr.PorterStemFilterFactory"/>
  330. </analyzer>
  331. <analyzer type="query">
  332. <tokenizer class="solr.StandardTokenizerFactory"/>
  333. <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="true"/>
  334. <filter class="solr.StopFilterFactory"
  335. ignoreCase="true"
  336. words="lang/stopwords_en.txt"
  337. enablePositionIncrements="true"
  338. />
  339. <filter class="solr.LowerCaseFilterFactory"/>
  340. <filter class="solr.EnglishPossessiveFilterFactory"/>
  341. <filter class="solr.KeywordMarkerFilterFactory" protected="protwords.txt"/>
  342. <!-- Optionally you may want to use this less aggressive stemmer instead of PorterStemFilterFactory:
  343. <filter class="solr.EnglishMinimalStemFilterFactory"/>
  344. -->
  345. <filter class="solr.PorterStemFilterFactory"/>
  346. </analyzer>
  347. </fieldType>
  348. <!-- A text field with defaults appropriate for English, plus
  349. aggressive word-splitting and autophrase features enabled.
  350. This field is just like text_en, except it adds
  351. WordDelimiterFilter to enable splitting and matching of
  352. words on case-change, alpha numeric boundaries, and
  353. non-alphanumeric chars. This means certain compound word
  354. cases will work, for example query "wi fi" will match
  355. document "WiFi" or "wi-fi".
  356. -->
  357. <fieldType name="text_en_splitting" class="solr.TextField" positionIncrementGap="100" autoGeneratePhraseQueries="true">
  358. <analyzer type="index">
  359. <tokenizer class="solr.WhitespaceTokenizerFactory"/>
  360. <!-- in this example, we will only use synonyms at query time
  361. <filter class="solr.SynonymFilterFactory" synonyms="index_synonyms.txt" ignoreCase="true" expand="false"/>
  362. -->
  363. <!-- Case insensitive stop word removal.
  364. add enablePositionIncrements=true in both the index and query
  365. analyzers to leave a 'gap' for more accurate phrase queries.
  366. -->
  367. <filter class="solr.StopFilterFactory"
  368. ignoreCase="true"
  369. words="lang/stopwords_en.txt"
  370. enablePositionIncrements="true"
  371. />
  372. <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" generateNumberParts="1" catenateWords="1" catenateNumbers="1" catenateAll="0" splitOnCaseChange="1"/>
  373. <filter class="solr.LowerCaseFilterFactory"/>
  374. <filter class="solr.KeywordMarkerFilterFactory" protected="protwords.txt"/>
  375. <filter class="solr.PorterStemFilterFactory"/>
  376. </analyzer>
  377. <analyzer type="query">
  378. <tokenizer class="solr.WhitespaceTokenizerFactory"/>
  379. <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="true"/>
  380. <filter class="solr.StopFilterFactory"
  381. ignoreCase="true"
  382. words="lang/stopwords_en.txt"
  383. enablePositionIncrements="true"
  384. />
  385. <filter class="solr.WordDelimiterFilterFactory" generateWordParts="1" generateNumberParts="1" catenateWords="0" catenateNumbers="0" catenateAll="0" splitOnCaseChange="1"/>
  386. <filter class="solr.LowerCaseFilterFactory"/>
  387. <filter class="solr.KeywordMarkerFilterFactory" protected="protwords.txt"/>
  388. <filter class="solr.PorterStemFilterFactory"/>
  389. </analyzer>
  390. </fieldType>
  391. <!-- Less flexible matching, but less false matches. Probably not ideal for product names,
  392. but may be good for SKUs. Can insert dashes in the wrong place and still match. -->
  393. <fieldType name="text_en_splitting_tight" class="solr.TextField" positionIncrementGap="100" autoGeneratePhraseQueries="true">
  394. <analyzer>
  395. <tokenizer class="solr.WhitespaceTokenizerFactory"/>
  396. <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="false"/>
  397. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_en.txt"/>
  398. <filter class="solr.WordDelimiterFilterFactory" generateWordParts="0" generateNumberParts="0" catenateWords="1" catenateNumbers="1" catenateAll="0"/>
  399. <filter class="solr.LowerCaseFilterFactory"/>
  400. <filter class="solr.KeywordMarkerFilterFactory" protected="protwords.txt"/>
  401. <filter class="solr.EnglishMinimalStemFilterFactory"/>
  402. <!-- this filter can remove any duplicate tokens that appear at the same position - sometimes
  403. possible with WordDelimiterFilter in conjuncton with stemming. -->
  404. <filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
  405. </analyzer>
  406. </fieldType>
  407. <!-- Just like text_general except it reverses the characters of
  408. each token, to enable more efficient leading wildcard queries. -->
  409. <fieldType name="text_general_rev" class="solr.TextField" positionIncrementGap="100">
  410. <analyzer type="index">
  411. <tokenizer class="solr.StandardTokenizerFactory"/>
  412. <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt" enablePositionIncrements="true" />
  413. <filter class="solr.LowerCaseFilterFactory"/>
  414. <filter class="solr.ReversedWildcardFilterFactory" withOriginal="true"
  415. maxPosAsterisk="3" maxPosQuestion="2" maxFractionAsterisk="0.33"/>
  416. </analyzer>
  417. <analyzer type="query">
  418. <tokenizer class="solr.StandardTokenizerFactory"/>
  419. <filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="true"/>
  420. <filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt" enablePositionIncrements="true" />
  421. <filter class="solr.LowerCaseFilterFactory"/>
  422. </analyzer>
  423. </fieldType>
  424. <!-- charFilter + WhitespaceTokenizer -->
  425. <!--
  426. <fieldType name="text_char_norm" class="solr.TextField" positionIncrementGap="100" >
  427. <analyzer>
  428. <charFilter class="solr.MappingCharFilterFactory" mapping="mapping-ISOLatin1Accent.txt"/>
  429. <tokenizer class="solr.WhitespaceTokenizerFactory"/>
  430. </analyzer>
  431. </fieldType>
  432. -->
  433. <!-- This is an example of using the KeywordTokenizer along
  434. With various TokenFilterFactories to produce a sortable field
  435. that does not include some properties of the source text
  436. -->
  437. <fieldType name="alphaOnlySort" class="solr.TextField" sortMissingLast="true" omitNorms="true">
  438. <analyzer>
  439. <!-- KeywordTokenizer does no actual tokenizing, so the entire
  440. input string is preserved as a single token
  441. -->
  442. <tokenizer class="solr.KeywordTokenizerFactory"/>
  443. <!-- The LowerCase TokenFilter does what you expect, which can be
  444. when you want your sorting to be case insensitive
  445. -->
  446. <filter class="solr.LowerCaseFilterFactory" />
  447. <!-- The TrimFilter removes any leading or trailing whitespace -->
  448. <filter class="solr.TrimFilterFactory" />
  449. <!-- The PatternReplaceFilter gives you the flexibility to use
  450. Java Regular expression to replace any sequence of characters
  451. matching a pattern with an arbitrary replacement string,
  452. which may include back references to portions of the original
  453. string matched by the pattern.
  454. See the Java Regular Expression documentation for more
  455. information on pattern and replacement string syntax.
  456. http://java.sun.com/j2se/1.6.0/docs/api/java/util/regex/package-summary.html
  457. -->
  458. <filter class="solr.PatternReplaceFilterFactory"
  459. pattern="([^a-z])" replacement="" replace="all"
  460. />
  461. </analyzer>
  462. </fieldType>
  463. <fieldtype name="phonetic" stored="false" indexed="true" class="solr.TextField" >
  464. <analyzer>
  465. <tokenizer class="solr.StandardTokenizerFactory"/>
  466. <filter class="solr.DoubleMetaphoneFilterFactory" inject="false"/>
  467. </analyzer>
  468. </fieldtype>
  469. <fieldtype name="payloads" stored="false" indexed="true" class="solr.TextField" >
  470. <analyzer>
  471. <tokenizer class="solr.WhitespaceTokenizerFactory"/>
  472. <!--
  473. The DelimitedPayloadTokenFilter can put payloads on tokens... for example,
  474. a token of "foo|1.4" would be indexed as "foo" with a payload of 1.4f
  475. Attributes of the DelimitedPayloadTokenFilterFactory :
  476. "delimiter" - a one character delimiter. Default is | (pipe)
  477. "encoder" - how to encode the following value into a playload
  478. float -> org.apache.lucene.analysis.payloads.FloatEncoder,
  479. integer -> o.a.l.a.p.IntegerEncoder
  480. identity -> o.a.l.a.p.IdentityEncoder
  481. Fully Qualified class name implementing PayloadEncoder, Encoder must have a no arg constructor.
  482. -->
  483. <filter class="solr.DelimitedPayloadTokenFilterFactory" encoder="float"/>
  484. </analyzer>
  485. </fieldtype>
  486. <!-- lowercases the entire field value, keeping it as a single token. -->
  487. <fieldType name="lowercase" class="solr.TextField" positionIncrementGap="100">
  488. <analyzer>
  489. <tokenizer class="solr.KeywordTokenizerFactory"/>
  490. <filter class="solr.LowerCaseFilterFactory" />
  491. </analyzer>
  492. </fieldType>
  493. <!--
  494. Example of using PathHierarchyTokenizerFactory at index time, so
  495. queries for paths match documents at that path, or in descendent paths
  496. -->
  497. <fieldType name="descendent_path" class="solr.TextField">
  498. <analyzer type="index">
  499. <tokenizer class="solr.PathHierarchyTokenizerFactory" delimiter="/" />
  500. </analyzer>
  501. <analyzer type="query">
  502. <tokenizer class="solr.KeywordTokenizerFactory" />
  503. </analyzer>
  504. </fieldType>
  505. <!--
  506. Example of using PathHierarchyTokenizerFactory at query time, so
  507. queries for paths match documents at that path, or in ancestor paths
  508. -->
  509. <fieldType name="ancestor_path" class="solr.TextField">
  510. <analyzer type="index">
  511. <tokenizer class="solr.KeywordTokenizerFactory" />
  512. </analyzer>
  513. <analyzer type="query">
  514. <tokenizer class="solr.PathHierarchyTokenizerFactory" delimiter="/" />
  515. </analyzer>
  516. </fieldType>
  517. <!-- since fields of this type are by default not stored or indexed,
  518. any data added to them will be ignored outright. -->
  519. <fieldtype name="ignored" stored="false" indexed="false" multiValued="true" class="solr.StrField" />
  520. <!-- This point type indexes the coordinates as separate fields (subFields)
  521. If subFieldType is defined, it references a type, and a dynamic field
  522. definition is created matching *___<typename>. Alternately, if
  523. subFieldSuffix is defined, that is used to create the subFields.
  524. Example: if subFieldType="double", then the coordinates would be
  525. indexed in fields myloc_0___double,myloc_1___double.
  526. Example: if subFieldSuffix="_d" then the coordinates would be indexed
  527. in fields myloc_0_d,myloc_1_d
  528. The subFields are an implementation detail of the fieldType, and end
  529. users normally should not need to know about them.
  530. -->
  531. <fieldType name="point" class="solr.PointType" dimension="2" subFieldSuffix="_d"/>
  532. <!-- A specialized field for geospatial search. If indexed, this fieldType must not be multivalued. -->
  533. <fieldType name="location" class="solr.LatLonType" subFieldSuffix="_coordinate"/>
  534. <!-- An alternative geospatial field type new to Solr 4. It supports multiValued and polygon shapes.
  535. For more information about this and other Spatial fields new to Solr 4, see:
  536. http://wiki.apache.org/solr/SolrAdaptersForLuceneSpatial4
  537. -->
  538. <fieldType name="location_rpt" class="solr.SpatialRecursivePrefixTreeFieldType"
  539. geo="true" distErrPct="0.025" maxDistErr="0.000009" units="degrees" />
  540. <!-- Money/currency field type. See http://wiki.apache.org/solr/MoneyFieldType
  541. Parameters:
  542. defaultCurrency: Specifies the default currency if none specified. Defaults to "USD"
  543. precisionStep: Specifies the precisionStep for the TrieLong field used for the amount
  544. providerClass: Lets you plug in other exchange provider backend:
  545. solr.FileExchangeRateProvider is the default and takes one parameter:
  546. currencyConfig: name of an xml file holding exchange rates
  547. solr.OpenExchangeRatesOrgProvider uses rates from openexchangerates.org:
  548. ratesFileLocation: URL or path to rates JSON file (default latest.json on the web)
  549. refreshInterval: Number of minutes between each rates fetch (default: 1440, min: 60)
  550. -->
  551. <fieldType name="currency" class="solr.CurrencyField" precisionStep="8" defaultCurrency="USD" currencyConfig="currency.xml" />
  552. <!-- some examples for different languages (generally ordered by ISO code) -->
  553. <!-- Arabic -->
  554. <fieldType name="text_ar" class="solr.TextField" positionIncrementGap="100">
  555. <analyzer>
  556. <tokenizer class="solr.StandardTokenizerFactory"/>
  557. <!-- for any non-arabic -->
  558. <filter class="solr.LowerCaseFilterFactory"/>
  559. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_ar.txt" enablePositionIncrements="true"/>
  560. <!-- normalizes ﻯ to ﻱ, etc -->
  561. <filter class="solr.ArabicNormalizationFilterFactory"/>
  562. <filter class="solr.ArabicStemFilterFactory"/>
  563. </analyzer>
  564. </fieldType>
  565. <!-- Bulgarian -->
  566. <fieldType name="text_bg" class="solr.TextField" positionIncrementGap="100">
  567. <analyzer>
  568. <tokenizer class="solr.StandardTokenizerFactory"/>
  569. <filter class="solr.LowerCaseFilterFactory"/>
  570. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_bg.txt" enablePositionIncrements="true"/>
  571. <filter class="solr.BulgarianStemFilterFactory"/>
  572. </analyzer>
  573. </fieldType>
  574. <!-- Catalan -->
  575. <fieldType name="text_ca" class="solr.TextField" positionIncrementGap="100">
  576. <analyzer>
  577. <tokenizer class="solr.StandardTokenizerFactory"/>
  578. <!-- removes l', etc -->
  579. <filter class="solr.ElisionFilterFactory" ignoreCase="true" articles="lang/contractions_ca.txt"/>
  580. <filter class="solr.LowerCaseFilterFactory"/>
  581. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_ca.txt" enablePositionIncrements="true"/>
  582. <filter class="solr.SnowballPorterFilterFactory" language="Catalan"/>
  583. </analyzer>
  584. </fieldType>
  585. <!-- CJK bigram (see text_ja for a Japanese configuration using morphological analysis) -->
  586. <fieldType name="text_cjk" class="solr.TextField" positionIncrementGap="100">
  587. <analyzer>
  588. <tokenizer class="solr.StandardTokenizerFactory"/>
  589. <!-- normalize width before bigram, as e.g. half-width dakuten combine -->
  590. <filter class="solr.CJKWidthFilterFactory"/>
  591. <!-- for any non-CJK -->
  592. <filter class="solr.LowerCaseFilterFactory"/>
  593. <filter class="solr.CJKBigramFilterFactory"/>
  594. </analyzer>
  595. </fieldType>
  596. <!-- Czech -->
  597. <fieldType name="text_cz" class="solr.TextField" positionIncrementGap="100">
  598. <analyzer>
  599. <tokenizer class="solr.StandardTokenizerFactory"/>
  600. <filter class="solr.LowerCaseFilterFactory"/>
  601. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_cz.txt" enablePositionIncrements="true"/>
  602. <filter class="solr.CzechStemFilterFactory"/>
  603. </analyzer>
  604. </fieldType>
  605. <!-- Danish -->
  606. <fieldType name="text_da" class="solr.TextField" positionIncrementGap="100">
  607. <analyzer>
  608. <tokenizer class="solr.StandardTokenizerFactory"/>
  609. <filter class="solr.LowerCaseFilterFactory"/>
  610. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_da.txt" format="snowball" enablePositionIncrements="true"/>
  611. <filter class="solr.SnowballPorterFilterFactory" language="Danish"/>
  612. </analyzer>
  613. </fieldType>
  614. <!-- German -->
  615. <fieldType name="text_de" class="solr.TextField" positionIncrementGap="100">
  616. <analyzer>
  617. <tokenizer class="solr.StandardTokenizerFactory"/>
  618. <filter class="solr.LowerCaseFilterFactory"/>
  619. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_de.txt" format="snowball" enablePositionIncrements="true"/>
  620. <filter class="solr.GermanNormalizationFilterFactory"/>
  621. <filter class="solr.GermanLightStemFilterFactory"/>
  622. <!-- less aggressive: <filter class="solr.GermanMinimalStemFilterFactory"/> -->
  623. <!-- more aggressive: <filter class="solr.SnowballPorterFilterFactory" language="German2"/> -->
  624. </analyzer>
  625. </fieldType>
  626. <!-- Greek -->
  627. <fieldType name="text_el" class="solr.TextField" positionIncrementGap="100">
  628. <analyzer>
  629. <tokenizer class="solr.StandardTokenizerFactory"/>
  630. <!-- greek specific lowercase for sigma -->
  631. <filter class="solr.GreekLowerCaseFilterFactory"/>
  632. <filter class="solr.StopFilterFactory" ignoreCase="false" words="lang/stopwords_el.txt" enablePositionIncrements="true"/>
  633. <filter class="solr.GreekStemFilterFactory"/>
  634. </analyzer>
  635. </fieldType>
  636. <!-- Spanish -->
  637. <fieldType name="text_es" class="solr.TextField" positionIncrementGap="100">
  638. <analyzer>
  639. <tokenizer class="solr.StandardTokenizerFactory"/>
  640. <filter class="solr.LowerCaseFilterFactory"/>
  641. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_es.txt" format="snowball" enablePositionIncrements="true"/>
  642. <filter class="solr.SpanishLightStemFilterFactory"/>
  643. <!-- more aggressive: <filter class="solr.SnowballPorterFilterFactory" language="Spanish"/> -->
  644. </analyzer>
  645. </fieldType>
  646. <!-- Basque -->
  647. <fieldType name="text_eu" class="solr.TextField" positionIncrementGap="100">
  648. <analyzer>
  649. <tokenizer class="solr.StandardTokenizerFactory"/>
  650. <filter class="solr.LowerCaseFilterFactory"/>
  651. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_eu.txt" enablePositionIncrements="true"/>
  652. <filter class="solr.SnowballPorterFilterFactory" language="Basque"/>
  653. </analyzer>
  654. </fieldType>
  655. <!-- Persian -->
  656. <fieldType name="text_fa" class="solr.TextField" positionIncrementGap="100">
  657. <analyzer>
  658. <!-- for ZWNJ -->
  659. <charFilter class="solr.PersianCharFilterFactory"/>
  660. <tokenizer class="solr.StandardTokenizerFactory"/>
  661. <filter class="solr.LowerCaseFilterFactory"/>
  662. <filter class="solr.ArabicNormalizationFilterFactory"/>
  663. <filter class="solr.PersianNormalizationFilterFactory"/>
  664. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_fa.txt" enablePositionIncrements="true"/>
  665. </analyzer>
  666. </fieldType>
  667. <!-- Finnish -->
  668. <fieldType name="text_fi" class="solr.TextField" positionIncrementGap="100">
  669. <analyzer>
  670. <tokenizer class="solr.StandardTokenizerFactory"/>
  671. <filter class="solr.LowerCaseFilterFactory"/>
  672. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_fi.txt" format="snowball" enablePositionIncrements="true"/>
  673. <filter class="solr.SnowballPorterFilterFactory" language="Finnish"/>
  674. <!-- less aggressive: <filter class="solr.FinnishLightStemFilterFactory"/> -->
  675. </analyzer>
  676. </fieldType>
  677. <!-- French -->
  678. <fieldType name="text_fr" class="solr.TextField" positionIncrementGap="100">
  679. <analyzer>
  680. <tokenizer class="solr.StandardTokenizerFactory"/>
  681. <!-- removes l', etc -->
  682. <filter class="solr.ElisionFilterFactory" ignoreCase="true" articles="lang/contractions_fr.txt"/>
  683. <filter class="solr.LowerCaseFilterFactory"/>
  684. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_fr.txt" format="snowball" enablePositionIncrements="true"/>
  685. <filter class="solr.FrenchLightStemFilterFactory"/>
  686. <!-- less aggressive: <filter class="solr.FrenchMinimalStemFilterFactory"/> -->
  687. <!-- more aggressive: <filter class="solr.SnowballPorterFilterFactory" language="French"/> -->
  688. </analyzer>
  689. </fieldType>
  690. <!-- Irish -->
  691. <fieldType name="text_ga" class="solr.TextField" positionIncrementGap="100">
  692. <analyzer>
  693. <tokenizer class="solr.StandardTokenizerFactory"/>
  694. <!-- removes d', etc -->
  695. <filter class="solr.ElisionFilterFactory" ignoreCase="true" articles="lang/contractions_ga.txt"/>
  696. <!-- removes n-, etc. position increments is intentionally false! -->
  697. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/hyphenations_ga.txt" enablePositionIncrements="false"/>
  698. <filter class="solr.IrishLowerCaseFilterFactory"/>
  699. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_ga.txt" enablePositionIncrements="true"/>
  700. <filter class="solr.SnowballPorterFilterFactory" language="Irish"/>
  701. </analyzer>
  702. </fieldType>
  703. <!-- Galician -->
  704. <fieldType name="text_gl" class="solr.TextField" positionIncrementGap="100">
  705. <analyzer>
  706. <tokenizer class="solr.StandardTokenizerFactory"/>
  707. <filter class="solr.LowerCaseFilterFactory"/>
  708. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_gl.txt" enablePositionIncrements="true"/>
  709. <filter class="solr.GalicianStemFilterFactory"/>
  710. <!-- less aggressive: <filter class="solr.GalicianMinimalStemFilterFactory"/> -->
  711. </analyzer>
  712. </fieldType>
  713. <!-- Hindi -->
  714. <fieldType name="text_hi" class="solr.TextField" positionIncrementGap="100">
  715. <analyzer>
  716. <tokenizer class="solr.StandardTokenizerFactory"/>
  717. <filter class="solr.LowerCaseFilterFactory"/>
  718. <!-- normalizes unicode representation -->
  719. <filter class="solr.IndicNormalizationFilterFactory"/>
  720. <!-- normalizes variation in spelling -->
  721. <filter class="solr.HindiNormalizationFilterFactory"/>
  722. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_hi.txt" enablePositionIncrements="true"/>
  723. <filter class="solr.HindiStemFilterFactory"/>
  724. </analyzer>
  725. </fieldType>
  726. <!-- Hungarian -->
  727. <fieldType name="text_hu" class="solr.TextField" positionIncrementGap="100">
  728. <analyzer>
  729. <tokenizer class="solr.StandardTokenizerFactory"/>
  730. <filter class="solr.LowerCaseFilterFactory"/>
  731. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_hu.txt" format="snowball" enablePositionIncrements="true"/>
  732. <filter class="solr.SnowballPorterFilterFactory" language="Hungarian"/>
  733. <!-- less aggressive: <filter class="solr.HungarianLightStemFilterFactory"/> -->
  734. </analyzer>
  735. </fieldType>
  736. <!-- Armenian -->
  737. <fieldType name="text_hy" class="solr.TextField" positionIncrementGap="100">
  738. <analyzer>
  739. <tokenizer class="solr.StandardTokenizerFactory"/>
  740. <filter class="solr.LowerCaseFilterFactory"/>
  741. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_hy.txt" enablePositionIncrements="true"/>
  742. <filter class="solr.SnowballPorterFilterFactory" language="Armenian"/>
  743. </analyzer>
  744. </fieldType>
  745. <!-- Indonesian -->
  746. <fieldType name="text_id" class="solr.TextField" positionIncrementGap="100">
  747. <analyzer>
  748. <tokenizer class="solr.StandardTokenizerFactory"/>
  749. <filter class="solr.LowerCaseFilterFactory"/>
  750. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_id.txt" enablePositionIncrements="true"/>
  751. <!-- for a less aggressive approach (only inflectional suffixes), set stemDerivational to false -->
  752. <filter class="solr.IndonesianStemFilterFactory" stemDerivational="true"/>
  753. </analyzer>
  754. </fieldType>
  755. <!-- Italian -->
  756. <fieldType name="text_it" class="solr.TextField" positionIncrementGap="100">
  757. <analyzer>
  758. <tokenizer class="solr.StandardTokenizerFactory"/>
  759. <!-- removes l', etc -->
  760. <filter class="solr.ElisionFilterFactory" ignoreCase="true" articles="lang/contractions_it.txt"/>
  761. <filter class="solr.LowerCaseFilterFactory"/>
  762. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_it.txt" format="snowball" enablePositionIncrements="true"/>
  763. <filter class="solr.ItalianLightStemFilterFactory"/>
  764. <!-- more aggressive: <filter class="solr.SnowballPorterFilterFactory" language="Italian"/> -->
  765. </analyzer>
  766. </fieldType>
  767. <!-- Latvian -->
  768. <fieldType name="text_lv" class="solr.TextField" positionIncrementGap="100">
  769. <analyzer>
  770. <tokenizer class="solr.StandardTokenizerFactory"/>
  771. <filter class="solr.LowerCaseFilterFactory"/>
  772. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_lv.txt" enablePositionIncrements="true"/>
  773. <filter class="solr.LatvianStemFilterFactory"/>
  774. </analyzer>
  775. </fieldType>
  776. <!-- Dutch -->
  777. <fieldType name="text_nl" class="solr.TextField" positionIncrementGap="100">
  778. <analyzer>
  779. <tokenizer class="solr.StandardTokenizerFactory"/>
  780. <filter class="solr.LowerCaseFilterFactory"/>
  781. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_nl.txt" format="snowball" enablePositionIncrements="true"/>
  782. <filter class="solr.StemmerOverrideFilterFactory" dictionary="lang/stemdict_nl.txt" ignoreCase="false"/>
  783. <filter class="solr.SnowballPorterFilterFactory" language="Dutch"/>
  784. </analyzer>
  785. </fieldType>
  786. <!-- Norwegian -->
  787. <fieldType name="text_no" class="solr.TextField" positionIncrementGap="100">
  788. <analyzer>
  789. <tokenizer class="solr.StandardTokenizerFactory"/>
  790. <filter class="solr.LowerCaseFilterFactory"/>
  791. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_no.txt" format="snowball" enablePositionIncrements="true"/>
  792. <filter class="solr.SnowballPorterFilterFactory" language="Norwegian"/>
  793. <!-- less aggressive: <filter class="solr.NorwegianLightStemFilterFactory"/> -->
  794. <!-- singular/plural: <filter class="solr.NorwegianMinimalStemFilterFactory"/> -->
  795. </analyzer>
  796. </fieldType>
  797. <!-- Portuguese -->
  798. <fieldType name="text_pt" class="solr.TextField" positionIncrementGap="100">
  799. <analyzer>
  800. <tokenizer class="solr.StandardTokenizerFactory"/>
  801. <filter class="solr.LowerCaseFilterFactory"/>
  802. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_pt.txt" format="snowball" enablePositionIncrements="true"/>
  803. <filter class="solr.PortugueseLightStemFilterFactory"/>
  804. <!-- less aggressive: <filter class="solr.PortugueseMinimalStemFilterFactory"/> -->
  805. <!-- more aggressive: <filter class="solr.SnowballPorterFilterFactory" language="Portuguese"/> -->
  806. <!-- most aggressive: <filter class="solr.PortugueseStemFilterFactory"/> -->
  807. </analyzer>
  808. </fieldType>
  809. <!-- Romanian -->
  810. <fieldType name="text_ro" class="solr.TextField" positionIncrementGap="100">
  811. <analyzer>
  812. <tokenizer class="solr.StandardTokenizerFactory"/>
  813. <filter class="solr.LowerCaseFilterFactory"/>
  814. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_ro.txt" enablePositionIncrements="true"/>
  815. <filter class="solr.SnowballPorterFilterFactory" language="Romanian"/>
  816. </analyzer>
  817. </fieldType>
  818. <!-- Russian -->
  819. <fieldType name="text_ru" class="solr.TextField" positionIncrementGap="100">
  820. <analyzer>
  821. <tokenizer class="solr.StandardTokenizerFactory"/>
  822. <filter class="solr.LowerCaseFilterFactory"/>
  823. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_ru.txt" format="snowball" enablePositionIncrements="true"/>
  824. <filter class="solr.SnowballPorterFilterFactory" language="Russian"/>
  825. <!-- less aggressive: <filter class="solr.RussianLightStemFilterFactory"/> -->
  826. </analyzer>
  827. </fieldType>
  828. <!-- Swedish -->
  829. <fieldType name="text_sv" class="solr.TextField" positionIncrementGap="100">
  830. <analyzer>
  831. <tokenizer class="solr.StandardTokenizerFactory"/>
  832. <filter class="solr.LowerCaseFilterFactory"/>
  833. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_sv.txt" format="snowball" enablePositionIncrements="true"/>
  834. <filter class="solr.SnowballPorterFilterFactory" language="Swedish"/>
  835. <!-- less aggressive: <filter class="solr.SwedishLightStemFilterFactory"/> -->
  836. </analyzer>
  837. </fieldType>
  838. <!-- Thai -->
  839. <fieldType name="text_th" class="solr.TextField" positionIncrementGap="100">
  840. <analyzer>
  841. <tokenizer class="solr.StandardTokenizerFactory"/>
  842. <filter class="solr.LowerCaseFilterFactory"/>
  843. <filter class="solr.ThaiWordFilterFactory"/>
  844. <filter class="solr.StopFilterFactory" ignoreCase="true" words="lang/stopwords_th.txt" enablePositionIncrements="true"/>
  845. </analyzer>
  846. </fieldType>
  847. <!-- Turkish -->
  848. <fieldType name="text_tr" class="solr.TextField" positionIncrementGap="100">
  849. <analyzer>
  850. <tokenizer class="solr.StandardTokenizerFactory"/>
  851. <filter class="solr.TurkishLowerCaseFilterFactory"/>
  852. <filter class="solr.StopFilterFactory" ignoreCase="false" words="lang/stopwords_tr.txt" enablePositionIncrements="true"/>
  853. <filter class="solr.SnowballPorterFilterFactory" language="Turkish"/>
  854. </analyzer>
  855. </fieldType>
  856. </types>
  857. <!-- Similarity is the scoring routine for each document vs. a query.
  858. A custom Similarity or SimilarityFactory may be specified here, but
  859. the default is fine for most applications.
  860. For more info: http://wiki.apache.org/solr/SchemaXml#Similarity
  861. -->
  862. <!--
  863. <similarity class="com.example.solr.CustomSimilarityFactory">
  864. <str name="paramkey">param value</str>
  865. </similarity>
  866. -->
  867. </schema>