MoreRSS

site iconThe Practical DeveloperModify

A constructive and inclusive social network for software developers.
Please copy the RSS to your reader, or quickly subscribe to:

Inoreader Feedly Follow Feedbin Local Reader

Rss preview of Blog of The Practical Developer

A Rust TUI for Your UniFi Network That Actually Takes Code Review Seriously

2026-04-09 20:44:50

If you run UniFi gear, you manage it through a web UI. That's fine until you need to script something, automate a deployment, or check your firewall rules from an SSH session on a box that doesn't have a browser. Ubiquiti doesn't ship a CLI. The API exists but it's split across two incompatible surfaces with different auth mechanisms, different response formats, and different ideas about what an entity ID should look like. Most people who try to automate UniFi end up writing bespoke Python scripts against whichever API endpoint they needed that week. The scripts work until a firmware update moves the endpoint.

Someone decided to build the CLI that Ubiquiti didn't. And then kept going until it had a full TUI dashboard.

What Is Unifly?

Unifly is a Rust CLI and terminal dashboard for managing UniFi network infrastructure. Built by Stefanie Jane, it ships as a single binary with 27 CLI commands covering devices, clients, networks, firewall rules, NAT policies, DNS, VPN, Wi-Fi observability, and more. There's also a 10-screen ratatui TUI for real-time monitoring: device health, client connections, traffic charts, firewall policies, network topology. The whole thing speaks both UniFi API dialects (the modern Integration API and the older Session API) and reconciles data between them.

123 stars at time of writing. Eight weeks old. About 15,000 lines of Rust across two crates. The pace of development is aggressive: 71 commits in the first eight days of April alone.

The Snapshot

Project Unifly
Stars 123 at time of writing
Maintainer Solo (hyperb1iss), AI-assisted
Code health 250+ tests, pedantic clippy, forbid(unsafe), e2e suite against simulated controller
Docs Thorough CONTRIBUTING.md, detailed architecture guide, explicit ROADMAP with named gaps
Contributor UX Same-day responses, content always lands, merge mechanism varies
Worth using Yes if you have UniFi gear. The CLI alone replaces a lot of web UI clicking.

Under the Hood

The architecture is a two-crate Cargo workspace. unifly-api is the library: HTTP and WebSocket transport, a Controller facade behind an Arc, and a reactive DataStore built on DashMap and tokio::watch channels. unifly is the binary: clap-based CLI commands and ratatui TUI screens. The library is published to crates.io independently, so you could build your own tooling on top of it without pulling in the CLI.

The dual-API problem is the interesting engineering challenge. UniFi controllers expose a modern Integration API (REST, API key auth, UUIDs) and an older Session API (cookie + CSRF, hex string IDs, envelope-wrapped responses). Some data only exists on one side. Client Wi-Fi experience metrics? Session API. Firewall policy CRUD? Integration API. NAT rules? Session v2 API, a third dialect. Unifly handles all of this behind a single Controller type. You call controller.execute(Command::CreateNatPolicy(...)) and the command router figures out which API to hit, which auth to use, and which ID format to resolve.

The lint configuration tells you a lot about a project's standards. Unifly runs clippy::pedantic at deny level, clippy::unwrap_used at deny, and unsafe_code at forbid. The workspace Cargo.toml has 30+ individual clippy rule overrides, each with a clear rationale. This is not someone who pasted a default config. The test suite uses wiremock for API mocking, assert_cmd for CLI testing, and insta for snapshot tests. The e2e suite spins up a simulated UniFi controller and runs full command flows. cargo-deny enforces a license allowlist and vulnerability advisories.

One thing you notice immediately: nearly every commit has Co-Authored-By: Claude Opus 4.6 in the trailer. This is an AI-assisted codebase, and the maintainer isn't hiding it. The code quality is high regardless of how it got there. The architecture is coherent, the tests are real, the error handling uses thiserror and miette properly. AI-assisted doesn't mean AI-dumped. The commit history shows iterative problem-solving, not a single prompt that produced 15,000 lines.

What's rough? The TUI has ten screens and zero test coverage. The controller reconnect lifecycle is broken (the CancellationToken goes permanent after the first disconnect). And the ROADMAP had a few stale entries that claimed features were missing when they'd already been implemented. These are the kinds of gaps you'd expect in a project that's moving this fast with a solo maintainer.

The Contribution

The ROADMAP listed "NAT policies have no update subcommand" as a known gap. The workaround was to delete and recreate, which means re-specifying every field just to change one. NAT rules are the kind of thing you adjust frequently (new port forward, toggling a rule on and off), so this was a real workflow friction.

