Propan
pydantic
Propan | pydantic | |
---|---|---|
16 | 167 | |
466 | 18,617 | |
- | 2.1% | |
8.8 | 9.8 | |
about 1 month ago | 7 days ago | |
Python | Python | |
MIT License | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
Propan
-
FastStream: Python's framework for Efficient Message Queue Handling
Later, we discovered Propan, a library created by Nikita Pastukhov, which solved similar problems but for RabbitMQ. Recognizing the potential for collaboration, we joined forces with Nikita to build a unified library that could work seamlessly with both Kafka and RabbitMQ. And that's how FastStream came to be—a solution born out of the need for simplicity and efficiency in microservices development.
-
How we deprecated two successful projects and joined forces to create an even more successful one
The next step was to figure out what to do next. We posted questions on a few relevant subreddits and got quite a few feature requests, mostly around supporting other protocols, encoding schemas etc. But, we also got a message from a developer of a similar framework Propan that was released at about the same time and was gaining quite a traction in the RabbitMQ community. That developer was Nikita Pastukhov and he made an intriguing proposal: let's join our efforts and create one framework with the best features of both. Both projects were growing at roughly the same speed but targeted different communities. So the potential for double growth was there. After a quick consideration, we realized there was not much to lose and there was a lot to gain. Of course, we would lose absolute control over the project but losing control to the community is the only way for an open-source project to succeed. On the positive side, we would gain a very skilled maintainer who single-handedly created a similar framework all by himself. The frameworks were conceptually very similar so we concluded there would not be much friction of ideas and we should be able to reach consensus on the most important design issues.
-
Introducing FastStream: the easiest way to write microservices for Apache Kafka and RabbitMQ in Python
FastStream simplifies the process of writing producers and consumers for message queues, handling all the parsing, networking and documentation generation automatically. It is a new package based on the ideas and experiences gained from FastKafka and Propan. By joining our forces, we picked up the best from both packages and created a unified way to write services capable of processing streamed data regardless of the underlying protocol. We'll continue to maintain both packages, but new development will be in this project.
-
FastStream: the easiest way to add Kafka and RabbitMQ support to FastAPI services
FastStream (https://github.com/airtai/faststream) is a new Python framework, born from Propan and FastKafka teams' collaboration (both are deprecated now). It extremely simplifies event-driven system development, handling all the parsing, networking, and documentation generation automatically. Now FastStream supports RabbitMQ and Kafka, but supported brokers are constantly growing (wait for NATS and Redis a bit). FastStream itself is a really great tool to build event-driven services. Also, it has a native FastAPI integration. Just create a StreamRouter (very close to APIRouter) and register event handlers the same with the regular HTTP-endpoints way:
-
Propan – Python Framework for building messaging services has a big update
Hello everyone!
Two months ago I told you about Propan - the Python framework to build messaging services based on Any Message Broker. So, there were a lot of changes for this time and I want you to tell me again about them.
At first, we added Kafka, Redis Pub/Sub, SQS, and NatsJS support (to RabbitMQ and regular NATS). At now you can interact with these brokers via the same Propan interfaces.
Also, we added an AsyncAPI schema autogeneration, so you already have documentation for your services if you are using Propan.
And the last (but not least) - PydanticV2 support! You can use V1 and V2 both, but V2 is much faster - it is a preferred way to write new services.
By the way: we have a new Propan major version draft, so if you want to participate in the discussion and suggest a new feature, it is time to join our discord and tell about it!
Propan: https://github.com/Lancetnik/Propan
- Looking for Python contributors to a new Messaging Framework
-
Help wanted: support for PR
Also it is important for my own Propan package implementing some custom routers.
- FLaNK Stack Weekly 29 may 2023
-
Propan is a best way to interact SQS from Python
As you may know, I am developing Propan framework to interact with various message brokers single way. When I published a post about the existence of the framework, users immediately asked "When to expect SQS support?". Now!
-
Propan 0.1.2 - new way to interact with Kafka from Python
A couple of days ago I wrote about the release of my framework for working with various message brokers - Propan!
pydantic
-
Advanced RAG with guided generation
First, note the method prefix_allowed_tokens_fn. This method applies a Pydantic model to constrain/guide how the LLM generates tokens. Next, see how that constrain can be applied to txtai's LLM pipeline.
-
utype VS pydantic - a user suggested alternative
2 projects | 15 Feb 2024
utype is a concise alternative of pydantic with simplified parameters and usages, supporting both sync/async functions and generators parsing, and capable of using native logic operators to define logical types like AND/OR/NOT, also provides custom type parsing by register mechanism that supports libraries like pydantic, attrs and dataclasses
- Pydantic v2 ruined the elegance of Pydantic v1
-
Ask HN: Pydantic has too much deprecation. Why is it popular?
I like some of the changes from v1 to v2. But then you have something like this [0] removed from the library without proper documentation or replacement, resulting in ugly workarounds in the link that wont' work properly.
[0]: https://github.com/pydantic/pydantic/discussions/6337
- OpenAI uses Pydantic for their ChatCompletions API
-
🍹GinAI - Cocktails mixed with generative AI
The easiest implementation I found was to use a PyDantic class for my target schema — and use that as a parameter for the method call to “ChatCompletion.create()”. Here’s a fragment of the GinAI Python classes used.
-
FastStream: Python's framework for Efficient Message Queue Handling
Also, FastStream uses Pydantic to parse input JSON-encoded data into Python objects, making it easy to work with structured data in your applications, so you can serialize your input messages just using type annotations.
-
Introducing FastStream: the easiest way to write microservices for Apache Kafka and RabbitMQ in Python
Pydantic Validation: Leverage Pydantic's validation capabilities to serialize and validate incoming messages
-
Cannot get Langchain to work
Not sure if it is exactly related, but there is an open issue on Github for that exact message.
-
FastAPI 0.100.0:Release Notes
Well the performance increase is so huge because pydantic1 is really really slow. And for using rust, I'd have expected more tbh…
I've been benchmarking pydantic v2 against typedload (which I write) and despite the rust, it still manages to be slower than pure python in some benchmarks.
The ones on the website are still about comparing to v1 because v2 was not out yet at the time of the last release.
pydantic's author will refuse to benchmark any library that is faster (https://github.com/pydantic/pydantic/pull/3264 https://github.com/pydantic/pydantic/pull/1525 https://github.com/pydantic/pydantic/pull/1810) and keep boasting about amazing performances.
On pypy, v2 beta was really really really slow.
What are some alternatives?
DB-GPT - AI Native Data App Development framework with AWEL(Agentic Workflow Expression Language) and Agents
Cerberus - Lightweight, extensible data validation library for Python
faststream - FastStream is a powerful and easy-to-use Python framework for building asynchronous services interacting with event streams such as Apache Kafka, RabbitMQ, NATS and Redis.
nexe - 🎉 create a single executable out of your node.js apps
kafka-native - Kafka broker compiled to native using Quarkus and GraalVM.
msgspec - A fast serialization and validation library, with builtin support for JSON, MessagePack, YAML, and TOML
fastgron - High-performance JSON to GRON (greppable, flattened JSON) converter
SQLAlchemy - The Database Toolkit for Python
bunny-storm - RabbitMQ asynchronous connector library for Python with built in RPC support
sqlmodel - SQL databases in Python, designed for simplicity, compatibility, and robustness.
FastDepends - FastDepends - FastAPI Dependency Injection system extracted from FastAPI and cleared of all HTTP logic. Async and sync modes are both supported.
mypy - Optional static typing for Python