It’s called chatlas, but it’s not about making only chat bots. It’s a module for interacting with LLMs. It lets you send in prompts and get back structured, defined, responses. In the examples you can see them using it for entity recognition. sentiment, etc.
Ah ha, I was able to reproduce your example with chatlas… (I don't think I can do markdown in here?)
```
from chatlas import ChatAnthropic
chat = ChatAnthropic(
api_key=anthropic_key
)
res = chat.chat_structured(comment_text,data_model=CommentAnalysis)
res.model_dump()
```
Not sure it's any *better* than LiteLLM (which I haven't tried) but it offers very similar structured functionality.
I did slightly tweak the CommentAnalysis class to put a class level docstring which I think Chatlas wants...
I think, from the functionality and how the developers describe it, it's mostly geared at chat apps--it's solving some specific problems that I don't have for unstructured text data pipelines. You can get structured output, but litellm is much more mature in terms of tooling and has such a bigger user base that I'd stick with it unless I needed additional functionality. For instance, I don't have to use a separate function for Anthropic, I can just swap out model name/provider.
That all makes sense. I am very much an LLM skeptic, but at Positconf was challenged to actually use the apis and try to make something - not just use the chatbot interfaces on the web site. Then I could be an informed skeptic. And since chatlas is from Posit, and it was mentioned repeatedly at the conference, that's what I tried out. I didn't know Litellm was a thing!
My toy app summarizes my bluesky feed. It's… fine? It costs a few cents to run with Sonnet. But after the novelty wore off, I don't run it most days.
(I did find a ChatAuto class, fwiw, that is model-agnostic)
Posit is doing great work in terms of AI. The Shiny Assistant really impressed me. And Databot looks cool, but I'm not a Positron user: https://posit.co/blog/introducing-databot/
Have you tried Posits chatlas library? It also lets you define structured responses, using pydantic.
https://posit-dev.github.io/chatlas/get-started/structured-data.html
I'm not building chat apps, so I think it's not my use case.
It’s called chatlas, but it’s not about making only chat bots. It’s a module for interacting with LLMs. It lets you send in prompts and get back structured, defined, responses. In the examples you can see them using it for entity recognition. sentiment, etc.
Ah ha, I was able to reproduce your example with chatlas… (I don't think I can do markdown in here?)
```
from chatlas import ChatAnthropic
chat = ChatAnthropic(
api_key=anthropic_key
)
res = chat.chat_structured(comment_text,data_model=CommentAnalysis)
res.model_dump()
```
Not sure it's any *better* than LiteLLM (which I haven't tried) but it offers very similar structured functionality.
I did slightly tweak the CommentAnalysis class to put a class level docstring which I think Chatlas wants...
I think, from the functionality and how the developers describe it, it's mostly geared at chat apps--it's solving some specific problems that I don't have for unstructured text data pipelines. You can get structured output, but litellm is much more mature in terms of tooling and has such a bigger user base that I'd stick with it unless I needed additional functionality. For instance, I don't have to use a separate function for Anthropic, I can just swap out model name/provider.
That all makes sense. I am very much an LLM skeptic, but at Positconf was challenged to actually use the apis and try to make something - not just use the chatbot interfaces on the web site. Then I could be an informed skeptic. And since chatlas is from Posit, and it was mentioned repeatedly at the conference, that's what I tried out. I didn't know Litellm was a thing!
My toy app summarizes my bluesky feed. It's… fine? It costs a few cents to run with Sonnet. But after the novelty wore off, I don't run it most days.
(I did find a ChatAuto class, fwiw, that is model-agnostic)
Posit is doing great work in terms of AI. The Shiny Assistant really impressed me. And Databot looks cool, but I'm not a Positron user: https://posit.co/blog/introducing-databot/