The fix touched 11 files across both crates. On the library side: an UpdateNatPolicyRequest struct, a new Command variant, and an apply_nat_update function that fetches the existing rule via the Session v2 API, merges only the changed fields, and PUTs it back. On the CLI side: an Update variant in the clap args with all NAT fields as optional flags plus --from-file support, validation that at least one field is provided, and conflicts_with between --name and --description (both map to the same v2 API field, which I caught during my pre-submission review). I also promoted a private ensure_session_access function from the events handler to a shared utility, and wired it into the NAT handler so users get a clean error message when their auth mode is insufficient instead of a deep transport failure.

The codebase was easy to navigate. The project's AGENTS.md (symlinked as CLAUDE.md) doubles as a comprehensive architecture guide. It documents every API quirk, every CLI pattern, every module's responsibility. When I needed to understand how the firewall update command worked (to replicate the pattern for NAT), I read the architecture doc first, then confirmed in code. The existing firewall implementation was an almost perfect blueprint. The CONTRIBUTING.md lays out the full checklist: define args, implement handler, wire dispatch, update skill docs, add tests. I followed it step by step.

PR #10 is open and waiting for review. The maintainer's track record with external PRs is good. Five previous PRs from two contributors all had their content land in main. Clean PRs against current main get proper GitHub merges. PRs that conflict with ongoing refactors get reworked by the maintainer with co-author credit. Either way, the work ships.

The Verdict

Unifly is for anyone who manages UniFi networks and wants to do it from the terminal. If you run a homelab with Ubiquiti gear, or you're an MSP managing multiple sites, or you just want to script your firewall rules instead of clicking through a web UI, this is the tool. The CLI covers enough surface area to be genuinely useful today. The TUI is a bonus for monitoring.

The trajectory is steep. Eight weeks from first commit to 27 commands, a full TUI, dual-API support, and a published crate on crates.io. The codebase is clean enough that an external contributor (me) could implement a missing feature by following the existing patterns. The maintainer responds quickly and ships contributed work. Those are the signals that matter for whether a project has legs.

What would push it further? Test coverage on the TUI screens. Fixing the reconnect lifecycle so long-running TUI sessions survive network blips. And eventually, Cloud/Site Manager API support so you can manage controllers through Ubiquiti's cloud without direct network access. The AuthCredentials::Cloud variant already exists in the code. The transport just isn't wired yet.

Go Look At This

If you have UniFi gear, try unifly. cargo install unifly or grab a binary from the releases page. Run unifly config init to connect to your controller, then unifly devices list and see what happens.

The ROADMAP has more gaps worth picking up. TUI test coverage is explicitly welcomed. The radio data parsing has untested code paths. The Cloud API transport is waiting for someone to implement it.

This is Review Bomb #13, a series where I find under-the-radar projects on GitHub, read the code, contribute something, and write it up. If you know a project that deserves more eyeballs, drop it in the comments.

This post was originally published at wshoffner.dev/blog. If you liked it, the Review Bomb series lives there too.

We Query ChatGPT, Claude, and Perplexity About Your Brand. Here's the Architecture

2026-04-09 20:43:14

A few months ago I had a question that didn't let me sleep. When people ask ChatGPT "what's the best tool for X", which brands actually get mentioned? And more importantly: does my brand get mentioned?

Turns out this is a surprisingly hard thing to measure. So we built a product for it. It's called Be Recommended, and under the hood it's a system that parallel-queries ChatGPT, Claude, Perplexity, and Gemini, then scores how visible a brand is inside their answers.

This post is about the architecture. And about the data we found, which frankly shocked us.

The problem in one line

Traditional SEO tells you how you rank on Google. But when someone opens ChatGPT and asks "what's the best CRM for a solo consultant", Google isn't in the room. The LLM answers directly, from its training data plus whatever live retrieval it does. If your brand isn't in that answer, you lose the customer before you even know they existed.

The Gartner forecast everyone quotes says roughly a quarter of search volume moves to AI assistants by 2026. Our own data, which I'll get to, suggests the shift is faster than that in some verticals.

Why this is harder than it looks

The naive version is easy: open ChatGPT, type a prompt, see if your brand is mentioned. Done.

The real version is not.

Problem one is prompt variance. "Best CRM for solo consultant" and "what CRM should a one person agency use" return different answers. Any scoring that hits a single prompt is basically noise. You need a prompt set per vertical, seeded with realistic intent, and you need to rotate through it.

Problem two is model variance. ChatGPT and Claude don't even agree on what decade it is, let alone which SaaS product is the market leader. Averaging them hides the signal. We report per-engine scores separately and then a blended composite.

Problem three is response variance. The same prompt to the same model on two different days will surface different brands. You need to sample, not snapshot.

