Phulax

Your defi Guardian agent that never sleeps. Protect. Detect. Withdraw.

Open AgentsShipped April 24, 2026 Dormant#ai#defi#infra
Visit Repo
Phulax banner

About

This project is meant to safeguard users in yield protocol. I myself have been victim of defi hacks on various yield protocols and so I wanted to build something that can help that.

What I built is a guardian that watches over every transaction that hit the pool you are in.

You deposit through `PhulaxAccount, a smart contract where the agent key can call exactly one function withdraw(adapter)` and funds are hard-coded to return to you. This is fine as worst case, the agent gets compromised and forces an exit.

A Keeperhub worflow has most of the steps, it fetches the latest transactions, runs it through a detection pipeine which checks for invariants, oracle deviation, vector similarity against historical exploits, and a classifier we fine-tuned. If risk crosses the threshold, the keeperhub workflow is set to withdraw the funds and append a log to 0g. The guardian is also an iNFT so it can be monetized and transferrable.

Here is the demo:

- https://46.225.141.153/web/what-is-it -> explains the project - https://46.225.141.153/ -> a fork of keeperhub with 0g integration and my custom workflow. To Sign in using username: patrick@bytalabs.com and password: password. You will find 2 workflows, one is to show the 0g nodes crearted, the other one "Phulax Guardian" is the one I'm talking about - https://46.225.141.153/web -> frontend to see what the agent is doing

How it's made

I combined the power and extensibility of Keeperhub. First I added 0g as a first class citizen workflow into Keeperhub (which I will make a PR for) so we can do inference/kv get and puts and append logs to 0g. This was useful for my use case. Tech used: Keeperhub, nodejs, 0g cli and docs

Then I created a library of past defi attacks, stored those on 0g storage, used 0g to fine tune a model on those attacks (using Qwen 2.5). Because 0g doesn't allow yet to run inference on the fine tuned model I had to spin up a server for that inference step, otherwise this would be on-chain (or on network). Tech used: Python, FastAPI, uvicorn, transformers, PEFT, PyTorch, Pydantic v2

Then I created the smart contracts that were needed for this, a fake lending pool, the Phulax smart contract and a fake token with scripts to send transactions to them. Also created the iNFT contract. Tech used: Solidity, foundry, iNFT

Then I wired everything together using Keeperhub which was very easy as it's simply drag and drop. I had to fine tune some steps to ensure that the agent doesn't by default withdraw, it was a lot of fine tuning on the different detection tiers. But I've always thought it's better to be safe than sorry (forego a few cents of APY to keep your principle!)

I created a nextjs frontend to visualize it all, along with SSE events so we can understand what the whole flow is doing.

From the public ETHGlobal showcase page. Votes, swipes and the judge score are hackfeed's own.

AI judge

Not judged yet. A free model reads this page, compares it with similar projects and this event's winners, then scores it and says what would make it win.

Still being built?

DormantLast push 215 days ago

Swipe stats

0upvotes
0skips
0saves

Discussion 0

No comments yet. Ask the team something, or say what you'd use it for.

Posting as a guest. Plain text, 1,000 characters max.

Already built nearby

Closest projects by meaning and shared words. Similar isn't the same as copied: read them.

Protocol Guardian

AI agent that catches DeFi exploits in the mempool before they hit the blockchain

Don't Get Drained

Agentic firewall marketplace where anyone can publish security agents that guard DeFi transactions