<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
    <channel>
        <title>Apple Dictionary on Jingyuan</title>
        <link>https://jingyuan-zheng.github.io/tags/apple-dictionary/</link>
        <description>Recent content in Apple Dictionary on Jingyuan</description>
        <generator>Hugo -- gohugo.io</generator>
        <language>en-US</language>
        <copyright>Jingyuan Zheng</copyright>
        <lastBuildDate>Sat, 08 Aug 2026 14:00:00 +0200</lastBuildDate><atom:link href="https://jingyuan-zheng.github.io/tags/apple-dictionary/index.xml" rel="self" type="application/rss+xml" /><item>
            <title>Convert MDX Dictionaries to macOS Dictionary with an Agent Skill</title>
            <link>https://jingyuan-zheng.github.io/p/mdx-to-macos-dictionary-skill/</link>
            <pubDate>Sat, 08 Aug 2026 14:00:00 +0200</pubDate>
            <guid>https://jingyuan-zheng.github.io/p/mdx-to-macos-dictionary-skill/</guid>
            <description>&lt;p&gt;This post introduces &lt;strong&gt;MDX to macOS Dictionary&lt;/strong&gt;, an open-source Agent Skill that turns local MDict &lt;code&gt;.mdx&lt;/code&gt; dictionaries into searchable native macOS &lt;code&gt;.dictionary&lt;/code&gt; bundles and ready-to-install DMG files.&lt;/p&gt;&#xA;&lt;p&gt;MDX is a popular format for dictionary data, but macOS Dictionary.app cannot use an &lt;code&gt;.mdx&lt;/code&gt; file directly. Converting one usually means preparing XML, compiling it with Apple&amp;rsquo;s Dictionary Development Kit, preserving styles, and packaging the result. This skill brings those steps into one guided workflow.&lt;/p&gt;&#xA;&lt;h2 id=&#34;what-the-skill-creates&#34;&gt;What the skill creates&#xA;&lt;/h2&gt;&lt;p&gt;Give a supported coding agent a local &lt;code&gt;.mdx&lt;/code&gt; file or dictionary folder, and the skill can:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;extract the dictionary entries from MDX;&lt;/li&gt;&#xA;&lt;li&gt;convert them into Apple&amp;rsquo;s searchable dictionary format;&lt;/li&gt;&#xA;&lt;li&gt;preserve companion CSS when it is available;&lt;/li&gt;&#xA;&lt;li&gt;use a supplied cover or logo as the dictionary icon;&lt;/li&gt;&#xA;&lt;li&gt;build a drag-to-install DMG installer;&lt;/li&gt;&#xA;&lt;li&gt;install the finished dictionary in &lt;code&gt;~/Library/Dictionaries/&lt;/code&gt; when requested.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;The original MDX, CSS, JavaScript, and MDD files are left untouched. The result is a native dictionary that can be enabled in Dictionary.app and used from macOS features such as Spotlight and Look Up.&lt;/p&gt;&#xA;&lt;h2 id=&#34;why-convert-an-mdx-dictionary&#34;&gt;Why convert an MDX dictionary?&#xA;&lt;/h2&gt;&lt;p&gt;An MDX dictionary is convenient to share between compatible dictionary applications, but it is separate from the dictionary service built into macOS. A native &lt;code&gt;.dictionary&lt;/code&gt; bundle fits more naturally into the Mac:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;search entries from Dictionary.app;&lt;/li&gt;&#xA;&lt;li&gt;use macOS&amp;rsquo;s Look Up feature on selected text;&lt;/li&gt;&#xA;&lt;li&gt;access the dictionary from Spotlight where supported;&lt;/li&gt;&#xA;&lt;li&gt;keep several dictionaries together in the system&amp;rsquo;s own dictionary folder;&lt;/li&gt;&#xA;&lt;li&gt;install the result from a familiar DMG window.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;This is useful for language learners, researchers, translators, and anyone who already owns a useful MDX dictionary and wants it to feel like part of macOS.&lt;/p&gt;&#xA;&lt;h2 id=&#34;install-the-agent-skill&#34;&gt;Install the Agent Skill&#xA;&lt;/h2&gt;&lt;p&gt;The skill is available on GitHub:&lt;/p&gt;&#xA;&lt;p&gt;&lt;a class=&#34;link&#34; href=&#34;https://github.com/Jingyuan-Zheng/mdx-to-macos-dictionary-skill&#34;  target=&#34;_blank&#34; rel=&#34;noopener&#34;&#xA;    &gt;Jingyuan-Zheng/mdx-to-macos-dictionary-skill&lt;/a&gt;&lt;/p&gt;&#xA;&lt;p&gt;If you use a compatible coding agent, install it with:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;div class=&#34;chroma&#34;&gt;&#xA;&lt;table class=&#34;lntable&#34;&gt;&lt;tr&gt;&lt;td class=&#34;lntd&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code&gt;&lt;span class=&#34;lnt&#34;&gt;1&#xA;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td class=&#34;lntd&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;npx skills add Jingyuan-Zheng/mdx-to-macos-dictionary-skill --agent codex&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&lt;p&gt;After installation, ask the agent to convert a local &lt;code&gt;.mdx&lt;/code&gt; file or folder. The skill checks the Mac&amp;rsquo;s prerequisites first and explains what needs attention before starting the conversion.&lt;/p&gt;&#xA;&lt;h2 id=&#34;what-the-conversion-looks-like&#34;&gt;What the conversion looks like&#xA;&lt;/h2&gt;&lt;p&gt;The workflow is designed to keep the complicated parts together:&lt;/p&gt;&#xA;&lt;ol&gt;&#xA;&lt;li&gt;Select a local MDX dictionary and any companion CSS, JS, MDD, cover, or logo files.&lt;/li&gt;&#xA;&lt;li&gt;Let the skill check the required macOS tools.&lt;/li&gt;&#xA;&lt;li&gt;It extracts the entries and builds the native Apple Dictionary data.&lt;/li&gt;&#xA;&lt;li&gt;It verifies the finished &lt;code&gt;.dictionary&lt;/code&gt; bundle and creates a DMG installer.&lt;/li&gt;&#xA;&lt;li&gt;The dictionary can then be copied into the user&amp;rsquo;s Dictionary folder and enabled in Dictionary.app.&lt;/li&gt;&#xA;&lt;/ol&gt;&#xA;&lt;p&gt;You can request an output-only conversion if you do not want the skill to install anything. Otherwise, it installs the completed bundle in the current user&amp;rsquo;s &lt;code&gt;~/Library/Dictionaries/&lt;/code&gt; folder. An existing dictionary with the same name is not replaced without approval.&lt;/p&gt;&#xA;&lt;h2 id=&#34;what-you-need-on-the-mac&#34;&gt;What you need on the Mac&#xA;&lt;/h2&gt;&lt;p&gt;The project runs on macOS and uses Apple&amp;rsquo;s dictionary-building tools. Depending on the Mac and the source dictionary, it may require:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Python 3;&lt;/li&gt;&#xA;&lt;li&gt;Xcode Command Line Tools;&lt;/li&gt;&#xA;&lt;li&gt;Rosetta on Apple Silicon Macs;&lt;/li&gt;&#xA;&lt;li&gt;Homebrew&amp;rsquo;s &lt;code&gt;create-dmg&lt;/code&gt; tool.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;The skill checks these requirements before processing a dictionary. It can also obtain the open-source components it needs, including &lt;code&gt;mdict-utils&lt;/code&gt;, Apple&amp;rsquo;s Dictionary Development Kit, and &lt;a class=&#34;link&#34; href=&#34;https://github.com/Jingyuan-Zheng/dmg-maker&#34;  target=&#34;_blank&#34; rel=&#34;noopener&#34;&#xA;    &gt;DMG Maker&lt;/a&gt;, while keeping the conversion work inside a separate working directory.&lt;/p&gt;&#xA;&lt;h2 id=&#34;from-a-finished-dictionary-to-everyday-use&#34;&gt;From a finished dictionary to everyday use&#xA;&lt;/h2&gt;&lt;p&gt;After installation, open &lt;strong&gt;Dictionary.app&lt;/strong&gt;, choose &lt;strong&gt;Dictionary → Settings&lt;/strong&gt; (or &lt;strong&gt;Dictionary → Preferences&lt;/strong&gt; on older macOS versions), and enable the new dictionary. You can change its position in the list to control which source appears first.&lt;/p&gt;&#xA;&lt;p&gt;Once enabled, select a word in a supported Mac app and use &lt;strong&gt;Look Up&lt;/strong&gt;, or open Dictionary.app and search normally. With a compatible trackpad, you can also tap the selected word with three fingers. On a Force Touch trackpad, you can press firmly instead, using &lt;strong&gt;Force Click&lt;/strong&gt;. These gestures use the &lt;strong&gt;Look Up &amp;amp; data detectors&lt;/strong&gt; option in &lt;strong&gt;System Settings → Trackpad&lt;/strong&gt;; the available choice depends on your Mac and macOS version. Apple documents the gesture options in &lt;a class=&#34;link&#34; href=&#34;https://support.apple.com/en-gb/guide/mac-help/mchl3983326c/mac&#34;  target=&#34;_blank&#34; rel=&#34;noopener&#34;&#xA;    &gt;Look up words on Mac&lt;/a&gt;.&lt;/p&gt;&#xA;&lt;h2 id=&#34;two-open-source-dictionaries-from-my-projects&#34;&gt;Two open-source dictionaries from my projects&#xA;&lt;/h2&gt;&lt;p&gt;This Skill is meant to make projects like these easier to package and share. I have already written about two Mac dictionaries built from open dictionary data:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;a class=&#34;link&#34; href=&#34;https://jingyuan-zheng.github.io/zh/p/the-little-dict-macos/&#34; &gt;The Little Dict Mac 版&lt;/a&gt; — a large English dictionary converted from MDX into Apple&amp;rsquo;s native &lt;code&gt;.dictionary&lt;/code&gt; format, with support for Dictionary.app and trackpad Look Up.&lt;/li&gt;&#xA;&lt;li&gt;&lt;a class=&#34;link&#34; href=&#34;https://jingyuan-zheng.github.io/p/introducing-%c4%a1abra-a-native-maltese-dictionary-for-macos/&#34; &gt;Ġabra Maltese Dictionary for macOS&lt;/a&gt; — an open-source Maltese dictionary with millions of inflected forms, packaged for Dictionary.app, Spotlight, and three-finger or Force Click Look Up.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;They show the practical result of the conversion workflow: a dictionary is no longer just a file to open in a separate reader, but a source that can participate in the Mac&amp;rsquo;s built-in lookup experience.&lt;/p&gt;&#xA;&lt;h2 id=&#34;how-it-works&#34;&gt;How it works&#xA;&lt;/h2&gt;&lt;p&gt;The skill uses &lt;code&gt;mdict-utils&lt;/code&gt; to read the MDX entries, converts them to the XML structure expected by Apple&amp;rsquo;s Dictionary Development Kit, and compiles that data into a &lt;code&gt;.dictionary&lt;/code&gt; bundle. It validates the generated XML and checks that the bundle contains the indexes, metadata, stylesheet, and dictionary body before packaging it.&lt;/p&gt;&#xA;&lt;p&gt;The project is MIT licensed and available on &lt;a class=&#34;link&#34; href=&#34;https://github.com/Jingyuan-Zheng/mdx-to-macos-dictionary-skill&#34;  target=&#34;_blank&#34; rel=&#34;noopener&#34;&#xA;    &gt;GitHub&lt;/a&gt;. For the DMG packaging step itself, see &lt;a class=&#34;link&#34; href=&#34;https://jingyuan-zheng.github.io/p/dmg-maker-create-beautiful-macos-installers-automatically/&#34; &gt;DMG Maker&lt;/a&gt;.&lt;/p&gt;&#xA;</description>
        </item></channel>
</rss>