Problem four, and this is the one that took us the longest, is parsing. LLMs don't return JSON when you ask "what CRM should I use". They return prose with brand names sprinkled inside sentences, sometimes with typos, sometimes with "CRM Hub" instead of "HubSpot CRM", sometimes with a brand mentioned in a dismissive footnote. You can't just grep.

The architecture, top to bottom

Here is how a single "analyze my brand" request flows through the system.

Step one: intent expansion. The user gives us a brand name and a URL. We pull the landing page, classify the vertical, and generate a set of 20 to 40 representative buyer intents. "Best X for Y", "alternatives to Z", "is brand A worth it", "what's the cheapest way to do W". The prompts are not random. They are templated against real search intents we've scraped from Quora, Reddit, and Google's People Also Ask.

Step two: parallel fanout. Each prompt is dispatched to every engine in parallel. Four engines, up to forty prompts, that's one hundred and sixty concurrent inference calls per scan. We don't wait serially. If you do, a single scan takes twenty minutes and the user bounces.

Step three: rate limiting. This is where it got real. OpenAI's TPM limits on the standard tier make a naive fanout impossible. We implemented a token-bucket limiter per engine, per model, with exponential backoff and jittered retries. When one engine is saturated we spill to another to keep the user's scan moving. Responses get deduplicated against a short-lived cache so two prompts with near-identical semantics don't double-bill.

Step four: response normalization. This is the parsing layer. Each response gets run through a second, cheaper LLM call whose only job is to extract mentioned entities and classify the sentiment of each mention. Positive mention, neutral mention, negative mention, dismissive footnote. We also track position: was your brand first, third, or buried at the end of a list of ten? Position matters because users don't read past the top three.

Step five: scoring. The scoring algorithm is where the opinion lives. We weight by engine reach (ChatGPT dominates), by mention sentiment, by position, and by the share of prompts that mentioned the brand at all. The output is a 0 to 100 score, the AI Visibility Score. The math is tuned so that a brand mentioned positively in the top three of most prompts on most engines lands around 80. That's the "top performer" band.

Step six: reporting. We don't dump raw data on users. The final report shows the composite score, a per-engine breakdown, the exact prompts where you were mentioned and where you weren't, the top competitors that showed up in your place, and a prioritized list of fixes. The fixes come from a rules engine that pattern-matches on the gaps. Missing G2 listing, thin landing page, no schema markup, no authoritative third-party mention, and so on.

What the data showed us

We ran the system against a few hundred brands across SaaS, e-commerce, agencies, and consumer apps. A few findings that genuinely surprised me.

The average AI Visibility Score is 31. Out of 100. That means for most companies, most of the time, the major LLMs either don't mention them or mention them in a throwaway sentence. Think about that for a second. A whole industry is optimizing for Google while the actual decision-making conversation has already moved somewhere they're not even present.

Brand recognition and AI visibility are barely correlated. We scanned some household SaaS names and found scores in the 40s. We scanned smaller tools with great documentation and active third-party review coverage and found scores in the 70s. Training data eats marketing budgets for breakfast. What the internet wrote about you five years ago matters more than what your ad agency shipped last quarter.

The engines disagree a lot. It's common to see a 30-point spread between ChatGPT and Perplexity for the same brand. Perplexity leans heavily on fresh retrieval, so it rewards recent coverage. ChatGPT leans on training snapshots, so it rewards longevity and repeat mentions in tech press. Claude sits in the middle. Gemini is the wildcard.

Position bias is brutal. Being mentioned fifth in a list of ten is almost the same as not being mentioned at all. Users read the first two or three answers and stop. If the LLM puts you in sixth place, you're invisible.

What we learned building it

Two things I'd tell anyone trying to build something similar.

First: the parsing layer is where your product lives or dies. Getting prompts right is easy. Calling the APIs is easy. Extracting clean, structured mentions from messy LLM prose is the whole game. We rewrote ours three times before it was usable.

Second: this space is moving fast enough that any snapshot is a guess at the current weather. We rescan on a schedule because the same brand can swing 20 points in a month when a big review lands or a model version ships. A one-shot audit is entertainment. A tracked score over time is actually useful.

Try it

If you're curious what the three big LLMs say about your own brand, Be Recommended runs a scan for $4. You get a full report with the prompts, the engines, the competitors, and the fixes. We built it because we were running this for ourselves every week and decided it was silly not to let other people use it.

Would love to hear what score you get. Drop it in the comments.

# Your AI Agents Are Talking — But Can You Prove What They Said?

2026-04-09 20:41:56

Your AI Agents Are Talking — But Can You Prove What They Said?

AI agents are no longer “helpers.”

They move money, make decisions, and talk to each other.

If you have at least two agents, you’re already in a multi‑agent system — whether you planned for it or not.

PiQrypt is an open‑source trust layer that ensures every interaction between your agents is cryptographically verifiable.

