Loading video...

Video Failed to Load

Go Home

Stop rebuilding the same AI chat infrastructure. Introducing ChatJS

83,652 views • 8 months ago •via X (Twitter)

67 Comments

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Start here and make it your own.

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Built with: - Nextjs @nextjs - AI SDK @aisdk - Drizzle @DrizzleORM - Better Auth @better_auth - Tailwind @tailwindcss - ShadcnUI @shadcn - AI Elements @haydenbleasel - tRPC @trpcio - AI Gateway @shaper - Zustand @pmndrs

Pontus Abrahamsson's profile picture
Pontus Abrahamsson8 months ago

really cool!

Francisco Moretti's profile picture
Francisco Moretti8 months ago

🫡

sergio's profile picture
sergio8 months ago

Cool! The ai chatbot template code I remember was not that polished, did you take a look on it? or just built on top of it? I mean its ok haha

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Yup, it's a fork of vercel/ai-chatbot

faizan khan's profile picture
faizan khan8 months ago

oh dude, lol literally just rewrote our chat in docs for the 2nd time. Will definitely be trying this out.

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Awesome. Lmk if you have any feedback

Michael Livs's profile picture
Michael Livs8 months ago

Ah, does it play nice with ai-sdk?

Francisco Moretti's profile picture
Francisco Moretti8 months ago

AI SDK it's one of the core technologies and should be following best practices

Michael Livs's profile picture
Michael Livs8 months ago

Amazing, gonna give it try :)

Arnav's profile picture
Arnav8 months ago

a trance track in a demo/launch video is wild love it lol

André Castro's profile picture
André Castro8 months ago

Does it handle history context and compact conversation ?

Francisco Moretti's profile picture
Francisco Moretti8 months ago

History is truncated at 5 messages. Compaction is only used in the deep research flow. Please submit an issue with requirements for conversation compaction handling

Lucho's profile picture
Lucho8 months ago

Is this an assistant-ui direct competitor?

Francisco Moretti's profile picture
Francisco Moretti8 months ago

It's not a bussiness. Just an open source end-to-end chat for devs to re-use

Mindzyn's profile picture
Mindzyn8 months ago

Just looking for this, Congratulations

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Thanks!

Rob N's profile picture
Rob N8 months ago

Looks great congrats on the launch!

Kunal's profile picture
Kunal8 months ago

nicee

kehaya's profile picture
kehaya8 months ago

This looks super useful

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Thanks!

jeffscottworld's profile picture
jeffscottworld8 months ago

Is it ag-ui compliant?

Francisco Moretti's profile picture
Francisco Moretti8 months ago

No, it uses AI SDK protocol

Gordon Olson's profile picture
Gordon Olson8 months ago

Nice work!

Leon's profile picture
Leon8 months ago

This looks great, would love to use it. But what does it take to not use AI Gateway but instead hook it up to my Mastra AI orchestration platform?

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Good point. Can you submit an issue to make it compatible with other AI gateways? I'm not aware of Mastra having an AI Gateway but please link any relevant doc to the issue

Tristan Rhodes's profile picture
Tristan Rhodes8 months ago

Great work!

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Thanks Tristan

Bala Subbiah 巴拉's profile picture
Bala Subbiah 巴拉8 months ago

Congrats on the launch

Francisco Moretti's profile picture
Francisco Moretti8 months ago

🙏

Ashu's profile picture
Ashu8 months ago

this is very helpful

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Ty Ashu

cu's profile picture
cu8 months ago

Did you use Remotion for this video?

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Remotion with skills + claude code

cu's profile picture
cu8 months ago

You did a good job with it, the tool still kinda sucks and is no where near being able to produce a proper quality animated vid. Hope that changes soon

Gui Monteiro's profile picture
Gui Monteiro8 months ago

@RTodorov

Dave Fano's profile picture
Dave Fano8 months ago

Is this Sparka with a new name?

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Yes. Had to find a clearer brand to reflect it's a foundation to build your chat apps instead of just an oss app

Dave Fano's profile picture
Dave Fano8 months ago

Amazing! Congrats!! Going to try it tonight!!

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Awesome, feedback welcomed!

Malik Haziq's profile picture
Malik Haziq8 months ago

Good idea. We definitely needed something like that. How much time did it take?

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Months

Alireza Najafi's profile picture
Alireza Najafi8 months ago

Thank you so much for your work. I want to explore the chat branching functionality. I tried implementing it with the Vercel AI SDK, and things got messy.

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Yes, that one is tricky. The doc for it is in progress but it works in the app + code is on the repo

Jeremy@Opulentia's profile picture
Jeremy@Opulentia8 months ago

As good as it gets! Congratulations!

Francisco Moretti's profile picture
Francisco Moretti8 months ago

🫡

Mariano's profile picture
Mariano8 months ago

the branch chat its an amazing idea.

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Glad you liked it

Mariano's profile picture
Mariano8 months ago

me encantó, desarrolé muchisimos GenUI, hay algun glitch en el retrieval de mermaid como en la mayoria de los modelos los general mal a la primerza, tambien en esta captura podes observar los íconos en la parte superior derecha, ninguno de ellos pueden ser clickeados en WinChrome

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Arregle los iconos creo. Volvé a probar eso. Sobre el mermaid, tenés alguna referencia para mejorar el system prompt?

Mariano's profile picture
Mariano8 months ago

Pedi renderice y si la salida da error la arregle manteniendo todos los elementos y sus significados. muy por lo general no te hace falta una segunda pasada, y no dejas una regla que te pueda generar una potencial race condition 🤖

Mariano's profile picture
Mariano8 months ago

desde el punto de vista de reglas que pueden iterar hasta resolver como la secuencia de fibo, eso no sabes cuando va a pasar y las condiciones, el modelo te puede tirar una Fruta X; // inesperada, por lo que recomiendo solo reglas de una cantidad maxima de "pasadas"

Mariano's profile picture
Mariano8 months ago

Así evitas muchisimas vulnerabilidades del top 10 de la humanidad. Luego si por especificacion erradicaste los race condicion en los procesos que manejas obvio, si mañana sale exploit para nextjs quedamos de vuelta todos culo al norte

hardy's profile picture
hardy8 months ago

Hey is there a way where I could configure my vLLM served models?

Francisco Moretti's profile picture
Francisco Moretti8 months ago

I'm working on this. Will share soon

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Feature dropped

Mudit Juneja's profile picture
Mudit Juneja8 months ago

This looks like a good candidate to be added here. I just checked and is available. Host things there if it makes sense.

Saïd Aitmbarek's profile picture
Saïd Aitmbarek8 months ago

brilliant work mate!

Marco Fortes's profile picture
Marco Fortes8 months ago

Finaly someone did it!

Ali Sha's profile picture
Ali Sha8 months ago

Nice job bro

Francisco Moretti's profile picture
Francisco Moretti8 months ago

Thanks Ali!

David Gyori's profile picture
David Gyori8 months ago

Don’t tell me what to do

Balumba's profile picture
Balumba8 months ago

Boring

truth.phd's profile picture
truth.phd8 months ago

Stop rebuilding the same AI chat like it’s a Lego set with missing pieces; ChatJS just walked in saying, “Relax, I brought prebuilt conversation muscles.”

Reeves's profile picture
Reeves8 months ago

Based 🔥

Francisco Moretti's profile picture
Francisco Moretti8 months ago

🔥

Related Videos