Alcides Fonseca.AI & Programming Languages researcher
40.197958, -8.408312

Making intelligent software
more reliable.

I work on the intersection of AI, Software Engineering and Programming Languages. Currently, I am applying Formal Methods to Agents, towards AI Safety.

Program synthesisLiquid typesReliable AIGuardrailsEvals

Subscribe to the RSS Feed for new Society posts.

Are we finally solving micro transactions on the web?

I've previously written about how I believe the open web is dying. Maybe one solution to prevent it, and to save anonymity on the web is to finally fix the micro-payment that no-one ever solved.

Disclaimer: I started developing during the Web 1.0 age (a.k.a. dotCom era) and substantially improved my engineering skills during the Web 2.0 movement. I completely skipped all the Web 3.0 craze (unless you count the original Web 3.0 — the Semantic Web) not necessarily because of technical limitations, but because of the community around it. Now that everyone moved to AI, I think we can look at blockchain again, with more sober eyes.

Agents have the potential multiply the web traffic by a thousand fold or more. As an early example in software engineering (the early adopters of autonomous AIs), git traffic has increased in Github and at Anthropic and OpenAI so much they all needed new infrastructure to handle this increased load. The same is happening all across the industry.

AI-generated illustration for a small robotic agent buying a webpage from Brave

As agents become the UI for the whole internet, many service providers lose their ad-based income and become unsustainable. I applaud Brave's initiative to change the economics and start charging for agent access (although I believe it will spill over to human access as well).

Pricing follows Brave’s published API rates: LLM Context, an API designed specifically for providing search context for agents, will cost $0.005 ($5 per 1,000). Additionally, web (search for humans), news, image, video, and local endpoints will also be available for $0.005 ($5 per 1,000). Gas fees for transacting on the Base blockchain will be covered for a limited time. Since each request carries its own payment, a Brave Search API account is no longer needed to use the service.

— The Brave Search API now accepts agentic payments via the x402 protocol

Anonymous (as anonymous as blockchain can be) payments may solve the problem of the anonymous internet. You no longer need to create user accounts and prove you are human. As long as you pay for the service it does not matter. Except for age verification, which is still a problem. But it solves the lack of monetization of past-user-facing services that are now MCP providers and APIs. And at the same time it might also help prevent DDoS attacks from LLM crawlers, such as the ones this website has been suffering from (Hello dear Singaporean bots!).

Brave will be using the x402 protocol, which I was unaware of, despite knowing the 402 error code. That protocol is not yet widespread, but if bigger players start adopting it, maybe with an Apple Pay-like authorization prompt guard railing agentic purchases, we might see it succeed soon.

Habitação Insustentável em Portugal

A realidade da habitação em Portugal é completamente fora deste mundo. A minha geração e a mais nova não consegue pagar o custo que a habitação tem sido nas grandes cidades, nem no Algarve.

O Ivo Bernardo fez uma análise da situação da habitação em Portugal, baseado em números públicos de uma variedade de fontes.

Data on Housing costs, considering cost of living

  • Public housing: this is where the data sides most with the protesters. Social rental housing is 1.1% of dwellings in Portugal, against an EU average of 8%. At €150,000 per home, 3% financing and public land, a cost-rent home in Lisbon breaks even at about €10.9/m² a month, 35% below the city’s median new rent. It can almost pay for itself exactly where it’s needed most. Remember the €1.74 billion NHR cost in 2024? That’s roughly 11,600 of those homes. In one year.
  • Vacant homes: worth chasing, in the right places. The 100,000-plus recoverable homes in pressure municipalities are real.
  • Limiting investment funds: I can’t back it or reject it, because the data doesn’t exist. Before we legislate, we need to measure.

— The housing crisis in Europe pt1 by Ivo Bernardo

Por sua vez, o João Tomé usa também dados reais para analisar a questão das casas vazias.

Em 2021, quase 249 mil casas estavam vagas por outros motivos, fora do mercado, em edifícios sem necessidade de reparação ou apenas com reparações ligeiras. Os dados ajudam a localizar uma possibilidade de resposta à falta de habitação. Ainda não dizem quantas dessas portas se podem abrir. As experiências de outros países ajudam a escolher o que tentar: apoiar obras, gerir o arrendamento e reforçar a oferta nas zonas com procura.

— Quantas casas vazias podem voltar a ter gente? por João Tomé

O artigo inclui ainda uma tabela com referências para medidas que foram implementadas noutros países e os resultados.