Even if your agents change, your LLMs evolve, or your infrastructure migrates — PiQrypt stays as the immutable proof layer on top.

The gap nobody talks about

Modern AI stacks are incredibly powerful:

  • LLMs: OpenAI, Anthropic, Mistral, DeepSeek, local models.
  • Agent frameworks: LangChain, CrewAI, AutoGen, custom agents.
  • Observability tools: logs, traces, dashboards.

They all share a blind spot:

“They can show you what happened — but they can’t prove it.”

Logs can be modified.

Traces aren’t cryptographic.

And when agents interact, there’s no shared, verifiable record of that interaction.

When something goes wrong:

  • Which agent made the decision?
  • In what order?
  • Based on which interaction?
  • Can you prove it to someone outside your system?

Most systems today can’t.

Agents don’t just need to connect — they need to agree

When two agents interact, there are actually two problems:

  1. How do they communicate?
  2. How do they prove they communicated?

Today’s A2A‑style protocols (Agent2Agent, AI‑to‑agent handshakes, and custom flows) mainly solve the first.

PiQrypt solves the second — with cryptographic proof around agent‑to‑agent interactions.

“Agents need a handshake — not just a connection.”

Enter PiQrypt: co‑signed interactions with cryptographic memory

PiQrypt is an open‑source trust layer that sits between your agents and your memory / logs. It’s LLM‑agnostic, framework‑agnostic, and infrastructure‑agnostic:

  • Works with any LLM (OpenAI, Anthropic, Mistral, DeepSeek, local).
  • Integrates with any framework (LangChain, CrewAI, AutoGen, or your own).
  • Independent of your storage, logs, MLflow, or cloud provider.

Every interaction becomes:

  • Co‑signed by the participating agents,
  • Anchored in a hash‑chained audit trail,
  • Part of a verifiable, multi‑agent session.

This is powered by AISS (Agent Identity and Signature Standard) and built on top of PCP (Proof of Continuity Protocol) — an open protocol specification for agent‑to‑agent collaboration, with PiQrypt as the reference implementation.

How the A2A handshake works conceptually

PiQrypt’s A2A handshake is a short, peer‑to‑peer protocol used to:

  • Discover other agents (via registry or direct),
  • Authenticate both agents,
  • Collaborate with cryptographic proof,
  • Audit all interactions, stored in both agents’ audit trails.

Here’s how it looks at the protocol level:

  1. Each agent generates an Ed25519 keypair.
  2. Agents exchange public keys (via your agent bus, API, WebSocket, or A2A‑style transport).
  3. Every agent pair performs a co‑signed handshake:
    • Both sign the fact that “Agent X and Agent Y have agreed to talk.”
    • The handshake is appended to each agent’s hash‑chained memory.
from aiss.a2a import initiate_handshake, accept_handshake, verify_handshake
from aiss.crypto import ed25519
from aiss.identity import derive_agent_id

# Agent A
priv_a, pub_a = ed25519.generate_keypair()
agent_a = derive_agent_id(pub_a)

# Agent B
priv_b, pub_b = ed25519.generate_keypair()
agent_b = derive_agent_id(pub_b)

# 1. Agent A initiates handshake
handshake = initiate_handshake(
    priv_a,
    agent_a,
    agent_b,
    payload={
        "intent": "data_sharing",
        "scope": "market_analysis",
        "terms": "50/50 split"
    },
    expires_in=3600  # 1h timeout, anti‑replay
)

# 2. Send to Agent B
# ...

# 3. Agent B accepts
response = accept_handshake(
    priv_b,
    agent_b,
    handshake,
    counter_payload={
        "agreed": True,
        "conditions": "Data encrypted in transit"
    }
)

# 4. Verify (both agents)
is_valid = verify_handshake(response, {
    agent_a: pub_a,
    agent_b: pub_b
})

print(f"Handshake valid: {is_valid}")

Thanks to piqrypt-session-multi-ai-agents, this is packaged as an AgentSession that creates a shared session across all agents before a single action is taken.

From handshake to verifiable sessions

Here’s a minimal example with three agents: planner (LangChain), executor (AutoGen), and reviewer (CrewAI). All frameworks, one session.

from piqrypt.session import AgentSession
import piqrypt as aiss

# Generate keypairs
planner_key, planner_pub = aiss.generate_keypair()
executor_key, executor_pub = aiss.generate_keypair()
reviewer_key, reviewer_pub = aiss.generate_keypair()

# Define agents
session = AgentSession(agents=[
    {"name": "planner",   "agent_id": aiss.derive_agent_id(planner_pub), "private_key": planner_key, "public_key": planner_pub},
    {"name": "executor",  "agent_id": aiss.derive_agent_id(executor_pub), "private_key": executor_key, "public_key": executor_pub},
    {"name": "reviewer",  "agent_id": aiss.derive_agent_id(reviewer_pub), "private_key": reviewer_key, "public_key": reviewer_pub},
])

