Scala idioms ref
[COLM'26] SkillLearnBench is the first benchmark for evaluating continual learning methods that automatically generate agent skills.From the repository description
npx -y skills add cxcscmu/SkillLearnBench --skill scala-idioms-refAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
SKILL.md
1.1 KB, 334 tokens by cl100k_base, as published. Nobody here has run it
name: scala-idioms-ref description: Idiomatic Scala patterns for common Python idioms. Use this to translate Pythonic code into idiomatic Scala 2.13. Covers case classes, Option/Either, pattern matching, collections, and higher-order functions.
Idiomatic Translations (Python -> Scala)
1. Data Structures
- Python:
@dataclass(frozen=True)-> Scala:case class Token(value: String, tokenType: TokenType, metadata: Map[String, Any] = Map.empty) - Python:
Union[str, int]-> Scala:sealed trait ValueType; case class StringVal(v: String) extends ValueType; ...(ADT) - Python:
list[T]-> Scala:List[T]orSeq[T](immutable)
2. Control Flow
- Python:
if x is None: ...-> Scala:x match { case None => ... }orx.fold(...) - Python:
for v in values: yield v-> Scala:values.iterator
3. Error Handling
- Python:
try...except/raise-> Scala:Try { ... }orEither[Error, Result]
4. Functional Programming
- Python:
Callable[[T], R]-> Scala:T => R - Python:
list comprehension-> Scala:list.map(f)orfor { x <- list } yield f(x)
What ships with it
Read from the repository
Just SKILL.md. No reference files, no scripts.