De ambos os estudos, a minha conclusão é que precisamos de mais construção e reabilitação, precisamos de melhores números e acompanhamento da situação e, sobretudo, precisamos de descentralizar a população nas grandes áreas metropolitanas.

Infelizmente, manifestações de tendas dão-me pouca confiança que algo vá mudar. Mas termos novas iniciativas políticas que trabalhem estes desafios parece-me algo com maior probabilidade de funcionar. O resultado na Sérvia de um movimento estudantil ganhar as eleições inspira-me confiança, mas não podemos ter a taxa de abstenção que tem sido habitual no nosso país.

The internet was built on hypertext. Now hypertext is a premium feature

If you subscribe to a Meta One plan, you can add links to a set number of posts and reels each month based on your plan:

  • Meta One Advanced plan: up to 4 posts and 4 reels with links per month
  • Meta One Expert plan: up to 8 posts and 8 reels with links per month
  • Meta One Max plan: up to 12 posts and 12 reels with links per month

Meta is trying to sherlock Linktree. But I can't stop and think it's completely bananas that the internet was built on hypertext and openness, and Instagram created a silo and now it's requiring content creators to pay so their users can have a way out.

ChinAI #374: China’s first AI-generated longform TV series

Published in the 16th century, Journey to the West is a classic Chinese novel that tells the tale of Sun Wukong, a mythological monkey that helps a Buddhist monk journey to India. Among the many published sequels to Journey to the West, one of the three main ones, written by an unknown author, is The Later Journey to the West [后西游记]. In this sequel, the story shifts to Sun Xiaosheng, a young stone monkey who grows up on the same mountain long after Sun Wukong departed on his journey.

On August 31, Mango Excellent Media’s TV adaptation of this novel premiered during prime time. “It’s the first-ever fully AI-generated entertainment to hit mainstream provincial satellite prime time,” writes Mandy Wong. After seeing Bytedance Seedance 2.0’s (AI text-to-video model) release earlier this year, the team behind Journey to the West felt there was an opportunity to make a long-form series and break through a market “saturated with uninspired short-form dramas.” In this week’s feature translation (link to Huxiu article), Shuhan Liu reports on the makings of this AI-generated TV series.

Key Takeaways: From initial planning in March of this year to the premiere on August 31, the project took just six months (traditional TV dramas take 1-2 years). ByteDance’s Seeedance 2.0 and 2.5 models generated all the visuals, without live-action actors and filmed footage.

— ChinAI #374: China’s first AI-generated longform TV series by Jeffrey Ding

In the way-less-protective-than-europe US, there are writers’ strikes that prevent this from happening. What if, just as crazy idea, China decides to produce English-speaking TV shows?

It’s the screens, stupid! - by Alexander Thompson

Post-literacy is different from illiteracy. We can still read, but we prefer videos and podcasts to writing. This laziness is transforming us from a written society into an oral society. Oral societies think in ways that are more tribal than written ones: they are more forgetful, irrational, superficial, and simplistic. Thus, democracy, and perhaps the enlightenment itself, is imperilled.

— It’s the screens, stupid! by Alexander Thompson, a review of James Marriott's The New Dark Ages

Worth the rid to understand the relationship between screens (and their different nature) and society.

The expectations of privacy in driverless cars – Terence Eden’s Blog

The 15-year-old passengers were riding in a driverless autonomous car around San Mateo Monday afternoon. The teens drank alcohol inside the Waymo taxi and shot Orbeez beads with a toy gun toward other vehicles.

A Waymo employee, who was remotely monitoring the car, tricked the unruly teenagers, authorities said. The employee told the young passengers that the Waymo was having mechanical issues and needed to stop.

Unknown to the teens, the employee had also called the San Mateo Police Department to report that a gun was firing from the car.

— The expectations of privacy in driverless cars – Terence Eden’s Blog by Terence Eden

Driverless cars are public spaces, currently owned by private companies who have the interest in protecting their property (the car) and their business (by being law-abiding, and avoiding issues like people dying in their cars).

Once (or if...) driverless cars become state owned, then I think that discussion should be relevant again.

Monopoly, Black Mirror Edition

Wizard of Id — 13th September 2026

— Wizard of Id — 13th September 2026

Not being a fan of monopoly when it comes to Good Boardgames™ (try Suburbia or Tigris & Euphrates if you want something actually good), but we really need an interactive media experience closer to Black Mirror or Years and Years. AI Safety is a big issue today, but no one wants to watch or play the media from the 80ies (WarGames), 90ies (The Net) or 2000s (I, Robot, A.I., Minority Report).

Consumer protection and environmental impact