# 1. Start: all pairwise A2A handshakes are recorded
session.start()

# 2. Stamp events in the session
session.stamp("planner", "task_delegation", {"task": "rebalance_portfolio"}, peer="executor")
session.stamp("executor", "order_executed", {"order_id": 42, "price": 182.5, "quantity": 100}, peer="reviewer")
session.stamp("reviewer", "review_approved", {"approved": True})

# 3. Later: export and verify offline
session.export("trading‑session‑audit.json")

# That audit is:
# - signed by each agent,
# - co‑signed by every interaction,
# - readable and verifiable without your production stack.

From this moment on:

  • Every session.stamp(agent_name, event_type, payload, peer=...) is signed by the acting agent.
  • It’s anchored in the shared, hash‑chained session.
  • It’s reflected in every agent’s memory, with a shared interaction_hash.

“Same interaction. Two memories. One verifiable truth.”

Trust scores: how much you can rely on a session

PiQrypt doesn’t stop at proof. For every session, it computes:

  • VRS (Vulnerability Risk Score): a risk metric based on agent behavior, anomalies, and policy flags.
  • Trust score (0–1): how “safe” the agent’s history and current session are.
  • TrustGate decision: ALLOW, REQUIRE_HUMAN, or BLOCK, enforced at runtime with signed proof of every decision.

Example:

result = piqrypt.verify(
    signature=agent_event.signature,
    chain=agent_event.chain,
    context={"agent_id": "pq1_planner_a3f8", "action": "portfolio_rebalance"}
)

print(f"trust_score: {result.trust_score:.4f}")   # → 0.9987
print(f"decision: {result.decision}")             # → ALLOW

You can block risky actions, require human approval, or allow automatically, all based on verifiable data.

Stack‑agnostic by design

PiQrypt is built to be truly agnostic:

  • LLMs: OpenAI, Anthropic, Mistral, DeepSeek, local models.
  • Agent frameworks: LangChain, CrewAI, AutoGen, or any custom stack.
  • Cloud / infra: Independent of your storage, logs, MLflow, Application Insights, or LangSmith.

“Your agents can change. Your infrastructure can change. Your trust layer should not.”

PiQrypt’s A2A handshake and PCP‑backed audit trail work over any transport (API, message bus, A2A style, or custom protocol). The registry can be centralized, distributed, or even DHT‑based in the future.

Why this matters in production

If you’re building:

  • Multi‑agent workflows (planner → executor → reviewer → auditor).
  • Agents that communicate across boundaries (company ↔ partner, SaaS ↔ local).
  • Compliance‑sensitive applications (finance, healthcare, legal, etc.).

…then an A2A handshake with cryptographic trust scoring is no longer optional.

With PiQrypt, you get:

  • Cryptographic identity for every agent.
  • Co‑signed, hash‑chained handshakes for every session.
  • Session‑anchored events that are verifiable offline, across frameworks.
  • Numeric trust scores integrated into your governance and policy layer.

Getting started

  1. Install PiQrypt and the A2A‑ready session module:
   pip install piqrypt piqrypt-session-multi-ai-agents
  1. Follow the A2A‑focused guides:
  • docs/A2A_HANDSHAKE_GUIDE.md
  • docs/A2A_SESSION_GUIDE.md
  • QUICK-START.md (A2A handshake section).
  1. Run the 3‑agent demo (plannerexecutorreviewer) and experiment with verify() + trust_score on your own event chains.

From observability to verifiability

We’ve spent years building observability for software systems.

Now, AI needs the same — but stronger:

“Not just visibility.

Proof.”

Your agents already talk.

The real question is:

“Can you prove what happened between them?”

Right now, most systems can’t.

PiQrypt does.

PiQrypt is the A2A handshake your agents never knew they needed.

Nothing ever disappears, and nothing appears out of nowhere — only what’s cryptographically agreed upon.

You can check out the full reference implementation on [GitHub/PiQrypt]
https://github.com/PiQrypt/piqrypt and try your first A2A handshake today.

Machine Identity Crisis: Why the AI Era Needs a New Trust Protocol

2026-04-09 20:35:51

Table of Contents

  • The Great Identity Shift of 2026
  • Understanding the 82:1 Machine Identity Crisis
  • Why Traditional IAM Falls Short in the AI Era
  • The Rise of Identity-Based Attacks
  • MAIP: The Machine Agent Identity Protocol
  • Building the Machine Trust Ecosystem
  • Truthlocks' Infrastructure for Scale
  • From Crisis to Opportunity
  • FAQ

