- Forced Optimization - YouTube
-
- Deno 2.0 今年夏天发布。
- Deno 对 Node.js 有天然的支持
- Deno KV
- What is a Vector Database? | Pinecone
Vector embeddings 是一种帮助 AI 记忆事物的工具。在执行一些复杂任务时很方便。
Embbedding 由 AI 模型生成,有着巨量的特征信息,这些特征信息代表了数据的不同维度,对于理解模式、关系和底层结构至关重要。所以,需要设计一种专门存储这些信息的数据库。矢量数据库通过为嵌入提供优化后的存储和查询功能,以此满足这一需求。矢量数据库具有传统数据库所没有的独立矢量索引的能力,以及传统标量数据库所没有的专门处理矢量嵌入的能力。
- IndexedDB as a Vector Database
<script type="module"> import { VectorDB } from "./node_modules/idb-vector/index.js"; const db = new VectorDB({ vectorPath: "embedding" }); await db.insert({ embedding: [1, 2, 3], "text": "ASDASINDASDASZd" }); await db.insert({ embedding: [2, 3, 4], "text": "GTFSDGRG" }); await db.insert({ embedding: [73, -213, 3], "text": "hYTRTERFR" }); // Query returns a list ordered by the entries closest to the vector (cosine similarity) console.log(await db.query([1, 2, 3], { limit: 20 })); </script>
- TypeScript is 'not worth it' for developing libraries, says Svelte author, as team switches to JavaScript and JSDoc • DEVCLASS
- 作为 Svelte 的用户,依然可以在 Svelte 中使用 TypeScript,但是对于该框架的开发将变成 JavaScript + JSDoc。
- 关于 TweetID:1658453862561501184 中典型诡辩论部分的拆解 | Kivinsae's Nest
逻辑分析很精彩,知道了:
诡辩、滑坡论证、从众式论证、强加因果
等概念。
- An introduction to Pinia – Vue’s favourite state management library - YouTube
Live视频笔记:
- Pinia的状态管理
-
什么时候知道应该在项目中使用 Pinia?
- 有些嵌套组件之间需要共享状态的
- 如果知道应用能够增长的
- How I manage GitHub Notifications - Anthony Fu - YouTube
- @antfu 分享了自己是如何管理大量 GitHub 通知的
- 陈佩斯 时间不会欺骗我|新刊
https://chinadigitaltimes.net/chinese/696236.html
话剧《惊梦》——故事说的是解放战争背景下,一个昆曲戏班的生死命运,以及历史的偶然和必然,幽默又悲凉,大气也婉转。
他也糊涂过。筹备《惊梦》的剧本时,他以为故事里最大的事儿是新旧文化更替,是昆曲班子学唱新戏的波折。真到排练演出来,他感到这新旧文化冲突却是最弱的驱动力。
“最重的是命,是活命。”他说,“唱新戏并不是最重的,因为并不能因此生发出一连串的情节。是他们因为要活命,去寻找生路,才找到了新戏,是为了保住性命才答应唱山歌北曲,童孝璋(老班主)也不知道新戏是什么,接到手发现,完了,寸步难行,可不得了。”
“在极端困苦的环境下,一个人活不成,人人都互相帮助,必须一群人共同去完成目标,一点点活下来。”陈佩斯说,“所以那种人性的光辉,我也沐浴过。而且在那里头,把我们打造成特别的好人,离开那儿以后,你见不到那么多好的人。”
“你会对人失去信心吗?”我们问他。
“不会,因为我看过好的。”他斩钉截铁回答,“这么多年苦难的生活历练之后,当我们都成了一群很好的人,我发现那种善良的东西,是最有力量的。”
“不是每个人都有机会做个好人,有时候机会都不会给到他们。这是身不由己,所以你看了才会悲从中来。”陈佩斯又强调道,“但这不是我作品的第一目的。我不是为了教化或者笑中带泪,只是因为人物深陷困境,这种身不由己的状态,会给人新的感受。”
- China calls in loans to Pakistan, Kenya, dozens more | Fortune
A dozen poor countries are facing economic instability and even collapse under the weight of hundreds of billions of dollars in foreign loans, much of them from the world’s biggest and most unforgiving government lender, China.
Behind the scenes is China’s reluctance to forgive debt and its extreme secrecy about how much money it has loaned and on what terms, which has kept other major lenders from stepping in to help. On top of that is the recent discovery that borrowers have been required to put cash in hidden escrow accounts that push China to the front of the line of creditors to be paid.
A case study of how it has played out is in Zambia, a landlocked country of 20 million people in southern Africa that over the past two decades has borrowed billions of dollars from Chinese state-owned banks to build dams, railways and roads.
The loans boosted Zambia’s economy but also raised foreign interest payments so high there was little left for the government, forcing it to cut spending on healthcare, social services and subsidies to farmers for seed and fertilizer.
“I just sit in the house thinking what I will eat because I have no money to buy food,” said Marvis Kunda, a blind 70-year-old widow in Zambia’s Luapula province whose welfare payments were recently slashed. “Sometimes I eat once a day and if no one remembers to help me with food from the neighborhood, then I just starve.”
Poor countries have been hit with foreign currency shortages, high inflation, spikes in unemployment and widespread hunger before, but rarely like in the past year.
Along with the usual mix of government mismanagement and corruption are two unexpected and devastating events: the war in Ukraine, which has sent prices of grain and oil soaring, and the U.S. Federal Reserve’s decision to raise interest rates 10 times in a row, the latest this month. That has made variable rate loans to countries suddenly much more expensive.
The Chinese Ministry of Foreign Affairs, in a statement to the AP, disputed the notion that China is an unforgiving lender and echoed previous statements putting the blame on the Federal Reserve. It said that if it is to accede to IMF and World Bank demands to forgive a portion of its loans, so should those multilateral lenders, which it views as U.S. proxies.
China argues it has offered relief in the form of extended loan maturities and emergency loans, and as the biggest contributor to a program to temporarily suspend interest payments during the coronavirus pandemic. It also says it has forgiven 23 no-interest loans to African countries, though AidData’s Parks said such loans are mostly from two decades ago and amount to less than 5% of the total it has lent.
As Parks dug into the details of the loans, he found something alarming: Clauses mandating that borrowing countries deposit U.S. dollars or other foreign currency in secret escrow accounts that Beijing could raid if those countries stopped paying interest on their loans.
In effect, China had jumped to the front of the line to get paid without other lenders knowing.
“You’ve got a growing number of countries that are in dire financial straits,” said Parks, attributing it largely to China’s stunning rise in just a generation from being a net recipient of foreign aid to the world’s largest creditor.
- Deep Sleep May Be the Best Defense Against Alzheimer’s - WSJ
深度睡眠可能是预防阿尔茨海默症的最佳方法
睡眠问题和阿尔茨海默症密切相关,但就像鸡和蛋问题,是睡眠问题先出现还是阿尔茨海默症先出现,目前尚不清楚。深度睡眠有助于清除阿尔茨海默症的两种标志性蛋白质淀粉样蛋白和 tau 蛋白。发表在《Annals of Neurology》期刊上的一项研究发现,名叫 suvorexant 的安眠药能减少没有认知问题的中年人的淀粉样蛋白和 tau 蛋白。持续两晚的实验发现,淀粉样蛋白减少了 10%-20%,tau 蛋白减少了 10%-15%。UC 伯克利的研究人员发现,深度睡眠显著改善了高风险阿尔茨海默症患者的记忆测试成绩。安眠药和深度睡眠一样,都有助于保护高风险患者。
- 国际单位制新词头中文名称发布
2022年11月,第27届国际计量大会通过决议,引入4个SI新词头ronna、ronto、quetta、quecto,分别表示10^27、10^-27、10^30、10^-30。这是自1991年以来,国际单位制首次新增词头。
最终确定新词头的中文名称为:容[那]、柔[托]、昆[它]、亏[科托],分别表示10^27、10^-27、10^30、10^-30。