In the late 1970s, concerned by resource use and scarcity, German industrial designer Dieter Rams developed his “ten principles for good design”. Among other things, he argued for design that is long-lasting and environmentally friendly. Half a century later, his concerns are more relevant than ever.

Repair is vitally important to making this happen, but current options are often limited or unaffordable. When a device breaks, consumers can struggle to find repair information, let alone spare parts. This means it is often easier, quicker and cheaper to buy a whole new device.

Building on the success of ecodesign laws and energy labels that drove efficiency improvements in products and homes across Europe, the 2024 European Sustainable Products Regulation sets out a framework for wider product sustainability, with repairability as one of its core principles. Similarly, the EU Batteries Regulation set requirements and conditions for how easy it is to replace batteries.

— The EU’s repair policies are changing the way tech is designed

Personally, I believe the best course of action is to make product companies a stakeholder that aims to have longer lasting products, instead of regulation around electronics. The Australian Consumer Law gives assurances that the acquired goods are of acceptable quality, which includes their duration. If a car or a phone does not last for the expected lifetime of that device, the seller is liable. In Europe, we simply require products to have a longer by-default warranty (4 years for phones instead of 2+1) and manufacturers would now care about repairability and durability of their devices. And, since we're asking, this could include Software and Security updates as well.

Spaniards are having dinner earlier

Dinner in Europe can range from 6pm (in Nordic countries) to 10pm in Spain and Italy. Portugal sits in the middle at 8pm, although I have the feeling it is moving towards 9pm.

The Fork and CoverManager report that the average dine out in Spain is now before 9pm, and Cataluña's survey reports the same trend.

While the reasons for the change are not entirely clear, Marta Junqué Surià, the director of Time Use Initiative, a nonprofit based in Barcelona that advocates for policies around sleep and wellness, pointed to the pandemic, which ruptured old routines, and suggested more people were seeking the health benefits associated with earlier mealtimes.

— The 10 P.M. Dinner Is a Spanish Tradition. Are People Giving It Up? by Jonathan Wolfe (NYT) (via Tyler Cohen)

Copyright, AI and the Future of the Web

Gorillaz’s Damon Albarn and Kate Bush are among 1000 artists who launched a silent album (on Spotify no less) in protest against the UK government allowing AIs to be trained using copyright-protected work without permission.

This protest highlights the tension between creating valuable tools and devaluing human content.

The value of AI

ChatGPT (and even Apple Intelligence) is trained on information publicly available on the internet, data from (consenting) third parties, and information provided by their employees or contractors. Over the last year and a half, people have been amazed at what ChatGPT has been able to do. Although the quality of its work fluctuates as new data/methods are being updated, ChatGPT and similar tools are being used to create value. But at what cost?

Unconsciously, The Algorithm has become more and more important in our lives. From Instagram and TikTok reels, X and Facebook timelines, Spotify, YouTube, or Netflix’s recommendations, the decision of what we see is no longer ours. And we are also not delegating our choices to a human editor (as is the case of the old boring telly or radio channels). Those decisions are being made by black-box algorithms that are hidden in the shadows.

The EU AI law, which I blogged about before, only requires explainability for applications in high-risk domains. Entertainment can hardly be thought of as high-risk. However, I would argue that given the importance of online content consumption in today’s society, it should be considered high-risk. One example is the perceived power of Twitter/X in political elections.

On the other hand, educational purposes are considered fair use in most countries (which is certainly true here in Portugal). What is the difference between fair use for human and machine learning? As we become increasingly dependent on AI for our daily tasks – I use Siri and Reminders to augment my memory and recalling ability — we become de facto cyborgs. Is there a difference between human and machine learning for education?

The devalue of Human content

In 2017, Spotify introduced the Perfect Fit Content program, encouraging editors to include songs purposely designed to fit a given mood in their playlists. Liz Pelly goes into all the details in her piece The Ghosts in the Machine. Some human, some AI, several companies have been starting to produce music à lá carte for Spotify.

According to The Dark Side of Spotify, Spotify investors are also investing in these companies (phantom artists on the platform, which use random names with no online presence other than inside the platforms) and promoting the use of AI to beat the algorithm. While this vertical integration might be cause for considering anti-trust or monopoly issues, the fact is that Netflix has been successful in expanding to content production (as has Disney been successful in expanding into content distribution).