We've hit a breaking point. For every human on Earth, 82 machine identities now operate in our digital ecosystem. This isn't some distant future scenario—it's happening right now in 2026, creating the biggest security challenge our industry has ever seen.

The path from 2024's AI excitement to 2025's widespread experimentation has led us to what security leaders call the "Year of the Defender." Organizations everywhere are racing to secure an autonomous economy where AI agents, smart contracts, and automated workflows vastly outnumber human users.

Here's what the 82:1 machine identity crisis means, why our current security models can't handle it, and how a new trust protocol is emerging to solve this fundamental problem.

The Great Identity Shift of 2026

The numbers paint a clear picture. In 2024, we celebrated AI breakthroughs and proof-of-concepts. In 2025, businesses experimented with AI agents and automation at scale. Now in 2026, we're dealing with the fallout of rapid AI adoption without proper identity infrastructure.

Machine identities encompass AI agents, IoT devices, automated trading systems, smart contracts, robotic process automation (RPA) bots, and countless other autonomous entities. Each needs authentication, authorization, and verification—yet most run on security models built for human users.

This shift happened faster than anyone expected. Enterprise AI deployments took off through 2025, with organizations launching thousands of AI agents for customer service, data analysis, and workflow automation. IoT ecosystems exploded simultaneously, while blockchain applications introduced entirely new categories of autonomous actors.

The result? A digital world where machine-to-machine interactions dominate, but security protocols still assume human operators are calling the shots.

Understanding the 82:1 Machine Identity Crisis

The 82:1 ratio isn't just about numbers—it exposes a massive gap between our security infrastructure and reality. Traditional identity and access management (IAM) systems expect human operators with predictable patterns: login times, geographic locations, and consistent behavior.

Machine identities work completely differently. They authenticate thousands of times per second, operate across multiple regions at once, and execute complex workflows without human oversight. They don't use passwords, don't follow business hours, and don't exhibit the human behavioral patterns that traditional security systems depend on for anomaly detection.

Take a typical enterprise AI agent managing supply chain operations. It authenticates with dozens of external APIs, processes real-time data feeds, and makes autonomous decisions affecting millions of dollars in transactions. Most organizations secure these agents using the same methods they use for human employees.

This creates dangerous blind spots. Security teams can't see into machine-to-machine communications, struggle to audit autonomous decisions, and can't verify whether AI-generated actions are authentic. The attack surface keeps expanding while traditional security tools fall further behind.

Why Traditional IAM Falls Short in the AI Era

Human-centric IAM systems make several assumptions that completely break down when machines take over:

Password-based authentication makes no sense for AI agents that need programmatic authentication. Static credentials create security risks, while dynamic token management adds complexity that doesn't scale.

Role-based access control (RBAC) can't handle autonomous agents that need flexible permissions based on real-time context. An AI agent managing cloud resources might need different access levels depending on current system load, time of day, or detected anomalies.

Behavioral analytics built for human patterns can't establish baselines for machine behavior. AI agents legitimately exhibit patterns that would trigger fraud alerts for human users—accessing systems 24/7, processing data at superhuman speeds, or operating from multiple locations simultaneously.

Audit trails become unmanageable when machines generate thousands of authentication events per minute. Traditional logging systems can't capture the context needed to understand machine decision-making or verify autonomous actions.

The core issue is trust. With humans, we rely on legal frameworks, employment contracts, and social accountability. With machines, we need cryptographic proof and mathematical certainty.

The Rise of Identity-Based Attacks

The security implications are already here. Recent studies show over 90% of organizations experienced an identity-based attack in the past year, with machine identities increasingly becoming the primary target.

Attackers go after machine identities because they often have elevated privileges, operate with minimal monitoring, and can execute actions at scale. A compromised AI agent can access sensitive data, manipulate automated processes, or impersonate legitimate systems across an entire network.


Common attack patterns include:

Credential harvesting from poorly secured AI agents or automated systems. Unlike human credentials, machine credentials often sit in configuration files or environment variables with weak protection.

Privilege escalation through compromised automation workflows. Attackers exploit the broad permissions typically granted to AI agents to access systems and data far beyond their intended scope.

Impersonation attacks where malicious actors create fake machine identities that mimic legitimate AI agents or automated systems. Without proper verification mechanisms, these imposters can operate undetected for months.

Detection is the real challenge. Traditional security tools excel at spotting unusual human behavior but struggle with the complex, high-volume patterns that legitimate machine operations generate.

MAIP: The Machine Agent Identity Protocol

The solution requires moving from human-centric to cryptographic trust models. Enter MAIP (Machine Agent Identity Protocol)—an emerging open standard built specifically for AI agent authentication and machine-to-machine verification.


MAIP tackles the unique requirements of machine identities through several key innovations:

