各種特殊符號的英文

Hacker News 首頁上看到「Pronunciation guide for UNIX」這個列表,裡面有各種特殊符號的英文。

裡面列的真的比較簡易,舉例來說,像是他對 - 的說明是:

但如果你查 Hyphen (連字號) 與 Dash (連接號) 的定義,都會指出者兩個東西是不一樣的東西:

The hyphen is sometimes confused with dashes (figure dash ‒, en dash –, em dash —, horizontal bar ―), which are longer and have different uses, or with the minus sign −, which is also longer and more vertically centred in some typefaces.

The dash is a punctuation mark consisting of a long horizontal line. It is similar in appearance to the hyphen but is longer and sometimes higher from the baseline.

裡面的說明用在口語上表達應該還行,但如果是真的在寫比較正式的資料的時候還是要去其他地方確認...

PostgreSQL 的 Fuzzy Matching

在「Fuzzy Name Matching in Postgres」這邊看到 PostgreSQL 下怎麼設計 Fuzzy Matching 的方式,文章裡用的方法主要是出自 PostgreSQL 的文件:「F.15. fuzzystrmatch」。

文章最後的解法是 Soundex + Levenshtein

翻了一下資料,這個領域另外有 NYSIIS (New York State Identification and Intelligence System):

The New York State Identification and Intelligence System Phonetic Code, commonly known as NYSIIS, is a phonetic algorithm devised in 1970 as part of the New York State Identification and Intelligence System (now a part of the New York State Division of Criminal Justice Services). It features an accuracy increase of 2.7% over the traditional Soundex algorithm.

以及 Metaphone

Metaphone is a phonetic algorithm, published by Lawrence Philips in 1990, for indexing words by their English pronunciation. It fundamentally improves on the Soundex algorithm by using information about variations and inconsistencies in English spelling and pronunciation to produce a more accurate encoding, which does a better job of matching words and names which sound similar. As with Soundex, similar-sounding words should share the same keys. Metaphone is available as a built-in operator in a number of systems.

不過這些都是以英文為主,中文的沒特別翻到...

美國政府對於書面文字的要求

好像是在 Twitter 上看到的,但一時間找不到是誰推的...

美國在 2010 年簽署的「Plain Writing Act of 2010」要求各種政府文件都必須用簡單的文字書寫,甚至還弄一個官方網站「Home | plainlanguage.gov」列出說明...

在網站裡面的「Use simple words and phrases」給了一個蠻長對應表,可以將一些艱澀的法律慣用詞彙換成平常常用的詞彙...

維基百科給的 Before & After 範例還蠻不錯的,在比較極端的情況下,讀起來的確輕鬆很多:

(Before) The amount of expenses reimbursed to a claimant under this subpart shall be reduced by any amount that the claimant receives from a collateral source. In cases in which a claimant receives reimbursement under this subpart for expenses that also will or may be reimbursed from another source, the claimant shall subrogate the United States to the claim for payment from the collateral source up to the amount for which the claimant was reimbursed under this subpart.

(After) If you get a payment from a collateral source, we will reduce our payment by the amount you get. If you get payments from us and from a collateral source for the same expenses, you must pay us back the amount we paid you.

用 YouTube 上的影片查發音

Improve your English pronunciation using Youtube」這個服務利用 YouTube 上的影片與字幕提供界面,讓你可以知道現實世界的人怎麼發音的查詢系統。

系統本身不難做,主要是去撈大量資料,然後建立 search engine 提供,idea 與執行才是這個服務的賣點。

拿到後第一個想到的就是,一定要拿來查一下「IKEA」怎麼唸 XDDD

除了英文以外還可以查其他語言,包括中文...

Mozilla 實做百度發表的 Speech-To-Text 引擎 Deep Speech

Hacker News 上看到 MozillaGitHub 上的 mozilla/DeepSpeech 這個專案,用 TensorFlow 實做了百度的「Deep Speech: Scaling up end-to-end speech recognition」論文:

A TensorFlow implementation of Baidu's DeepSpeech architecture

語音轉文字的方案,Mozilla 開專案實做出來了...

這程式碼需要安裝 Git Large File Storage 才能完整下載包含訓練資料的部份:

