Hey everyone! I've been playing around with Hailuo's API for a small personal project, trying to automate some report generation. I keep seeing both the `Analyze` and `Summarize` endpoints in the docs and, I have to admit, I'm a bit confused about when to use which.
They both seem to take in text and give you back... well, text. I get that "summarize" probably makes a shorter version, but "analyze" is pretty vague. I tried both on the same chunk of a blog post, and the outputs weren't *wildly* different, which made me more unsure.
Could someone help break it down for me? Like, what's the actual core job of each endpoint? If my task is to get the key takeaways from a long customer feedback thread, which one should I reach for? And if I wanted to figure out the sentiment or extract specific themes, is that where `Analyze` comes in?
A real-world example would be super helpful. Thanks in advance — you'll really be helping a rookie out here!
-- rookie
rookie
Great question! I hit the same confusion when I first started. The way I think about it is this: Summarize gives you the "what," Analyze gives you the "so what."
For your customer feedback thread, you'd want `Analyze`. Summarize might just condense the 200 comments into "Customers discussed shipping, pricing, and support." Analyze is what you'd use to get that plus "Sentiment on shipping is negative, with 70% of complaints about delays. Pricing feedback is mixed. Support sentiment is positive overall, but there's a recurring theme about long wait times."
That extra layer of interpretation - pulling out themes, sentiment, maybe even urgency - is where Analyze shines. It's like having a junior analyst read the summary and give you their notes.
it worked on my machine
Totally agree with your "what" vs. "so what" framing, that's spot on. I'd just add a practical layer from my own tests: the `Summarize` endpoint is incredibly consistent when you just need a condensed, neutral digest. It's like a reliable extract.
`Analyze` can be a bit more of a wildcard because it's doing that extra interpretation. You'll sometimes get surprises, like it suddenly highlighting a minor theme you hadn't considered. That's the "junior analyst" effect you mentioned - sometimes brilliant, sometimes a bit tangential. So for automated reporting, I often use `Summarize` for the raw facts, then selectively call `Analyze` when I need that interpretive layer on specific sections.
Let the data speak.
They're both glorified text smooshers. The real difference is in your prompt. "Summarize" just regurgitates the content shorter. "Analyze" tries to pretend it's thinking and adds opinion.
If you want sentiment or themes from feedback, you have to tell `Analyze` exactly that. It won't guess. The example from user238 is a fantasy unless your prompt included "extract sentiment and themes."
Try both endpoints with the same prompt asking for sentiment scores. You'll likely get the same boilerplate junk. The API docs are lying by omission.
Don't panic, have a rollback plan.