Cryptographic identity anchoring gives each machine identity a mathematically verifiable foundation. Instead of passwords or tokens, MAIP uses public-key cryptography to establish immutable identity proofs.

Real-time verification enables instant authentication without depending on central authorities. Machine identities can prove their authenticity through cryptographic signatures that any system can verify independently.

Context-aware permissions let machine identities present different capabilities based on current operational context. An AI agent can cryptographically prove not just its identity, but also its current authorization level and operational constraints.

Audit-ready attestations provide complete visibility into machine actions through cryptographically signed logs. Every decision, access request, and data operation generates verifiable proof that can be audited without slowing down operations.

MAIP shifts the paradigm from "trust but verify" to "verify then trust"—a model that actually works for autonomous systems operating at machine speed and scale.

Building the Machine Trust Ecosystem

Implementing MAIP demands infrastructure that can handle machine-scale authentication demands. The system must process thousands of verification requests per second while maintaining cryptographic integrity and providing real-time responses.

Key infrastructure requirements include:

High-throughput processing to handle the volume of machine-to-machine authentication requests that modern AI systems generate. Traditional IAM systems built for human login patterns simply can't scale to machine requirements.

Hardware security modules (HSMs) to protect cryptographic keys and ensure tamper-resistant operations. Machine identities need higher security standards than human credentials because they often operate with elevated privileges.

Multi-region redundancy to support global AI operations without introducing latency or single points of failure. Machine identities need consistent authentication performance regardless of where they operate.

Offline verification capabilities to ensure machine identities can be authenticated even when network connectivity is limited or compromised. This is crucial for edge computing and IoT deployments.

The infrastructure must also integrate seamlessly with existing enterprise systems while providing flexibility to support emerging AI architectures and use cases.

Truthlocks' Infrastructure for Scale

Truthlocks provides the foundational infrastructure for implementing MAIP at enterprise scale. The platform combines cryptographic proof generation with high-performance verification capabilities designed specifically for machine identity requirements.

The system processes over 10,000 transactions per second while maintaining sub-40ms verification latency. This performance enables real-time authentication for AI agents and automated systems without introducing operational delays.

Security features include FIPS 140-2 Level 3 HSM integration for cryptographic key protection and multi-region redundancy to ensure global availability. The infrastructure supports both online and offline verification through an SDK that enables independent proof validation without central authority dependencies.

Organizations can implement MAIP through Truthlocks' verification infrastructure while maintaining complete control over their machine identity policies and operational requirements. The platform provides the cryptographic foundation while allowing enterprises to customize authentication workflows for their specific AI architectures.

Learn more about enterprise implementation options at truthlocks.com.

From Crisis to Opportunity

The 82:1 machine identity crisis represents both a major challenge and a transformative opportunity. Organizations that tackle machine identity security proactively will gain competitive advantages in AI deployment, operational efficiency, and regulatory compliance.

Moving to cryptographic trust models opens up new possibilities: AI agents that can prove their decisions, automated systems with verifiable audit trails, and machine-to-machine interactions with mathematical certainty rather than assumed trust.

Early adopters are already seeing results. Enterprises implementing MAIP report improved security posture, fewer identity-related incidents, and enhanced ability to scale AI operations with confidence.

The key insight is recognizing that machine identities aren't just more human identities—they require fundamentally different approaches to authentication, authorization, and verification.

FAQ

What exactly is the 82:1 machine identity crisis?

The 82:1 machine identity crisis refers to the current ratio of machine identities (AI agents, IoT devices, automated systems) to human users in our digital ecosystem. This represents a fundamental shift where traditional human-centric security models are inadequate for protecting machine-dominated environments.

How does MAIP differ from traditional IAM systems?

MAIP uses cryptographic proof rather than password-based authentication, provides real-time verification without central authorities, and offers context-aware permissions designed for autonomous systems. Unlike traditional IAM, MAIP is built specifically for machine-scale operations and verification requirements.

Why can't existing security tools handle machine identities effectively?

Traditional security tools rely on human behavioral patterns, password-based authentication, and role-based access control. Machine identities operate 24/7, authenticate thousands of times per second, and need flexible permissions based on real-time context—requirements that overwhelm human-centric security models.

What are the main security risks of unmanaged machine identities?

Unmanaged machine identities create risks including credential harvesting, privilege escalation, impersonation attacks, and blind spots in audit trails. Since machine identities often have elevated privileges and minimal monitoring, they present attractive targets for attackers seeking to operate at scale.

How does cryptographic verification work for machine identities?

Cryptographic verification uses public-key cryptography to create mathematically provable identity assertions. Each machine identity generates cryptographic signatures that can be verified independently, providing certainty about authenticity without requiring central authority validation.