Manually install Git Large File Storage, then clone the repository normally:
git clone https://github.com/mozilla/DeepSpeech

而目前已經有的資料來自於 Mozilla 另外一個專案「Common Voice」:

The Common Voice project is Mozilla's initiative to help teach machines how real people speak.

Common Voice 這個專案目前只有英文,網頁上就可以參與 validation 過程...

AWS 的翻譯服務:Amazon Translate

Google 的應該是做的最早的,MicrosoftMicrosoft Translator Text API 也出來一陣子了,而 AWS 在這次 re:Invent 推出了自家的翻譯服務 Amazon Translate:「Introducing Amazon Translate – Real-time Language Translation」。

目前還在 Preview,需要申請才能用,不過價目表「Amazon Translate Pricing」已經先出來了 (畢竟已經有競爭對手,可以參考他們的價錢):

Sign up for the Amazon Translate preview today and try the translation service. Learn more about the service by checking out the preview product page or reviewing the technical guides provided in the AWS documentation.

然後目前支援的語言有這些,都是對英文轉換:

At Preview, Amazon Translate supports translation between English and any of the following languages: Arabic, Chinese (Simplified), French, German, Portuguese, and Spanish. Support for more languages is coming soon.

英文母語的人學習外語所需的時間

這個報導蠻有趣的:「A Map Showing How Much Time It Takes to Learn Foreign Languages: From Easiest to Hardest」。

文章裡分成這幾種:(扣除已經是母語的英語,Category 0)

  • Category I: 23-24 weeks (575-600 hours) Languages closely related to English
  • Category II: 30 weeks (750 hours) Languages similar to English
  • Category III: 36 weeks (900 hours) Languages with linguistic and/or cultural differences from English
  • Category IV: 44 weeks (1100 hours) Languages with significant linguistic and/or cultural differences from English
  • Category V: 88 weeks (2200 hours) Languages which are exceptionally difficult for native English speakers

其中時間最長的這部份引用一下:

Arabic
Cantonese (Chinese)
Mandarin (Chinese)
*Japanese
Korean
* Usually more difficult than other languages in the same category.

字母在單字裡的位置分佈

是一篇老文章了... (2014 年的文章,最近從其他地方提起)

這邊講的是英文,不過同樣方式也可以拿來分析其他語言:「The distribution of letters in English words」,原始文章在「Graphing the distribution of English letters towards the beginning, middle or end of words」。

原文有描述他的資料分析來源:

The data is from the entire Brown corpus in the Natural Language Toolkit. It's a smaller and out-of-date corpus, but it's open source and easy to obtain. I repeated the analysis with COHA, the Corpus of Historical American English, a well-curated, proprietary data set from Brigham Young University for which I have a license, and the only differences were in rare letters like "z" or "x".

用程式自動同步字幕與聲音

Hacker News 上看到的專案,readbeyond/aeneas

aeneas is a Python/C library and a set of tools to automagically synchronize audio and text (aka forced alignment).

馬上想到的是... 這根本就是字幕組的福音 XDDD

支援的語言:

Confirmed working on 38 languages: AFR, ARA, BUL, CAT, CYM, CES, DAN, DEU, ELL, ENG, EPO, EST, FAS, FIN, FRA, GLE, GRC, HRV, HUN, ISL, ITA, JPN, LAT, LAV, LIT, NLD, NOR, RON, RUS, POL, POR, SLK, SPA, SRP, SWA, SWE, TUR, UKR

除了 ENG 以外,有 JPN... XD

Mac 上的 Cleartext

看到 Mac 上的「Cleartext」這個軟體:

A text editor that only allows the 1,000 most common words in English

限制你使用比較簡單的英文,這樣可以讓讀的人比較容易了解 (尤其是非母語的人)。

有種跟 Simple English Wikipedia 的想法很像的感覺:

The project uses around 2,000 common English words, and is based on Basic English, an 850-word auxiliary international language created by Charles Kay Ogden in the 1920s.

另外還有提供 Trump mode XDDD:

Trained with a few of Trump's best known speeches, the app is now ready to help you write like a billionaire.

這好壞 XDDD