DeepClause meets pi: controlling pi with Prolog and vice versa A developer has released a DeepClause extension for pi, an AI harness, enabling the execution of DML (DeepClause Meta Language) agentic workflows within pi and the use of logic programs as executable plans for controlling pi. The extension, available on GitHub, allows users to run DML skills via slash commands and generate executable plans from natural language requests, aiming to improve reproducibility and control in AI-driven development. So, for a while I’ve been working on my own harness, which was fun and interesting, but ultimately there comes a point where you have to admit defeat and just start using something a bit more serious ever tried to write your own search engine? . In my case I’ve decided to start using pi https://pi.dev/ as a frontend for DeepClause https://github.com/deepclause/deepclause-sdk . The result is the new DeepClause extension for pi https://github.com/deepclause/deepclause-pi . Installation is easy: pi install git:github.com/deepclause/deepclause-pi Before you start using DeepClause from a project, you need to initialize the .pi/deepclause folder using the “/dc” command. Then you’re ready to go In the following I will now briefly describe the two main use cases for this extension: 1. Creating and running small agentic automations Run DML from Pi 2. Controlling pi using logic programs as executable plans Run Pi from DML If you like deepclause and the deepclause pi extension, please consider starring the projects on github. https://github.com/deepclause/deepclause-pi https://github.com/deepclause/deepclause-pi https://github.com/deepclause/deepclause-sdk https://github.com/deepclause/deepclause-sdk Use Case 1: Running DML inside pi for automating common workflows DML DeepClause Meta Language is a small DSL that can be used to encode agents and agentic workflows as small executable logic programs. For some more background, please take a look at some recent posts, such as this one https://deepclause.substack.com/p/loops-graphs-prolog . DML programs meant to be executed by pi live in .pi/deepclause/skills/ and can be run with a slash command: /dc-run example The extension uses the model currently selected in pi. It does not ask for another API key or try to guess the provider. Model calls, cancellation, input prompts and usage stay connected to the current pi session. A minimal DML file or “compiled skill” : agent main Topic :- system "You are a concise technical analyst." , format string Request , "Explain ~w. Store the final explanation in Summary.", Topic , task Request, string Summary , answer Summary . Run it as follows: /dc-run skills/explain.dml "constraint logic programming" Once you have the extension installed, pi will also know about how to write DML programs via a conjext injection. So you can directly ask it to e.g implement a lot of recurring workflows as DML Use Case 2: Executable Plans from Specs There have been a lot of discussions around “Spec Driven Development”, “Software Factories”, “Loop Engineering” etc. All of these approaches somehow aim at formalizing and automating the software development process. However, what I always felt was a bit weird, is that whatever approach is chosen, the end result is a bunch of markdown plan files combined with the hope that the model/harness combination is smart enough to turn this into working software. And to some extent the models and harnesses are good enough, that is if you pay enough money to Anthropic and OpenAI. However, even SOTA models do sometimes decide to go off the rails and once your agents are running it is often very hard to follow what’s going on. Also, the entire modern agentic development process is hardly reproducible. So, if you’d like a bit more sanity in all of this, why not try turning your markdown specs into actual exectuable plans Let’s explore how DeepCLause and pi can help with that deepclause-pi and /dc-plan + /dc-run The extension adds this command: /dc-plan