What infrastructure requirements are needed for MAIP implementation?

MAIP implementation requires high-throughput processing (10,000+ TPS), hardware security modules for key protection, multi-region redundancy for global operations, and offline verification capabilities. The infrastructure must handle machine-scale authentication while maintaining cryptographic integrity.

How can organizations start addressing their machine identity challenges?

Organizations should begin by inventorying their machine identities, assessing current security gaps, and evaluating MAIP-compatible infrastructure. Pilot programs with critical AI agents or automated systems provide practical experience before full-scale implementation.

The machine identity crisis of 2026 demands immediate attention, but the solutions are within reach. Organizations that act now to implement cryptographic trust protocols will be positioned to thrive in an AI-dominated future while maintaining security and operational integrity.``

© 2026 Truthlocks, Inc.

Scaling PaddleOCR to Zero: A Multi-Cloud GPU Pipeline with KEDA

2026-04-09 20:31:10

Running GPU-intensive tasks like OCR can get expensive quickly. If you leave a GPU server running 24/7, you pay for idle time. If you use a standard CPU, processing multi-page PDFs takes forever.

We built a document analysis API that solves this by splitting the workload across AWS and Azure, using a "scale-to-zero" architecture. Here is the technical breakdown.

The Architecture

The system follows an asynchronous worker pattern to ensure the API stays responsive even when processing 100-page documents.

1. The Entry Point (AWS)

We use AWS Lambda as our API gateway. It handles the "light" work:

Validation: Checking file signatures (hex headers) to verify if the file is a real PDF/JPG.

Storage: Saving the raw file to Amazon S3.

State Management: Creating a job record in Amazon DynamoDB.

2. The Bridge (Azure Queue)

Once the file is safe in S3, the Lambda sends a Base64-encoded message to Azure Queue Storage. This acts as our buffer.

3. The GPU Worker (Azure Container Apps)

This is where the heavy lifting happens. We use Azure Container Apps running on Consumption-GPU (NVIDIA T4) profiles.

Scale-to-Zero: Using KEDA (Kubernetes-based Event Driven Autoscaling), the GPU workers only spin up when there is a message in the queue. When the queue is empty, the replica count drops to 0, so we stop paying for the GPU.

The Engine: The worker runs PaddleOCR (PP-StructureV3). It handles layout analysis, identifying titles, text blocks, and tables.

PDF Rendering: Since PaddleOCR processes images, we use pypdfium2 to render PDF pages into high-res bitmaps before analysis.

# A look at our page-by-page processing logic
for i in range(start_idx, end_idx):
    page = pdf[I]
    bitmap = page.render(scale=2) # 2x scale for better OCR accuracy
    images_to_process.append(bitmap.to_numpy())

4. Result Delivery

The worker saves two JSON files to Azure Blob Storage:

Raw: Every coordinate and confidence score from the engine.

Normalized: A cleaned version that maps text lines to specific layout regions.

Finally, a Webhook is triggered to let the user know the data is ready for download.

Why Multi-Cloud?

We chose this setup to get the best of both worlds: AWS’s robust API management and DynamoDB, combined with Azure’s flexible GPU Container Apps and KEDA integration. This setup allows us to process complex documents in seconds while keeping infrastructure costs extremely low during quiet periods.

Skip the Infrastructure

Setting up GPU clusters and managing auto-scaling is a headache. Skip the infrastructure work and start using our ready-made API today. You can focus on your code while we handle the servers.
Try out our PaddleOCR API live in your browser at https://www.silverlining.cloud/products/ocr-api

I bootstrapped an SDK that competes with $87M in funded competitors. Heres the playbook.

2026-04-09 20:30:06

I bootstrapped an SDK that competes with $87M in funded competitors. Heres the playbook.

When I started building MnemoPay, I looked at the competitive landscape:

  • Mem0: $24M, 88K weekly npm downloads. Memory only.
  • Skyfire: $9.5M, a16z backed. Payments only.
  • Kite: $33M, PayPal Ventures. Payments + identity only.
  • Payman: $13.8M, Visa backed. Payments only.

The gap was obvious: everyone built either memory OR payments. Nobody built both.

So I built both. Plus identity. Plus fraud detection. Plus a double-entry ledger. Plus multi-agent commerce.

On zero funding.

The lesson: in developer tools, features-per-dollar matters more than total funding. A solo founder shipping 6 features beats a 37-person team shipping 2.

14 modules. Every financial operation stress-tested with 1,000 random cycles. Zero penny drift.

The SDK is free and open source.

npm install @mnemopay/sdk
https://getbizsuite.com/mnemopay

AIagents #AgentBanking #DevTools #MnemoPay

Originally posted on LinkedIn. Try MnemoPay: npm install @mnemopay/sdk