如何为您的博客文章获取DOI

Lobsters Hottest 工具

摘要

本文提供了一份指南,介绍如何为博客文章获取数字对象标识符(DOI),以提高其在学术研究中的可引用性,讨论了方法、好处和潜在问题。

<p><a href="https://lobste.rs/s/lvld5b/how_get_doi_for_your_blog_posts">评论</a></p>
查看原文
查看缓存全文

缓存时间: 2026/09/16 17:28

# 如何为您的博客文章获取数字对象标识符 来源:https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/ 本博客的每篇新文章现在都拥有一个数字对象标识符(https://www.doi.org/)。本文将探讨获取DOI的方法与原因、其效用,以及选择此路径可能遇到的问题。 ## 目录 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#table-of-contents) 背景 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#background) 获取DOI的简易途径 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#getting-a-doi-the-easy-way) 让我们开始探索! (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#lets-go-rogue) 新内容的自动提交 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#automatic-submission-of-new-content) 旧内容的手动提交 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#manual-submission-of-old-content) 获取DOI (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#getting-the-doi) 自行生成DOI (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#generating-your-own-doi) 在HTML中让DOI可被发现 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#making-the-doi-discoverable-in-html) 缺点 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#downsides) 控制权的丧失 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#loss-of-control) 追踪引用 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#tracking-citations) 许可证问题 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#licencing) 内容验证 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#verification) 排除内容 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#excluding-content) 删除内容 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#deleting-content) 机构关联 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#affiliations) 更多的自我展示 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#more-vanity) 保持谦逊 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#humility) 值得吗? (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#is-it-worth-it) ## 背景 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#background) 几年前,我曾记录过如何为博客获取国际标准连续出版物号 (https://shkspr.mobi/blog/2021/09/how-to-add-issn-metadata-to-a-web-page/)。国际标准连续出版物号能唯一标识一份出版物,使学者和研究人员更易引用。获取它在一定程度上取决于国家机构是否愿意受理你的申请。类似地,我还获取了一个 ORCiD (https://orcid.org/),用于唯一标识研究者。这意味着,可以区分“爱因斯坦,A”(杰出物理学家)和“爱因斯坦,A”(一位在巴拉圭研究入侵蛞蝓的友善人士艾伦)。我的博客文章 (https://shkspr.mobi/blog/citations/) 经常被学术论文、书籍、会议和新闻文章引用。大多数学者引用作品的方式是使用数字对象标识符。其理念在于,DOI是一个唯一且持久的代码,可用于引用特定文章。即使我停止使用`shkspr.mobi`作为我的域名,或重组网站,DOI也能被重定向到文章的新位置。未来的学者将能更容易地跟踪引用,而无需寄望于`https://example.com/article123`仍然存在。 ## 获取DOI的简易途径 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#getting-a-doi-the-easy-way) 如果您是学术人员,您的机构通常会订阅一项付费服务,为您的所有文章“铸造”新的DOI。如果不是,您可以将论文上传到 arXiv 等服务,它们会为您铸造DOI。我就是这样 (https://shkspr.mobi/blog/2023/04/i-got-a-doi-from-arxiv-for-my-msc/) 为我的硕士学位论文获得DOI的。那么,非传统学术人士或希望将内容保留在自己网站上的人该怎么办呢?有多种付费服务,有些会收取高昂的费用为您创建DOI。或者,还有 Rogue Scholar。 ## 让我们开始探索! (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#lets-go-rogue) 那么,Rogue-Scholar.org (https://rogue-scholar.org/overview) 是什么? > Rogue Scholar 是一个面向科学博客的开放获取档案库和注册表。它保存科学博客文章,使其可通过DOI被引用,并确保其与正式学术文献一同被长期发现。 很棒!我的博客*勉强*符合其“计算机科学”类别。他们要求您提供文章的全文订阅源。您还需要将内容以知识共享署名许可证授权给他们。申请过程不算太难。我填写了他们的表格,然后加入他们的Slack。我们稍微讨论了一下我需要做出哪些改变才能获得批准。几天后,我就上线了,地址是 https://rogue-scholar.org/communities/shkspr/。这意味着,如果您访问 https://doi.org/10.59350/395ha-fss97,将被重定向到我的一篇博客文章。 ## 新内容的自动提交 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#automatic-submission-of-new-content) Rogue Scholar 会自动轮询我的订阅源,摄取我的内容,然后为遇到的每篇新文章铸造DOI。我无需进行任何手动操作。这对新内容来说非常好。但我这里的文章*可以追溯到*1986年。它们如何被发现并获得DOI呢? ## 旧内容的手动提交 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#manual-submission-of-old-content) 默认情况下,Rogue Scholar 从我的博客摄取了最近的40篇文章。实际上,这并不完全准确。它获取的是40篇最近*更新*的文章。因为我最近编辑了几篇较旧的文章,所以它们获得了DOI。我不知道 Rogue Scholar 多久轮询一次我的博客订阅源。根据我的测试,发布新文章后几分钟内就能获得DOI。目前,似乎没有简单的方法来添加较旧的内容。我正在开发一个WordPress插件,用于追溯性地添加DOI并使其可被发现。 ## 获取DOI (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#getting-the-doi) Rogue Scholar API 基于 InvenioDRM (https://inveniordm.docs.cern.ch/reference/metadata/)。通过其API检索DOI需要进行一个无需认证的请求到: `https://rogue-scholar.org/api/records?q=metadata.identifiers.identifier%3A%22https%3A%2F%2Fexample.com%2Fwhatever%22` 即您的URL(用引号包裹),整个字符串进行URL编码。查看此示例 (https://rogue-scholar.org/api/records?q=metadata.identifiers.identifier%3A%22https%3A%2F%2Fshkspr.mobi%2Fblog%2F2026%2F09%2Fthe-purpose-of-dns-is-to-spread-scams%2F%22)。您也可以使用文章的GUID。返回的JSON文档相当详细。DOI在多个位置都有标注,但最容易找到的位置是 hits→hits→0→links→doi。 需要注意的是,Rogue Scholar 会为您的文章生成*两个*DOI (https://rogue-scholar.org/help/versioning)。一个是文章的DOI,另一个是文章特定版本的DOI。如果您更新文章,它应该会获得一个新的DOI。这样,有人就可以引用您说您最爱乐队是辣妹组合的那个版本,而不是您将其修改为B*Witched的那个版本。 或者,如果您想查看HTML结果,可以使用 CrossRef 搜索。参见此 CrossRef 示例 (https://search.crossref.org/search/works?q=https%3A%2F%2Fshkspr.mobi%2Fblog%2F2026%2F09%2Fthe-purpose-of-dns-is-to-spread-scams%2F&from_ui=yes)。 顺便提一下,一旦您有了DOI,可以在 https://shortdoi.org/ 创建一个*短*DOI。坦白说,我从未在实际中见过它们,并且它们 (https://www.crossref.org/display-guidelines/#shortdoi) 并不推荐使用。尽管如此,API相当简单 - `https://shortdoi.org/10.59350/395ha-fss97?format=json` 将返回一个更短的URL,如 `https://doi.org/rnjj`。 最后,还有一个整个博客的“展示”DOI。在我的例子中是 `10.59350/shkspr` (https://doi.org/10.59350/shkspr)。 ## 自行生成DOI (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#generating-your-own-doi) 您的博客文章可以自行声明DOI - 当 Rogue Scholar 在您的Atom订阅源中看到它时,会代您注册。生成有效DOI (https://github.com/inveniosoftware/base32-lib/blob/master/base32_lib/base32.py) 的代码相对简单。 - 在0到1,099,511,627,775之间生成一个随机数。 - 将其转换为Base 32字符串。 - 在末尾添加两位校验码。 - 加上前缀 `10.59350/` 您可以通过在文章中添加以下内容,使新DOI在Atom订阅源中被发现: ```xml <id>https://doi.org/10.59350/12345-67890</id> ``` 发布后不久,它就会被“铸造”并可链接。 ## 在HTML中让DOI可被发现 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#making-the-doi-discoverable-in-html) 如何从语义上将DOI添加到HTML的元数据中?迄今为止,最流行的引用管理器是 Zotero (https://www.zotero.org/)。他们维护着一个页面 (https://www.zotero.org/support/dev/exposing_metadata),描述他们寻找的元数据。根据他们的说明,这需要在页面的 `<head>` 中: ```html <meta name="citation_doi" content="10.1234/5678"> ``` 他们没有说明是否需要 `https://doi.org/` 前缀 - 但查看 Mendeley (https://www.mendeley.com/guides/information-for-publishers) 和 AltMetric (https://help.altmetric.com/en/articles/9806913),似乎不需要。 要使用 DublinCore (https://www.dublincore.org/specifications/dublin-core/dcmi-terms/terms/identifier/),AltMetric 推荐的语法 (https://help.altmetric.com/en/articles/9803009) 是: ```html <link rel="identifier" href="https://doi.org/10.1234/5678" /> ``` 在HTML中,没有特定的微数据语法,但 Schema.org (https://schema.org/ScholarlyArticle#eg-0399) 建议使用 `sameAs` 属性。类似这样: ```html <div itemprop="sameAs" content="https://doi.org/10.1234/5678"></div> ``` ## 缺点 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#downsides) 好吧,这并非全是鲜花和阳光。在您选择这条道路之前,有几件事情您应该知道。 ### 控制权的丧失 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#loss-of-control) 对于独立网络 (IndieWeb) / 重新去中心化 (ReDeCentralise) / 自托管 (Self-Hosting) 群体来说,重要的是要意识到DOI是一个某种程度上中心化的服务。是的,许多不同的组织都可以铸造DOI (https://www.doi.org/the-community/existing-registration-agencies/),但由于每个ID必须是全局唯一的,doi.org 作为善意的守门人居于中间。如果DOI.org倒闭或变坏,所有 `https://doi.org/10....` 链接都将失效。还有许多其他服务可以解析DOI,例如 DataCite (https://datacite.org/) 和 CrossRef (https://www.crossref.org/),但这可能有点脆弱。同样,如果 Rogue Scholar 真的*变得不可靠*,他们可以将我的DOI重定向到他们喜欢的任何地方。这种控制级别在我不复存在时是有用的;他们可以重定向到一个存档。但如果他们被黑客攻击,就可能重定向到不合适的地方。将我的网站内容备份在某处是有用的,但同样,没有控制权或验证 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#verification),我担心可能无法有效管理它。我使用CSS控制我作品的布局,但一旦存档为纯HTML或PDF,这种格式就可能消失。我不知道如果我更换DOI颁发者会发生什么。 ### 追踪引用 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#tracking-citations) 我为我的域名 `shkspr.mobi` 设置了谷歌学术警报。这能发现引用本站点的人。太好了!但是,如果他们使用 `https://doi.org/10....` 而不是 `https://shkspr.mobi/...`,我将不会收到警报。幸运的是,Rogue Scholar 提供了引用跟踪服务 (https://doi.org/10.53731/zyg15-qv911),*应该*会自动在其API中填充来自其他来源的任何反向链接。我还没弄清楚这在实践中是如何运作的。我不认为它会给我发邮件警报。 在自我展示方面,DOI元数据显示我文章的发布者是 Rogue Scholar 的母公司 - Front Matter (https://front-matter.de/)。如果您查看 https://api.crossref.org/works/10.59350/5ck9b-kjv69 的API响应,您会看到类似的内容: ```json { "message": { "institution": [ { "name": "Front Matter" } ], "group-title": "Terence Eden's Blog", "publisher": "Front Matter", "DOI": "10.59350/5ck9b-kjv69", "author": [ { "ORCID": "https://orcid.org/0000-0002-9265-9069", "given": "Terence", "family": "Eden" } ] } } ``` 一些引用管理器会将出版物名称显示为“Terence Eden's Blog” - 其他的则显示为“Front Matter”。 ### 许可证问题 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#licencing) Rogue Scholar 的硬性要求是所有内容必须采用知识共享署名许可证 (CC BY)。目前(还没有)能力选择不同的许可证。就个人而言,我更喜欢知识共享署名-相同方式共享 (CC BY-SA)。我已经允许 Rogue Scholar 为我的作品使用 CC BY,当然,这意味着如果您通过他们获取我的文章,您也被允许使用 CC BY。如果您通过我自己的网站获取我的作品,则采用限制稍多的 CC BY-SA。这会造成实际差异吗?我不知道。 ### 内容验证 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#verification) DOI是持久的。这并不意味着它是可验证的。如果这个博客下线,DOI将重定向到存档 - 但无法真正判断该存档中的文本是否准确。没有哈希或加密签名。是的,这些东西相当脆弱,但我认为这对于引用链的长期完整性会有所帮助。 ### 排除内容 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#excluding-content) 假设有一些内容您*不希望*获得DOI,您该怎么办?您需要生成一个排除这些特定文章的RSS订阅源。对于WordPress,您可以使用类似 `/feed/atom/?cat=-1234` 的方式来排除分类ID为1234的文章。Rogue Scholar 网站上也有一些过滤器,您或许也可以使用。 ### 删除内容 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#deleting-content) 我认为目前还没有办法从 Rogue Scholar 的DOI系统中删除或撤回内容。如果您不小心发布了本无意发布的东西,它将永远存在于存档中。 ### 机构关联 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#affiliations) 我的 ORCiD 列出了我在某些日期工作的地方。最初,Rogue Scholar 将这些与我任职期间撰写的博客文章联系起来。然而,我所有的文章都是以个人身份撰写的。如果这些关联不准确,可以申请移除。 ### 更多的自我展示 (https://shkspr.mobi/blog/2026/09/how-to-get-a-doi-for-your-blog-posts/#more-vanity) 我最初尝试生成像 `edent-00f47` 这样的DOI - 虽然它是一个带校验码的有效Base 32字符串,但它带有语义含义(我的名字),所以真的不应该使用。好吧!回到随机字符串。

相似文章

学术界的D-index衡量竞赛

Hacker News Top

本文批判了学术界对可量化指标的过度依赖,例如引用计数和指数,并探讨了Research.com引入的D-index作为另一个有问题的衡量标准。

DIDs 很酷,但我们并不需要它们

Hacker News Top

In a Moon 认为,尽管去中心化标识符(DID)在技术上是优雅的,但它们的用例并不需要它们——相反,选择了一个更简单的“主体”原语(命名空间:ID),该原语利用了已经嵌入在网页内容中的现有网络身份系统,例如 GitHub 用户名和电子邮件地址。

用机器重建我的博客,为机器服务·

Lobsters Hottest

作者重建了博客,加入了完整的结构化数据标记(JSON-LD、微格式),并配备了一个由提示词引导的AI协作写作助手,该提示词避免了常见的LLM模式,同时通过CI验证防止数据损坏。