AIs are much more productive in generating music than humans. Which is not necessarily the same as being successful in producing music a) that humans enjoy or b) that is commercially viable. The Musical Turing Test is almost solved, addressing a). Commercial viability is even easier to address. Because the cost of producing AI music is so low compared to the human equivalent, AI companies can flood the market with millions of songs, letting the algorithm filter out the ones that do not work. In that scenario, human musicians are not just competing with each other for user’s attention but are now unable to be showcased to users without an explicit search. Additionally, AI can better cater to some audiences based on data extracted from these networks (remember Spotify’s investors also investing in AI music production companies?) than humans can, at least in large numbers.

And I’m aware AI can be a tool for musicians, but if AI can perform end-to-end music generation passing the Musical Turing Test, it becomes much more interesting from a commercial standpoint.

The only chance for musicians is to promote their own content outside of these platforms, abandoning the initial goal of Web 2.0, where anyone can create content on the web. They can, but it just won’t be discoverable in the ocean of AI-generated content. But this is a symptom of a more significant problem for the web.

I feel like the people who try to be positive – well, I don’t know what they’re doing. I’m a music producer and also a writer who also happens to make art/design her own album art. Thankfully, I also dance, which is going to be the one thing that saves me I feel. — PrettyLittleHateMaschine on AI music.

The quality of AIs depends on human

ChatGPT was primarily trained on internet-available content. So, its quality depends on what is available at a given time. If we stop collecting new information, we can assume its quality will remain unchanged. Still, it will not be helpful with new information, such as news updates or scientific discoveries. Its usefulness will be reduced.

On the other hand, if the quality of AIs increases — it’s more and more difficult to tell the difference between human and GPT-generated text — and it passes the Turing test, the content available online will be more and more AI-generated than human-generated, as it’s more economical to use AI to produce text, audio or even video.

Here, we consider what may happen to GPT-{n} once LLMs contribute much of the text found online. We find that indiscriminate use of model-generated content in training causes irreversible defects in the resulting models, in which tails of the original content distribution disappear.

— AI models collapse when trained on recursively generated data

This recent Nature paper reports that LLMs perform worse when trained on LLM-generated content. Human content is now essential! LLM companies need high-quality human content to train their next-generation models, especially concerning novel knowledge. But econmics no longer work. Content is created once, consumed once, and used to generate millions of derivates for almost free. An author might publish a book, hoping to make the money for the time it took to write from the sum of all individual sales. However, AI companies will not buy the book at its production cost to train a model. Same for daily news. The human audience is still needed to make this work. And suppose everything is made available for free on the web. In that case, humans are making the same mistake that led to ChatGPT being in business without contributing to the original content sources.

The current Web is not enough.

Web 2.0 died and now the web happens more and more inside silos. Famously, Instragram does not allow for links outside its app. “Link in the bio” will be listed as the cause of death in Tim Berners Lee’s obituary. It goes against what the web was supposed to be. But today’s personal entertainment happens in silos (Instagram, Netflix, Disney+, etc…), not on the open web. Even Reddit communities have started blocking links to some websites, like X.

The web failed at microtransactions. Paying 10 cents for reading a well-written article was the original goal. Even with Paypal and Apple Pay, the model was only successful for large purchases, not pay-per-view. Imagine that you give Youtube your credit card, and it takes 1 euro for each hour watched. Once you have something for free, it is difficult for companies to make you pay for it.

As a business that moved from analog to digital almost completely, most news outlets have failed to change their economics and they are now struggeling financially. As the price of advertising online has decreased over the past years, they have switched to a subscription model, putting up paywalls with dubious outcomes.

The future of the Web

I foresee a web where high-quality human content is behind paywalls. While most of the web can be AI-generated and free, it will be ignored if high-quality content is available from trusted sources. Content will be signed and (possibly) encrypted using personal keys. These keys can be provided by the government, or other parties. For instance, every Portuguese citizen already has their keys inside our citizen cards, sometimes with professional attributes.

If you wanted to read the news, you can go to an online newspaper, where the content will be signed by a recognized journalist or editor. The body of the text can be encrypted but with a faster Apple Pay-like prompt, you can pay cents to read it. Even if the journalist published AI-generated content, they are liable for its content.

This proposal makes the web a more trustful place and somewhat addresses the economic problems of paying for content on the web. It requires payment processors to drop the minimum cost per transaction, which I believe is happening more and more. And as more and more garbage is published online, users will see the need to pay for high-quality content.

As for AI providers, they will now have to pay for content. And even if it is ridiculously cheap, there is a trace that they bought that information, useful when you want to prove in court that your content was used in training LLMs.

We might not get to this Web, but I hope some of this ideas help the web survide the tsunami of garbage content that is starting to flood our dear World Wide Web.