<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Margin Notes</title><description>一个手绘笔记本风格的个人站点：学术、洞见、日常、资料库与项目。</description><link>https://slackkai.github.io/</link><language>zh</language><item><title>笔记本语法演示</title><link>https://slackkai.github.io/astro-margin-notes/projects/syntax-showcase/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/projects/syntax-showcase/</guid><description>这个站点在标准 Markdown 之外长出来的东西：页边批注、便利贴、相片、折页、红笔、视频与嵌入页面。每一段都是它自己的示例。</description><pubDate>Tue, 22 Sep 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;这一页把站点的自定义语法全部用一遍，源码就是说明书。它是一个“项目”，下面挂着一篇文档&lt;a href=&quot;https://slackkai.github.io/astro-margin-notes/projects/syntax-showcase/markdown/&quot;&gt;《原生 Markdown 的手绘重绘》&lt;/a&gt;，两者各有自己的 &lt;code&gt;attachments/&lt;/code&gt; 文件夹。完整写法见仓库里的 &lt;code&gt;docs/SYNTAX.md&lt;/code&gt;。&lt;/p&gt;
&lt;h2 id=&quot;页边&quot;&gt;页边&lt;/h2&gt;
&lt;p&gt;行内批注跟着句子走。&lt;label class=&quot;note-wrap&quot;&gt;&lt;input type=&quot;checkbox&quot; class=&quot;note-toggle&quot; aria-label=&quot;展开批注&quot;&gt;&lt;span class=&quot;note-ref&quot;&gt;&lt;/span&gt;&lt;span class=&quot;note&quot;&gt;这条批注在宽屏浮到右侧页边并编号，窄屏点击上标展开。&lt;/span&gt;&lt;/label&gt; 需要放多段内容时用块级批注：&lt;/p&gt;
&lt;aside class=&quot;note-block&quot;&gt;&lt;p class=&quot;note-block-title&quot;&gt;为什么放在页边&lt;/p&gt;&lt;p&gt;页边是读者眼睛停留的地方，不打断正文，又比脚注近。&lt;/p&gt;&lt;p&gt;可以放列表、公式 &lt;span class=&quot;katex&quot;&gt;&lt;span class=&quot;katex-mathml&quot;&gt;&lt;math xmlns=&quot;http://www.w3.org/1998/Math/MathML&quot;&gt;&lt;semantics&gt;&lt;mrow&gt;&lt;msqrt&gt;&lt;msub&gt;&lt;mi&gt;d&lt;/mi&gt;&lt;mi&gt;k&lt;/mi&gt;&lt;/msub&gt;&lt;/msqrt&gt;&lt;/mrow&gt;&lt;annotation encoding=&quot;application/x-tex&quot;&gt;\sqrt{d_k}&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/span&gt;&lt;span class=&quot;katex-html&quot; aria-hidden=&quot;true&quot;&gt;&lt;span class=&quot;base&quot;&gt;&lt;span class=&quot;strut&quot; style=&quot;height:1.04em;vertical-align:-0.1828em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord sqrt&quot;&gt;&lt;span class=&quot;vlist-t vlist-t2&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.8572em;&quot;&gt;&lt;span class=&quot;svg-align&quot; style=&quot;top:-3em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:3em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord&quot; style=&quot;padding-left:0.833em;&quot;&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord mathnormal&quot;&gt;d&lt;/span&gt;&lt;span class=&quot;msupsub&quot;&gt;&lt;span class=&quot;vlist-t vlist-t2&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.3361em;&quot;&gt;&lt;span style=&quot;top:-2.55em;margin-left:0em;margin-right:0.05em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:2.7em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;sizing reset-size6 size3 mtight&quot;&gt;&lt;span class=&quot;mord mathnormal mtight&quot; style=&quot;margin-right:0.0315em;&quot;&gt;k&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-s&quot;&gt;​&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.15em;&quot;&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;top:-2.8172em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:3em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;hide-tail&quot; style=&quot;min-width:0.853em;height:1.08em;&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; width=&quot;400em&quot; height=&quot;1.08em&quot; viewBox=&quot;0 0 400000 1080&quot; preserveAspectRatio=&quot;xMinYMin slice&quot;&gt;&lt;path d=&quot;M95,702
c-2.7,0,-7.17,-2.7,-13.5,-8c-5.8,-5.3,-9.5,-10,-9.5,-14
c0,-2,0.3,-3.3,1,-4c1.3,-2.7,23.83,-20.7,67.5,-54
c44.2,-33.3,65.8,-50.3,66.5,-51c1.3,-1.3,3,-2,5,-2c4.7,0,8.7,3.3,12,10
s173,378,173,378c0.7,0,35.3,-71,104,-213c68.7,-142,137.5,-285,206.5,-429
c69,-144,104.5,-217.7,106.5,-221
l0 -0
c5.3,-9.3,12,-14,20,-14
H400000v40H845.2724
s-225.272,467,-225.272,467s-235,486,-235,486c-2.7,4.7,-9,7,-19,7
c-6,0,-10,-1,-12,-3s-194,-422,-194,-422s-65,47,-65,47z
M834 80h400000v40h-400000z&quot;&gt;&lt;/path&gt;&lt;/svg&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-s&quot;&gt;​&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.1828em;&quot;&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt; 和图片。&lt;/p&gt;&lt;/aside&gt;
&lt;p&gt;脚注也进页边&lt;label class=&quot;note-wrap&quot;&gt;&lt;input type=&quot;checkbox&quot; class=&quot;note-toggle&quot; aria-label=&quot;展开批注&quot;&gt;&lt;span class=&quot;note-ref&quot;&gt;&lt;/span&gt;&lt;span class=&quot;note&quot;&gt;这是一个标准 Markdown 脚注，写在文末，渲染时搬到了页边。&lt;/span&gt;&lt;/label&gt;，编号和行内批注连续。&lt;/p&gt;
&lt;h2 id=&quot;落在文字上的笔&quot;&gt;落在文字上的笔&lt;/h2&gt;
&lt;p&gt;荧光笔有四种颜色：&lt;span class=&quot;mark&quot;&gt;默认色随配色变&lt;/span&gt;、&lt;span class=&quot;mark mark-green&quot;&gt;绿&lt;/span&gt;、&lt;span class=&quot;mark mark-pink&quot;&gt;粉&lt;/span&gt;、&lt;span class=&quot;mark mark-yellow&quot;&gt;黄&lt;/span&gt;。&lt;/p&gt;
&lt;p&gt;红笔批改：把 &lt;span class=&quot;pen pen-circle&quot;&gt;关键词&lt;/span&gt; 圈出来，给 &lt;span class=&quot;pen pen-wavy&quot;&gt;需要强调的句子&lt;/span&gt; 画波浪线，给 &lt;span class=&quot;pen pen-box&quot;&gt;术语&lt;/span&gt; 加框，把 &lt;span class=&quot;pen pen-strike&quot;&gt;写错的地方&lt;/span&gt; 划掉。自测题的答案可以先 &lt;label class=&quot;pen pen-hide&quot;&gt;&lt;input type=&quot;checkbox&quot; class=&quot;pen-toggle&quot; aria-label=&quot;显示被遮住的内容&quot;&gt;&lt;span class=&quot;pen-hidden&quot;&gt;涂掉，点一下才显示&lt;/span&gt;&lt;/label&gt;。&lt;/p&gt;
&lt;p&gt;盖章：&lt;span class=&quot;stamp stamp-red&quot;&gt;待验证&lt;/span&gt;、&lt;span class=&quot;stamp stamp-green&quot;&gt;已复现&lt;/span&gt;、&lt;span class=&quot;stamp stamp-blue&quot;&gt;存疑&lt;/span&gt;。&lt;/p&gt;
&lt;h2 id=&quot;贴在纸上的东西&quot;&gt;贴在纸上的东西&lt;/h2&gt;
&lt;aside class=&quot;sticky sticky-tip&quot; role=&quot;note&quot;&gt;&lt;span class=&quot;sticky-kind&quot;&gt;💡 提示&lt;/span&gt;&lt;p class=&quot;sticky-title&quot;&gt;什么时候用便利贴&lt;/p&gt;&lt;p&gt;一段需要跳出正文的提醒。类型有提示、注意、说明、疑问四种，也可以不写类型。&lt;/p&gt;&lt;/aside&gt;
&lt;aside class=&quot;sticky sticky-warn&quot; role=&quot;note&quot;&gt;&lt;span class=&quot;sticky-kind&quot;&gt;⚠️ 注意&lt;/span&gt;&lt;p&gt;不写标题也可以。注意类型用粉色便利贴，说明类型用蓝色。&lt;/p&gt;&lt;/aside&gt;
&lt;aside class=&quot;sticky sticky-question&quot; role=&quot;note&quot;&gt;&lt;span class=&quot;sticky-kind&quot;&gt;❓ 疑问&lt;/span&gt;&lt;p class=&quot;sticky-title&quot;&gt;还没想清楚的问题&lt;/p&gt;&lt;p&gt;疑问类型是虚线边框的白纸，留给自己以后回答。&lt;/p&gt;&lt;/aside&gt;
&lt;div class=&quot;photos&quot; style=&quot;--cols:3&quot;&gt;&lt;figure class=&quot;photo&quot;&gt;&lt;img src=&quot;https://slackkai.github.io/astro-margin-notes/projects/syntax-showcase/attachments/sketch-arm.svg&quot; alt=&quot;两连杆机械臂的草图&quot;&gt;&lt;figcaption&gt;两连杆机械臂的草图&lt;/figcaption&gt;&lt;/figure&gt;&lt;figure class=&quot;photo&quot;&gt;&lt;img src=&quot;https://slackkai.github.io/astro-margin-notes/projects/syntax-showcase/attachments/sketch-dog.svg&quot; alt=&quot;四足机器人&quot;&gt;&lt;figcaption&gt;四足机器人&lt;/figcaption&gt;&lt;/figure&gt;&lt;figure class=&quot;photo&quot;&gt;&lt;img src=&quot;https://slackkai.github.io/astro-margin-notes/projects/syntax-showcase/attachments/sketch-notebook.svg&quot; alt=&quot;一本摊开的笔记本&quot;&gt;&lt;figcaption&gt;一本摊开的笔记本&lt;/figcaption&gt;&lt;/figure&gt;&lt;/div&gt;
&lt;div class=&quot;photos photos-scatter&quot; style=&quot;--cols:2&quot;&gt;&lt;figure class=&quot;photo&quot;&gt;&lt;img src=&quot;https://slackkai.github.io/astro-margin-notes/projects/syntax-showcase/attachments/sketch-arm.svg&quot; alt=&quot;散落模式：倾斜角更大&quot;&gt;&lt;figcaption&gt;散落模式：倾斜角更大&lt;/figcaption&gt;&lt;/figure&gt;&lt;figure class=&quot;photo&quot;&gt;&lt;img src=&quot;https://slackkai.github.io/astro-margin-notes/projects/syntax-showcase/attachments/sketch-dog.svg&quot; alt=&quot;每张相片顶上都有一条胶带&quot;&gt;&lt;figcaption&gt;每张相片顶上都有一条胶带&lt;/figcaption&gt;&lt;/figure&gt;&lt;/div&gt;
&lt;details class=&quot;fold&quot;&gt;&lt;summary class=&quot;fold-summary&quot;&gt;展开看一份长清单&lt;/summary&gt;&lt;div class=&quot;fold-body&quot;&gt;&lt;p&gt;折页适合放不想一开始就占满屏幕的内容。&lt;/p&gt;&lt;ul class=&quot;contains-task-list&quot;&gt;
&lt;li class=&quot;task-list-item&quot;&gt;&lt;input type=&quot;checkbox&quot; checked disabled&gt; 页边批注&lt;/li&gt;
&lt;li class=&quot;task-list-item&quot;&gt;&lt;input type=&quot;checkbox&quot; checked disabled&gt; 便利贴&lt;/li&gt;
&lt;li class=&quot;task-list-item&quot;&gt;&lt;input type=&quot;checkbox&quot; disabled&gt; 更多相片样式&lt;/li&gt;
&lt;/ul&gt;&lt;/div&gt;&lt;/details&gt;
&lt;a class=&quot;bookmark hand-card is-link&quot; href=&quot;https://github.com/remarkjs/remark-directive&quot; target=&quot;_blank&quot; rel=&quot;noopener&quot;&gt;&lt;svg class=&quot;clip&quot; viewBox=&quot;0 0 24 48&quot; aria-hidden=&quot;true&quot;&gt;&lt;path d=&quot;M8 44 V10 a4 4 0 0 1 8 0 V38 a2 2 0 0 1 -4 0 V14&quot;&gt;&lt;/path&gt;&lt;/svg&gt;&lt;span class=&quot;bookmark-title&quot;&gt;remark-directive&lt;/span&gt;&lt;span class=&quot;bookmark-desc&quot;&gt;这套语法的解析器：一个冒号行内，两个冒号独占一行，三个冒号包住段落&lt;/span&gt;&lt;span class=&quot;bookmark-host&quot;&gt;github.com&lt;/span&gt;&lt;/a&gt;
&lt;h2 id=&quot;步骤与时间线&quot;&gt;步骤与时间线&lt;/h2&gt;
&lt;div class=&quot;steps&quot;&gt;&lt;ol class=&quot;steps-list&quot;&gt;
&lt;li&gt;在 &lt;code&gt;src/markdown/directives.mjs&lt;/code&gt; 登记一个名字和它的渲染函数。&lt;/li&gt;
&lt;li&gt;在 &lt;code&gt;src/styles/markdown.css&lt;/code&gt; 写样式，后台预览样式会自动跟着生成。&lt;/li&gt;
&lt;li&gt;在 &lt;code&gt;public/admin/components.js&lt;/code&gt; 加一个同名按钮，再到 &lt;code&gt;docs/SYNTAX.md&lt;/code&gt; 补一段说明。&lt;/li&gt;
&lt;li&gt;&lt;code&gt;npm test&lt;/code&gt; 会检查这三处是否对齐。&lt;/li&gt;
&lt;/ol&gt;&lt;/div&gt;
&lt;div class=&quot;steps steps-timeline&quot;&gt;&lt;ol class=&quot;steps-list&quot;&gt;
&lt;li&gt;&lt;strong&gt;2026-09-21&lt;/strong&gt; 页边批注和荧光笔改成 Markdown 指令，文章从此可以在后台编辑。&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;2026-09-22&lt;/strong&gt; 附件跟着文章走，语法扩展成一个家族，这一页诞生。&lt;/li&gt;
&lt;/ol&gt;&lt;/div&gt;
&lt;h2 id=&quot;版式&quot;&gt;版式&lt;/h2&gt;
&lt;div class=&quot;layout layout-cols&quot; style=&quot;--cols:2&quot;&gt;&lt;p&gt;左边一栏。分栏在手机上会变回单栏，所以每栏放独立的段落最稳妥。&lt;/p&gt;&lt;p&gt;右边一栏。适合并排放两张图或两段对照的文字。&lt;/p&gt;&lt;/div&gt;
&lt;div class=&quot;layout layout-wide&quot;&gt;












































