tessl install tessl/pypi-rodi@2.0.0Implementation of dependency injection for Python 3
Agent Success
Agent success rate when using this tile
92%
Improvement
Agent success rate improvement when using this tile compared to baseline
1.06x
Baseline
Agent success rate without this tile
87%
{
"context": "This criteria evaluates how effectively the engineer uses rodi's generic type support features to implement a type-safe configuration management system. The focus is on proper registration and resolution of List[T], Dict[K,V], and Optional[T] generic types through the dependency injection container.",
"type": "weighted_checklist",
"checklist": [
{
"name": "List[T] Factory Registration",
"description": "Uses add_scoped_by_factory() or add_singleton_by_factory() to register a factory that returns List[DatabaseConfig] with the correct return_type parameter (e.g., return_type=List[DatabaseConfig])",
"max_score": 20
},
{
"name": "Dict[K,V] Factory Registration",
"description": "Uses add_scoped_by_factory() or add_singleton_by_factory() to register a factory that returns Dict[str, ApiEndpoint] with the correct return_type parameter (e.g., return_type=Dict[str, ApiEndpoint])",
"max_score": 20
},
{
"name": "Optional[T] Factory Registration",
"description": "Uses add_scoped_by_factory() or add_singleton_by_factory() to register a factory that returns Optional[List[FeatureFlag]] or List[FeatureFlag] with the correct return_type parameter (e.g., return_type=Optional[List[FeatureFlag]])",
"max_score": 15
},
{
"name": "Type-Annotated Constructor",
"description": "ConfigurationService class uses type annotations in its __init__ method or as class annotations for all parameters (e.g., database_configs: List[DatabaseConfig], endpoint_configs: Dict[str, ApiEndpoint], feature_flags: Optional[List[FeatureFlag]])",
"max_score": 15
},
{
"name": "Service Class Registration",
"description": "Registers ConfigurationService and ApplicationBootstrap classes with the container using container.register() or container.add_transient()/add_singleton()",
"max_score": 10
},
{
"name": "Provider Build and Resolution",
"description": "Calls container.build_provider() to create the provider and uses provider.get() to resolve services correctly",
"max_score": 10
},
{
"name": "Correct Generic Types",
"description": "All generic type registrations match the type annotations in consuming classes (List matches List, Dict matches Dict, Optional matches Optional with the same inner types)",
"max_score": 10
}
]
}