<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>MLflow Vast.ai backend on Alwaldend</title><link>https://alwaldend.com/docs/projects/mlflow_vastai_backend/</link><description>Recent content in MLflow Vast.ai backend on Alwaldend</description><generator>Hugo</generator><language>en</language><atom:link href="https://alwaldend.com/docs/projects/mlflow_vastai_backend/index.xml" rel="self" type="application/rss+xml"/><item><title>Application state machines</title><link>https://alwaldend.com/docs/projects/mlflow_vastai_backend/docs/state-machines/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alwaldend.com/docs/projects/mlflow_vastai_backend/docs/state-machines/</guid><description>&lt;h2 id="cli-dispatch"&gt;CLI dispatch&lt;a class="td-heading-self-link" href="#cli-dispatch" aria-label="Heading self-link"&gt;&lt;/a&gt;&lt;/h2&gt;&lt;p&gt;&lt;a href="https://alwaldend.com/docs/projects/mlflow_vastai_backend/docs/assets/state-machine.svg"&gt;&lt;img src="https://alwaldend.com/docs/projects/mlflow_vastai_backend/docs/assets/state-machine.svg" alt="CLI, coordinator, and worker state machines" loading="lazy"&gt;&lt;/a&gt;&lt;/p&gt;&#10;&lt;p&gt;See the &lt;a href="../architecture/"&gt;plugin architecture&lt;/a&gt; for the service boundaries&#10;and protocols.&lt;/p&gt;&#10;&lt;p&gt;The CLI machine enters &lt;code&gt;cli-parsing&lt;/code&gt; and uses Cobra to parse the arguments.&#10;&lt;code&gt;cli-dispatch&lt;/code&gt; calls the selected application method. The application calls&#10;the worker through its named methods. Each component adds its own states and&#10;child calls to the graph. Dashed arrows show those calls.&lt;/p&gt;&#10;&lt;ul&gt;&#10;&lt;li&gt;&lt;code&gt;server serve&lt;/code&gt; runs the coordinator and its job machine.&lt;/li&gt;&#10;&lt;li&gt;&lt;code&gt;worker serve&lt;/code&gt; runs the worker&amp;rsquo;s listener child machine. Its states open the listener&#10;in &lt;code&gt;worker-starting&lt;/code&gt;, serve RPCs in &lt;code&gt;worker-serving&lt;/code&gt;, and release resources&#10;in &lt;code&gt;worker-stopping&lt;/code&gt;.&lt;/li&gt;&#10;&lt;li&gt;&lt;code&gt;state-machine graph&lt;/code&gt; prints the machine definitions and their calls as one DOT graph.&lt;/li&gt;&#10;&lt;/ul&gt;&#10;&lt;p&gt;&lt;code&gt;worker submit&lt;/code&gt;, &lt;code&gt;worker status&lt;/code&gt;, and &lt;code&gt;worker cancel&lt;/code&gt; enter &lt;code&gt;forward-rpc&lt;/code&gt;&#10;and send protobuf requests over the worker&amp;rsquo;s Unix socket. Bazel regenerates&#10;the diagram from the CLI when it builds this page.&lt;/p&gt;</description></item><item><title>Plugin architecture</title><link>https://alwaldend.com/docs/projects/mlflow_vastai_backend/docs/architecture/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://alwaldend.com/docs/projects/mlflow_vastai_backend/docs/architecture/</guid><description>&lt;p&gt;&lt;a href="https://alwaldend.com/docs/projects/mlflow_vastai_backend/docs/assets/architecture.svg"&gt;&lt;span class="mermaid-diagram"&gt;&lt;img src="https://alwaldend.com/docs/projects/mlflow_vastai_backend/docs/assets/architecture.svg" alt="MLflow Vast.ai plugin architecture" loading="lazy" class="mermaid-light"&gt;&lt;img src="https://alwaldend.com/docs/projects/mlflow_vastai_backend/docs/assets/architecture.dark.svg" alt="MLflow Vast.ai plugin architecture" loading="lazy" class="mermaid-dark"&gt;&lt;/span&gt;&lt;/a&gt;&lt;/p&gt;&#10;&lt;p&gt;The MLflow run ID identifies the workload across the plugin, coordinator, and&#10;worker. The coordinator records its rental assignment before dispatch. The&#10;worker records the outcome before reporting it.&lt;/p&gt;&#10;&lt;p&gt;The worker receives the project snapshot from MLflow&amp;rsquo;s artifact store and runs&#10;the entry point on the rental. The workload logs metrics and artifacts to the&#10;run. The coordinator publishes confirmed terminal status to MLflow and retries&#10;failed updates after the submitting client disconnects.&lt;/p&gt;</description></item></channel></rss>