Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Datasette Apps: Host custom HTML applications inside Datasette (simonwillison.net)
96 points by lumpa 11 hours ago | hide | past | favorite | 35 comments
 help



To save anyone else wondering what is Datasette a search:

“Datasette is a tool for exploring and publishing data. It helps people take data of any shape, analyze and explore it, and publish it as an interactive website and accompanying API.

Datasette is aimed at data journalists, museum curators, archivists, local governments, scientists, researchers and anyone else who has data that they wish to share with the world. It is part of a wider ecosystem of 44 tools and 154 plugins dedicated to making working with structured data as productive as possible.”


Hey Simon,

although I'm coming from a different starting point, it seems like some of our thoughts have aligned. I'm building https://caipi.ai/ as a workspace for agents to build simple data driven apps. The agent edits through MCP and the user gets an interactive app in the browser.

If you're interested picking each others brains around this topic, I'd be psyched to have a chat. gh:pietz.


When I've needed something like this in the past I've spun up simple HTML pages and used the json endpoint that all datasette instances come with [0]. I like this new pattern much better, as it keeps your app and data in one place (I remember having some issue with this at the time, though I can't remember what the actual issue was)

So I imagine we could now load some data in to sqlite, design some HTML also loaded in to the db, and deploy. Although looking at the source, it seems like stored apps are expected to be managed by the plugin itself, but I'm sure there's a way around that

[0] Eg from one of the examples - https://datasette.io/legislators/-/query.json?sql=select+*+f... . If you strip the '.json' you get the html view. For what it's worth there's also a '.csv' version.


> it keeps your app and data in one place (I remember having some issue with this at the time, though I can't remember what the actual issue was)

CORS headers?


This seems to attractive side of seeing it, however the striping Json would not be suitable i believe

I'm going to think about how Datasette Apps can work with the apps themselves stored on a filesystem so they can be revision controlled using Git.

I have an idea for a way to edit them through Datasette and have them backed up to Git via a separate mechanism, but having them on disk would be a whole lot more convenient.

Filed an issue here: https://github.com/datasette/datasette-apps/issues/30


Interesting idea, I know there's the fsdir [0] table-valued function / module that allows loading from disk, so it should be possible to modify that or hard-code base list of paths or something

[0] https://sqlite.org/src/file/ext/misc/fileio.c, it allows you to read a directory recursively in the cli (`select * from fsdir("./");`)

Edit: It allows upwards traversals (`select * from fsdir("../../../../etc/passwd");`), so beware


Wow, I didn't know about that one. SQLite never ceases to surprise.

I'm sticking with the Python bundled sqlite3 though so I'm not in a good place to take advantage of that one.


It's probably out of scope for you, but I've used the 'vtfunc' module [0] for a similar purpose actually.

[0] https://github.com/coleifer/sqlite-vtfunc


I never understood why someone hasn't made a framework that makes it stupidly easy to fill an HTML page with SQLite database tables, with all the usual display controls, and with as much "liveness" as desired, and with a protocol (over HTTPS) to manage comms to a server-side instance. SQLite is robust, lightweight, bulletproof - a WASM build belongs on ALL the webpages !

As mentioned below I have been building the 'read' side of this: a data publication platform. I wanted to avoid any server side components. The communication / write part and updating the server-side sqlite database would need running components on the server which I wanted to avoid.

The 'write' part would technically be very doable and not that different from other back-ends.

https://github.com/GhentCDH/Pihka


Something like sync engines? I think there are a bunch nowadays.

https://syntax.fm/show/924/sync-engines-and-local-data


Did you have a look at https://evidence.dev

Like MS Access on web?

Because it's pretty much worthless.

You almost never need just a basic list of all the data in your table, even if you're able to filter and sort it. There's no moat there at all. People need serious BI tools, and that throws simplicity out of the window (PowerBI, QuickSight, etc.).


It is pretty cool that we have browser features like this to rely on.

I remember writing code in the bad old days to parse HTML tags and allowlist specific attributes. Now browsers have a much better solution baked in.

But it still makes me a bit nervous. Seems like a very small bug could sneak in. This is a good example of where I would reach for Fable to double check the implementation and have a lot of extra tests.

(nit: would be nice if the chat box treated Enter and Shift+Enter the way these other companies have trained my brain, but maybe that is a deliberate choice.)


In the three short days we had access to Fable I did have it run a review, and it spotted an issue for me to fix.

Thankfully GPT-5.5 is really strong on security stuff too. I wouldn't have dared build this without a whole lot of Opus/GPT-assisted prototyping and testing along the way.


Looks like a good addition to the datasette ecosystem. I have been working on a similar idea with cusom html around sqlite databases. By default a faceted search interface is generated but by reusing the client side data layer, custom apps are made easy.

The design keeps data and presentation together and even maps do not rely on external services.

I have called it Pihka: https://ghentcdh.github.io/Pihka/ https://github.com/GhentCDH/Pihka


I just went through the github project repository.

It has 119 repositories.

Is this how AI slop looks like in code? Made for the agents, by the agents? Is this separation of concerns or context management with agents as a first class residents and humans merely acting as custodians?


Datasette pre-dates agentic AI

This guy is head slopper of the current moment, for sure.

THen Garry Tan.


Our leader is Boris Cherny.

Simon needs to resist the pelicans(and the django mindset) and Garry needs a new loop which can loop on itself without any human trigger so that the agents can "dream" better. Who knew that it was not just the models which could hallucinate.


Why people feel the need to overload terms like "datasette" I'll never know

I think the current meaning has quite successfully replaced the original usage. Unless you typed this on a Commodore VIC-20, I suppose.

For you maybe, but I've never heard of this site, my only reference for "datasette" is the commodore 1560

I can’t even parse what you’re complaining about. Could you elaborate?

I'm assuming he's talking about the old hardware data cassette vs the software project of the save name?

https://en.wikipedia.org/wiki/Commodore_Datasette vs

https://datasette.io/


My favourite Datassette is the electronic artist.

https://datassette.bandcamp.com/

https://musicforprogramming.net/


I’m assuming they’re just taking about the word dataset.

Either way feels ridiculous, but the human in me wants to know which it is ^_^


    10 PRINT "HAVE YOU TRIED READING IT AGAIN?"
    20 GOTO "https://news.ycombinator.com/item?id=48594798"

I learned to program on a C64 and one of the first programs I wrote myself was an incredible basic "database" (really just a program that could store and then return simple fielded data.)

I named my database management software Datasette as an homage to the C64. I also figured it would be a unique name that would be easy to search for...

... jokes on me, it turns out the retro computing C64 community is way more active than I expected and there are still plenty of people taking about Datasette tape drives online, 30+ years after they stopped being manufactured and sold.


Wow this is very similar to the direction im taking with my new project https://github.com/hank-bond/uix (warning the code base is certainly not messy but the application is barely usable for anything as of this post).

Here the goal is to be a self-assembling harness (akin to pi) but focusing on duplex human-agent interactivity over rendered HTML "apps". To start, it's focused more on the "please review this PR and then generate a one-page report" with the ability to write comments in the actual report that automatically get sent back to the agent. The end goal is closer to offering a substrate for less technical people to be able to build personal applications like

- an interactive wiki maintainer: chat with the agent about an article, pull out sections, append/create concepts in the wiki with the new info - agent code harness: agent tabs to the left, chat in middle, code diffs on the right (like the superset/commander class of apps)

Anyway, I'm really into the "self assembling" class of software where everything is basically just an SDK + Agent. I think we might actually be ushering in a new era of "personal computing" in that it's less friction than ever to personalize your setup to your whims. Anyway, thats the goal I'm reaching for.

It seems many others are coalescing on this idea at the same time, so it must just be in the aether.


People that overuse LLMs I notice all build the same things and have the same ideas. Its one of the many reasons I avoid them, it kinda leads people into this average group where creativity is dead and there's a kinda hive mind controlling them.

Ive witnessed it many times now, im positive this phenomenon exists.


Or, your know, people who are exploring the limit of current tools come across the lack of certain solutions and start building them.

People also build the same things if they have the same needs. That doesn't mean creativity is dead. My life as a software engineer is not that unique of others. This isn't really something to lament. There's nothing wrong with exploring similar ideas.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: