Live data from Hacker News

Show HN: Mastra – Open-source JS agent framework, by the developers of Gatsby

github.com

141–150 of 159 posts

Re: Show HN: Mastra – Open-source JS agent framework, by the developers of Gatsby

#141
post #119

The example from the landing page does not exactly spark joy: testWorkflow .step(llm) .then(decider) .then(agentOne) .then(workflow) .after(decider) .then(agentTwo) .then(workflow) .commit(); On a first glance, this looks like a very awkward way to represent the graph from the picture. And this is just a simple "workflow" (the structure of the graph does not depend on the results of the execution), not an agent.

I get the same feeing when I first looked at the LangChain documentation when I wanted to first start tinkering with LLM apps. I built my own TypeScript AI platform https://typedai.dev with an extensive feature list where I've kept iterating on what I find the most ergonomic way to develop, using standard constructs as much as possible. I've coded enough Java streams, RxJS chains, and JavaScript callbacks and Promise…

Kind of similar camp, I checked LangChain and others and ultimately I was like, well, it's not really doing much is it, just adding abstraction on top of what is essentially basic loops and conditional statements, and tbh it feels like in nearly every case I'll never be using them the same way such that some abstraction will help over just making some function helpers myself.

I don't think from first principles there's any broad framework that makes sense to be honest. I'll reach for a specific vector DB, or logging library, but beyond that you'll never convince me your "query-builder" API is going to make me build a better thing when I have the full power of TypeScript already.

Especially when these products start throwing in proprietary features and add-ons with fancy names on top.

Re: Show HN: Mastra – Open-source JS agent framework, by the developers of Gatsby

#142
post #118

Earlier quoted context omitted.

It has concurrency with Promise; it doesn't have parallelism.

And these agents are all network I/O bound by the model services so a lot of use cases don't need threading. I would argue that python is the overrated language when it comes to building agents. Just because it's the language of choice for training models doesn't mean it should be for building apps against them. The dx typescript brings to these types of applications is nice.

    > The dx typescript brings to these types of applications is nice.
Ironically, it only gets halfways there.

What I've found is that teams that want TS probably should just move up to C#; they are close enough [0]. The main thing is that once you start to get serious with your backend API, then data integrity matters. TS types disappear at runtime and it's just JS. So you need a Zod or Valibot to validate the incoming data. Then your API starts getting bigger and you want to generate OpenAPI for your frontend. Now your fast and easy Node/Express app is looking a lot like Spring or .NET...without the headway and perf...the irony.

[0] https://github.com/CharlieDigital/js-ts-csharp

Re: Show HN: Mastra – Open-source JS agent framework, by the developers of Gatsby

#143

Earlier quoted context omitted.

Thanks! The conditional `when` clauses live on the steps, rather than being represented in the workflow, and in fact when we built this for an example, the last step being called depended on the results of the previous two steps. How would you simplify this?

I think the problem is that a 'fluent' chain of calls already expresses a sequence, so the way that 'after' resets the context to start a new branch feels very awkward ... like a GOTO or something It's telling that the example relies on arbitrary indentation (which a linter will get rid of) to have some hope of comprehending it Possibly this was all motivated by a desire to avoid nested structures above all? But for…

You’re right that the syntax was inspired by the desire to avoid nested structures. But the syntax here is interesting as well and fairly readable. Worth thinking about!

Re: Show HN: Mastra – Open-source JS agent framework, by the developers of Gatsby

#144
post #119

The example from the landing page does not exactly spark joy: testWorkflow .step(llm) .then(decider) .then(agentOne) .then(workflow) .after(decider) .then(agentTwo) .then(workflow) .commit(); On a first glance, this looks like a very awkward way to represent the graph from the picture. And this is just a simple "workflow" (the structure of the graph does not depend on the results of the execution), not an agent.

I knew it will be bad when I seen "by the developers of Gatsby", but this is pure comedy.

JQuery plugin for LLM.

Re: Show HN: Mastra – Open-source JS agent framework, by the developers of Gatsby

#145
post #119

The example from the landing page does not exactly spark joy: testWorkflow .step(llm) .then(decider) .then(agentOne) .then(workflow) .after(decider) .then(agentTwo) .then(workflow) .commit(); On a first glance, this looks like a very awkward way to represent the graph from the picture. And this is just a simple "workflow" (the structure of the graph does not depend on the results of the execution), not an agent.

I get the same feeing when I first looked at the LangChain documentation when I wanted to first start tinkering with LLM apps. I built my own TypeScript AI platform https://typedai.dev with an extensive feature list where I've kept iterating on what I find the most ergonomic way to develop, using standard constructs as much as possible. I've coded enough Java streams, RxJS chains, and JavaScript callbacks and Promise…

TypedAI looks solid, was not aware of it! Bookmarked for further research.

Personally I am not fond of the decorator approach and decided to not use it in pgflow (my soon-to-be-released workflow orchestration engine on top of Postgres).

1. I wanted it to be simple to reason about and explicit (being more verbose as a trade-off)

2. There are some issues with supporting decorators (Svelte https://github.com/sveltejs/svelte/issues/11502, and a lot of others).

3. I decided to only support directed acyclic graphs (no loops!) in order to promote simplicity. Will be supporting conditional recursive sub-workflows to provide a way to repeat some steps and be able to branch.

Cheers!

Re: Show HN: Mastra – Open-source JS agent framework, by the developers of Gatsby

#147
post #49

Earlier quoted context omitted.

I don't work in prompt engineering but my partner does and she tells me numerous need for agents in cases where you want some technology which goes and seeks things on the live web and then comes back and you want to make sense of that found data with the LLM and pre-written prompts where you use that data as variables, and then possibly go back into the web if the task remains unsolved.

Can't that be solved with regular workflow tools and prompts? Is that what an agent is, essentially? Or is an agent a collection of prompts with a limited set of available tools?

I think the agent part is deciding how to navigate the web on its own and when it is convinced (and you haven't told it specifically deterministically) it found what it wanted, to come back and work with your prompts. You can't really logic code this into a workflow.

Re: Show HN: Mastra – Open-source JS agent framework, by the developers of Gatsby

#148
post #136

Earlier quoted context omitted.

Thanks! The conditional `when` clauses live on the steps, rather than being represented in the workflow, and in fact when we built this for an example, the last step being called depended on the results of the previous two steps. How would you simplify this?

I think it is just easier to comprehend if the edges/dependencies are explicit (as an array for example).

We have a ticket to allow this actually!

Re: Show HN: Mastra – Open-source JS agent framework, by the developers of Gatsby

#149
post #119

The example from the landing page does not exactly spark joy: testWorkflow .step(llm) .then(decider) .then(agentOne) .then(workflow) .after(decider) .then(agentTwo) .then(workflow) .commit(); On a first glance, this looks like a very awkward way to represent the graph from the picture. And this is just a simple "workflow" (the structure of the graph does not depend on the results of the execution), not an agent.

I get the same feeing when I first looked at the LangChain documentation when I wanted to first start tinkering with LLM apps. I built my own TypeScript AI platform https://typedai.dev with an extensive feature list where I've kept iterating on what I find the most ergonomic way to develop, using standard constructs as much as possible. I've coded enough Java streams, RxJS chains, and JavaScript callbacks and Promise…

Can dbos work with CF durable objects?

Re: Show HN: Mastra – Open-source JS agent framework, by the developers of Gatsby

#150
post #20
post #13

Impressive. Have you seen any success with Mastra being used to build voice agents? Our company has been experimenting with VAPI, which just launched a workflow builder into open beta ( https://docs.vapi.ai/workflows ), but it has a lot of rough edges.

We're just starting to do that and have a few TTS providers: ElevenLabs, OpenAI, PlayAI. We hear a lot from people who are outgrowing the voice agent platforms and moving to something like pipecat (in Python), and we'd love to be the JS option.

Is any of the voice stuff in any way 'natural' sounding, I'd love to be able to recreate the ChatGPT app voice experience in my own app with a custom agent, but it just sounds robotic and crap
Post reply on HN