找了个成语词典提取了拼音按照拼音排序试了下,还可以

贴一张Goldendict(ng)排的,人来看毫无规律
按拼音排序,这应该是和原词典一样的,不管怎么说,顺序对人友好
写完这个简陋的demo试用了几下再回到gd mdict 这些排了个寂寞的就有些割裂
研究mdict没用了,已经把所有词条顺序都打乱,屎山不可恢复。多看看物書堂还有epwing官方推出的格式,词条完全按照原书顺序,仅对索引排序。当然这个排序算法也不是那么容易,先拿使用人数最多的几种语言来说,欧洲那些有符号的拉丁字母,希腊字母,西里尔字母,阿拉伯字母,日文假名,天城文字母怎么排序,估计没人能全写对。
又遇到个坑,直接按拼音的ascii排会za<zhi<zu,不过这能说错吗?严格来讲对于字典里的声母zh和z分开排是不对,也许有人就是习惯先按声母排,也可能习惯按单个字母排,不过我想应该后者多,或许应该留两列让用户来选
epwing稍微研究了下,似乎是按假名排序的,日本那个编码JIS X 0208在这些字符的码位本来就是人可读的顺序,假名由做词典的提供,再配合“辅助索引”,多个搜索键指向同一词条,还有某些字符的转换。中文只有GB2312里的汉字是按拼音或者笔画排序的
不是吧。。。有个定义部分的,可以把附录按想要的顺序放在前面。没有这个部分的话,就是按照正文顺序而已,根据十六进制标志符定位词头从哪里开始和结束。
这个就是“排序键”的一种实现方式,换句话说,额外注明某部分比如封面 凡例 这些放哪,词典软件一拿就是排好的
id text pinyin
636 一鼓而下 yi1 gu3 er2 xia4
637 一鼻孔出气 yi1 bi2 kong3 chu1 qi4
638 一龙一蛇 yi1 long2 yi1 she2
639 丁一卯二 ding1 yi1 mao3 er4
640 丁一确二 ding1 yi1 que4 er4
……
761 万全之策 wan4 quan2 zhi1 ce4
762 万全之算 wan4 quan2 zhi1 suan4
直接查的是文本,候选的顺序是找到所有匹配的词条按排序键排出的,pinyin这列纯ascii排序就是空格<数字0-9<小写字母a-z,当作排序键
如果我想让“声明”这个词条是第一个,排序键设为0就行
id 声明 0
展示所有词条时按排序键排序
id ,"声明","0"
24717,"阿鼻地狱","a1 bi2 di4 yu4"
24712,"阿狗阿猫","a1 gou3 a1 mao1"
……
epwing是电子书的形式,索引可以有多个,索引和目录是分开的,这也是我之前提到的按电子书标准epub加上索引来设计词典格式的好处,就是可以查也可以按电子书浏览。
你做的这个词典新格式文本存储是 JSON 的还是 HTML 的?
我觉得电子书也可以一起搞,KFX 不就是这样的自带词典,但也要用 JSON 的 AST, 建立一种标准化的语义数据结构,以彻底解决电子书格式渲染不一与表现力受限的问题。(参考 KFX,虽然输入是 HTML ,但存储的时候还是自定义的 AST。
我觉得这个问题总结其实挺好,先把问题写一写,需求搞清楚。咱们用不着先着急定二进制格式。格式总是要为需求服务的。
看看现在的字典格式都有什么问题,新的格式除解决问题之外,还打算做什么增强。
我已经很清楚有哪些问题了,剩下的只需要在 JSON 和 HTML 之间选择。选后面的直接和 MDX 竞争,失败可能性太高,选前面的放弃大多数词典,只能做少量精品词典,但有生存的可能。
大部分都没有问题,做数据库的那些人都趟过坑了。
麻烦在于中文这种有多种排序方式,不知道用户会用哪个
json是语义,html是表现,这俩不冲突,可以共存的
实际是不可以共存的,难度太高了。
套一个类似于xslt的模板不就行了
HTML和JSON都有考虑,但我觉得JSON对于太复杂的会很绕
JSON对于不复杂的结构很好搞
{
"derivation": "南朝·梁·萧绎《驰檄告四方》郭默清夷,晋熙附义,计穷力屈,反杀后主。”",
"example": "妖王笑道那猴儿~,无处求人,断然是送命来也。”★明·吴承恩《西游记》第六十六回",
"explanation": "穷、竭尽。计谋、力量都用尽了。",
"pinyin": "jì qióng lì jié",
"word": "计穷力竭",
"abbreviation": "jqlj"
},
{
"derivation": "南朝·梁·萧绎《驰檄告四方》郭默清夷、晋熙附义,计穷力屈,反杀后主。”",
"example": "臣已~,只好整兵与他决一死战。★清·钱彩《说岳全传》第四十二回",
"explanation": "计计策;穷、屈尽,竭。计策、力量都用完了。",
"pinyin": "jì qióng lì jìn",
"word": "计穷力尽",
"abbreviation": "jqlj"
},
{
"derivation": "明·鹿善继《请发帑疏》臣今日之请,非但司辽饷言辽饷,实在新库言新库,计穷力诎,不得不出于此。”",
"example": "无",
"explanation": "计策、力量都用完了。见计穷力屈”。",
"pinyin": "jì qióng lì qū",
"word": "计穷力诎",
"abbreviation": "jqlq"
},
像这个朗文的XML转到HTML很简单,但用JSON会复杂得多,而且不少词典没这么结构化
<Entry id="u2fc098491a42200a.6e2b450a.1150446158e.2630" sortname="ta_0117">
<Head>
<HWD>take</HWD>
<HOMNUM>1</HOMNUM>
<PronCodes>
<PRON>teɪk</PRON>
</PronCodes>
<LEVEL value="3" pron="yes" />
<POS>v</POS>
<Inflections>
<PASTTENSE>took</PASTTENSE>
<PronCodes>
<PRON>tʊk</PRON>
</PronCodes>
<PASTPART>taken</PASTPART>
<PronCodes>
<PRON>ˈteɪkən</PRON>
</PronCodes>
</Inflections>
<FREQ>S1</FREQ>
<FREQ>W1</FREQ>
<SearchInflections>
<WF>takes</WF>
<WF>took</WF>
<WF>taken</WF>
<WF>taking</WF>
</SearchInflections>
</Head>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.2653">
<SIGNPOST>move</SIGNPOST>
<GRAM>T</GRAM>
<DEF>to move or go with someone or something from one place to another</DEF>
<OPP>bring</OPP>
<Thesref>
<Crossrefto refid="u2fc098491a42200a.262cc60a.117ee7c0f66.-73b9">
<REFHWD>bring</REFHWD>
</Crossrefto>
</Thesref>
<Thesref>
<Crossrefto refid="u2fc098491a42200a.262cc60a.117ee7c0f66.-4468">
<REFHWD>lead</REFHWD>
<REFHOMNUM>1</REFHOMNUM>
</Crossrefto>
</Thesref>
<ExpandableInformation>
<GramExa>
<PROPFORM>take sb/sth to/into etc sth</PROPFORM>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.265b">Barney took us to the airport.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.265c">Would you mind <COLLOINEXA>taking</COLLOINEXA> Susie <COLLOINEXA>home</COLLOINEXA>?</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.265f">When he refused to give his name, he was taken into custody.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2660">My job has taken me all over the world.</EXAMPLE>
</GramExa>
<GramExa>
<PROPFORM>take sb/sth with you</PROPFORM>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2663">His wife went to Australia, taking the children with her.</EXAMPLE>
</GramExa>
<GramExa>
<PROPFORM>take sb sth</PROPFORM>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2666">I have to take Steve the money tonight.</EXAMPLE>
</GramExa>
<GramExa>
<PROPFORM>take sb to do sth</PROPFORM>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2669">He took me to meet his parents.</EXAMPLE>
</GramExa>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.2641">
<SIGNPOST>action</SIGNPOST>
<GRAM>T</GRAM>
<DEF>used with a noun instead of using a verb to describe an action. For example, if you take a walk, you walk somewhere</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2646">Would you like to take a look?</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2647">Mike’s just taking a shower.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2648">Sara took a deep breath.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2649">I waved, but he <COLLOINEXA>didn’t take any notice</COLLOINEXA><GLOSS>pretended not to notice</GLOSS>.<GEO>BrE</GEO></EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.264d">Please <COLLOINEXA>take a seat</COLLOINEXA><GLOSS>sit down</GLOSS>.</EXAMPLE>
<ColloExa>
<COLLO>take a picture/photograph/photo</COLLO>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2652">Would you mind taking a photo of us together?</EXAMPLE>
</ColloExa>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.266a">
<SIGNPOST>remove</SIGNPOST>
<GRAM>T</GRAM>
<DEF>to remove something from a place</DEF>
<Thesref>
<Crossrefto refid="u2fc098491a42200a.262cc60a.117ee7c0f66.-1683">
<REFHWD>steal</REFHWD>
<REFHOMNUM>1</REFHOMNUM>
</Crossrefto>
</Thesref>
<ExpandableInformation>
<GramExa>
<PROPFORM>take sth off/from etc sth</PROPFORM>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2670">Take your feet off the seats.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2671">Someone’s taken a pen from my desk.</EXAMPLE>
</GramExa>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2672">Police say money and jewellery were taken in the raid.</EXAMPLE>
<Crossref>
<Crossrefto refid="u2fc098491a42200a.6e2b450a.1150446158e.27e5">
<REFHWD>take </REFHWD>
</Crossrefto>
</Crossref>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.2676">
<SIGNPOST>time/money/effort etc</SIGNPOST>
<GRAM>T</GRAM>
<DEF>if something takes a particular amount of time, money, effort etc, that amount of time etc is needed for it to happen or succeed</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.267a">How <COLLOINEXA>long</COLLOINEXA> is this going to <COLLOINEXA>take</COLLOINEXA>?</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.267d">Organizing a successful street party takes a lot of energy.</EXAMPLE>
<GramExa>
<PROPFORM>take (sb) sth (to do sth)</PROPFORM>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2680">Repairs take time to carry out.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2681">
<COLLOINEXA>It took</COLLOINEXA> a few minutes for his eyes to adjust to the dark.</EXAMPLE>
</GramExa>
<ColloExa>
<COLLO>take (sb) ages/forever</COLLO>
<REGISTERLAB>informal</REGISTERLAB>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2686">It took me ages to find a present for Dad.</EXAMPLE>
</ColloExa>
<ColloExa>
<COLLO>take some doing</COLLO>
<GEO>BrE</GEO>
<REGISTERLAB>informal</REGISTERLAB>
<GLOSS>need a lot of time or effort</GLOSS>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.268c">Catching up four goals will take some doing.</EXAMPLE>
</ColloExa>
<ColloExa>
<COLLO>take courage/guts</COLLO>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.268f">
<COLLOINEXA>It takes</COLLOINEXA> courage to admit you are wrong.</EXAMPLE>
</ColloExa>
<ColloExa>
<COLLO>have what it takes</COLLO>
<REGISTERLAB>informal</REGISTERLAB>
<GLOSS>to have the qualities that are needed for success</GLOSS>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2695">Neil’s got what it takes to be a great footballer.</EXAMPLE>
</ColloExa>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.2696">
<SIGNPOST>accept</SIGNPOST>
<GRAM>T</GRAM>
<DEF>to accept or choose something that is offered, suggested, or given to you</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.269a">Will you take the job?</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.269b">Do you take American Express?</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.269c">If you <COLLOINEXA>take</COLLOINEXA> my <COLLOINEXA>advice</COLLOINEXA>, you’ll see a doctor.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.269f">Our helpline <COLLOINEXA>takes</COLLOINEXA> 3.5 million <COLLOINEXA>calls</COLLOINEXA><GLOSS>telephone calls</GLOSS> a year.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26a3">Some doctors are unwilling to take new patients without a referral.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26a4">Liz found his criticisms <COLLOINEXA>hard to take</COLLOINEXA>.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26a6">I just <COLLOINEXA>can’t take any more</COLLOINEXA><GLOSS>can’t deal with a bad situation any longer</GLOSS>.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26a9">Staff have agreed to take a 2% pay cut.</EXAMPLE>
<ColloExa>
<COLLO>take a hammering/beating</COLLO>
<GLOSS>be forced to accept defeat or a bad situation</GLOSS>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26ad">Small businesses took a hammering in the last recession.</EXAMPLE>
</ColloExa>
<ColloExa>
<COLLO>I take your point/point taken</COLLO>
<GLOSS>used to say that you accept someone’s opinion</GLOSS>
</ColloExa>
<ColloExa>
<COLLO>take sb’s word for it/take it from sb</COLLO>
<GLOSS>accept that what someone says is true</GLOSS>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26b4">That’s the truth – <COLLOINEXA>take it from me</COLLOINEXA>.</EXAMPLE>
</ColloExa>
<ColloExa>
<COLLO>take the credit/blame/responsibility</COLLO>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26b8">He’s the kind of man who makes things happen but lets others take the credit.</EXAMPLE>
</ColloExa>
<ColloExa>
<COLLO>take it as read/given</COLLO>
<GLOSS>
<NonDV>
<REFHWD>assume</REFHWD>
</NonDV> that something is correct or certain, because you are sure that this is the case</GLOSS>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26be">It isn’t official yet, but you can take it as read that you’ve got the contract.</EXAMPLE>
</ColloExa>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.26bf">
<SIGNPOST>hold sth</SIGNPOST>
<GRAM>T</GRAM>
<DEF>to get hold of something in your hands</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26c4">Let me take your coat.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26c5">Can you take this package while I get my wallet?</EXAMPLE>
<GramExa>
<PROPFORM>take sb/sth in/by sth</PROPFORM>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26c8">I just wanted to take him in my arms.</EXAMPLE>
</GramExa>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.26c9">
<SIGNPOST>travel</SIGNPOST>
<GRAM>T</GRAM>
<DEF>to use a particular form of transport or a particular road in order to go somewhere</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26ce">Let’s take a cab.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26cf">I took the first plane out.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26d0">Take the M6 to Junction 19.</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.26d1">
<SIGNPOST>study</SIGNPOST>
<GRAM>T</GRAM>
<DEF>to study a particular subject in school or college for an examination</DEF>
<Thesref>
<Crossrefto refid="u2fc098491a42200a.-5592f786.1197a3eee79.-2fa7">
<REFHWD>study</REFHWD>
<REFHOMNUM>2</REFHOMNUM>
</Crossrefto>
</Thesref>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26d5">Are you taking French next year?</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.26d6">
<SIGNPOST>test</SIGNPOST>
<GRAM>T</GRAM>
<DEF>to do an examination or test</DEF>
<BREQUIV>sit</BREQUIV>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26db">Applicants are asked to take a written test.</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.26dc">
<SIGNPOST>suitable</SIGNPOST>
<GRAM>T</GRAM>
<DEF>to be the correct or suitable size, type etc for a particular person or thing</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26e1">a car that takes low sulphur fuel</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26e2">What size shoe do you take?</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26e3">The elevator takes a maximum of 32 people.</EXAMPLE>
<GramBox type="unspecified">
<HEADING>Using the progressive</HEADING>
<EXPL>In this meaning, <EXPR>take</EXPR> is not used in the progressive. You say: <EXAMPLE id="u2fc098491a42200a.1bed7895.141dd7cc035.-6085">I take size 12.</EXAMPLE> <CROSS type="frownie" />Don’t say: <BADEXA>I’m taking size 12.</BADEXA></EXPL>
<Gramref>VERBS</Gramref>
</GramBox>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.26e4">
<SIGNPOST>collect</SIGNPOST>
<GRAM>T</GRAM>
<DEF>to collect or gather something for a particular purpose</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26e8">Investigators will <COLLOINEXA>take samples</COLLOINEXA> of the wreckage to identify the cause.</EXAMPLE>
<GramExa>
<PROPFORM>take sth from sth</PROPFORM>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26ec">The police <COLLOINEXA>took</COLLOINEXA> a <COLLOINEXA>statement</COLLOINEXA> from both witnesses.</EXAMPLE>
</GramExa>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.26ef">
<SIGNPOST>consider</SIGNPOST>
<GRAM>I,T always + adv/prep</GRAM>
<DEF>to react to someone or something or consider them in a particular way</DEF>
<ExpandableInformation>
<ColloExa>
<COLLO>take sb/sth seriously/badly/personally etc</COLLO>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26f5">I was joking, but he took me seriously.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26f6">Ben took the news very badly.</EXAMPLE>
</ColloExa>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26f7">She does <COLLOINEXA>not take kindly to</COLLOINEXA> criticism <GLOSS>reacts badly to criticism</GLOSS>.</EXAMPLE>
<GramExa>
<PROPFORM>take sth as sth</PROPFORM>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26fc">I’ll take that remark as a compliment.</EXAMPLE>
</GramExa>
<ColloExa>
<COLLO>take sth as evidence/proof (of sth)</COLLO>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.26ff">The presence of dust clouds has been taken as evidence of recent star formation.</EXAMPLE>
</ColloExa>
<GramExa>
<PROPFORM>take sb/sth to be sth</PROPFORM>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2702">I took her to be his daughter.</EXAMPLE>
</GramExa>
<GramExa>
<PROPFORM>take sb/sth for sth</PROPFORM>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2705">Of course I won’t tell anyone! <COLLOINEXA>What do you take me for</COLLOINEXA>?<GLOSS>what sort of person do you think I am?</GLOSS></EXAMPLE>
</GramExa>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2708">
<COLLOINEXA>I take it</COLLOINEXA>
<GLOSS>I <NonDV><REFHWD>assume</REFHWD></NonDV></GLOSS> you’ve heard that Rick’s resigned.</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.270d">
<SIGNPOST>feelings</SIGNPOST>
<GRAM>T usually + adv</GRAM>
<DEF>to have or experience a particular feeling</DEF>
<ExpandableInformation>
<ColloExa>
<COLLO>take delight/pleasure/pride etc in (doing) sth</COLLO>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2714">You should take pride in your work.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2715">At first, he <COLLOINEXA>took</COLLOINEXA> no <COLLOINEXA>interest in</COLLOINEXA> the baby.</EXAMPLE>
</ColloExa>
<ColloExa>
<COLLO>take pity on sb</COLLO>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.271a">She stood feeling lost until an elderly man took pity on her.</EXAMPLE>
</ColloExa>
<ColloExa>
<COLLO>take offence</COLLO>
<GLOSS>feel offended</GLOSS>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.271e">Don’t take offence. Roger says things like that to everybody.</EXAMPLE>
</ColloExa>
<ColloExa>
<COLLO>take comfort from/in (doing) sth</COLLO>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2721">Investors can <COLLOINEXA>take comfort from the fact that</COLLOINEXA> the World Bank is underwriting the shares.</EXAMPLE>
</ColloExa>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.2723">
<SIGNPOST>control</SIGNPOST>
<GRAM>T</GRAM>
<DEF>to get possession or control of something</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2728">Enemy forces have taken the airport.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2729">Both boys were <COLLOINEXA>taken prisoner</COLLOINEXA>.</EXAMPLE>
<ColloExa>
<COLLO>take control/charge/power</COLLO>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.272d">The communists took power in 1948.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.272e">Youngsters need to take control of their own lives.</EXAMPLE>
</ColloExa>
<ColloExa>
<COLLO>take the lead</COLLO>
<GLOSS>in a race, competition etc</GLOSS>
</ColloExa>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.2732">
<SIGNPOST>medicine/drugs</SIGNPOST>
<GRAM>T</GRAM>
<DEF>to swallow, breathe in, <NonDV><REFHWD>inject</REFHWD></NonDV> etc a drug or medicine</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.273a">The doctor will ask whether you are taking any medication.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.273b">Take two tablets before bedtime.</EXAMPLE>
<ColloExa>
<COLLO>take drugs</COLLO>
<GLOSS>take illegal drugs</GLOSS>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.273f">Most teenagers start taking drugs through boredom.</EXAMPLE>
</ColloExa>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2740">She <COLLOINEXA>took</COLLOINEXA> an <COLLOINEXA>overdose</COLLOINEXA> after a row with her boyfriend.</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.2743">
<LEXUNIT>do you take sugar/milk?</LEXUNIT>
<GEO>BrE</GEO>
<REGISTERLAB>spoken</REGISTERLAB>
<DEF>used to ask someone whether they like to have sugar or milk in a drink such as tea or coffee</DEF>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.2749">
<SIGNPOST>level</SIGNPOST>
<GRAM>T always + adv/prep</GRAM>
<DEF>to make someone or something go to a higher level or position</DEF>
<ExpandableInformation>
<GramExa>
<PROPFORM>take sth to/into sth</PROPFORM>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.274f">The latest raise takes his salary into six figures.</EXAMPLE>
</GramExa>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2750">Even if you have the talent to <COLLOINEXA>take</COLLOINEXA> you <COLLOINEXA>to the top</COLLOINEXA>, there’s no guarantee you’ll get there.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2753">If you want to <COLLOINEXA>take</COLLOINEXA> it <COLLOINEXA>further</COLLOINEXA>, you should consult an attorney.</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.2756">
<SIGNPOST>measure</SIGNPOST>
<GRAM>T</GRAM>
<DEF>to measure the amount, level, rate etc of something</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.275b">Take the patient’s pulse first.</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.275c">
<SIGNPOST>numbers</SIGNPOST>
<GRAM>T</GRAM>
<DEF>to make a number smaller by a particular amount</DEF>
<SYN>subtract</SYN>
<ExpandableInformation>
<GramExa>
<PROPFORM>take sth away/take sth (away) from sth</PROPFORM>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2764">‘Take four from nine and what do you get?’ ‘Five.’</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2765">Ten take away nine equals one.</EXAMPLE>
</GramExa>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.2766">
<SIGNPOST>money</SIGNPOST>
<GRAM>T</GRAM>
<GEO>BrE</GEO>
<DEF>if a shop, business etc takes a particular amount of money, it receives that amount of money from its customers</DEF>
<AMEQUIV>take in</AMEQUIV>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.276c">The stall took £25 on Saturday.</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.276d">
<LEXUNIT>sb can take it or leave it</LEXUNIT>
<Subsense>
<DEF>to neither like nor dislike something</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2771">To some people, smoking is addictive. Others can take it or leave it.</EXAMPLE>
</ExpandableInformation>
</Subsense>
<Subsense>
<DEF>used to say that you do not care whether someone accepts your offer or not</DEF>
</Subsense>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.2774">
<LEXUNIT>take sb/sth (for example)</LEXUNIT>
<DEF>used to give an example of something you have just been talking about</DEF>
<Thesref>
<Crossrefto refid="u2fc098491a42200a.262cc60a.117ee7c0f66.-59b3">
<REFHWD>example</REFHWD>
</Crossrefto>
</Thesref>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2778">People love British cars. Take the Mini. In Japan, it still sells more than all the other British cars put together.</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.2779">
<SIGNPOST>teach</SIGNPOST>
<GRAM>T</GRAM>
<GEO>BrE</GEO>
<DEF>to teach a particular group of students in a school or college</DEF>
<ExpandableInformation>
<GramExa>
<PROPFORM>take sb for sth</PROPFORM>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2781">Who takes you for English?</EXAMPLE>
</GramExa>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.2782">
<SIGNPOST>write</SIGNPOST>
<GRAM>T</GRAM>
<DEF>to write down information</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2787">Let me take your email address.</EXAMPLE>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2788">Sue offered to <COLLOINEXA>take notes</COLLOINEXA>.</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.278a">
<LEXUNIT>take sb out of themselves</LEXUNIT>
<GEO>BrE</GEO>
<DEF>to make someone forget their problems and feel more confident</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.278e">Alf said joining the club would take me out of myself.</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.278f">
<LEXUNIT>take a lot out of you/take it out of you</LEXUNIT>
<DEF>to make you very tired</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2792">Looking after a baby really takes it out of you.</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.2793">
<LEXUNIT>take it upon/on yourself to do sth</LEXUNIT>
<REGISTERLAB>formal</REGISTERLAB>
<DEF>to decide to do something without getting someone’s permission or approval first</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.2797">Reg took it upon himself to hand the press a list of names.</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.2798">
<LEXUNIT>take sth to bits/pieces</LEXUNIT>
<GEO>BrE</GEO>
<DEF>to separate something into its different parts</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.279c">how to take an engine to bits</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.279d">
<LEXUNIT>be taken with/by sth</LEXUNIT>
<DEF>to be attracted by a particular idea, plan, or person</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.27a1">I’m quite taken by the idea of Christmas in Berlin.</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.27a2">
<LEXUNIT>be taken ill/sick</LEXUNIT>
<REGISTERLAB>formal</REGISTERLAB>
<DEF>to suddenly become ill</DEF>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.27a7">
<SIGNPOST>sex</SIGNPOST>
<GRAM>T</GRAM>
<REGISTERLAB>literary</REGISTERLAB>
<DEF>if a man takes someone, he has sex with them</DEF>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.27ad">
<LEXUNIT>take a bend/fence/corner etc</LEXUNIT>
<DEF>to try to get over or around something in a particular way</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.27b1">He took the bend at over 60 and lost control.</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.27b2">
<SIGNPOST>have an effect</SIGNPOST>
<GRAM>I</GRAM>
<DEF>if a treatment, <NonDV><REFHWD>dye</REFHWD></NonDV>, drug etc takes, it begins to work successfully</DEF>
</Sense>
<Tail />
<PhrVbEntry id="u2fc098491a42200a.6e2b450a.1150446158e.27b9">
<Head>
<PHRVBHWD>be taken aback</PHRVBHWD>
<POS>phr v</POS>
</Head>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.27bd">
<DEF>to be very surprised about something</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.27c0">Emma was somewhat taken aback by his directness.</EXAMPLE>
</ExpandableInformation>
</Sense>
</PhrVbEntry>
<PhrVbEntry id="u2fc098491a42200a.6e2b450a.1150446158e.27c1">
<Head>
<PHRVBHWD>take after<OBJECT>sb</OBJECT></PHRVBHWD>
<POS>phr v</POS>
</Head>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.27c7">
<DEF>to look or behave like an older relative</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.27ca">Jenni really takes after her mother.</EXAMPLE>
<GramBox type="unspecified">
<HEADING>Using the progressive</HEADING>
<EXPL>
<EXPR>Take after</EXPR> is not used in the progressive. You say: <EXAMPLE id="u2fc098491a42200a.1bed7895.141dd7cc035.-6024">He takes after you.</EXAMPLE> <CROSS type="frownie" />Don’t say: <BADEXA>He is taking after you.</BADEXA></EXPL>
<Gramref>VERBS</Gramref>
</GramBox>
</ExpandableInformation>
</Sense>
</PhrVbEntry>
<PhrVbEntry id="u2fc098491a42200a.6e2b450a.1150446158e.27cb">
<Head>
<PHRVBHWD>take<OBJECT>sb/sth</OBJECT> apart</PHRVBHWD>
<POS>phr v</POS>
</Head>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.27d0">
<DEF>to separate something into all its different parts</DEF>
<OPP>put together</OPP>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.27d3">Tom was always taking things apart in the garage.</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.27d4">
<DEF>to search a place very thoroughly</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.27d6">The police took the house apart looking for clues.</EXAMPLE>
</ExpandableInformation>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.27d7">
<DEF>to beat someone very easily in a game, sport, fight etc</DEF>
</Sense>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.27d9">
<DEF>to show that someone is wrong or something is not true</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.27db">Tariq takes several gay myths apart in his book.</EXAMPLE>
</ExpandableInformation>
</Sense>
</PhrVbEntry>
<PhrVbEntry id="u2fc098491a42200a.6e2b450a.1150446158e.27dc">
<Head>
<PHRVBHWD>take against<OBJECT>sb/sth</OBJECT></PHRVBHWD>
<POS>phr v</POS>
<GEO>BrE</GEO>
</Head>
<Sense id="u2fc098491a42200a.6e2b450a.1150446158e.27e2">
<DEF>to begin to dislike someone or something, especially without a good reason</DEF>
<ExpandableInformation>
<EXAMPLE id="u2fc098491a42200a.6e2b450a.1150446158e.27e4">Voters took against the relationship between the government and the unions in the 1970s.</EXAMPLE>
</ExpandableInformation>
</Sense>
</PhrVbEntry>
</Entry>
向下兼容epub是个巨大的优点
但这恐怕也是最大的限制,只支持deflate压缩,如果按一些词一章分的话阅读器必须得支持懒加载,按少量或者单个词分的话epub的索引会很大,zip对文件的索引没有顺序,涉及到大量小文件不知能否优化好……
兼容 epub 意义何在呢?难道要把词典当成电子书一样浏览阅读吗?
xml 在 ai 时代不行了,xslt 也没几个人会了。