News for hackers. Stuff that matters.

Hoshang07

The 5 layers of safely connecting agents to your databases:

Most AI agents need access to structured data (CRMs, databases, warehouses), but giving them database access is a security nightmare. Here's a layered architecture that addresses this:

Layer 1: Data Sources Your raw data repositories (Salesforce, PostgreSQL, Snowflake, etc.). Traditional ETL/ELT approaches to clean and transform it needs to be done here.

Layer 2: Agent Views (The Critical Boundary) Materialized SQL views that are sandboxed from the source acting as controlled windows for LLMs to access your data. You know what data the agent needs to perform it's task. You can define exactly the columns agents can access (for example, removing PII columns, financial data or conflicting fields that may confuse the LLM)

These views: • Join data across multiple sources • Filter columns and rows • Apply rules/logic

Agents can ONLY access data through these views. They can be tightly scoped at first and you can always optimize it's scope to help the agent get what's necessary to do it's job.

Layer 3: MCP Tool Interface Model Context Protocol (MCP) tools built on top of agent data views. Each tool includes: • Function name and description (helps LLM select correctly) • Parameter validation i.e required inputs (e.g customer_id is required) • Policy checks (e.g user A should never be able to query user B's data)

Layer 4: AI Agent Layer Your LLM-powered agent (LangGraph, Cursor, n8n, etc.) that: • Interprets user queries • Selects appropriate MCP tools • Synthesizes natural language responses

Layer 5: User Interface End users asking questions and receiving answers (e.g via AI chatbots)

The Flow: User query → Agent selects MCP tool → Policy validation → Query executes against sandboxed view → Data flows back → Agent responds

Agents must never touch raw databases - the agent view layer is the single point of control, with every query logged for complete observability into what data was accessed, by whom, and when.

This architecture enables AI agents to work with your data while maintaining: • Complete security and access control • Reduces LLMs from hallucinating • Agent views acts as the single control and command plane for agent-data interaction • Compliance-ready audit trails

If you're building agents that touch sensitive customer information stored across your data stack, Pylar can help!

Show HN: Pylar – Fix over-querying, data leaks, and governance for AI agents

https://www.pylar.ai

Hey HN! We're Hoshang & Vishal, the team behind Pylar - a governed access layer between databases and LLMs. We previously led data and AI and we kept seeing the same problem across teams using LLMs internally: agents are great with unstructured data, but the moment you want them touching your actual systems of record — Snowflake, Postgres, CRMs, product DBs — everything becomes fragile,...

( Read More... | no comments | on HN )
Re:The AI Localhost on Tuesday November 04, 2025 @02:00AM (#45808150)
We’re putting together a small Slack group for ops, data and devs who are hands-on building internal AI agents — people experimenting with things like n8n, LangGraph, Zapier, Make, OpenAI agents, Agno, or custom setups.

The goal’s to share what’s actually working: use cases, architecture ideas, prompt design, and maybe a few fails too.

If you’re building agents for analytics, internal ops, or workflow automation inside your company — would love to have you join.

Re:Would you trust AI to query and act on your company data? on Tuesday September 30, 2025 @09:47AM (#45425390)
@auslegung - Do you let agents touch internal structured data stored in a warehouse (for example)? If so, how do you do that today? Would love to have your thoughts on this - https://youtu.be/98PZMcYQKDI
yes.. that makes a lot of sense to me. I'm almost imagining building an evals layer to show which views were useful (or not) for the agent to do it's thing.. so i'd know whether to increase/decrease the scope of the views + further tuning the custom mcp layers. thoughts on how you'd imagine doing this?
that's a good baseline..db rbac locks scope, but i guess not behavior. inside that schema the agent can still fire off wide scans, weird joins, or grab way more rows than needed.. Ai can write apt queries for sure but there's always a dependancy on the kinda prompt it gets. you may also lose semantic clarity and telemetry .. no way to know if it actually pulled the right data. how would you enforce “only these lookups” or “only these joins” with just db perms? is there a way?

Ask HN: Non-career ending way to let agents touch internal structured data?

right now i wouldn’t trust an ai agent anywhere near my warehouse with raw sql. too risky. what i really want is simple: let the agent only “search” a safe view that i define.. say a join of customers, tickets, and product events.. instead of having free rein over every table.the approach i’m experimenting with is: i build a malloy model of that view (so it’s more graph-like and semantic), then...

( Read More... | 4 comments | 2 points | on HN )

Show HN: Schema aware AI to build data products

https://www.airbook.io

hey hn — we’re hoshang & vishal, co-founders of airbook. it’s an ai-native workspace to build notebooks, dashboards, or even lightweight data apps — all from one place (https://www.airbook.io)we used to run ops and analytics at saas startups and constantly found ourselves juggling 10 tools just to get one thing done - exploration in a notebook, kpis in a dashboard, and re-usable scripts or...

( Read More... | no comments | on HN )

Show HN: Airbook – Cursor for Analytics

Hi HN - We’re Hoshang & Vishal from Airbook (https://www.airbook.io) - An AI native workspace to do all your analytics work in one place.Airbook automatically syncs, cleans and centralizes all your data scattered across HubSpot, Amplitude, GA4, Zendesk, Stripe, Postgres, Snowflake and more - You can then use Airbook AI to build powerful interactive reports and unified dashboards.Here's a...

( Read More... | no comments | 3 points | on HN )
Re:Show HN: A Startup Ops Simulation Game Using Claude on Tuesday May 27, 2025 @10:36AM (#44107404)
fixed a few things, here's a new link - https://claude.ai/public/artifacts/037456ea-caa4-420f-90c0-d...

(the old link still works too)

Nice work!
Re:Convert your data notebook to CDP instantly on Friday January 31, 2025 @10:46AM (#42888762)
Hey HN!

We've been working on Airbook, a tool that helps teams turn their data notebooks into fully functional CDPs—instantly.

Most companies either struggle with fragmented customer data or spend months engineering a homegrown solution.

We thought: what if you could just use the data notebooks you already have?

With Airbook, you can:

Connect to your existing data stack (dbt, BigQuery, Snowflake, Salesforce etc.) Define customer identities, audiences and segments dynamically Sync insights to downstream tools to trigger growth campaigns—without custom pipelines

We'd love to hear your thoughts!

Show HN: Power Growth Campaigns from Your BI Dashboards

https://www.airbook.io

Hello HN! I'm Hoshang, Co-founder of Airbook.We're a team of former data and ops leaders who often struggled with a fragmented analytics landscape—various specialized tools for data pipelines, SQL explorers, BI dashboards, and ad-hoc automation scripts.These tools, tailored for distinct skill sets, unfortunately failed to integrate effectively, leaving valuable insights isolated within...

( Read More... | no comments | 3 points | on HN )
Thanks Peter! You're 100% right. At the moment, we're built to handle reasonably large volumes of data and making it super fast is something we're definitely taking care off.

Older »