<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Arthur Farias on Medium]]></title>
        <description><![CDATA[Stories by Arthur Farias on Medium]]></description>
        <link>https://medium.com/@afarias.arthur?source=rss-a5588e96d369------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*tmc31MWUGmRQ_AtT</url>
            <title>Stories by Arthur Farias on Medium</title>
            <link>https://medium.com/@afarias.arthur?source=rss-a5588e96d369------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 27 Nov 2026 23:14:53 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@afarias.arthur/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Parsing Made Easy with C++: A Boost Spirit-Like Approach]]></title>
            <link>https://medium.com/@afarias.arthur/building-a-grammar-with-c-ece5955efebe?source=rss-a5588e96d369------2</link>
            <guid isPermaLink="false">https://medium.com/p/ece5955efebe</guid>
            <category><![CDATA[softforge]]></category>
            <category><![CDATA[peg]]></category>
            <category><![CDATA[grammar]]></category>
            <category><![CDATA[cpp]]></category>
            <dc:creator><![CDATA[Arthur Farias]]></dc:creator>
            <pubDate>Fri, 27 Nov 2026 22:30:30 GMT</pubDate>
            <atom:updated>2026-11-27T22:31:44.735Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>Soft Forge — Experiments</strong></p><p>I wonder if you have already tried using Boost Spirit and its Parsing Expression Grammars. If so, you probably know how powerful it can be. However, you may also have experienced how difficult it is to get started with its underlying mechanisms.</p><p>In Boost, I found that getting started with the complexity of its implementation was rather prohibitive. Compiler errors aren’t particularly easy to understand either, especially when dealing with complex template instantiations.</p><p>I started wondering whether we could achieve the same conceptual approach with a much simpler implementation, using only the C++ Standard Library.</p><p>That question became the starting point for an experimental project: building a parsing expression grammar infrastructure using C++ templates.</p><h3>Starting with the simplest possible grammar</h3><p>I decided to start with something considerably simpler than parsing an entire programming language.</p><p>The main file is actually a realization of one of the simplest things in Lisp: parsing a function call.</p><p>Consider the following expression:</p><pre>(fn 1 &quot;hello&quot;)</pre><p>We have a function identifier followed by two arguments: an integer and a string.</p><p>The implementation looks like this:</p><pre>#include &lt;cctype&gt;<br>#include &lt;iostream&gt;<br>#include &lt;sstream&gt;<br>#include &lt;streambuf&gt;<br>#include &lt;string&gt;<br>#include &lt;string_view&gt;<br>#include &lt;utility&gt;<br>#include &lt;vector&gt;</pre><pre>#include &lt;cx/language/and_.hpp&gt;<br>#include &lt;cx/language/any_token.hpp&gt;<br>#include &lt;cx/language/detail/to_char_type.hpp&gt;<br>#include &lt;cx/language/expression.hpp&gt;<br>#include &lt;cx/language/identifier.hpp&gt;<br>#include &lt;cx/language/literal.hpp&gt;<br>#include &lt;cx/language/not_.hpp&gt;<br>#include &lt;cx/language/optional.hpp&gt;<br>#include &lt;cx/language/repeat.hpp&gt;<br>#include &lt;cx/language/rule.hpp&gt;<br>#include &lt;cx/language/space.hpp&gt;<br>#include &lt;cx/language/seq_parser.hpp&gt;<br>int main() {<br>  using namespace cx::language;<br>  std::string str = R&quot;((fn 1 &quot;hello&quot;))&quot;;<br>  std::istringstream ss{str};<br>  expression expr;<br>  auto argument_rule = and_{not_{literal{&quot;)&quot;}}, any_token&lt;&gt;{}};<br>  auto grammar =<br>      rule{literal{&quot;(&quot;} &gt;&gt; optional{space{}} &gt;&gt; identifier{&quot;fn&quot;} &gt;&gt;<br>           optional{space{}} &gt;&gt; repeat{argument_rule &gt;&gt; optional{space{}}} &gt;&gt;<br>           literal{&quot;)&quot;}};<br>  if (ss &gt;&gt; (grammar &gt;&gt; expr)) {<br>    std::cout &lt;&lt; &quot;Parsed successfully! Tokens:\n&quot;;<br>    for (const auto &amp;tok : expr)<br>      std::cout &lt;&lt; &quot;  - &quot; &lt;&lt; tok.value &lt;&lt; &#39;\n&#39;;<br>  } else {<br>    std::cout &lt;&lt; &quot;Failed to parse.\n&quot;;<br>  }<br>  return 0;<br>}</pre><p>The interesting part is how little code is actually needed to describe the grammar.</p><h3>Thinking in grammar expressions</h3><p>I define and_ and the expression syntax to compose parsing expressions and accomplish tokenization.</p><p>For example, consider the argument rule:</p><pre>auto argument_rule = and_{not_{literal{&quot;)&quot;}}, any_token&lt;&gt;{}};</pre><p>Here, we combine two expressions. The first uses not_ to check that the next input is not a closing parenthesis. The second consumes the next token.</p><p>Together, they describe an argument that must not begin with the closing delimiter.</p><p>Then we compose the complete grammar:</p><pre>auto grammar =<br>    rule{literal{&quot;(&quot;} &gt;&gt; optional{space{}} &gt;&gt; identifier{&quot;fn&quot;} &gt;&gt;<br>         optional{space{}} &gt;&gt; repeat{argument_rule &gt;&gt; optional{space{}}} &gt;&gt;<br>         literal{&quot;)&quot;}};</pre><p>Each expression has a specific responsibility:</p><ul><li>literal recognizes a literal sequence.</li><li>identifier recognizes an identifier.</li><li>optional makes an expression optional.</li><li>repeat allows an expression to be repeated.</li><li>and_ combines expressions sequentially.</li><li>not_ provides negative lookahead.</li><li>rule establishes a grammar rule.</li></ul><p>The &gt;&gt; operator allows us to compose these expressions in the order they should be recognized.</p><p>I think this is one of the most interesting aspects of the approach. Instead of implementing a parser specifically for each language, we describe the language through reusable grammar expressions.</p><h3>Why this matters beyond C++</h3><p>The great part of this library is that we can make it easy to parse other file formats by defining only their grammar expressions.</p><p>Take JSON, for example. JSON itself defines its grammar in just a few pages of documentation. We already have a formal description of objects, arrays, strings, numbers, and literals.</p><p>The idea is to translate those grammatical definitions into expressions using the same infrastructure.</p><p>This means we could implement JSON parsing without having to develop an entirely new parsing engine. We would only need to define its grammar.</p><p>The same approach could be applied to configuration files, domain-specific languages, protocol descriptions, and other structured data formats.</p><h3>Why I think C++ needs this</h3><p>In my perspective, this is the correct direction for parsing data, given the technological background we already have nowadays.</p><p>C++ has excellent abstractions for containers, algorithms, iterators, and compile-time computation. However, I think it still lacks an approachable and really useful way to express grammars directly in the language.</p><p>We shouldn’t need to fight complex parser implementations every time we want to describe a new data format.</p><p>The objective is to make grammar definitions readable, composable, reusable, and easy to maintain.</p><p>I believe C++ templates provide a very interesting foundation for achieving this, without introducing additional dependencies or requiring an external parsing framework.</p><h3>An experiment in progress</h3><p>This project is still experimental. What I have here are the first steps toward that idea, starting with elementary parsing expressions, tokenization, and grammar composition.</p><p>The whole repository is the result of this attempt.</p><p>I would like to explore how far we can take this concept while keeping the implementation simple and entirely based on the C++ Standard Library.</p><p><strong>The idea is simple: describe the grammar, compose its expressions, and let the parser do the work.</strong></p><p>I think parsing should be about describing a language, not fighting the machinery required to recognize it.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ece5955efebe" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[The Economics of Artificial Intelligence]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-snippet">Personally, I cannot write a million lines of code in a few seconds. Nobody can. It is physically impossible for an individual to compete&#x2026;</p><p class="medium-feed-link"><a href="https://medium.com/@afarias.arthur/the-economics-of-artificial-intelligence-d0c2371d8b39?source=rss-a5588e96d369------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://medium.com/@afarias.arthur/the-economics-of-artificial-intelligence-d0c2371d8b39?source=rss-a5588e96d369------2</link>
            <guid isPermaLink="false">https://medium.com/p/d0c2371d8b39</guid>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[economics]]></category>
            <dc:creator><![CDATA[Arthur Farias]]></dc:creator>
            <pubDate>Sat, 07 Nov 2026 10:48:02 GMT</pubDate>
            <atom:updated>2026-11-07T10:48:02.090Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[Meet UI Designer: A New Way to Design User Interfaces Without Leaving VS Code]]></title>
            <link>https://medium.com/@afarias.arthur/meet-ui-designer-a-new-way-to-design-user-interfaces-without-leaving-vs-code-edf354523e1b?source=rss-a5588e96d369------2</link>
            <guid isPermaLink="false">https://medium.com/p/edf354523e1b</guid>
            <category><![CDATA[ui]]></category>
            <category><![CDATA[ui-design]]></category>
            <category><![CDATA[vscode]]></category>
            <category><![CDATA[ai]]></category>
            <dc:creator><![CDATA[Arthur Farias]]></dc:creator>
            <pubDate>Sat, 24 Oct 2026 12:09:59 GMT</pubDate>
            <atom:updated>2026-10-24T13:54:28.603Z</atom:updated>
            <content:encoded><![CDATA[<p><em>What if your interface design tool lived alongside your source code, shared your repository, and could be operated by both you and your AI coding agents?</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/960/0*UpkfRI38pMIhNe4n.gif" /></figure><p>For years, designing a user interface and implementing it have been two separate activities. Designers create mockups in one application, developers reproduce them in another, and the original design gradually drifts away from the actual implementation.</p><p><strong>UI Designer takes a different approach: bring interface design directly into Visual Studio Code.</strong></p><p>UI Designer is a vector-based interface design editor built to run inside VS Code. It lets you draw screens, organize components, define layouts, prototype interactions, and hand designs off to code — all within the environment where you build your software.</p><p>Explore the guide: <a href="https://soft-forge.dev/vscode-extension-ui-designer/guide/">https://soft-forge.dev/vscode-extension-ui-designer/guide/</a></p><h3>Design where your code lives</h3><p>The central idea behind UI Designer is simple: your design should be part of your development workflow, not an isolated artifact sitting somewhere else.</p><p>Instead of maintaining a separate design project, you can keep a .design file directly in your repository. This brings interface design closer to the source code, making it easier to version, review, share, and evolve alongside the application.</p><p>The result is a more connected workflow between product design and software engineering.</p><h3>A complete visual design environment</h3><p>UI Designer goes beyond placing rectangles on a canvas. It provides the building blocks needed to design real interfaces:</p><ul><li><strong>Vector editing:</strong> Draw frames, shapes, text, and paths using dedicated canvas tools.</li><li><strong>Layout systems:</strong> Work with constraints, auto layout, and grid layout.</li><li><strong>Reusable components:</strong> Build components with properties and variants.</li><li><strong>Design systems:</strong> Manage styles, variables, libraries, and design tokens.</li><li><strong>Interactive prototypes:</strong> Connect screens, define transitions, create overlays, and test user flows.</li><li><strong>Developer handoff:</strong> Inspect measurements, generate code, map design components to implementation, and trace design elements to requirements.</li></ul><p>These capabilities make UI Designer relevant not only to visual designers but also to developers who want more control over how their interfaces are conceived and implemented.</p><h3>The interesting part: design becomes programmable</h3><p>One of the most compelling aspects of UI Designer is its command-line interface, ud.</p><p>The editor is not limited to manual interaction. Its command-line interface exposes the editor’s capabilities, allowing scripts and AI agents to operate on the same design files and work with the open editor.</p><p>This changes the role of the design tool.</p><p>A design can become something that software can inspect and modify programmatically, rather than simply an image that a developer must interpret.</p><p>For example, this opens the door to workflows where an agent can help create screens, adjust layouts, maintain components, or iterate on a design while the developer reviews the results visually.</p><p>The project also supports MCP integration, making its design operations accessible to compatible AI agents and tools.</p><h3>AI-assisted design, with human review</h3><p>UI Designer includes an AI panel that uses Claude Code running on your machine. You can ask it to create, modify, or review a design, then inspect its proposal on the canvas before deciding whether to keep the changes.</p><p>That review step matters.</p><p>AI-assisted design is most useful when it accelerates implementation without removing the developer’s ability to evaluate the result. Combining programmatic design operations with a visual editor gives developers a practical way to experiment, iterate, and retain control over the final interface.</p><p>The same principle extends to scripts and other compatible agents: automation can help produce changes, while the visual editor remains the place to inspect them.</p><h3>From design to implementation</h3><p>The gap between a mockup and working software is one of the most persistent problems in UI development.</p><p>UI Designer addresses this with inspection and handoff features that connect the visual design to the implementation. Developers can inspect dimensions and code, generate files into their workspace, map components to existing code, and use linting and traceability features to help maintain consistency.</p><p>It also supports importing designs from Figma, Sketch, and Penpot, as well as from running web pages, with reports indicating what has been approximated during import.</p><p>This makes the tool useful even when a project already has an established design workflow.</p><h3>Built for the developer’s environment</h3><p>Because UI Designer lives inside VS Code, it can fit into familiar development workflows. Its documentation also covers keyboard accessibility, screen readers, high-contrast themes, collaborative editing through Live Share, and browser-based use through vscode.dev and github.dev.</p><p>The .design file format, command-line interface, and agent integration are particularly interesting for teams that want design artifacts to participate in their normal engineering processes.</p><p>Rather than treating design as a deliverable that gets handed over once, the approach encourages it to evolve with the codebase.</p><h3>Why this matters</h3><p>The next generation of development tools will increasingly need to support both human creativity and machine-assisted workflows.</p><p>A design editor that can be operated visually, manipulated through a command line, and accessed by AI agents creates an interesting foundation for that future. It offers a shared workspace where developers can move between drawing, prototyping, automation, and implementation without constantly switching tools.</p><p>UI Designer brings these ideas together inside an environment many developers already use every day.</p><p>It is a particularly interesting project for developers who want to experiment with AI-assisted interface development, maintain design artifacts alongside their code, or reduce the friction between visual design and implementation.</p><h3>Try it yourself</h3><p>If you develop software with Visual Studio Code and want to explore a more integrated approach to interface design, UI Designer is worth a look.</p><p><strong>Start here:</strong></p><ul><li><strong>User guide:</strong> <a href="https://soft-forge.dev/vscode-extension-ui-designer/guide/">https://soft-forge.dev/vscode-extension-ui-designer/guide/</a></li><li><strong>Installation:</strong> <a href="https://marketplace.visualstudio.com/">https://marketplace.visualstudio.com/</a></li><li><strong>Project website:</strong> <a href="https://soft-forge.dev/vscode-extension-ui-designer/">https://soft-forge.dev/vscode-extension-ui-designer/</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=edf354523e1b" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[The Shrinking Mind: Rapid Visual Consumption, Memory Fragility, and the Reduction of Human Context…]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-snippet">Over the last century, visual storytelling has undergone a structural acceleration. In the Golden Age of Cinema (1930s&#x2013;1940s), the average&#x2026;</p><p class="medium-feed-link"><a href="https://medium.com/@afarias.arthur/the-shrinking-mind-rapid-visual-consumption-memory-fragility-and-the-reduction-of-human-context-589416dd8c46?source=rss-a5588e96d369------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://medium.com/@afarias.arthur/the-shrinking-mind-rapid-visual-consumption-memory-fragility-and-the-reduction-of-human-context-589416dd8c46?source=rss-a5588e96d369------2</link>
            <guid isPermaLink="false">https://medium.com/p/589416dd8c46</guid>
            <category><![CDATA[cognition]]></category>
            <category><![CDATA[mindfulness]]></category>
            <category><![CDATA[memories]]></category>
            <dc:creator><![CDATA[Arthur Farias]]></dc:creator>
            <pubDate>Wed, 07 Oct 2026 20:44:40 GMT</pubDate>
            <atom:updated>2026-10-07T20:44:40.337Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[Can a Synchrotron Define a Semiconductor Gate?]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-snippet">An essay architecture for X-ray lithography</p><p class="medium-feed-link"><a href="https://medium.com/@afarias.arthur/can-a-synchrotron-define-a-semiconductor-gate-20e6f6d0ac11?source=rss-a5588e96d369------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://medium.com/@afarias.arthur/can-a-synchrotron-define-a-semiconductor-gate-20e6f6d0ac11?source=rss-a5588e96d369------2</link>
            <guid isPermaLink="false">https://medium.com/p/20e6f6d0ac11</guid>
            <category><![CDATA[phisics]]></category>
            <category><![CDATA[x-rays]]></category>
            <dc:creator><![CDATA[Arthur Farias]]></dc:creator>
            <pubDate>Tue, 29 Sep 2026 14:24:23 GMT</pubDate>
            <atom:updated>2026-09-29T14:24:23.028Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[I’ve created my own network library in C++23, performance traits and comparisons]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://medium.com/@afarias.arthur/ive-created-my-own-network-library-in-c-23-performance-traits-and-comparisons-276d31f84e97?source=rss-a5588e96d369------2"><img src="https://cdn-images-1.medium.com/max/1536/1*EmvY9Xb0OQ412QCjhYSE2A.png" width="1536"></a></p><p class="medium-feed-snippet">For the last few months I&#x2019;ve been building cx-networking, a header-only, zero-dependency asynchronous networking toolkit for C++23. This&#x2026;</p><p class="medium-feed-link"><a href="https://medium.com/@afarias.arthur/ive-created-my-own-network-library-in-c-23-performance-traits-and-comparisons-276d31f84e97?source=rss-a5588e96d369------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://medium.com/@afarias.arthur/ive-created-my-own-network-library-in-c-23-performance-traits-and-comparisons-276d31f84e97?source=rss-a5588e96d369------2</link>
            <guid isPermaLink="false">https://medium.com/p/276d31f84e97</guid>
            <category><![CDATA[cpp]]></category>
            <category><![CDATA[cpp23]]></category>
            <category><![CDATA[udp]]></category>
            <category><![CDATA[netowrking]]></category>
            <category><![CDATA[tcp]]></category>
            <dc:creator><![CDATA[Arthur Farias]]></dc:creator>
            <pubDate>Mon, 31 Aug 2026 20:55:26 GMT</pubDate>
            <atom:updated>2026-08-31T20:55:26.445Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[I Deleted the Stylesheet: Why a Component Should Own Its Style]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://medium.com/@afarias.arthur/i-deleted-the-stylesheet-why-a-component-should-own-its-style-9d88bbdb9587?source=rss-a5588e96d369------2"><img src="https://cdn-images-1.medium.com/max/1488/0*vj1Hf8eKhL-eAsJi" width="1488"></a></p><p class="medium-feed-snippet">Last week I deleted index.css from a production portfolio site. Not trimmed it. Deleted it. index.html now loads zero stylesheets, and the&#x2026;</p><p class="medium-feed-link"><a href="https://medium.com/@afarias.arthur/i-deleted-the-stylesheet-why-a-component-should-own-its-style-9d88bbdb9587?source=rss-a5588e96d369------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://medium.com/@afarias.arthur/i-deleted-the-stylesheet-why-a-component-should-own-its-style-9d88bbdb9587?source=rss-a5588e96d369------2</link>
            <guid isPermaLink="false">https://medium.com/p/9d88bbdb9587</guid>
            <category><![CDATA[css]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[html]]></category>
            <category><![CDATA[web-development]]></category>
            <dc:creator><![CDATA[Arthur Farias]]></dc:creator>
            <pubDate>Mon, 31 Aug 2026 19:24:13 GMT</pubDate>
            <atom:updated>2026-08-31T20:09:30.125Z</atom:updated>
        </item>
    </channel>
</rss>