&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;指令&lt;/th&gt;&lt;th&gt;位置&lt;/th&gt;&lt;th&gt;变体&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;&lt;code&gt;:mark[]&lt;/code&gt;&lt;/td&gt;&lt;td&gt;行内&lt;/td&gt;&lt;td&gt;green / pink / yellow&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;code&gt;:pen[]&lt;/code&gt;&lt;/td&gt;&lt;td&gt;行内&lt;/td&gt;&lt;td&gt;circle / wavy / box / strike / hide&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;code&gt;:stamp[]&lt;/code&gt;&lt;/td&gt;&lt;td&gt;行内&lt;/td&gt;&lt;td&gt;red / blue / green&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;code&gt;:::postit&lt;/code&gt;&lt;/td&gt;&lt;td&gt;段落&lt;/td&gt;&lt;td&gt;tip / warn / info / question&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;code&gt;:::photos&lt;/code&gt;&lt;/td&gt;&lt;td&gt;段落&lt;/td&gt;&lt;td&gt;cols= / scatter&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;code&gt;::video&lt;/code&gt;&lt;/td&gt;&lt;td&gt;独占一行&lt;/td&gt;&lt;td&gt;src= / youtube= / bilibili=，loop&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;code&gt;::embed&lt;/code&gt;&lt;/td&gt;&lt;td&gt;独占一行&lt;/td&gt;&lt;td&gt;page= / snippet=，height=&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;
&lt;h2 id=&quot;视频与嵌入&quot;&gt;视频与嵌入&lt;/h2&gt;
&lt;figure class=&quot;media-frame taped media-video&quot;&gt;&lt;video src=&quot;https://slackkai.github.io/astro-margin-notes/projects/syntax-showcase/attachments/arm-demo.mp4&quot; poster=&quot;https://slackkai.github.io/astro-margin-notes/projects/syntax-showcase/attachments/arm-demo-poster.webp&quot; controls playsinline preload=&quot;metadata&quot; loop muted autoplay&gt;&lt;/video&gt;&lt;figcaption&gt;附件里的视频文件：静音自动循环&lt;/figcaption&gt;&lt;/figure&gt;
&lt;figure class=&quot;media-frame taped media-embed&quot;&gt;&lt;a class=&quot;media-facade&quot; href=&quot;https://www.youtube.com/watch?v=dQw4w9WgXcQ&quot; data-embed=&quot;https://www.youtube-nocookie.com/embed/dQw4w9WgXcQ?autoplay=1&quot; target=&quot;_blank&quot; rel=&quot;noopener&quot;&gt;&lt;span class=&quot;media-play&quot;&gt;▶ 播放 · YouTube&lt;/span&gt;&lt;/a&gt;&lt;figcaption&gt;YouTube 示例：页面打开时不向站外发请求，点击封面后才加载播放器&lt;/figcaption&gt;&lt;/figure&gt;
&lt;figure class=&quot;media-frame taped media-page&quot;&gt;&lt;iframe class=&quot;embed-page&quot; src=&quot;https://slackkai.github.io/astro-margin-notes/projects/syntax-showcase/attachments/ik-arm/&quot; loading=&quot;lazy&quot; title=&quot;嵌入页面&quot;&gt;&lt;/iframe&gt;&lt;figcaption&gt;一个交互演示：两连杆机械臂跟着指针做逆运动学，颜色随站点配色变化&lt;/figcaption&gt;&lt;/figure&gt;
&lt;div class=&quot;embed-snippet&quot;&gt;&lt;!-- 片段：直接嵌进正文的静态 HTML，可以引用站点的颜色变量 --&gt;
&lt;style&gt;
  .sketch-wave { display: block; width: min(100%, 36rem); margin: 0 auto; }
  .sketch-wave .wave { stroke: var(--pen, #3b4f9e); stroke-dasharray: 900; stroke-dashoffset: 900; animation: sketch-draw 4s ease-in-out infinite alternate; }
  .sketch-wave .axis { stroke: var(--pencil-45, rgba(31, 36, 51, 0.45)); }
  .sketch-wave .dot { fill: var(--marker, #c4562f); animation: sketch-dot 4s ease-in-out infinite alternate; }
  @keyframes sketch-draw { to { stroke-dashoffset: 0; } }
  @keyframes sketch-dot { from { transform: translateX(0); } to { transform: translateX(640px); } }
  @media (prefers-reduced-motion: reduce) { .sketch-wave .wave, .sketch-wave .dot { animation: none; stroke-dashoffset: 0; } }
&lt;/style&gt;
&lt;svg class=&quot;sketch-wave&quot; viewBox=&quot;0 0 720 200&quot; fill=&quot;none&quot; stroke-width=&quot;3&quot; stroke-linecap=&quot;round&quot; aria-label=&quot;手绘正弦波&quot;&gt;
  &lt;path class=&quot;axis&quot; d=&quot;M40 100 h640 M40 30 v140&quot; stroke-dasharray=&quot;6 8&quot;&gt;&lt;/path&gt;
  &lt;path class=&quot;wave&quot; d=&quot;M40 100 C 80 20, 120 20, 160 100 S 240 180, 280 100 S 360 20, 400 100 S 480 180, 520 100 S 600 20, 640 100 S 700 160, 680 110&quot;&gt;&lt;/path&gt;
  &lt;circle class=&quot;dot&quot; cx=&quot;40&quot; cy=&quot;100&quot; r=&quot;7&quot;&gt;&lt;/circle&gt;
&lt;/svg&gt;
&lt;p class=&quot;embed-caption&quot;&gt;片段：一段带 CSS 动画的 SVG，直接嵌进正文&lt;/p&gt;&lt;/div&gt;
&lt;p&gt;嵌入页面是附件里的一个文件夹，有自己的 &lt;code&gt;index.html&lt;/code&gt;，站点只负责把它放进相框并同步配色。想看它的源码，打开 &lt;a href=&quot;https://slackkai.github.io/astro-margin-notes/projects/syntax-showcase/attachments/ik-arm/index.html&quot;&gt;&lt;code&gt;attachments/ik-arm/index.html&lt;/code&gt;&lt;/a&gt;。&lt;/p&gt;</content:encoded><category>projects</category><category>site</category><category>markdown</category></item><item><title>原生 Markdown 的手绘重绘</title><link>https://slackkai.github.io/astro-margin-notes/projects/syntax-showcase/markdown/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/projects/syntax-showcase/markdown/</guid><description>不加任何新语法，标题、列表、引用、表格、代码块和分割线在这个站点上长什么样。</description><pubDate>Tue, 22 Sep 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;这是&lt;a href=&quot;https://slackkai.github.io/astro-margin-notes/projects/syntax-showcase/&quot;&gt;《笔记本语法演示》&lt;/a&gt;项目里的一篇文档，有自己的附件夹。下面全是标准 Markdown，没有一个自定义指令。&lt;/p&gt;
&lt;h2 id=&quot;标题与分割线&quot;&gt;标题与分割线&lt;/h2&gt;
&lt;p&gt;二级标题和 &lt;code&gt;---&lt;/code&gt; 分割线沿用站点原有的虚线，安静地把段落隔开：&lt;/p&gt;
&lt;hr&gt;
&lt;h2 id=&quot;列表&quot;&gt;列表&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;无序列表用铅笔点&lt;/li&gt;
&lt;li&gt;第二条
&lt;ul&gt;
&lt;li&gt;嵌套一层也是同样的点&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;ol&gt;
&lt;li&gt;有序列表的编号是手绘圈号&lt;/li&gt;
&lt;li&gt;第二步&lt;/li&gt;
&lt;li&gt;第三步&lt;/li&gt;
&lt;/ol&gt;
&lt;ul class=&quot;contains-task-list&quot;&gt;
&lt;li class=&quot;task-list-item&quot;&gt;&lt;input type=&quot;checkbox&quot; checked disabled&gt; 任务清单：勾选的用马克笔打勾&lt;/li&gt;
&lt;li class=&quot;task-list-item&quot;&gt;&lt;input type=&quot;checkbox&quot; disabled&gt; 还没做的保持空框&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id=&quot;引用&quot;&gt;引用&lt;/h2&gt;
&lt;blockquote&gt;
&lt;p&gt;简单的东西不一定容易，但容易的东西往往不简单。&lt;/p&gt;
&lt;p class=&quot;quote-source&quot;&gt;一位不愿透露姓名的工程师&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;引用块最后一段以 &lt;code&gt;——&lt;/code&gt; 开头，就会变成右对齐的出处。&lt;/p&gt;
&lt;h2 id=&quot;表格&quot;&gt;表格&lt;/h2&gt;




















&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;板块&lt;/th&gt;&lt;th&gt;每篇一个文件夹&lt;/th&gt;&lt;th&gt;附件位置&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;学术、洞见、项目&lt;/td&gt;&lt;td&gt;是&lt;/td&gt;&lt;td&gt;&lt;code&gt;&amp;#x3C;slug&gt;/attachments/&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;日常、资料库&lt;/td&gt;&lt;td&gt;否&lt;/td&gt;&lt;td&gt;&lt;code&gt;&amp;#x3C;板块&gt;/attachments/&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;
&lt;h2 id=&quot;代码&quot;&gt;代码&lt;/h2&gt;
&lt;pre class=&quot;astro-code astro-code-themes github-light github-dark&quot; style=&quot;background-color:#fff;--shiki-dark-bg:#24292e;color:#24292e;--shiki-dark:#e1e4e8; overflow-x: auto; white-space: pre-wrap; word-wrap: break-word;&quot; tabindex=&quot;0&quot; data-language=&quot;python&quot;&gt;&lt;code&gt;&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;def&lt;/span&gt;&lt;span style=&quot;color:#6F42C1;--shiki-dark:#B392F0&quot;&gt; ik&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;(x, y, l1&lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color:#005CC5;--shiki-dark:#79B8FF&quot;&gt;1.0&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;, l2&lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color:#005CC5;--shiki-dark:#79B8FF&quot;&gt;0.8&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;):&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#032F62;--shiki-dark:#9ECBFF&quot;&gt;    &quot;&quot;&quot;两连杆逆运动学：给末端坐标，返回两个关节角。&quot;&quot;&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;    import&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; math&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;    c2 &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; (x &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;*&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; x &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;+&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; y &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;*&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; y &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;-&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; l1 &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;*&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; l1 &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;-&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; l2 &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;*&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; l2) &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;/&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; (&lt;/span&gt;&lt;span style=&quot;color:#005CC5;--shiki-dark:#79B8FF&quot;&gt;2&lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt; *&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; l1 &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;*&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; l2)&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;    t2 &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; math.acos(&lt;/span&gt;&lt;span style=&quot;color:#005CC5;--shiki-dark:#79B8FF&quot;&gt;max&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;-&lt;/span&gt;&lt;span style=&quot;color:#005CC5;--shiki-dark:#79B8FF&quot;&gt;1.0&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;, &lt;/span&gt;&lt;span style=&quot;color:#005CC5;--shiki-dark:#79B8FF&quot;&gt;min&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color:#005CC5;--shiki-dark:#79B8FF&quot;&gt;1.0&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;, c2)))&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;    t1 &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; math.atan2(y, x) &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;-&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; math.atan2(l2 &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;*&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; math.sin(t2), l1 &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;+&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; l2 &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;*&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; math.cos(t2))&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;    return&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; t1, t2&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;右上角的胶带标签写着语言名。行内代码 &lt;code&gt;like this&lt;/code&gt; 还是原来的样子。&lt;/p&gt;
&lt;h2 id=&quot;公式与脚注&quot;&gt;公式与脚注&lt;/h2&gt;
&lt;p&gt;行内公式 &lt;span class=&quot;katex&quot;&gt;&lt;span class=&quot;katex-mathml&quot;&gt;&lt;math xmlns=&quot;http://www.w3.org/1998/Math/MathML&quot;&gt;&lt;semantics&gt;&lt;mrow&gt;&lt;mi&gt;τ&lt;/mi&gt;&lt;mo&gt;=&lt;/mo&gt;&lt;msup&gt;&lt;mi&gt;J&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;⊤&lt;/mi&gt;&lt;/msup&gt;&lt;mi&gt;F&lt;/mi&gt;&lt;/mrow&gt;&lt;annotation encoding=&quot;application/x-tex&quot;&gt;\tau = J^\top F&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/span&gt;&lt;span class=&quot;katex-html&quot; aria-hidden=&quot;true&quot;&gt;&lt;span class=&quot;base&quot;&gt;&lt;span class=&quot;strut&quot; style=&quot;height:0.4306em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord mathnormal&quot; style=&quot;margin-right:0.1132em;&quot;&gt;τ&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.2778em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mrel&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.2778em;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;base&quot;&gt;&lt;span class=&quot;strut&quot; style=&quot;height:0.8491em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord mathnormal&quot; style=&quot;margin-right:0.0962em;&quot;&gt;J&lt;/span&gt;&lt;span class=&quot;msupsub&quot;&gt;&lt;span class=&quot;vlist-t&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.8491em;&quot;&gt;&lt;span style=&quot;top:-3.063em;margin-right:0.05em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:2.7em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;sizing reset-size6 size3 mtight&quot;&gt;&lt;span class=&quot;mord mtight&quot;&gt;⊤&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;mord mathnormal&quot; style=&quot;margin-right:0.1389em;&quot;&gt;F&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;，独立公式：&lt;/p&gt;
&lt;span class=&quot;katex-display&quot;&gt;&lt;span class=&quot;katex&quot;&gt;&lt;span class=&quot;katex-mathml&quot;&gt;&lt;math xmlns=&quot;http://www.w3.org/1998/Math/MathML&quot; display=&quot;block&quot;&gt;&lt;semantics&gt;&lt;mrow&gt;&lt;mover accent=&quot;true&quot;&gt;&lt;mi&gt;q&lt;/mi&gt;&lt;mo&gt;˙&lt;/mo&gt;&lt;/mover&gt;&lt;mo&gt;=&lt;/mo&gt;&lt;msup&gt;&lt;mi&gt;J&lt;/mi&gt;&lt;mo lspace=&quot;0em&quot; rspace=&quot;0em&quot;&gt;+&lt;/mo&gt;&lt;/msup&gt;&lt;mo stretchy=&quot;false&quot;&gt;(&lt;/mo&gt;&lt;mi&gt;q&lt;/mi&gt;&lt;mo stretchy=&quot;false&quot;&gt;)&lt;/mo&gt;&lt;mtext&gt; &lt;/mtext&gt;&lt;mover accent=&quot;true&quot;&gt;&lt;mi&gt;x&lt;/mi&gt;&lt;mo&gt;˙&lt;/mo&gt;&lt;/mover&gt;&lt;/mrow&gt;&lt;annotation encoding=&quot;application/x-tex&quot;&gt;\dot{q} = J^{+}(q)\,\dot{x}&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/span&gt;&lt;span class=&quot;katex-html&quot; aria-hidden=&quot;true&quot;&gt;&lt;span class=&quot;base&quot;&gt;&lt;span class=&quot;strut&quot; style=&quot;height:0.8623em;vertical-align:-0.1944em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord accent&quot;&gt;&lt;span class=&quot;vlist-t vlist-t2&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.6679em;&quot;&gt;&lt;span style=&quot;top:-3em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:3em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord mathnormal&quot; style=&quot;margin-right:0.0359em;&quot;&gt;q&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;top:-3em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:3em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;accent-body&quot; style=&quot;left:-0.0556em;&quot;&gt;&lt;span class=&quot;mord&quot;&gt;˙&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-s&quot;&gt;​&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.1944em;&quot;&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.2778em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mrel&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.2778em;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;base&quot;&gt;&lt;span class=&quot;strut&quot; style=&quot;height:1.0713em;vertical-align:-0.25em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord mathnormal&quot; style=&quot;margin-right:0.0962em;&quot;&gt;J&lt;/span&gt;&lt;span class=&quot;msupsub&quot;&gt;&lt;span class=&quot;vlist-t&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.8213em;&quot;&gt;&lt;span style=&quot;top:-3.113em;margin-right:0.05em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:2.7em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;sizing reset-size6 size3 mtight&quot;&gt;&lt;span class=&quot;mord mtight&quot;&gt;&lt;span class=&quot;mord mtight&quot;&gt;+&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;mopen&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;mord mathnormal&quot; style=&quot;margin-right:0.0359em;&quot;&gt;q&lt;/span&gt;&lt;span class=&quot;mclose&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.1667em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord accent&quot;&gt;&lt;span class=&quot;vlist-t&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.6679em;&quot;&gt;&lt;span style=&quot;top:-3em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:3em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord mathnormal&quot;&gt;x&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;top:-3em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:3em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;accent-body&quot; style=&quot;left:-0.1111em;&quot;&gt;&lt;span class=&quot;mord&quot;&gt;˙&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;p&gt;脚注会进页边&lt;label class=&quot;note-wrap&quot;&gt;&lt;input type=&quot;checkbox&quot; class=&quot;note-toggle&quot; aria-label=&quot;展开批注&quot;&gt;&lt;span class=&quot;note-ref&quot;&gt;&lt;/span&gt;&lt;span class=&quot;note&quot;&gt;&lt;span class=&quot;katex&quot;&gt;&lt;span class=&quot;katex-mathml&quot;&gt;&lt;math xmlns=&quot;http://www.w3.org/1998/Math/MathML&quot;&gt;&lt;semantics&gt;&lt;mrow&gt;&lt;msup&gt;&lt;mi&gt;J&lt;/mi&gt;&lt;mo lspace=&quot;0em&quot; rspace=&quot;0em&quot;&gt;+&lt;/mo&gt;&lt;/msup&gt;&lt;/mrow&gt;&lt;annotation encoding=&quot;application/x-tex&quot;&gt;J^{+}&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/span&gt;&lt;span class=&quot;katex-html&quot; aria-hidden=&quot;true&quot;&gt;&lt;span class=&quot;base&quot;&gt;&lt;span class=&quot;strut&quot; style=&quot;height:0.7713em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord mathnormal&quot; style=&quot;margin-right:0.0962em;&quot;&gt;J&lt;/span&gt;&lt;span class=&quot;msupsub&quot;&gt;&lt;span class=&quot;vlist-t&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.7713em;&quot;&gt;&lt;span style=&quot;top:-3.063em;margin-right:0.05em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:2.7em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;sizing reset-size6 size3 mtight&quot;&gt;&lt;span class=&quot;mord mtight&quot;&gt;&lt;span class=&quot;mord mtight&quot;&gt;+&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt; 是雅可比的伪逆；奇异位形附近要加阻尼。&lt;/span&gt;&lt;/label&gt;，和行内批注共用编号。&lt;/p&gt;
&lt;h2 id=&quot;图片&quot;&gt;图片&lt;/h2&gt;
&lt;p&gt;&lt;img src=&quot;https://slackkai.github.io/astro-margin-notes/projects/syntax-showcase/markdown/attachments/paper.svg&quot; alt=&quot;这篇文档自己的附件：一张纸&quot;&gt;&lt;/p&gt;
&lt;p&gt;标准图片有手绘边框；想要胶带和图注，用相片指令。&lt;/p&gt;</content:encoded><category>projects</category><category>site</category><category>markdown</category></item><item><title>博客搭好了</title><link>https://slackkai.github.io/astro-margin-notes/dailies/2026-09-18-blog-up/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/dailies/2026-09-18-blog-up/</guid><pubDate>Fri, 18 Sep 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;用 Astro 把站点骨架搭起来了。手绘风格的边框和硬阴影比想象中好看。&lt;/p&gt;
&lt;p&gt;接下来是把旧笔记慢慢搬过来。&lt;/p&gt;</content:encoded><category>dailies</category><category>blog</category></item><item><title>Margin Notes 主题</title><link>https://slackkai.github.io/astro-margin-notes/projects/latentk-site/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/projects/latentk-site/</guid><description>这个站点本身。Astro + 手绘笔记本风格，部署在 GitHub Pages。</description><pubDate>Fri, 18 Sep 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;五个板块、一套配色切换、一条机械臂，以及可视化内容管理后台。&lt;/p&gt;</content:encoded><category>projects</category><category>blog</category><category>web</category></item><item><title>为什么我把博客拆成四个板块</title><link>https://slackkai.github.io/astro-margin-notes/insight/why-four-sections/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/insight/why-four-sections/</guid><description>学术、洞见、日常、资料库：不同内容需要不同的形态，硬塞进一条时间线会互相干扰。</description><pubDate>Tue, 15 Sep 2026 00:00:00 GMT</pubDate><content:encoded>&lt;h2 id=&quot;一条时间线的问题&quot;&gt;一条时间线的问题&lt;/h2&gt;
&lt;p&gt;大多数博客只有一个”文章流”。论文笔记、生活碎碎念、读书清单混在一起，结果是：&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;想找某篇论文笔记时要翻过一堆日常。&lt;/li&gt;
&lt;li&gt;写一条两行的日常，会觉得”不够格”发出来。&lt;/li&gt;
&lt;li&gt;资料收藏根本不是”文章”，它需要的是卡片和筛选。&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id=&quot;拆分之后&quot;&gt;拆分之后&lt;/h2&gt;






























&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;板块&lt;/th&gt;&lt;th&gt;形态&lt;/th&gt;&lt;th&gt;更新频率&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;Academic&lt;/td&gt;&lt;td&gt;结构化笔记，带引用与链接&lt;/td&gt;&lt;td&gt;低&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Insight&lt;/td&gt;&lt;td&gt;长文&lt;/td&gt;&lt;td&gt;低&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Dailies&lt;/td&gt;&lt;td&gt;时间线短记&lt;/td&gt;&lt;td&gt;高&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Library&lt;/td&gt;&lt;td&gt;卡片 + 筛选&lt;/td&gt;&lt;td&gt;中&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;
&lt;p&gt;每个板块有自己的 schema，写作时只填该填的字段。&lt;/p&gt;
&lt;h2 id=&quot;代价&quot;&gt;代价&lt;/h2&gt;
&lt;p&gt;多维护几个页面模板。但这是一次性的成本，值得。&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;结构决定你愿意写什么。&lt;/p&gt;
&lt;/blockquote&gt;</content:encoded><category>insight</category><category>blog</category><category>writing</category><category>meta</category></item><item><title>四足控制器 · 二：奖励函数踩过的坑</title><link>https://slackkai.github.io/astro-margin-notes/insight/quadruped-2/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/insight/quadruped-2/</guid><description>系列第二篇。三个让策略学会作弊的奖励项，以及怎么改。</description><pubDate>Sat, 12 Sep 2026 00:00:00 GMT</pubDate><content:encoded>&lt;h2 id=&quot;坑一只奖励高度&quot;&gt;坑一：只奖励高度&lt;/h2&gt;
&lt;p&gt;策略学会了把腿伸直硬扛。&lt;/p&gt;
&lt;h2 id=&quot;坑二惩罚关节速度&quot;&gt;坑二：惩罚关节速度&lt;/h2&gt;
&lt;p&gt;策略干脆不动了。&lt;/p&gt;
&lt;h2 id=&quot;坑三终止条件太宽&quot;&gt;坑三：终止条件太宽&lt;/h2&gt;
&lt;p&gt;翻倒了还在拿奖励。&lt;/p&gt;</content:encoded><category>insight</category><category>robotics</category><category>rl</category><category>series</category></item><item><title>日常 · 2026-09-12</title><link>https://slackkai.github.io/astro-margin-notes/dailies/2026-09-12-library-afternoon/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/dailies/2026-09-12-library-afternoon/</guid><pubDate>Sat, 12 Sep 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;在图书馆待了一下午，把积压的三篇论文读完了。没有标题的日常长这样。&lt;/p&gt;</content:encoded><category>dailies</category><category>reading</category></item><item><title>Attention Is All You Need 精读笔记</title><link>https://slackkai.github.io/astro-margin-notes/academic/attention-is-all-you-need/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/academic/attention-is-all-you-need/</guid><description>Transformer 原始论文的结构梳理，重点是多头注意力与位置编码。</description><pubDate>Thu, 10 Sep 2026 00:00:00 GMT</pubDate><content:encoded>&lt;h2 id=&quot;核心思想&quot;&gt;核心思想&lt;/h2&gt;
&lt;p&gt;完全抛弃循环与卷积，&lt;span class=&quot;mark&quot;&gt;仅用注意力机制建模序列依赖&lt;/span&gt;。&lt;label class=&quot;note-wrap&quot;&gt;&lt;input type=&quot;checkbox&quot; class=&quot;note-toggle&quot; aria-label=&quot;展开批注&quot;&gt;&lt;span class=&quot;note-ref&quot;&gt;&lt;/span&gt;&lt;span class=&quot;note&quot;&gt;这一句话在 2017 年是很激进的主张。当时的主流是 LSTM 加注意力。&lt;/span&gt;&lt;/label&gt;&lt;/p&gt;
&lt;h2 id=&quot;缩放点积注意力&quot;&gt;缩放点积注意力&lt;/h2&gt;
&lt;span class=&quot;katex-display&quot;&gt;&lt;span class=&quot;katex&quot;&gt;&lt;span class=&quot;katex-mathml&quot;&gt;&lt;math xmlns=&quot;http://www.w3.org/1998/Math/MathML&quot; display=&quot;block&quot;&gt;&lt;semantics&gt;&lt;mrow&gt;&lt;mrow&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;A&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;t&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;t&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;e&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;n&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;t&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;i&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;o&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;n&lt;/mi&gt;&lt;/mrow&gt;&lt;mo stretchy=&quot;false&quot;&gt;(&lt;/mo&gt;&lt;mi&gt;Q&lt;/mi&gt;&lt;mo separator=&quot;true&quot;&gt;,&lt;/mo&gt;&lt;mi&gt;K&lt;/mi&gt;&lt;mo separator=&quot;true&quot;&gt;,&lt;/mo&gt;&lt;mi&gt;V&lt;/mi&gt;&lt;mo stretchy=&quot;false&quot;&gt;)&lt;/mo&gt;&lt;mo&gt;=&lt;/mo&gt;&lt;mrow&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;s&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;o&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;f&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;t&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;m&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;a&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;x&lt;/mi&gt;&lt;/mrow&gt;&lt;mrow&gt;&lt;mo fence=&quot;true&quot;&gt;(&lt;/mo&gt;&lt;mfrac&gt;&lt;mrow&gt;&lt;mi&gt;Q&lt;/mi&gt;&lt;msup&gt;&lt;mi&gt;K&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;⊤&lt;/mi&gt;&lt;/msup&gt;&lt;/mrow&gt;&lt;msqrt&gt;&lt;msub&gt;&lt;mi&gt;d&lt;/mi&gt;&lt;mi&gt;k&lt;/mi&gt;&lt;/msub&gt;&lt;/msqrt&gt;&lt;/mfrac&gt;&lt;mo fence=&quot;true&quot;&gt;)&lt;/mo&gt;&lt;/mrow&gt;&lt;mi&gt;V&lt;/mi&gt;&lt;/mrow&gt;&lt;annotation encoding=&quot;application/x-tex&quot;&gt;\mathrm{Attention}(Q, K, V) = \mathrm{softmax}\left(\frac{QK^\top}{\sqrt{d_k}}\right)V&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/span&gt;&lt;span class=&quot;katex-html&quot; aria-hidden=&quot;true&quot;&gt;&lt;span class=&quot;base&quot;&gt;&lt;span class=&quot;strut&quot; style=&quot;height:1em;vertical-align:-0.25em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord mathrm&quot;&gt;Attention&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;mopen&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;mord mathnormal&quot;&gt;Q&lt;/span&gt;&lt;span class=&quot;mpunct&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.1667em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord mathnormal&quot; style=&quot;margin-right:0.0715em;&quot;&gt;K&lt;/span&gt;&lt;span class=&quot;mpunct&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.1667em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord mathnormal&quot; style=&quot;margin-right:0.2222em;&quot;&gt;V&lt;/span&gt;&lt;span class=&quot;mclose&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.2778em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mrel&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.2778em;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;base&quot;&gt;&lt;span class=&quot;strut&quot; style=&quot;height:2.4761em;vertical-align:-0.95em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord mathrm&quot;&gt;softmax&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.1667em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;minner&quot;&gt;&lt;span class=&quot;mopen delimcenter&quot; style=&quot;top:0em;&quot;&gt;&lt;span class=&quot;delimsizing size3&quot;&gt;(&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mopen nulldelimiter&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mfrac&quot;&gt;&lt;span class=&quot;vlist-t vlist-t2&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:1.5261em;&quot;&gt;&lt;span style=&quot;top:-2.2528em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:3em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord sqrt&quot;&gt;&lt;span class=&quot;vlist-t vlist-t2&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.8572em;&quot;&gt;&lt;span class=&quot;svg-align&quot; style=&quot;top:-3em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:3em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord&quot; style=&quot;padding-left:0.833em;&quot;&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord mathnormal&quot;&gt;d&lt;/span&gt;&lt;span class=&quot;msupsub&quot;&gt;&lt;span class=&quot;vlist-t vlist-t2&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.3361em;&quot;&gt;&lt;span style=&quot;top:-2.55em;margin-left:0em;margin-right:0.05em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:2.7em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;sizing reset-size6 size3 mtight&quot;&gt;&lt;span class=&quot;mord mathnormal mtight&quot; style=&quot;margin-right:0.0315em;&quot;&gt;k&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-s&quot;&gt;​&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.15em;&quot;&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;top:-2.8172em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:3em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;hide-tail&quot; style=&quot;min-width:0.853em;height:1.08em;&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; width=&quot;400em&quot; height=&quot;1.08em&quot; viewBox=&quot;0 0 400000 1080&quot; preserveAspectRatio=&quot;xMinYMin slice&quot;&gt;&lt;path d=&quot;M95,702
c-2.7,0,-7.17,-2.7,-13.5,-8c-5.8,-5.3,-9.5,-10,-9.5,-14
c0,-2,0.3,-3.3,1,-4c1.3,-2.7,23.83,-20.7,67.5,-54
c44.2,-33.3,65.8,-50.3,66.5,-51c1.3,-1.3,3,-2,5,-2c4.7,0,8.7,3.3,12,10
s173,378,173,378c0.7,0,35.3,-71,104,-213c68.7,-142,137.5,-285,206.5,-429
c69,-144,104.5,-217.7,106.5,-221
l0 -0
c5.3,-9.3,12,-14,20,-14
H400000v40H845.2724
s-225.272,467,-225.272,467s-235,486,-235,486c-2.7,4.7,-9,7,-19,7
c-6,0,-10,-1,-12,-3s-194,-422,-194,-422s-65,47,-65,47z
M834 80h400000v40h-400000z&quot;&gt;&lt;/path&gt;&lt;/svg&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-s&quot;&gt;​&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.1828em;&quot;&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;top:-3.23em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:3em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;frac-line&quot; style=&quot;border-bottom-width:0.04em;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;top:-3.677em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:3em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord mathnormal&quot;&gt;Q&lt;/span&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord mathnormal&quot; style=&quot;margin-right:0.0715em;&quot;&gt;K&lt;/span&gt;&lt;span class=&quot;msupsub&quot;&gt;&lt;span class=&quot;vlist-t&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.8491em;&quot;&gt;&lt;span style=&quot;top:-3.063em;margin-right:0.05em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:2.7em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;sizing reset-size6 size3 mtight&quot;&gt;&lt;span class=&quot;mord mtight&quot;&gt;⊤&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-s&quot;&gt;​&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.93em;&quot;&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;mclose nulldelimiter&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;mclose delimcenter&quot; style=&quot;top:0em;&quot;&gt;&lt;span class=&quot;delimsizing size3&quot;&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.1667em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord mathnormal&quot; style=&quot;margin-right:0.2222em;&quot;&gt;V&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;p&gt;除以 &lt;span class=&quot;katex&quot;&gt;&lt;span class=&quot;katex-mathml&quot;&gt;&lt;math xmlns=&quot;http://www.w3.org/1998/Math/MathML&quot;&gt;&lt;semantics&gt;&lt;mrow&gt;&lt;msqrt&gt;&lt;msub&gt;&lt;mi&gt;d&lt;/mi&gt;&lt;mi&gt;k&lt;/mi&gt;&lt;/msub&gt;&lt;/msqrt&gt;&lt;/mrow&gt;&lt;annotation encoding=&quot;application/x-tex&quot;&gt;\sqrt{d_k}&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/span&gt;&lt;span class=&quot;katex-html&quot; aria-hidden=&quot;true&quot;&gt;&lt;span class=&quot;base&quot;&gt;&lt;span class=&quot;strut&quot; style=&quot;height:1.04em;vertical-align:-0.1828em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord sqrt&quot;&gt;&lt;span class=&quot;vlist-t vlist-t2&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.8572em;&quot;&gt;&lt;span class=&quot;svg-align&quot; style=&quot;top:-3em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:3em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord&quot; style=&quot;padding-left:0.833em;&quot;&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord mathnormal&quot;&gt;d&lt;/span&gt;&lt;span class=&quot;msupsub&quot;&gt;&lt;span class=&quot;vlist-t vlist-t2&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.3361em;&quot;&gt;&lt;span style=&quot;top:-2.55em;margin-left:0em;margin-right:0.05em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:2.7em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;sizing reset-size6 size3 mtight&quot;&gt;&lt;span class=&quot;mord mathnormal mtight&quot; style=&quot;margin-right:0.0315em;&quot;&gt;k&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-s&quot;&gt;​&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.15em;&quot;&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;top:-2.8172em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:3em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;hide-tail&quot; style=&quot;min-width:0.853em;height:1.08em;&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; width=&quot;400em&quot; height=&quot;1.08em&quot; viewBox=&quot;0 0 400000 1080&quot; preserveAspectRatio=&quot;xMinYMin slice&quot;&gt;&lt;path d=&quot;M95,702
c-2.7,0,-7.17,-2.7,-13.5,-8c-5.8,-5.3,-9.5,-10,-9.5,-14
c0,-2,0.3,-3.3,1,-4c1.3,-2.7,23.83,-20.7,67.5,-54
c44.2,-33.3,65.8,-50.3,66.5,-51c1.3,-1.3,3,-2,5,-2c4.7,0,8.7,3.3,12,10
s173,378,173,378c0.7,0,35.3,-71,104,-213c68.7,-142,137.5,-285,206.5,-429
c69,-144,104.5,-217.7,106.5,-221
l0 -0
c5.3,-9.3,12,-14,20,-14
H400000v40H845.2724
s-225.272,467,-225.272,467s-235,486,-235,486c-2.7,4.7,-9,7,-19,7
c-6,0,-10,-1,-12,-3s-194,-422,-194,-422s-65,47,-65,47z
M834 80h400000v40h-400000z&quot;&gt;&lt;/path&gt;&lt;/svg&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-s&quot;&gt;​&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.1828em;&quot;&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt; 是为了防止点积过大导致 softmax 进入梯度极小的区域。&lt;label class=&quot;note-wrap&quot;&gt;&lt;input type=&quot;checkbox&quot; class=&quot;note-toggle&quot; aria-label=&quot;展开批注&quot;&gt;&lt;span class=&quot;note-ref&quot;&gt;&lt;/span&gt;&lt;span class=&quot;note&quot;&gt;这里的 &lt;span class=&quot;katex&quot;&gt;&lt;span class=&quot;katex-mathml&quot;&gt;&lt;math xmlns=&quot;http://www.w3.org/1998/Math/MathML&quot;&gt;&lt;semantics&gt;&lt;mrow&gt;&lt;msub&gt;&lt;mi&gt;d&lt;/mi&gt;&lt;mi&gt;k&lt;/mi&gt;&lt;/msub&gt;&lt;/mrow&gt;&lt;annotation encoding=&quot;application/x-tex&quot;&gt;d_k&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/span&gt;&lt;span class=&quot;katex-html&quot; aria-hidden=&quot;true&quot;&gt;&lt;span class=&quot;base&quot;&gt;&lt;span class=&quot;strut&quot; style=&quot;height:0.8444em;vertical-align:-0.15em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord mathnormal&quot;&gt;d&lt;/span&gt;&lt;span class=&quot;msupsub&quot;&gt;&lt;span class=&quot;vlist-t vlist-t2&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.3361em;&quot;&gt;&lt;span style=&quot;top:-2.55em;margin-left:0em;margin-right:0.05em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:2.7em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;sizing reset-size6 size3 mtight&quot;&gt;&lt;span class=&quot;mord mathnormal mtight&quot; style=&quot;margin-right:0.0315em;&quot;&gt;k&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-s&quot;&gt;​&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.15em;&quot;&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt; 是键向量的维度，不是序列长度。我第一次读时搞混了。&lt;/span&gt;&lt;/label&gt;&lt;/p&gt;
&lt;h2 id=&quot;多头注意力&quot;&gt;多头注意力&lt;/h2&gt;
&lt;p&gt;把 &lt;span class=&quot;katex&quot;&gt;&lt;span class=&quot;katex-mathml&quot;&gt;&lt;math xmlns=&quot;http://www.w3.org/1998/Math/MathML&quot;&gt;&lt;semantics&gt;&lt;mrow&gt;&lt;mi&gt;Q&lt;/mi&gt;&lt;mo separator=&quot;true&quot;&gt;,&lt;/mo&gt;&lt;mi&gt;K&lt;/mi&gt;&lt;mo separator=&quot;true&quot;&gt;,&lt;/mo&gt;&lt;mi&gt;V&lt;/mi&gt;&lt;/mrow&gt;&lt;annotation encoding=&quot;application/x-tex&quot;&gt;Q, K, V&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/span&gt;&lt;span class=&quot;katex-html&quot; aria-hidden=&quot;true&quot;&gt;&lt;span class=&quot;base&quot;&gt;&lt;span class=&quot;strut&quot; style=&quot;height:0.8778em;vertical-align:-0.1944em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord mathnormal&quot;&gt;Q&lt;/span&gt;&lt;span class=&quot;mpunct&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.1667em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord mathnormal&quot; style=&quot;margin-right:0.0715em;&quot;&gt;K&lt;/span&gt;&lt;span class=&quot;mpunct&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.1667em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord mathnormal&quot; style=&quot;margin-right:0.2222em;&quot;&gt;V&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt; 各自线性投影 &lt;span class=&quot;katex&quot;&gt;&lt;span class=&quot;katex-mathml&quot;&gt;&lt;math xmlns=&quot;http://www.w3.org/1998/Math/MathML&quot;&gt;&lt;semantics&gt;&lt;mrow&gt;&lt;mi&gt;h&lt;/mi&gt;&lt;/mrow&gt;&lt;annotation encoding=&quot;application/x-tex&quot;&gt;h&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/span&gt;&lt;span class=&quot;katex-html&quot; aria-hidden=&quot;true&quot;&gt;&lt;span class=&quot;base&quot;&gt;&lt;span class=&quot;strut&quot; style=&quot;height:0.6944em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord mathnormal&quot;&gt;h&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt; 次，并行做注意力后拼接：&lt;/p&gt;
&lt;span class=&quot;katex-display&quot;&gt;&lt;span class=&quot;katex&quot;&gt;&lt;span class=&quot;katex-mathml&quot;&gt;&lt;math xmlns=&quot;http://www.w3.org/1998/Math/MathML&quot; display=&quot;block&quot;&gt;&lt;semantics&gt;&lt;mrow&gt;&lt;mrow&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;M&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;u&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;l&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;t&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;i&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;H&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;e&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;a&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;d&lt;/mi&gt;&lt;/mrow&gt;&lt;mo stretchy=&quot;false&quot;&gt;(&lt;/mo&gt;&lt;mi&gt;Q&lt;/mi&gt;&lt;mo separator=&quot;true&quot;&gt;,&lt;/mo&gt;&lt;mi&gt;K&lt;/mi&gt;&lt;mo separator=&quot;true&quot;&gt;,&lt;/mo&gt;&lt;mi&gt;V&lt;/mi&gt;&lt;mo stretchy=&quot;false&quot;&gt;)&lt;/mo&gt;&lt;mo&gt;=&lt;/mo&gt;&lt;mrow&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;C&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;o&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;n&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;c&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;a&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;t&lt;/mi&gt;&lt;/mrow&gt;&lt;mo stretchy=&quot;false&quot;&gt;(&lt;/mo&gt;&lt;msub&gt;&lt;mrow&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;h&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;e&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;a&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;d&lt;/mi&gt;&lt;/mrow&gt;&lt;mn&gt;1&lt;/mn&gt;&lt;/msub&gt;&lt;mo separator=&quot;true&quot;&gt;,&lt;/mo&gt;&lt;mo&gt;…&lt;/mo&gt;&lt;mo separator=&quot;true&quot;&gt;,&lt;/mo&gt;&lt;msub&gt;&lt;mrow&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;h&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;e&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;a&lt;/mi&gt;&lt;mi mathvariant=&quot;normal&quot;&gt;d&lt;/mi&gt;&lt;/mrow&gt;&lt;mi&gt;h&lt;/mi&gt;&lt;/msub&gt;&lt;mo stretchy=&quot;false&quot;&gt;)&lt;/mo&gt;&lt;msup&gt;&lt;mi&gt;W&lt;/mi&gt;&lt;mi&gt;O&lt;/mi&gt;&lt;/msup&gt;&lt;/mrow&gt;&lt;annotation encoding=&quot;application/x-tex&quot;&gt;\mathrm{MultiHead}(Q,K,V) = \mathrm{Concat}(\mathrm{head}_1,\dots,\mathrm{head}_h)W^O&lt;/annotation&gt;&lt;/semantics&gt;&lt;/math&gt;&lt;/span&gt;&lt;span class=&quot;katex-html&quot; aria-hidden=&quot;true&quot;&gt;&lt;span class=&quot;base&quot;&gt;&lt;span class=&quot;strut&quot; style=&quot;height:1em;vertical-align:-0.25em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord mathrm&quot;&gt;MultiHead&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;mopen&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;mord mathnormal&quot;&gt;Q&lt;/span&gt;&lt;span class=&quot;mpunct&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.1667em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord mathnormal&quot; style=&quot;margin-right:0.0715em;&quot;&gt;K&lt;/span&gt;&lt;span class=&quot;mpunct&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.1667em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord mathnormal&quot; style=&quot;margin-right:0.2222em;&quot;&gt;V&lt;/span&gt;&lt;span class=&quot;mclose&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.2778em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mrel&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.2778em;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;base&quot;&gt;&lt;span class=&quot;strut&quot; style=&quot;height:1.1413em;vertical-align:-0.25em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord mathrm&quot;&gt;Concat&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;mopen&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord mathrm&quot;&gt;head&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;msupsub&quot;&gt;&lt;span class=&quot;vlist-t vlist-t2&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.3011em;&quot;&gt;&lt;span style=&quot;top:-2.55em;margin-right:0.05em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:2.7em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;sizing reset-size6 size3 mtight&quot;&gt;&lt;span class=&quot;mord mtight&quot;&gt;1&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-s&quot;&gt;​&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.15em;&quot;&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;mpunct&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.1667em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;minner&quot;&gt;…&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.1667em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mpunct&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;mspace&quot; style=&quot;margin-right:0.1667em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord mathrm&quot;&gt;head&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;msupsub&quot;&gt;&lt;span class=&quot;vlist-t vlist-t2&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.3361em;&quot;&gt;&lt;span style=&quot;top:-2.55em;margin-right:0.05em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:2.7em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;sizing reset-size6 size3 mtight&quot;&gt;&lt;span class=&quot;mord mathnormal mtight&quot;&gt;h&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-s&quot;&gt;​&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.15em;&quot;&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;mclose&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;mord&quot;&gt;&lt;span class=&quot;mord mathnormal&quot; style=&quot;margin-right:0.1389em;&quot;&gt;W&lt;/span&gt;&lt;span class=&quot;msupsub&quot;&gt;&lt;span class=&quot;vlist-t&quot;&gt;&lt;span class=&quot;vlist-r&quot;&gt;&lt;span class=&quot;vlist&quot; style=&quot;height:0.8913em;&quot;&gt;&lt;span style=&quot;top:-3.113em;margin-right:0.05em;&quot;&gt;&lt;span class=&quot;pstrut&quot; style=&quot;height:2.7em;&quot;&gt;&lt;/span&gt;&lt;span class=&quot;sizing reset-size6 size3 mtight&quot;&gt;&lt;span class=&quot;mord mathnormal mtight&quot; style=&quot;margin-right:0.0278em;&quot;&gt;O&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;h2 id=&quot;位置编码&quot;&gt;位置编码&lt;/h2&gt;
&lt;pre class=&quot;astro-code astro-code-themes github-light github-dark&quot; style=&quot;background-color:#fff;--shiki-dark-bg:#24292e;color:#24292e;--shiki-dark:#e1e4e8; overflow-x: auto; white-space: pre-wrap; word-wrap: break-word;&quot; tabindex=&quot;0&quot; data-language=&quot;python&quot;&gt;&lt;code&gt;&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;def&lt;/span&gt;&lt;span style=&quot;color:#6F42C1;--shiki-dark:#B392F0&quot;&gt; positional_encoding&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;(pos, i, d_model):&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;    angle &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; pos &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;/&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; (&lt;/span&gt;&lt;span style=&quot;color:#005CC5;--shiki-dark:#79B8FF&quot;&gt;10000&lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt; **&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; (&lt;/span&gt;&lt;span style=&quot;color:#005CC5;--shiki-dark:#79B8FF&quot;&gt;2&lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt; *&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; (i &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;//&lt;/span&gt;&lt;span style=&quot;color:#005CC5;--shiki-dark:#79B8FF&quot;&gt; 2&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;) &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;/&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; d_model))&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;    return&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; math.sin(angle) &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;if&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; i &lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;%&lt;/span&gt;&lt;span style=&quot;color:#005CC5;--shiki-dark:#79B8FF&quot;&gt; 2&lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt; ==&lt;/span&gt;&lt;span style=&quot;color:#005CC5;--shiki-dark:#79B8FF&quot;&gt; 0&lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt; else&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; math.cos(angle)&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h2 id=&quot;我的疑问&quot;&gt;我的疑问&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;为什么正弦编码而不是可学习编码？论文说效果相近，但正弦能外推到更长序列。&lt;label class=&quot;note-wrap&quot;&gt;&lt;input type=&quot;checkbox&quot; class=&quot;note-toggle&quot; aria-label=&quot;展开批注&quot;&gt;&lt;span class=&quot;note-ref&quot;&gt;&lt;/span&gt;&lt;span class=&quot;note&quot;&gt;后来的 RoPE 和 ALiBi 都在改这一处。具身场景里位置往往是连续的物理量，&lt;span class=&quot;mark&quot;&gt;这个假设值得重新审视&lt;/span&gt;。&lt;/span&gt;&lt;/label&gt;&lt;/li&gt;
&lt;li&gt;后续工作（RoPE、ALiBi）如何改进？留待补充。&lt;/li&gt;
&lt;/ul&gt;</content:encoded><category>academic</category><category>transformer</category><category>attention</category><category>nlp</category></item><item><title>四足控制器 · 一：把问题说清楚</title><link>https://slackkai.github.io/astro-margin-notes/insight/quadruped-1/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/insight/quadruped-1/</guid><description>系列第一篇。为什么落地这个动作比走路难，以及我打算怎么拆。</description><pubDate>Sat, 05 Sep 2026 00:00:00 GMT</pubDate><content:encoded>&lt;h2 id=&quot;为什么是落地&quot;&gt;为什么是落地&lt;/h2&gt;
&lt;p&gt;走路是周期性的，落地是一次性的。没有稳态可以依赖，策略必须在几百毫秒里做对一件事。&lt;/p&gt;
&lt;h2 id=&quot;拆法&quot;&gt;拆法&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;仿真里先跑通。&lt;/li&gt;
&lt;li&gt;找出仿真和真机最大的三个差距。&lt;/li&gt;
&lt;li&gt;逐个补。&lt;/li&gt;
&lt;/ol&gt;</content:encoded><category>insight</category><category>robotics</category><category>rl</category><category>series</category></item><item><title>Deep Learning</title><link>https://slackkai.github.io/astro-margin-notes/library/deep-learning-book/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/library/deep-learning-book/</guid><pubDate>Tue, 01 Sep 2026 00:00:00 GMT</pubDate><content:encoded>&lt;h2 id=&quot;推荐章节&quot;&gt;推荐章节&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;第 5 章：机器学习基础&lt;/li&gt;
&lt;li&gt;第 8 章：优化&lt;/li&gt;
&lt;li&gt;第 10 章：序列模型&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id=&quot;笔记&quot;&gt;笔记&lt;/h2&gt;
&lt;p&gt;免费在线阅读。前三章数学复习非常好用。&lt;/p&gt;</content:encoded><category>library</category><category>deep-learning</category><category>textbook</category></item><item><title>四足机器人落地控制器</title><link>https://slackkai.github.io/astro-margin-notes/projects/quadruped-landing/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/projects/quadruped-landing/</guid><description>在 Isaac Lab 里训练一个能从空中落地并站稳的策略，然后部署到 Go2。</description><pubDate>Tue, 01 Sep 2026 00:00:00 GMT</pubDate><content:encoded>&lt;h2 id=&quot;目标&quot;&gt;目标&lt;/h2&gt;
&lt;p&gt;让四足机器人从 0.5m 高度落下后不翻倒，两秒内恢复站立。&lt;/p&gt;
&lt;h2 id=&quot;进度&quot;&gt;进度&lt;/h2&gt;
&lt;ul class=&quot;contains-task-list&quot;&gt;
&lt;li class=&quot;task-list-item&quot;&gt;&lt;input type=&quot;checkbox&quot; checked disabled&gt; 仿真环境与奖励设计&lt;/li&gt;
&lt;li class=&quot;task-list-item&quot;&gt;&lt;input type=&quot;checkbox&quot; checked disabled&gt; PPO 训练，成功率 92%&lt;/li&gt;
&lt;li class=&quot;task-list-item&quot;&gt;&lt;input type=&quot;checkbox&quot; disabled&gt; 真机部署&lt;/li&gt;
&lt;li class=&quot;task-list-item&quot;&gt;&lt;input type=&quot;checkbox&quot; disabled&gt; 域随机化对比实验&lt;/li&gt;
&lt;/ul&gt;</content:encoded><category>projects</category><category>robotics</category><category>rl</category><category>sim2real</category></item><item><title>八月小结</title><link>https://slackkai.github.io/astro-margin-notes/dailies/2026-08-31-august/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/dailies/2026-08-31-august/</guid><pubDate>Mon, 31 Aug 2026 00:00:00 GMT</pubDate><content:encoded>&lt;ul&gt;
&lt;li&gt;读完两本书。&lt;/li&gt;
&lt;li&gt;跑了 60 公里。&lt;/li&gt;
&lt;li&gt;开始整理资料库。&lt;/li&gt;
&lt;/ul&gt;</content:encoded><category>dailies</category><category>monthly</category></item><item><title>写作是思考的压缩</title><link>https://slackkai.github.io/astro-margin-notes/insight/writing-as-compression/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/insight/writing-as-compression/</guid><description>把一个想法写清楚，比把它想清楚更难，也更有用。</description><pubDate>Thu, 20 Aug 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;脑子里的想法是高维的、模糊的、随时会变的。写下来，就得选一个线性顺序、一组具体的词，于是模糊的部分被迫暴露出来。&lt;/p&gt;
&lt;p&gt;这也是为什么很多”我早就明白了”的东西，一落笔就写不下去。&lt;/p&gt;
&lt;h2 id=&quot;三个练习&quot;&gt;三个练习&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;一句话版本&lt;/strong&gt;：能不能用一句话说清楚？&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;反对者版本&lt;/strong&gt;：最强的反驳是什么？&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;例子版本&lt;/strong&gt;：有没有一个具体的例子？&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;写完这三个，想法通常已经和开始时不一样了。&lt;/p&gt;</content:encoded><category>insight</category><category>writing</category><category>thinking</category></item><item><title>Zotero</title><link>https://slackkai.github.io/astro-margin-notes/library/zotero/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/library/zotero/</guid><pubDate>Sat, 15 Aug 2026 00:00:00 GMT</pubDate><content:encoded>&lt;h2 id=&quot;我的配置&quot;&gt;我的配置&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Better BibTeX：自动导出 &lt;code&gt;.bib&lt;/code&gt;，citekey 用 &lt;code&gt;auth.lower + year&lt;/code&gt;。&lt;/li&gt;
&lt;li&gt;Zotfile：PDF 自动重命名并放到同步盘。&lt;/li&gt;
&lt;/ul&gt;</content:encoded><category>library</category><category>tool</category><category>research</category></item><item><title>CS231n: Deep Learning for Computer Vision</title><link>https://slackkai.github.io/astro-margin-notes/library/cs231n/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/library/cs231n/</guid><pubDate>Fri, 10 Jul 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;进度：Lecture 7。作业 2 做到一半。&lt;/p&gt;</content:encoded><category>library</category><category>course</category><category>computer-vision</category></item><item><title>The Bitter Lesson</title><link>https://slackkai.github.io/astro-margin-notes/library/bitter-lesson/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/library/bitter-lesson/</guid><pubDate>Sat, 20 Jun 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;一页纸的短文，但争议至今没停。&lt;/p&gt;</content:encoded><category>library</category><category>ai</category><category>essay</category></item><item><title>示例：一篇会议论文</title><link>https://slackkai.github.io/astro-margin-notes/academic/example-paper/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/academic/example-paper/</guid><description>这是一条“发表”类型的示例条目，用于展示 venue / links / bibtex 字段。</description><pubDate>Mon, 01 Jun 2026 00:00:00 GMT</pubDate><content:encoded>&lt;h2 id=&quot;摘要&quot;&gt;摘要&lt;/h2&gt;
&lt;p&gt;这是一篇虚构的主题演示条目，不代表站点作者的发表经历。实际使用时请替换或删除。&lt;/p&gt;
&lt;p&gt;把论文摘要或一段中文介绍放在这里。正文可以是对论文的补充说明、审稿意见回应、后续工作等。&lt;/p&gt;
&lt;h2 id=&quot;主要贡献&quot;&gt;主要贡献&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;第一点贡献。&lt;/li&gt;
&lt;li&gt;第二点贡献。&lt;/li&gt;
&lt;li&gt;第三点贡献。&lt;/li&gt;
&lt;/ol&gt;</content:encoded><category>academic</category><category>publication</category></item><item><title>桌面机械臂视觉抓取</title><link>https://slackkai.github.io/astro-margin-notes/projects/arm-grasp/</link><guid isPermaLink="true">https://slackkai.github.io/astro-margin-notes/projects/arm-grasp/</guid><description>用 RealSense 做位姿估计，六自由度小臂抓取桌面上的随机物体。</description><pubDate>Sun, 10 May 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;课程项目，已归档。留着当参考。&lt;/p&gt;</content:encoded><category>projects</category><category>robotics</category><category>vision</category></item></channel></rss>